org.rapla.entities.domain
Interface Allocatable

All Superinterfaces:
Classifiable, Entity, Named, RaplaObject

public interface Allocatable
extends Entity, RaplaObject, Named, Classifiable

Objects that implement allocatable can be allocated by reservations.

See Also:
Reservation

Field Summary
static Allocatable[] ALLOCATABLE_ARRAY
          Static empty dummy Array.
static RaplaType TYPE
           
 
Fields inherited from interface org.rapla.entities.Entity
ENTITY_ARRAY
 
Fields inherited from interface org.rapla.entities.dynamictype.Classifiable
CLASSIFIABLE_ARRAY
 
Method Summary
 void addPermission(Permission permission)
           
 boolean canAllocate(User user, Date start, Date end, Date today)
          returns if the user has the permission to allocate the resource in the given time.
 boolean canCreateConflicts(User user)
          returns if the user has the permission to create a conflict for the resource.
 boolean canModify(User user)
          returns if the user has the permission to modify the allocatable (and also its permission-table).
 boolean canRead(User user)
          returns if the user has the permission to read the allocations of this resource.
 Permission[] getPermissions()
           
 boolean isHoldBackConflicts()
           
 boolean isPerson()
           
 Permission newPermission()
           
 boolean removePermission(Permission permission)
           
 void setHoldBackConflicts(boolean enable)
          Conflicts for this allocatable should be ignored, if this flag is enabled.
 
Methods inherited from interface org.rapla.entities.Entity
isIdentical, isPersistant
 
Methods inherited from interface org.rapla.entities.RaplaObject
getRaplaType
 
Methods inherited from interface org.rapla.entities.Named
getName
 
Methods inherited from interface org.rapla.entities.dynamictype.Classifiable
getClassification, setClassification
 

Field Detail

TYPE

static final RaplaType TYPE

ALLOCATABLE_ARRAY

static final Allocatable[] ALLOCATABLE_ARRAY
Static empty dummy Array. Mainly for using the toArray() method of the collection interface

Method Detail

setHoldBackConflicts

void setHoldBackConflicts(boolean enable)
Conflicts for this allocatable should be ignored, if this flag is enabled.


isHoldBackConflicts

boolean isHoldBackConflicts()

addPermission

void addPermission(Permission permission)

removePermission

boolean removePermission(Permission permission)

canAllocate

boolean canAllocate(User user,
                    Date start,
                    Date end,
                    Date today)
returns if the user has the permission to allocate the resource in the given time. It returns true if for at least one permission calling permission.covers() and permission.affectsUser yields true.


canCreateConflicts

boolean canCreateConflicts(User user)
returns if the user has the permission to create a conflict for the resource.


canModify

boolean canModify(User user)
returns if the user has the permission to modify the allocatable (and also its permission-table).


canRead

boolean canRead(User user)
returns if the user has the permission to read the allocations of this resource.


getPermissions

Permission[] getPermissions()

newPermission

Permission newPermission()

isPerson

boolean isPerson()


Copyright © 2000-2006 Rapla Team. All Rights Reseserved.