Package org.apache.ofbiz.content.content
Class PermissionRecorder
java.lang.Object
org.apache.ofbiz.content.content.PermissionRecorder
PermissionRecorder Class
Services for granting operation permissions on Content entities in a data-driven manner.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
Gets check mode.Get content purpose operations generic value [ ].Gets current content id.boolean
Gets entity perm check result.Gets privilege enum id.String[]
Get status targets string [ ].String[]
Get target operations string [ ].Gets user login.boolean
isOn()
Is on boolean.void
record
(GenericValue purposeOp, boolean targetOpCond, boolean purposeCond, boolean statusCond, boolean privilegeCond, boolean roleCond) Record.Render current content map html string.Render result row html string.void
setCheckMode
(int val) Sets check mode.void
setContentPurposeOperations
(List<GenericValue> opList) Sets content purpose operations.void
Sets current content id.void
setEntityPermCheckResult
(boolean b) Sets entity perm check result.void
setOn
(boolean b) Sets on.void
Sets privilege enum id.void
setPurposes
(List<String> purposes) Sets purposes.void
Sets roles.void
setStatusTargets
(List<String> opList) Sets status targets.void
setTargetOperations
(List<String> opList) Sets target operations.void
setUserLogin
(GenericValue user) Sets user login.void
startMatchGroup
(List<String> targetOperations, List<String> purposes, List<String> roles, List<String> targStatusList, String targPrivilegeEnumId, String contentId) Start match group.toHtml()
To html string.
-
Constructor Details
-
PermissionRecorder
public PermissionRecorder()
-
-
Method Details
-
getCheckMode
public int getCheckMode()Gets check mode.- Returns:
- the check mode
-
setCheckMode
public void setCheckMode(int val) Sets check mode.- Parameters:
val
- the val
-
isOn
public boolean isOn()Is on boolean.- Returns:
- the boolean
-
setOn
public void setOn(boolean b) Sets on.- Parameters:
b
- the b
-
getUserLogin
Gets user login.- Returns:
- the user login
-
setUserLogin
Sets user login.- Parameters:
user
- the user
-
getEntityPermCheckResult
public boolean getEntityPermCheckResult()Gets entity perm check result.- Returns:
- the entity perm check result
-
setEntityPermCheckResult
public void setEntityPermCheckResult(boolean b) Sets entity perm check result.- Parameters:
b
- the b
-
getContentPurposeOperations
Get content purpose operations generic value [ ].- Returns:
- the generic value [ ]
-
setContentPurposeOperations
Sets content purpose operations.- Parameters:
opList
- the op list
-
getPrivilegeEnumId
Gets privilege enum id.- Returns:
- the privilege enum id
-
setPrivilegeEnumId
Sets privilege enum id.- Parameters:
id
- the id
-
getStatusTargets
Get status targets string [ ].- Returns:
- the string [ ]
-
setStatusTargets
Sets status targets.- Parameters:
opList
- the op list
-
getTargetOperations
Get target operations string [ ].- Returns:
- the string [ ]
-
setTargetOperations
Sets target operations.- Parameters:
opList
- the op list
-
setCurrentContentId
Sets current content id.- Parameters:
id
- the id
-
getCurrentContentId
Gets current content id.- Returns:
- the current content id
-
setRoles
Sets roles.- Parameters:
roles
- the roles
-
setPurposes
Sets purposes.- Parameters:
purposes
- the purposes
-
startMatchGroup
public void startMatchGroup(List<String> targetOperations, List<String> purposes, List<String> roles, List<String> targStatusList, String targPrivilegeEnumId, String contentId) Start match group.- Parameters:
targetOperations
- the target operationspurposes
- the purposesroles
- the rolestargStatusList
- the targ status listtargPrivilegeEnumId
- the targ privilege enum idcontentId
- the content id
-
record
public void record(GenericValue purposeOp, boolean targetOpCond, boolean purposeCond, boolean statusCond, boolean privilegeCond, boolean roleCond) Record.- Parameters:
purposeOp
- the purpose optargetOpCond
- the target op condpurposeCond
- the purpose condstatusCond
- the status condprivilegeCond
- the privilege condroleCond
- the role cond
-
toHtml
To html string.- Returns:
- the string
-
renderCurrentContentMapHtml
Render current content map html string.- Parameters:
cMap
- the c map- Returns:
- the string
-
renderResultRowHtml
public String renderResultRowHtml(Map<String, Object> rMap, Map<String, Object> currentContentResultMap) Render result row html string.- Parameters:
rMap
- the r mapcurrentContentResultMap
- the current content result map- Returns:
- the string
-