BrightSide Workbench Full Report + Source Code
org.turro.dossier.user.menu.DossierUserMenu Class Reference
Inheritance diagram for org.turro.dossier.user.menu.DossierUserMenu:
Collaboration diagram for org.turro.dossier.user.menu.DossierUserMenu:

Public Member Functions

 DossierUserMenu ()
 
void initMenu ()
 
boolean isInRole ()
 
Object getDetail ()
 
- Public Member Functions inherited from org.turro.elephant.user.menu.DefaultUserMenu
 DefaultUserMenu (String label, String image)
 
 DefaultUserMenu (String label, String image, String link)
 
 DefaultUserMenu (String label, String image, Function< IUserMenu, Boolean > command)
 
 DefaultUserMenu (String label, String image, int order)
 
 DefaultUserMenu (String label, String image, String link, int order)
 
 DefaultUserMenu (String id, String label, String image, Function< IUserMenu, Boolean > command, int order)
 
String getId ()
 
String getLabel ()
 
String getImage ()
 
int getOrder ()
 
String getLink ()
 
boolean isValid ()
 
boolean isCaption ()
 
boolean isOnlyLabel ()
 
boolean isOnlyImage ()
 
boolean isActive ()
 
IUserMenu getParent ()
 
Set< IUserMenugetChildren ()
 
IUserMenu addChild (IUserMenu menu)
 
boolean execute ()
 
int compareTo (IUserMenu o)
 
boolean isHidden ()
 

Additional Inherited Members

- Protected Member Functions inherited from org.turro.elephant.user.menu.DefaultUserMenu
 DefaultUserMenu (String id, String label, String image, String link, Function< IUserMenu, Boolean > command, int order)
 
void setOrder (int order)
 
- Protected Attributes inherited from org.turro.elephant.user.menu.DefaultUserMenu
IUserMenu parent
 
Set< IUserMenuchildren
 
String id
 
int order
 
Function< IUserMenu, Boolean > command
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 31 of file DossierUserMenu.java.

Constructor & Destructor Documentation

◆ DossierUserMenu()

org.turro.dossier.user.menu.DossierUserMenu.DossierUserMenu ( )

Definition at line 33 of file DossierUserMenu.java.

33  {
34  super("Dossiers", null, null, 5);
35  }

Member Function Documentation

◆ getDetail()

Object org.turro.dossier.user.menu.DossierUserMenu.getDetail ( )

Reimplemented from org.turro.elephant.user.menu.DefaultUserMenu.

Definition at line 117 of file DossierUserMenu.java.

117  {
118  return null;
119  }
Here is the caller graph for this function:

◆ initMenu()

void org.turro.dossier.user.menu.DossierUserMenu.initMenu ( )

Reimplemented from org.turro.elephant.user.menu.DefaultUserMenu.

Definition at line 38 of file DossierUserMenu.java.

38  {
39  addChild(new DefaultUserMenu("My dossiers", null, "/user/mydossiers") {
40  @Override
41  public boolean isInRole() {
42  return Application.getApplication().isInRole("dossier:list");
43  }
44  @Override
45  public Object getDetail() {
46  return UserSummaries.getAttribute("dossierCount");
47  }
48  });
49  addChild(new DefaultUserMenu("My projects", null, "/user/myprojects") {
50  @Override
51  public boolean isInRole() {
52  return Application.getApplication().isInRole("dossier:list");
53  }
54  @Override
55  public Object getDetail() {
56  return UserSummaries.getAttribute("projectCount");
57  }
58  });
59  addChild(new DefaultUserMenu("My issues", null, "/user/myissues") {
60  @Override
61  public boolean isInRole() {
62  return Application.getApplication().isInRole("issue:list");
63  }
64  @Override
65  public Object getDetail() {
66  return UserSummaries.getAttribute("issueOpenCount");
67  }
68  });
69  addChild(new DefaultUserMenu("Knowledge base", null, "/user/kbase") {
70  @Override
71  public boolean isInRole() {
72  return true;
73  }
74  @Override
75  public Object getDetail() {
76  return null;
77  }
78  });
79  addChild(new DefaultUserMenu("Project grants", null, "/user/projectgrants") {
80  @Override
81  public boolean isInRole() {
82  return Application.getApplication().isInRole("dossier:list");
83  }
84  @Override
85  public Object getDetail() {
86  return null;
87  }
88  });
89  addChild(new DefaultUserMenu("Pending revision", null, "/user/pendingrevision") {
90  @Override
91  public boolean isInRole() {
92  return Application.getApplication().isInRole("issue:list");
93  }
94  @Override
95  public Object getDetail() {
96  return UserSummaries.getAttribute("pendingCount");
97  }
98  });
99  addChild(new DefaultUserMenu("Report issue", null, "/user/newissue") {
100  @Override
101  public boolean isInRole() {
102  return Application.getApplication().isInRole("issue:list");
103  }
104  @Override
105  public Object getDetail() {
106  return null;
107  }
108  });
109  }
Here is the call graph for this function:

◆ isInRole()

boolean org.turro.dossier.user.menu.DossierUserMenu.isInRole ( )

Reimplemented from org.turro.elephant.user.menu.DefaultUserMenu.

Definition at line 112 of file DossierUserMenu.java.

112  {
113  return !isHidden() && !Application.getApplication().getConstructor().isOutsider();
114  }
Here is the call graph for this function:
Here is the caller graph for this function:

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