- Author
- Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g Role = {role1 = [value1, value2, ...], role2 = [...], ...}
Definition at line 43 of file ProfileMap.java.
◆ getProfilesInRole()
List<String> org.turro.elephant.impl.security.ProfileMap.getProfilesInRole |
( |
String |
role | ) |
|
Definition at line 54 of file ProfileMap.java.
55 List<String> profiles =
new ArrayList<String>();
56 for(String s : keySet()) {
60 else if(
get(s).isInRole(role)) {
◆ getRoleNames()
static List org.turro.elephant.impl.security.ProfileMap.getRoleNames |
( |
| ) |
throws IOException |
|
static |
Definition at line 135 of file ProfileMap.java.
136 List<String> names =
new ArrayList<String>();
138 names.add(a.getValue());
static List loadRoleByExpression(String expression)
◆ getRoleNamesByFilter()
static List org.turro.elephant.impl.security.ProfileMap.getRoleNamesByFilter |
( |
String |
filter | ) |
throws IOException |
|
static |
Definition at line 143 of file ProfileMap.java.
144 List<String> names =
new ArrayList<String>();
145 for(Attribute a : (List<Attribute>)
loadRoleByExpression(
"/xproles/role[resource/@name='" + filter +
"']/@name")) {
146 names.add(a.getValue());
◆ isInRoleByProfile()
boolean org.turro.elephant.impl.security.ProfileMap.isInRoleByProfile |
( |
String |
profile, |
|
|
String |
role |
|
) |
| |
Definition at line 45 of file ProfileMap.java.
47 if(containsKey(profile)) {
48 return get(profile).isInRole(role);
◆ loadProfiles()
static ProfileMap org.turro.elephant.impl.security.ProfileMap.loadProfiles |
( |
| ) |
throws IOException |
|
static |
◆ loadRoleByExpression()
static List org.turro.elephant.impl.security.ProfileMap.loadRoleByExpression |
( |
String |
expression | ) |
throws IOException |
|
static |
Definition at line 107 of file ProfileMap.java.
108 List roles =
new ArrayList();
112 if(l !=
null) roles.addAll(l);
114 new File(ElephantContext.getRealPath(ROLES_SITE_CONFIGURATION)),
116 if(l !=
null) roles.addAll(l);
static List loadRoleFile(File confFile, String expression)
static final String ROLES_CONFIGURATION
◆ loadRoleFile()
static List org.turro.elephant.impl.security.ProfileMap.loadRoleFile |
( |
File |
confFile, |
|
|
String |
expression |
|
) |
| throws IOException |
|
static |
Definition at line 120 of file ProfileMap.java.
121 if (confFile.exists()) {
122 SAXBuilder builder =
new SAXBuilder();
124 Document doc = builder.build(confFile);
125 return XPath.selectNodes(doc, expression);
126 }
catch (IOException ex) {
127 Logger.getLogger(ProfileMap.class.getName()).log(Level.SEVERE, ElephantContext.logMsg(
null), ex);
128 }
catch (JDOMException ex) {
129 Logger.getLogger(XpUser.class.getName()).log(Level.SEVERE, ElephantContext.logMsg(
null), ex);
◆ resetProfiles()
static void org.turro.elephant.impl.security.ProfileMap.resetProfiles |
( |
| ) |
|
|
static |
◆ ROLES_CONFIGURATION
final String org.turro.elephant.impl.security.ProfileMap.ROLES_CONFIGURATION = "/WEB-INF/elephant/conf/xproles.xml" |
|
static |
The documentation for this class was generated from the following file: