org.exist.dom
Class LockToken

java.lang.Object
  extended by org.exist.dom.LockToken

public class LockToken
extends Object

Class representing a locktoken. Introduced for webDAV locking.

Author:
Dannes Wessels

Field Summary
static byte LOCK_DEPTH_0
           
static byte LOCK_DEPTH_1
           
static byte LOCK_DEPTH_INFINIY
           
static byte LOCK_DEPTH_NOT_SET
           
static byte LOCK_SCOPE_EXCLUSIVE
           
static byte LOCK_SCOPE_NONE
           
static byte LOCK_SCOPE_NOT_SET
           
static byte LOCK_SCOPE_SHARED
           
static long LOCK_TIMEOUT_INFINITE
           
static byte LOCK_TYPE_NONE
           
static byte LOCK_TYPE_NOT_SET
           
static byte LOCK_TYPE_WRITE
           
static byte RESOURCE_TYPE_NOT_SPECIFIED
           
static byte RESOURCE_TYPE_NULL_RESOURCE
           
 
Constructor Summary
LockToken()
          Creates a new instance of LockToken
 
Method Summary
 void createOpaqueLockToken()
           
static String generateUUID()
           
 byte getDepth()
           
 String getOpaqueLockToken()
           
 String getOwner()
           
 byte getResourceType()
           
 byte getScope()
           
 long getTimeOut()
           
 byte getType()
           
 boolean isNullResource()
           
 void read(VariableByteInput istream)
           
 void setDepth(byte depth)
           
 void setOpaqueLockToken(String token)
           
 void setOwner(String owner)
           
 void setResourceType(byte type)
           
 void setScope(byte scope)
           
 void setTimeOut(long timeout)
           
 void setType(byte type)
           
 void write(VariableByteOutputStream ostream)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCK_TYPE_NONE

public static final byte LOCK_TYPE_NONE
See Also:
Constant Field Values

LOCK_TYPE_WRITE

public static final byte LOCK_TYPE_WRITE
See Also:
Constant Field Values

LOCK_TYPE_NOT_SET

public static final byte LOCK_TYPE_NOT_SET
See Also:
Constant Field Values

LOCK_DEPTH_0

public static final byte LOCK_DEPTH_0
See Also:
Constant Field Values

LOCK_DEPTH_1

public static final byte LOCK_DEPTH_1
See Also:
Constant Field Values

LOCK_DEPTH_INFINIY

public static final byte LOCK_DEPTH_INFINIY
See Also:
Constant Field Values

LOCK_DEPTH_NOT_SET

public static final byte LOCK_DEPTH_NOT_SET
See Also:
Constant Field Values

LOCK_SCOPE_NONE

public static final byte LOCK_SCOPE_NONE
See Also:
Constant Field Values

LOCK_SCOPE_EXCLUSIVE

public static final byte LOCK_SCOPE_EXCLUSIVE
See Also:
Constant Field Values

LOCK_SCOPE_SHARED

public static final byte LOCK_SCOPE_SHARED
See Also:
Constant Field Values

LOCK_SCOPE_NOT_SET

public static final byte LOCK_SCOPE_NOT_SET
See Also:
Constant Field Values

LOCK_TIMEOUT_INFINITE

public static final long LOCK_TIMEOUT_INFINITE
See Also:
Constant Field Values

RESOURCE_TYPE_NOT_SPECIFIED

public static final byte RESOURCE_TYPE_NOT_SPECIFIED
See Also:
Constant Field Values

RESOURCE_TYPE_NULL_RESOURCE

public static final byte RESOURCE_TYPE_NULL_RESOURCE
See Also:
Constant Field Values
Constructor Detail

LockToken

public LockToken()
Creates a new instance of LockToken

Method Detail

getType

public byte getType()

setType

public void setType(byte type)

getDepth

public byte getDepth()

setDepth

public void setDepth(byte depth)

getScope

public byte getScope()

setScope

public void setScope(byte scope)

getOwner

public String getOwner()

setOwner

public void setOwner(String owner)

getTimeOut

public long getTimeOut()

setTimeOut

public void setTimeOut(long timeout)

getOpaqueLockToken

public String getOpaqueLockToken()

setOpaqueLockToken

public void setOpaqueLockToken(String token)

getResourceType

public byte getResourceType()

setResourceType

public void setResourceType(byte type)

isNullResource

public boolean isNullResource()

createOpaqueLockToken

public void createOpaqueLockToken()

generateUUID

public static String generateUUID()

write

public void write(VariableByteOutputStream ostream)
           throws IOException
Throws:
IOException

read

public void read(VariableByteInput istream)
          throws IOException
Throws:
IOException


Copyright (C) Wolfgang Meier. All rights reserved.