Class WebdavPrincipalNode
java.lang.Object
org.bedework.webdav.servlet.shared.WebdavNsNode
org.bedework.webdav.servlet.shared.WebdavPrincipalNode
- All Implemented Interfaces:
Serializable,org.bedework.util.logging.Logged
Class to represent a principal in webdav.
- Author:
- Mike Douglass douglm rpi.edu
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bedework.webdav.servlet.shared.WebdavNsNode
WebdavNsNode.PropertyTagEntry, WebdavNsNode.PropVal, WebdavNsNode.SetPropertyResult -
Field Summary
Fields inherited from class org.bedework.webdav.servlet.shared.WebdavNsNode
alias, allowsGet, collection, exists, groupPrincipal, path, status, targetUri, uri, urlHandler, userPrincipal, wdSysIntf -
Constructor Summary
ConstructorsConstructorDescriptionWebdavPrincipalNode(WdSysIntf sysi, UrlHandler urlHandler, String path, org.bedework.access.AccessPrincipal account, boolean collection, String uri) -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleangeneratePropertyValue(QName tag, WebdavNsIntf intf, boolean allProp) Emit the property indicated by the tag.Collection<? extends WdEntity<?>>getChildren(Supplier<Object> filterGetter) Return a collection of children objects.WdCollection<?>getCollection(boolean deref) The node may refer to a collection object which may in fact be an alias to another.booleanlongA content type of null implies no content (or we don't know)org.bedework.access.CurrentAccessGet the current access granted to this principal for this node.booleangetEtagValue(boolean strong) Entity tags are defined in RFC2068 - they are supposed to provide some sort of indication the data has changed - e.g.WdCollection<?>org.bedework.util.logging.BwLoggerorg.bedework.access.AccessPrincipalgetOwner()Should return a value suitable for WebdavNsIntf.makeUserHrefbooleanknownProperty(QName tag) Return true if a call to generatePropertyValue will return a value.booleanRemove the given property for this node.booleansetProperty(Element val, WebdavNsNode.SetPropertyResult spr) Set the given property for this node.booleanTrailing "/" on uri?voidupdate()Update this node after changes.writeContent(org.bedework.util.xml.XmlEmit xml, Writer wtr, String contentType) Called during xml emission to write the content for the node.Methods inherited from class org.bedework.webdav.servlet.shared.WebdavNsNode
addPropEntry, addPropEntry, equals, generateHref, generateHref, generateUrl, getAlias, getAllowsGet, getContent, getContentStream, getContentString, getEncodedUri, getEncodedUri, getExists, getPath, getPrefixedUri, getPrefixedUri, getPropertyNames, getStatus, getSupportedReports, getTargetUri, getUri, hashCode, init, isCollection, isPrincipal, setAlias, setAllowsGet, setDefaults, setExists, setStatus, setTargetUri, setUriMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.bedework.util.logging.Logged
audit, debug, debug, debug, enableAuditLogger, enableErrorLogger, enableMetricsLogger, error, error, error, getLogLevel, info, isAuditLoggerEnabled, isErrorLoggerEnabled, isMetricsDebugEnabled, isMetricsLoggerEnabled, metrics, setLoggerClass, setLoggerClass, trace, trace, trace, warn
-
Constructor Details
-
Method Details
-
getOwner
public org.bedework.access.AccessPrincipal getOwner()Description copied from class:WebdavNsNodeShould return a value suitable for WebdavNsIntf.makeUserHref- Specified by:
getOwnerin classWebdavNsNode- Returns:
- AccessPrincipal owner
-
update
public void update()Description copied from class:WebdavNsNodeUpdate this node after changes.- Specified by:
updatein classWebdavNsNode
-
getCurrentAccess
public org.bedework.access.CurrentAccess getCurrentAccess()Description copied from class:WebdavNsNodeGet the current access granted to this principal for this node.- Specified by:
getCurrentAccessin classWebdavNsNode- Returns:
- CurrentAccess
-
getEtagValue
Description copied from class:WebdavNsNodeEntity tags are defined in RFC2068 - they are supposed to provide some sort of indication the data has changed - e.g. a checksum.There are weak and strong tags
This methods should return a suitable value for that tag.
- Specified by:
getEtagValuein classWebdavNsNode- Returns:
- String
-
trailSlash
public boolean trailSlash()Description copied from class:WebdavNsNodeTrailing "/" on uri?- Specified by:
trailSlashin classWebdavNsNode- Returns:
- boolean
-
getChildren
Description copied from class:WebdavNsNodeReturn a collection of children objects. For example, this is object represents a folder, they may be file objects or a mix of file and folder objects. These are not node objects.Default is to return null
- Specified by:
getChildrenin classWebdavNsNode- Parameters:
filterGetter- non-null if there is a filter- Returns:
- Collection of children
-
getCollection
Description copied from class:WebdavNsNodeThe node may refer to a collection object which may in fact be an alias to another. For deletions we want to remove the alias itself.Move and rename are also targetted at the alias.
Other operations are probably intended to work on the underlying target of the alias.
- Specified by:
getCollectionin classWebdavNsNode- Parameters:
deref- true if we want to act upon the target of an alias.- Returns:
- Collection this node represents
-
getImmediateTargetCollection
- Specified by:
getImmediateTargetCollectionin classWebdavNsNode
-
allowsSyncReport
public boolean allowsSyncReport()- Specified by:
allowsSyncReportin classWebdavNsNode- Returns:
- true if this node allows a sync-report.
-
getDeleted
public boolean getDeleted()- Specified by:
getDeletedin classWebdavNsNode- Returns:
- true if this represents a deleted resource.
-
getSyncToken
- Specified by:
getSyncTokenin classWebdavNsNode- Returns:
- String sync-token, a URI
-
writeContent
Description copied from class:WebdavNsNodeCalled during xml emission to write the content for the node.- Specified by:
writeContentin classWebdavNsNode- Parameters:
xml- - if this is embedded in an xml streamwtr- - if standalone output or no xml stream initialized.contentType- desired content type or null for default.- Returns:
- actual contentType
-
getContentBinary
public boolean getContentBinary()- Specified by:
getContentBinaryin classWebdavNsNode- Returns:
- boolean true if this is binary content
-
getContentLang
- Specified by:
getContentLangin classWebdavNsNode- Returns:
- String lang
-
getContentLen
public long getContentLen()- Specified by:
getContentLenin classWebdavNsNode- Returns:
- long content length
-
getContentType
Description copied from class:WebdavNsNodeA content type of null implies no content (or we don't know)- Specified by:
getContentTypein classWebdavNsNode- Returns:
- String content type
-
getCreDate
- Specified by:
getCreDatein classWebdavNsNode- Returns:
- String credate
-
getDisplayname
- Specified by:
getDisplaynamein classWebdavNsNode- Returns:
- String name
-
getLastmodDate
- Specified by:
getLastmodDatein classWebdavNsNode- Returns:
- String last mod date
-
knownProperty
Description copied from class:WebdavNsNodeReturn true if a call to generatePropertyValue will return a value.- Overrides:
knownPropertyin classWebdavNsNode- Returns:
- boolean
-
getLogger
public org.bedework.util.logging.BwLogger getLogger()- Specified by:
getLoggerin interfaceorg.bedework.util.logging.Logged- Overrides:
getLoggerin classWebdavNsNode
-