com.dynalivery.repository.util
Class SecurityOptions

java.lang.Object
  |
  +--com.dynalivery.repository.util.SecurityOptions

public class SecurityOptions
extends java.lang.Object
implements java.io.Serializable

This class describes the desired security options when creating or modifying a repository file or folder.

See Also:
Serialized Form

Field Summary
static int USE_DEFAULTS
          Ordinal for security mode indicating folder defaults should be used
static int USE_LIST
          Ordinal for security mode indicating access list should be used
 
Constructor Summary
SecurityOptions()
          Public constructor with no parameters.
SecurityOptions(int readMode, java.lang.String readACL, int writeMode, java.lang.String writeACL)
          Public constructor for setting security options explicitly This allows security modes and access control lists to be explicitly set
SecurityOptions(java.lang.String readACL, java.lang.String writeACL)
          Public constructor with the read/write access control lists to be used.
 
Method Summary
 java.lang.String getModeString(int mode, java.lang.String acl)
          Returns a String which describes the specifed security mode and ACL String
 java.lang.String getReadACL()
          returns the read Access Control List
 int getReadMode()
          returns the read security mode for this repository object
 java.lang.String getWriteACL()
          returns the write Access Control List
 int getWriteMode()
          returns the write security mode for this repository object
 java.lang.String toString()
          Returns a String which describes these security options
 void validate()
          Validates the security options
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

USE_DEFAULTS

public static final int USE_DEFAULTS
Ordinal for security mode indicating folder defaults should be used

USE_LIST

public static final int USE_LIST
Ordinal for security mode indicating access list should be used
Constructor Detail

SecurityOptions

public SecurityOptions()
Public constructor with no parameters. This indicates the folder defaults should be used.

SecurityOptions

public SecurityOptions(java.lang.String readACL,
                       java.lang.String writeACL)
Public constructor with the read/write access control lists to be used.
Parameters:
readACL - the read access control list for this repository object
writeACL - the read access control list for this repository object

SecurityOptions

public SecurityOptions(int readMode,
                       java.lang.String readACL,
                       int writeMode,
                       java.lang.String writeACL)
Public constructor for setting security options explicitly This allows security modes and access control lists to be explicitly set
Parameters:
readMode - the read security mode for this repository object
readACL - the read access control list for this repository object
writeMode - the read security mode for this repository object
writeACL - the read access control list for this repository object
Method Detail

getReadMode

public int getReadMode()
returns the read security mode for this repository object
Returns:
the read security mode for this repository object

getReadACL

public java.lang.String getReadACL()
returns the read Access Control List
Returns:
the read Access Control List

getWriteMode

public int getWriteMode()
returns the write security mode for this repository object
Returns:
the write security mode for this repository object

getWriteACL

public java.lang.String getWriteACL()
returns the write Access Control List
Returns:
the write Access Control List

validate

public void validate()
              throws InvalidParameterException
Validates the security options
Throws:
InvalidParameterException - if options are invalid

getModeString

public java.lang.String getModeString(int mode,
                                      java.lang.String acl)
Returns a String which describes the specifed security mode and ACL String
Returns:
a String which describes the specifed security mode and ACL String

toString

public java.lang.String toString()
Returns a String which describes these security options
Overrides:
toString in class java.lang.Object
Returns:
a String which describes these security options