Class ModelPermission

java.lang.Object
org.apache.ofbiz.service.ModelPermission
All Implemented Interfaces:
Serializable

public class ModelPermission extends Object implements Serializable
Service Permission Model Class
See Also:
  • Constructor Details

    • ModelPermission

      public ModelPermission()
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • evalPermission

      public Map<String,Object> evalPermission(DispatchContext dctx, Map<String,? extends Object> context)
      Eval permission map.
      Parameters:
      dctx - the dctx
      context - the context
      Returns:
      the map
    • setPermissionServiceName

      public void setPermissionServiceName(String permissionServiceName)
      Sets permission service name.
      Parameters:
      permissionServiceName - the permission service name
    • setPermissionType

      public void setPermissionType(int permissionType)
      Sets permission type.
      Parameters:
      permissionType - the permission type
    • setPermissionMainAction

      public void setPermissionMainAction(String permissionMainAction)
      Sets permission main action.
      Parameters:
      permissionMainAction - the permission main action
    • setPermissionResourceDesc

      public void setPermissionResourceDesc(String permissionResourceDesc)
      Sets permission resource desc.
      Parameters:
      permissionResourceDesc - the permission resource desc
    • setPermissionRequireNewTransaction

      public void setPermissionRequireNewTransaction(boolean permissionRequireNewTransaction)
      Sets permission require new transaction.
      Parameters:
      permissionRequireNewTransaction - the permission require new transaction
    • setPermissionReturnErrorOnFailure

      public void setPermissionReturnErrorOnFailure(boolean permissionReturnErrorOnFailure)
      Sets permission return error on failure.
      Parameters:
      permissionReturnErrorOnFailure - the permission return error on failure
    • setNameOrRole

      public void setNameOrRole(String nameOrRole)
      Sets name or role.
      Parameters:
      nameOrRole - the name or role
    • setAction

      public void setAction(String action)
      Sets action.
      Parameters:
      action - the action
    • getPERMISSION

      public static int getPERMISSION()
    • getEntityPermission

      public static int getEntityPermission()
    • getAction

      public String getAction()
      Gets action.
      Returns:
      the action
    • setAuth

      public void setAuth(Boolean auth)
      Sets auth.
      Parameters:
      auth - the auth
    • setServiceModel

      public void setServiceModel(ModelService serviceModel)
      Sets service model.
      Parameters:
      serviceModel - the service model
    • getPermissionService

      public static int getPermissionService()
      Gets permission service.
      Returns:
      the permission service