◆ AttachResults()
org.turro.attach.search.AttachResults.AttachResults |
( |
| ) |
|
◆ addCriteria()
void org.turro.attach.search.AttachResults.addCriteria |
( |
WhereClause |
wc | ) |
|
Definition at line 94 of file AttachResults.java.
96 if(Strings.isEmpty(attachValue) || (ckOthers && app!=
null && !app.
isInRole(
"attach-show:all"))) {
100 if(byParticipant ==
null) {
101 byParticipant = Authentication.getIContact();
104 wc = SQLHelper.getWhereClause(wc,
new String[] {
105 "attachment.fileName"
106 }, (attachValue ==
null ?
"" : attachValue.replaceAll(
"\\*",
"%")));
108 if(!(ckOthers && app!=
null && app.
isInRole(
"attach-show:all")) && byParticipant !=
null) {
109 wc.addClause(
"and (");
111 wc.addClause(
"attachment.onlyOwner = false");
115 wc.addClause(
"(attachment.onlyOwner = true and attachment.owner = :idOwner)");
116 wc.addNamedValue(
"idOwner", byParticipant.
getId());
122 wc.addClause(
"and attachment.validated = false");
126 wc.addClause(
"and attachment.publishable = true");
129 if(attachPath !=
null) {
130 wc.addClause(
"and UCASE(attachment.path) " +
131 (ckExactPath ?
"=" :
"like") +
133 wc.addNamedValue(
"path", attachPath);
boolean isInRole(String role)
◆ getAttachmentList()
java.util.List<Attachment> org.turro.attach.search.AttachResults.getAttachmentList |
( |
| ) |
|
Definition at line 62 of file AttachResults.java.
63 Dao dao =
new AttachPU();
64 WhereClause wc =
new WhereClause();
65 wc.addClause(
"select distinct attachment from Attachment as attachment");
66 wc.addClause(
"where 1=1");
68 wc.addClause(
"order by attachment.fileName, attachment.modification DESC");
69 return new AttachmentList(dao.getResultList(wc), ckOthers && app!=
null && app.
isInRole(
"attach-show:all"));
void addCriteria(WhereClause wc)
◆ getAttachPath()
String org.turro.attach.search.AttachResults.getAttachPath |
( |
| ) |
|
◆ getAttachValue()
String org.turro.attach.search.AttachResults.getAttachValue |
( |
| ) |
|
◆ getByParticipant()
IContact org.turro.attach.search.AttachResults.getByParticipant |
( |
| ) |
|
◆ getCountAttachments()
static long org.turro.attach.search.AttachResults.getCountAttachments |
( |
String |
root | ) |
|
|
static |
Definition at line 185 of file AttachResults.java.
186 Dao dao =
new AttachPU();
187 return (Long) dao.getSingleResult(
188 " select count(attachment) " +
189 " from Attachment as attachment" +
190 " where attachment.path like '" + root +
"/%'");
◆ getPathList()
java.util.Set<String> org.turro.attach.search.AttachResults.getPathList |
( |
String |
currPath | ) |
|
Definition at line 84 of file AttachResults.java.
85 Dao dao =
new AttachPU();
86 WhereClause wc =
new WhereClause();
87 wc.addClause(
"select distinct attachment.path from Attachment as attachment");
88 wc.addClause(
"where 1=1");
90 wc.addClause(
"order by attachment.path");
91 return new PathSet(dao.getResultList(wc), currPath, ckOthers && app!=
null && app.
isInRole(
"attach-show:all"));
◆ getVersionedAttachmentList()
java.util.List<Attachment> org.turro.attach.search.AttachResults.getVersionedAttachmentList |
( |
| ) |
|
Definition at line 72 of file AttachResults.java.
73 AttachVersionMap avm =
new AttachVersionMap();
77 ArrayList<Attachment> list =
new ArrayList<>();
78 for(AttachVersionSet avs : avm.values()) {
79 list.add(avs.first());
java.util.List< Attachment > getAttachmentList()
◆ isCkExactPath()
boolean org.turro.attach.search.AttachResults.isCkExactPath |
( |
| ) |
|
◆ isCkNonValidated()
boolean org.turro.attach.search.AttachResults.isCkNonValidated |
( |
| ) |
|
◆ isCkOthers()
boolean org.turro.attach.search.AttachResults.isCkOthers |
( |
| ) |
|
◆ isPublicOnly()
boolean org.turro.attach.search.AttachResults.isPublicOnly |
( |
| ) |
|
◆ markAll()
void org.turro.attach.search.AttachResults.markAll |
( |
| ) |
|
◆ setAttachPath()
void org.turro.attach.search.AttachResults.setAttachPath |
( |
String |
attachPath | ) |
|
◆ setAttachValue()
void org.turro.attach.search.AttachResults.setAttachValue |
( |
String |
attachValue | ) |
|
◆ setByParticipant()
void org.turro.attach.search.AttachResults.setByParticipant |
( |
IContact |
byParticipant | ) |
|
◆ setCkExactPath()
void org.turro.attach.search.AttachResults.setCkExactPath |
( |
boolean |
ckExactPath | ) |
|
◆ setCkNonValidated()
void org.turro.attach.search.AttachResults.setCkNonValidated |
( |
boolean |
ckNonValidated | ) |
|
◆ setCkOthers()
void org.turro.attach.search.AttachResults.setCkOthers |
( |
boolean |
ckOthers | ) |
|
◆ setPublicOnly()
void org.turro.attach.search.AttachResults.setPublicOnly |
( |
boolean |
publicOnly | ) |
|
The documentation for this class was generated from the following file: