|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.webdav.dom.ElementEditor
org.eclipse.webdav.dom.ActiveLock
public class ActiveLock
An element editor for the WebDAV activelock element. See RFC2518 section 12.1 for the element's definition.
Note: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.
LockDiscovery
,
Owner
Field Summary | |
---|---|
protected static String[] |
childNames
|
Fields inherited from class org.eclipse.webdav.dom.ElementEditor |
---|
DAV_NS, root, XML_NS_NAME, XML_NS_PREFIX, XML_PREFIX |
Constructor Summary | |
---|---|
ActiveLock(Element root)
Creates a new editor on the given WebDAV activelock element. |
Method Summary | |
---|---|
void |
addLockTokenHref(String href)
Adds the given href to this activelock's locktoken. |
String |
getDepth()
Returns the depth of this activelock; for example, Context.DEPTH_ZERO . |
Enumeration |
getLockTokenHrefs()
Returns an Enumeration of String s
containing this activelock's lock token hrefs. |
Owner |
getOwner()
Returns this activelock's owner, or null if this
active lock has no owner. |
String |
getTimeout()
Returns this activelock's timeout, or null if this
active lock has no timeout. |
boolean |
isShared()
Returns true if this activelock is shared, or
false if it is exclusive. |
void |
setDepth(String depth)
Sets the depth of this activelock to the given depth. |
void |
setIsShared(boolean isShared)
Sets whether this activelock is shared or exclusive. |
Owner |
setOwner()
Creates and sets an owner element on this activelock and returns an editor on it. |
void |
setTimeout(String timeout)
Sets the timeout on this activelock to the given timeout. |
Methods inherited from class org.eclipse.webdav.dom.ElementEditor |
---|
addChild, addChild, addChild, appendChild, appendChild, cloneNode, create, declareNS, decodeHref, encodeHref, ensure, ensure, ensureDAVElement, ensureDAVElement, ensureNotNull, ensureNull, ensureText, extractElement, extractNode, getChild, getChildElement, getChildText, getDAVChild, getElement, getFirstChild, getFirstChild, getFirstText, getLastChild, getNamespaces, getNamespaces, getNextSibling, getNextSibling, getNextSibling, getNSLocalName, getNSLocalName, getNSName, getNSPrefix, getNSPrefix, getQualifiedName, getSibling, getText, getTwin, hasChild, insertBefore, insertBefore, isDAVElement, isDAVElement, isElement, isText, makeNSStandalone, reduceNS, reduceNS, resolve, setChild, setChild, setChild |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final String[] childNames
Constructor Detail |
---|
public ActiveLock(Element root) throws MalformedElementException
root
- an activelock element
MalformedElementException
- if there is reason to
believe that the element is not well formedMethod Detail |
---|
public void addLockTokenHref(String href)
null
.
href
- the href to addpublic String getDepth() throws MalformedElementException
Context.DEPTH_ZERO
.
MalformedElementException
- if there is reason to believe that
this editor's underlying element is not well formedContext
public Enumeration getLockTokenHrefs() throws MalformedElementException
Enumeration
of String
s
containing this activelock's lock token hrefs.
Enumeration
of String
s
MalformedElementException
- if there is reason to believe that
this editor's underlying element is not well formedpublic Owner getOwner() throws MalformedElementException
null
if this
active lock has no owner.
null
MalformedElementException
- if there is reason to believe that
this editor's underlying element is not well formedpublic String getTimeout() throws MalformedElementException
null
if this
active lock has no timeout.
null
MalformedElementException
- if there is reason to believe that
this editor's underlying element is not well formedpublic boolean isShared() throws MalformedElementException
true
if this activelock is shared, or
false
if it is exclusive.
MalformedElementException
- if there is reason to believe that
this editor's underlying element is not well formedpublic void setDepth(String depth)
Context.DEPTH_ZERO
Context.DEPTH_ONE
Context.DEPTH_INFINITY
depth
- the depth for this activelockContext
public void setIsShared(boolean isShared)
true
, the activelock is set as shared, otherwise, the
activelock is set as exclusive.
isShared
- a boolean indicating whether this activelock will be
set to be shared or exclusivepublic Owner setOwner()
public void setTimeout(String timeout)
null
the current timeout is removed.
timeout
- the timeout value for this activelock, or
null
for no timeout
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |