Package org.deltava.security.command
Class TourAccessControl
java.lang.Object
org.deltava.security.command.AccessControl
org.deltava.security.command.TourAccessControl
- All Implemented Interfaces:
Serializable
An Access Controller for Tour beans.
- Since:
- 10.0
- Version:
- 10.3
- Author:
- Luke
- See Also:
-
Field Summary
Fields inherited from class org.deltava.security.command.AccessControl
_ctx
-
Constructor Summary
ConstructorDescriptionTourAccessControl
(SecurityContext ctx, Tour t) Initializes the access controller. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns whether the user can create a new Tour.boolean
Returns whether the user can delete this Tour.boolean
Returns whether the user can edit this Tour metadata.boolean
Returns whether the user can modify this Tour's Flight legs.boolean
Returns whether the user can read a Tour profile.void
validate()
Calculates access control rightsMethods inherited from class org.deltava.security.command.AccessControl
validateContext
-
Constructor Details
-
TourAccessControl
Initializes the access controller.- Parameters:
ctx
- the command contextt
- the Tour
-
-
Method Details
-
validate
public void validate()Description copied from class:AccessControl
Calculates access control rights- Specified by:
validate
in classAccessControl
-
getCanCreate
public boolean getCanCreate()Returns whether the user can create a new Tour.- Returns:
- TRUE if the user can create a Tour, otherwise FALSE
-
getCanRead
public boolean getCanRead()Returns whether the user can read a Tour profile.- Returns:
- TRUE if the user can read the Tour, otherwise FALSE
-
getCanEdit
public boolean getCanEdit()Returns whether the user can edit this Tour metadata.- Returns:
- TRUE if the user can edit the Tour, otherwise FALSE
-
getCanEditLegs
public boolean getCanEditLegs()Returns whether the user can modify this Tour's Flight legs.- Returns:
- TRUE if the user can edit the legs, otherwise FALSE
-
getCanDelete
public boolean getCanDelete()Returns whether the user can delete this Tour.- Returns:
- TRUE if the user can delete the Tour, otherwise FALSE
-