|
RSE Release 3.0 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
Interface for file permission and ownership support in RSE IFileService. An implementation of an IHostFilePermissions object is expected to be a data storage for permission and ownership information.
| Field Summary | |
static int |
PERM_ANY_EXECUTE
|
static int |
PERM_ANY_READ
|
static int |
PERM_ANY_WRITE
|
static int |
PERM_GROUP_EXECUTE
Permission constant indicating that the group can execute this file |
static int |
PERM_GROUP_READ
Permission constant indicating that the group can read this file |
static int |
PERM_GROUP_WRITE
Permission constant indicating that the group can write to this file |
static int |
PERM_OTHER_EXECUTE
Permission constant indicating that other users can execute to this file |
static int |
PERM_OTHER_READ
Permission constant indicating that other users can read this file |
static int |
PERM_OTHER_WRITE
Permission constant indicating that other users can write to this file |
static int |
PERM_USER_EXECUTE
Permission constant indicating that the user can execute this file |
static int |
PERM_USER_READ
Permission constant indicating that the user can read this file |
static int |
PERM_USER_WRITE
Permission constant indicating that the user can write to this file |
| Method Summary | |
Object |
clone()
Creates and returns a copy of this object, as specified by the Object.clone() contract.
|
String |
getGroupOwner()
returns the group owner of the file |
boolean |
getPermission(int bitmask)
Test if any of the permission bits from the bitmask are set. |
int |
getPermissionBits()
Get the set of permission bits. |
String |
getUserOwner()
returns the user owner of the file |
void |
setGroupOwner(String group)
Sets the group owner attribute |
void |
setPermission(int bitmask,
boolean value)
Set or reset all the permission bits from the given bitmask. |
void |
setPermissionBits(int bits)
Set the permission bits |
void |
setUserOwner(String user)
Sets the user owner attribute |
String |
toAlphaString()
return permissions in rwxrwxrwx form |
| Field Detail |
public static final int PERM_USER_READ
public static final int PERM_USER_WRITE
public static final int PERM_USER_EXECUTE
public static final int PERM_GROUP_READ
public static final int PERM_GROUP_WRITE
public static final int PERM_GROUP_EXECUTE
public static final int PERM_OTHER_READ
public static final int PERM_OTHER_WRITE
public static final int PERM_OTHER_EXECUTE
public static final int PERM_ANY_READ
public static final int PERM_ANY_WRITE
public static final int PERM_ANY_EXECUTE
| Method Detail |
public void setPermission(int bitmask,
boolean value)
bitmask - the permission(s) bits to modifyvalue - whether to turn on off of the permission(s)
Example: setPermission(PERM_USER_WRITE | PERM_GROUP_WRITE, true);public boolean getPermission(int bitmask)
bitmask - the permission(s) to check for
public int getPermissionBits()
public void setPermissionBits(int bits)
bits - the set of permission bitspublic String toAlphaString()
public String getUserOwner()
public String getGroupOwner()
public void setUserOwner(String user)
user - the user owner attributepublic void setGroupOwner(String group)
group - the group owner attribute
public Object clone()
throws CloneNotSupportedException
Object.clone() contract.
Each implementer of the IHostFilePermission API must properly implement
this method and implement the Cloneable interface.
CloneNotSupportedException - if an instance cannot be cloned for
any reason, e.g. because its state contains complex objects that
cannot be cloned.Object.clone()
|
RSE Release 3.0 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||