public class ReportInfo extends java.lang.Object implements XmlSerializable
ReportInfo
class encapsulates the body of a REPORT request.
RFC 3253 the top Xml element
being the name of the requested report. In addition a Depth header may
be present (default value: DavConstants.DEPTH_0
).Constructor and Description |
---|
ReportInfo(org.w3c.dom.Element reportElement,
int depth)
Create a new
ReportInfo object from the given Xml element. |
ReportInfo(ReportType type)
Create a new
ReportInfo |
ReportInfo(ReportType type,
int depth)
Create a new
ReportInfo |
ReportInfo(ReportType type,
int depth,
DavPropertyNameSet propertyNames)
Create a new
ReportInfo |
ReportInfo(java.lang.String typeLocalName,
Namespace typeNamespace)
Create a new
ReportInfo |
ReportInfo(java.lang.String typelocalName,
Namespace typeNamespace,
int depth,
DavPropertyNameSet propertyNames)
Create a new
ReportInfo |
Modifier and Type | Method and Description |
---|---|
boolean |
containsContentElement(java.lang.String localName,
Namespace namespace)
Indicates whether this info contains an element with the given name/namespace.
|
org.w3c.dom.Element |
getContentElement(java.lang.String localName,
Namespace namespace)
Retrieves the Xml element with the given name/namespace that is a child
of this info.
|
java.util.List<org.w3c.dom.Element> |
getContentElements(java.lang.String localName,
Namespace namespace)
Returns a list containing all child Xml elements of this info that have
the specified name/namespace.
|
int |
getDepth()
Returns the depth field.
|
DavPropertyNameSet |
getPropertyNameSet()
Returns a
DavPropertyNameSet providing the property names present
in an eventual DavConstants.XML_PROP child element. |
java.lang.String |
getReportName()
Name of the report type that will be / has been requested.
|
void |
setContentElement(org.w3c.dom.Element contentElement)
Add the specified Xml element as child of this info.
|
org.w3c.dom.Element |
toXml(org.w3c.dom.Document document)
Returns the xml representation of the implementing object as
Element . |
public ReportInfo(ReportType type)
ReportInfo
type
- public ReportInfo(ReportType type, int depth)
ReportInfo
type
- depth
- public ReportInfo(ReportType type, int depth, DavPropertyNameSet propertyNames)
ReportInfo
type
- depth
- propertyNames
- public ReportInfo(java.lang.String typeLocalName, Namespace typeNamespace)
ReportInfo
typeLocalName
- typeNamespace
- public ReportInfo(java.lang.String typelocalName, Namespace typeNamespace, int depth, DavPropertyNameSet propertyNames)
ReportInfo
typelocalName
- typeNamespace
- depth
- propertyNames
- public ReportInfo(org.w3c.dom.Element reportElement, int depth) throws DavException
ReportInfo
object from the given Xml element.reportElement
- depth
- Depth value as retrieved from the DavConstants.HEADER_DEPTH
.DavException
- if the report element is null
.public int getDepth()
public java.lang.String getReportName()
public boolean containsContentElement(java.lang.String localName, Namespace namespace)
localName
- namespace
- public org.w3c.dom.Element getContentElement(java.lang.String localName, Namespace namespace)
null
is returned. If
multiple elements with the same name exist, the first one is returned.localName
- namespace
- null
public java.util.List<org.w3c.dom.Element> getContentElements(java.lang.String localName, Namespace namespace)
localName
- namespace
- public void setContentElement(org.w3c.dom.Element contentElement)
contentElement
- public DavPropertyNameSet getPropertyNameSet()
DavPropertyNameSet
providing the property names present
in an eventual DavConstants.XML_PROP
child element. If no such
child element is present an empty set is returned.DavPropertyNameSet
providing the property names present
in an eventual DAV:prop
child element or an empty set.public org.w3c.dom.Element toXml(org.w3c.dom.Document document)
XmlSerializable
Element
. The given Document
is used
as factory and represents the owner document
of the returned DOM element.toXml
in interface XmlSerializable
document
- XmlSerializable.toXml(Document)
"Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"