Bees v0.5.0 API

bees.core.resource
Class PathSpec

java.lang.Object
  |
  +--bees.core.Capability
        |
        +--bees.core.resource.PathSpec
All Implemented Interfaces:
CapabilitySpec
Direct Known Subclasses:
Directory, File, FileSystemRoot

public class PathSpec
extends Capability
implements CapabilitySpec

PathSpec is used as a base for the Directory and File capabilities. It encodes the FileSystemRoot relative path to files and directories.


Fields inherited from class bees.core.Capability
DELETE_PERMISSION, id, INVALID_ID
 
Constructor Summary
PathSpec()
          Construct an empty PathSpec.
PathSpec(java.lang.String path)
          Construct a PathSpec with the given values.
 
Method Summary
 SpecCapabilityFactory getFactory()
           
 void revoke()
          Revoke access to the capability.
 CapabilitySpec specFromBytes(byte[] flattened)
          Initialize this object from the given flattened version of the object.
 byte[] toBytes()
           
 java.lang.String toString()
           
 
Methods inherited from class bees.core.Capability
checkPermission, clear, clonePermission, deleteCapability, equals, fromBytes, fromBytes, revokedPermission, revokePermission, revokePermissions, valid
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PathSpec

public PathSpec(java.lang.String path)
Construct a PathSpec with the given values.
Parameters:
path - The FileSystemRoot relative path.

PathSpec

public PathSpec()
Construct an empty PathSpec.
Method Detail

specFromBytes

public final CapabilitySpec specFromBytes(byte[] flattened)
Description copied from interface: CapabilitySpec
Initialize this object from the given flattened version of the object.
Specified by:
specFromBytes in interface CapabilitySpec
See Also:
CapabilitySpec.specFromBytes(byte[])

toBytes

public byte[] toBytes()
Returns:
A flattened version of this object.

getFactory

public SpecCapabilityFactory getFactory()
Specified by:
getFactory in interface CapabilitySpec
See Also:
CapabilitySpec.getFactory()

revoke

public void revoke()
Description copied from class: Capability
Revoke access to the capability.
Overrides:
revoke in class Capability
See Also:
Capability.revoke()

toString

public java.lang.String toString()
Overrides:
toString in class Capability
See Also:
Object.toString()

Bees v0.5.0 API

This documentation is Copyright (C) 2002 The University of Utah. All Rights Reserved. See the individual source files for distribution terms.
Documentation, software, and mailing lists for Bees v0.5.0 can be found at the Janos Project: http://www.cs.utah.edu/flux/janos/