BrightSide Workbench Full Report + Source Code
org.turro.alliance.content.ProjectGrantContentIterator Class Reference
Inheritance diagram for org.turro.alliance.content.ProjectGrantContentIterator:
Collaboration diagram for org.turro.alliance.content.ProjectGrantContentIterator:

Public Member Functions

 ProjectGrantContentIterator (IConstructor constructor, Writer writer, IContact contact, boolean mail, String pubPath)
 
String getProjectGrantUrl (WsMember member, AxProjectGrant projectGrant)
 
ProjectGrantCriteria getCriteria ()
 
- Public Member Functions inherited from org.turro.jpa.content.EntityDaoContentIterator< E, ID >
 EntityDaoContentIterator (Dao dao, IConstructor constructor, Writer writer, IContact contact, boolean mail, String contextPath)
 
void setSeenStatus (SeenStatusCheck seenStatus)
 
SeenStatusCheck getSeenStatus ()
 
String getId ()
 
String getContextPath ()
 
IContact getContact ()
 
boolean isMail ()
 
Object getVotesCtrl (E e)
 
Object getInterestCtrl (E e)
 
Object getCommentsCtrl (E e)
 
Object getAttachmentsCtrl (E e)
 
Object getFilesCtrl (E e)
 
Object getDescriptionsCtrl (E e)
 
Object getPollsCtrl (E e)
 
Object getForumCtrl (E e)
 
void assignDefaultsByName (String name)
 
void assignDefaultsByMacro (MacroProcessorContext context)
 
Object getParticipationCtrl (E e, ParticipationReason reason)
 
Object getSpamCtrl (E e)
 
Object getFollowCtrl (E e)
 
Object getSeenCtrl (E e)
 
Object getLikeCtrl (E e)
 
Object getApplyCtrl (E e)
 
Object getCtrlByLabel (String ctrl, E e, IContact contact)
 
- Public Member Functions inherited from org.turro.jpa.iterator.DaoHtmlIterator< E, ID >
 DaoHtmlIterator (Dao dao, ElephantMarker marker)
 
 DaoHtmlIterator (Dao dao, ElephantMarker marker, Writer writer)
 
void setSummaryTemplate (String summaryTemplate)
 
String getSummaryTemplate ()
 
void setFullTemplate (String fullTemplate)
 
String getFullTemplate ()
 
boolean isRestricted ()
 
void setRestricted (boolean restricted)
 
boolean isAllowInterest ()
 
void setAllowInterest (boolean allowInterest)
 
boolean isAllowComments ()
 
void setAllowComments (boolean allowComments)
 
boolean isAllowVotes ()
 
void setAllowVotes (boolean allowVotes)
 
boolean isAllowForum ()
 
void setAllowForum (boolean allowForum)
 
boolean isAllowDescriptions ()
 
void setAllowDescriptions (boolean allowDescriptions)
 
boolean isAllowAttachments ()
 
void setAllowAttachments (boolean allowAttachments)
 
boolean isAllowFiles ()
 
void setAllowFiles (boolean allowFiles)
 
boolean isAllowPolls ()
 
void setAllowPolls (boolean allowPolls)
 
boolean isAllowRanking ()
 
void setAllowRanking (boolean allowRanking)
 
boolean isAllowMatching ()
 
void setAllowMatching (boolean allowMatching)
 
boolean isDoMatching ()
 
void setDoMatching (boolean doMatching)
 
String getRankingInstance ()
 
void setRankingInstance (String rankingInstance)
 
String getMatchingInstance ()
 
void setMatchingInstance (String matchingInstance)
 
boolean isAllowSorting ()
 
void setAllowSorting (boolean allowSorting)
 
boolean isNavigatorTop ()
 
void setNavigatorTop (boolean navigatorTop)
 
boolean isNavigatorBottom ()
 
void setNavigatorBottom (boolean navigatorBottom)
 
DaoHtmlTree getNavigationTree ()
 
void setNavigationTree (DaoHtmlTree navigationTree)
 
DaoHtmlSearch getSearchEngine ()
 
void setSearchEngine (DaoHtmlSearch searchEngine)
 
boolean isSearchOption ()
 
void setSearchOption (boolean searchOption)
 
boolean isForceSummary ()
 
void setForceSummary (boolean forceSummary)
 
boolean wantItem ()
 
boolean isItem ()
 
boolean checkEntity (ID value)
 
Object addAttribute (String key, Object value)
 
Writer getWriter ()
 
void load ()
 
void forceItem (ID item)
 
String getTitle ()
 
Collection< String > getMetas ()
 
void render ()
 
boolean isFirst ()
 
boolean isLast ()
 
String renderSearchEngine ()
 
String renderTree ()
 
String renderTreeSelection ()
 
TagSet getCloudTags ()
 
TagSet getEntityTags (Object entity)
 
boolean isSeen (Object entity)
 
VisualElements getVisuals ()
 
boolean isEmpty ()
 
- Public Member Functions inherited from org.turro.jpa.iterator.DaoIterator< E, ID >
 DaoIterator (Dao dao)
 
int getPage ()
 
void setPage (int page)
 
List< E > getItems ()
 
int getTotalCount ()
 
List< E > getTotalItems ()
 
int item ()
 
void current (int value)
 
int current ()
 
int pages ()
 
boolean beginning ()
 
boolean end ()
 
void next ()
 
void previous ()
 

Protected Member Functions

WhereClause getWhereClause ()
 
WhereClause getCountClause ()
 
void renderSummary (ElephantMarker marker, AxProjectGrant e, int page)
 
void renderItem (ElephantMarker marker, AxProjectGrant e, int page)
 
String entityRoot ()
 
AxProjectGrant entity (ProcedenceId value)
 
ProcedenceId getIdentifier ()
 
String title (AxProjectGrant e)
 
Collection< String > metas (AxProjectGrant e)
 
String getTemplateRoot ()
 
Object doVotesCtrl (AxProjectGrant e)
 
Object doInterestCtrl (AxProjectGrant e)
 
Object doCommentsCtrl (AxProjectGrant e)
 
Object doAttachmentsCtrl (AxProjectGrant e)
 
Object doFilesCtrl (AxProjectGrant e)
 
Object doDescriptionsCtrl (AxProjectGrant e)
 
Object doPollsCtrl (AxProjectGrant e)
 
String getItemLink (AxProjectGrant project)
 
String getReadAllLink ()
 
String getRestrictedLink ()
 
String stringId (ProcedenceId value)
 
ProcedenceId parseId (String value)
 
- Protected Member Functions inherited from org.turro.jpa.content.EntityDaoContentIterator< E, ID >
void prepareControls (E entity, int page)
 
String doItemLink (E entity, ID id, boolean obfuscated)
 
abstract Object doVotesCtrl (E e)
 
abstract Object doInterestCtrl (E e)
 
abstract Object doCommentsCtrl (E e)
 
abstract Object doAttachmentsCtrl (E e)
 
abstract Object doFilesCtrl (E e)
 
abstract Object doDescriptionsCtrl (E e)
 
abstract Object doPollsCtrl (E e)
 
abstract String getItemLink (E e)
 
- Protected Member Functions inherited from org.turro.jpa.iterator.DaoHtmlIterator< E, ID >
VisualElements loadVisuals ()
 
abstract E entity (ID value)
 
abstract void renderSummary (ElephantMarker marker, E e, int page)
 
abstract void renderItem (ElephantMarker marker, E e, int page)
 
abstract String title (E e)
 
abstract Collection< String > metas (E e)
 
void renderForbidden (ElephantMarker marker, int page)
 
ID getIDFromURL (String root)
 
void preload ()
 
boolean isValid (E e)
 
boolean canShow (E e)
 
String stringId (ID value)
 
- Protected Member Functions inherited from org.turro.jpa.iterator.DaoIterator< E, ID >
void initClauses ()
 

Additional Inherited Members

- Static Public Attributes inherited from org.turro.action.content.IContentIterator
static String PRELOAD_TMPL = "#preload"
 
- Protected Attributes inherited from org.turro.jpa.iterator.DaoHtmlIterator< E, ID >
HTMLHelper html
 
IConstructor constructor
 
ElephantMarker marker
 
DaoHtmlSearch searchEngine
 
DaoHtmlTree navigationTree
 
- Protected Attributes inherited from org.turro.jpa.iterator.DaoIterator< E, ID >
List< E > items
 
Dao dao
 
int _total = -1
 

Detailed Description

Constructor & Destructor Documentation

◆ ProjectGrantContentIterator()

org.turro.alliance.content.ProjectGrantContentIterator.ProjectGrantContentIterator ( IConstructor  constructor,
Writer  writer,
IContact  contact,
boolean  mail,
String  pubPath 
)

Definition at line 56 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

56  {
57  super(new AlliancePU(), constructor, writer, contact, mail, pubPath);
58  this.criteria = new ProjectGrantCriteria();
59  }

Member Function Documentation

◆ doAttachmentsCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doAttachmentsCtrl ( AxProjectGrant  e)
protected

◆ doCommentsCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doCommentsCtrl ( AxProjectGrant  e)
protected

◆ doDescriptionsCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doDescriptionsCtrl ( AxProjectGrant  e)
protected

◆ doFilesCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doFilesCtrl ( AxProjectGrant  e)
protected

◆ doInterestCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doInterestCtrl ( AxProjectGrant  e)
protected

◆ doPollsCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doPollsCtrl ( AxProjectGrant  e)
protected

◆ doVotesCtrl()

Object org.turro.alliance.content.ProjectGrantContentIterator.doVotesCtrl ( AxProjectGrant  e)
protected

◆ entity()

AxProjectGrant org.turro.alliance.content.ProjectGrantContentIterator.entity ( ProcedenceId  value)
protected

Definition at line 118 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

118  {
119  processSearch();
120  WhereClause wc = createCriteria();
121  wc.addClause("and g.projectGrantId = :id");
122  wc.addNamedValue("id", value);
123  return (AxProjectGrant) dao.getSingleResultOrNull(wc);
124  }
Object getSingleResultOrNull(SqlClause sc)
Definition: Dao.java:419
Here is the call graph for this function:

◆ entityRoot()

String org.turro.alliance.content.ProjectGrantContentIterator.entityRoot ( )
protected

Reimplemented from org.turro.jpa.iterator.DaoHtmlIterator< E, ID >.

Definition at line 113 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

113  {
114  return "axproject-grant";
115  }

◆ getCountClause()

WhereClause org.turro.alliance.content.ProjectGrantContentIterator.getCountClause ( )
protected

Reimplemented from org.turro.jpa.iterator.DaoIterator< E, ID >.

Definition at line 90 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

90  {
91  processSearch();
92  return createCount();
93  }

◆ getCriteria()

ProjectGrantCriteria org.turro.alliance.content.ProjectGrantContentIterator.getCriteria ( )

◆ getIdentifier()

ProcedenceId org.turro.alliance.content.ProjectGrantContentIterator.getIdentifier ( )
protected

Reimplemented from org.turro.jpa.iterator.DaoHtmlIterator< E, ID >.

Definition at line 127 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

127  {
128  ProcedenceId identifier = getIDFromURL("/axproject-grant");
129  if(identifier == null) {
130  identifier = super.getIdentifier();
131  }
132  return identifier;
133  }
Here is the call graph for this function:

◆ getItemLink()

String org.turro.alliance.content.ProjectGrantContentIterator.getItemLink ( AxProjectGrant  project)
protected

Definition at line 311 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

311  {
312  return doItemLink(project, project.getProjectGrantId(), true);
313  }
String doItemLink(E entity, ID id, boolean obfuscated)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getProjectGrantUrl()

String org.turro.alliance.content.ProjectGrantContentIterator.getProjectGrantUrl ( WsMember  member,
AxProjectGrant  projectGrant 
)

Definition at line 61 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

61  {
62  if(ObjectUtils.allNotNull(member, projectGrant)) {
63  if(member.getMemberId() == projectGrant.getProjectGrantId().getMemberId()) {
64  return Interceptors.parameters("projectgrant", projectGrant.getProjectGrantId().getEntityId())
65  .url(member.getMemberUrl())
66  .encoded();
67  } else {
68  return Interceptors.parameters("axproject-grant", projectGrant.getId().replaceAll("#", "_"))
69  .add("server", ElephantContext.getSiteForcedDomain())
70  .url(member.getMemberUrl())
71  .encoded();
72  }
73  }
74  return "#";
75  }
Here is the call graph for this function:

◆ getReadAllLink()

String org.turro.alliance.content.ProjectGrantContentIterator.getReadAllLink ( )
protected

Reimplemented from org.turro.jpa.content.EntityDaoContentIterator< E, ID >.

Definition at line 316 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

316  {
317  String path = getContextPath();
318  if(Strings.isBlank(path)) {
319  path = ElephantContext.getEntityWebContext("/axproject-grant");
320  }
321  if(Strings.isBlank(path)) {
322  return getRestrictedLink();
323  }
324  return path;
325  }
Here is the call graph for this function:

◆ getRestrictedLink()

String org.turro.alliance.content.ProjectGrantContentIterator.getRestrictedLink ( )
protected

Reimplemented from org.turro.jpa.content.EntityDaoContentIterator< E, ID >.

Definition at line 328 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

328  {
329  return "/user/alliance/projectgrants";
330  }
Here is the caller graph for this function:

◆ getTemplateRoot()

String org.turro.alliance.content.ProjectGrantContentIterator.getTemplateRoot ( )
protected

Reimplemented from org.turro.jpa.content.EntityDaoContentIterator< E, ID >.

Definition at line 271 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

271  {
272  return isMail() ? "content/newsletter/sections/alliance/projectgrants" : "alliance/projectgrant";
273  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getWhereClause()

WhereClause org.turro.alliance.content.ProjectGrantContentIterator.getWhereClause ( )
protected

Reimplemented from org.turro.jpa.iterator.DaoIterator< E, ID >.

Definition at line 82 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

82  {
83  processSearch();
84  WhereClause wc = createCriteria();
85  wc.addClause("order by (case when g.endDate < now() then 1 else 0 end) asc, g.endDate asc, g.title");
86  return wc;
87  }
Here is the call graph for this function:

◆ metas()

Collection<String> org.turro.alliance.content.ProjectGrantContentIterator.metas ( AxProjectGrant  e)
protected

Definition at line 256 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

256  {
257  ArrayList<RepositoryFile> files = new ArrayList<>();
258  String path = getItemLink(e);
259  if(!SocialImageMap.hasImage(path)) {
260  FileAttach fa = new FileAttach(ContactsPU.getObjectPath(e));
261  Repository repository = fa.getPublishableRepository(constructor);
262  files.addAll(repository.getRepositoryFiles("*_social.png,*_social.jpg"));
263  files.addAll(repository.getRepositoryFiles("*.png,*.jpg"));
264  }
265  SocialNet sn;
266  sn = new SocialNet(path, e.getName(), e.getDescription(), files);
267  return sn.getMetas();
268  }
Here is the call graph for this function:

◆ parseId()

ProcedenceId org.turro.alliance.content.ProjectGrantContentIterator.parseId ( String  value)
protected

Reimplemented from org.turro.jpa.iterator.DaoHtmlIterator< E, ID >.

Definition at line 338 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

338  {
339  return ProcedenceId.from(value);
340  }
Here is the call graph for this function:

◆ renderItem()

void org.turro.alliance.content.ProjectGrantContentIterator.renderItem ( ElephantMarker  marker,
AxProjectGrant  e,
int  page 
)
protected

◆ renderSummary()

void org.turro.alliance.content.ProjectGrantContentIterator.renderSummary ( ElephantMarker  marker,
AxProjectGrant  e,
int  page 
)
protected

Definition at line 96 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

96  {
97  if(e != null) {
98  marker.put("projectGrant", e);
99  prepareValues(e, page);
100  }
102  }
Here is the call graph for this function:

◆ stringId()

String org.turro.alliance.content.ProjectGrantContentIterator.stringId ( ProcedenceId  value)
protected

Definition at line 333 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

333  {
334  return value.stringify();
335  }
Here is the call graph for this function:

◆ title()

String org.turro.alliance.content.ProjectGrantContentIterator.title ( AxProjectGrant  e)
protected

Definition at line 248 of file Elephant/elephant-alliance/src/main/java/org/turro/alliance/content/ProjectGrantContentIterator.java.

248  {
249  if(!Strings.isBlank(e.getName())) {
250  return e.getName();
251  }
252  return null;
253  }
Here is the call graph for this function:

The documentation for this class was generated from the following file: