Package org.restlet.ext.atom
Class Service
- java.lang.Object
-
- org.restlet.representation.Variant
-
- org.restlet.representation.RepresentationInfo
-
- org.restlet.representation.Representation
-
- org.restlet.representation.CharacterRepresentation
-
- org.restlet.representation.WriterRepresentation
-
- org.restlet.ext.xml.XmlRepresentation
-
- org.restlet.ext.xml.SaxRepresentation
-
- org.restlet.ext.atom.Service
-
- All Implemented Interfaces:
javax.xml.namespace.NamespaceContext
public class Service extends SaxRepresentation
Represents an Atom introspection document.- Author:
- Jerome Louvel
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
APP_NAMESPACE
Atom Publishing Protocol namespace.-
Fields inherited from class org.restlet.ext.xml.SaxRepresentation
XML_SECURE_PROCESSING
-
Fields inherited from class org.restlet.ext.xml.XmlRepresentation
XML_EXPANDING_ENTITY_REFS, XML_VALIDATING_DTD
-
-
Constructor Summary
Constructors Constructor Description Service(java.lang.String serviceUri)
Constructor.Service(java.lang.String serviceUri, org.restlet.representation.Representation xmlService)
Constructor.Service(org.restlet.Client clientDispatcher)
Constructor.Service(org.restlet.Client clientDispatcher, java.lang.String serviceUri)
Constructor.Service(org.restlet.Context context, java.lang.String serviceUri)
Constructor.Service(org.restlet.representation.Representation xmlService)
Constructor.Service(org.restlet.Restlet clientDispatcher, java.lang.String serviceUri, org.restlet.representation.Representation xmlService)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.restlet.data.Status
deleteResource(java.lang.String uri)
Deletes a resource.org.restlet.data.Reference
getBaseReference()
Returns the base reference used to resolve relative references found within the scope of the xml:base attribute.org.restlet.Restlet
getClientDispatcher()
Returns the client HTTP dispatcher.org.restlet.data.Reference
getReference()
Returns the hypertext reference.org.restlet.representation.Representation
getResource(java.lang.String uri)
Retrieves a resource representation.java.util.List<Workspace>
getWorkspaces()
Returns the list of workspaces.void
setBaseReference(org.restlet.data.Reference baseReference)
Sets the base reference used to resolve relative references found within the scope of the xml:base attribute.void
setClientDispatcher(org.restlet.Client clientDispatcher)
Sets the client HTTP dispatcher.void
setReference(org.restlet.data.Reference ref)
Sets the hypertext reference.org.restlet.data.Status
updateResource(java.lang.String uri, org.restlet.representation.Representation updatedRepresentation)
Updates a resource representation.void
write(XmlWriter writer)
Writes the representation to a XML writer.-
Methods inherited from class org.restlet.ext.xml.SaxRepresentation
getInputSource, getSaxSource, isSecureProcessing, parse, release, setSaxSource, setSecureProcessing, write
-
Methods inherited from class org.restlet.ext.xml.XmlRepresentation
getBoolean, getDocument, getDocumentBuilder, getDomSource, getEntityResolver, getErrorHandler, getNamespaces, getNamespaceURI, getNode, getNodes, getNumber, getPrefix, getPrefixes, getSaxSource, getSchema, getStreamSource, getText, isCoalescing, isExpandingEntityRefs, isIgnoringComments, isIgnoringExtraWhitespaces, isNamespaceAware, isValidatingDtd, isXIncludeAware, setCoalescing, setEntityResolver, setErrorHandler, setExpandingEntityRefs, setIgnoringComments, setIgnoringExtraWhitespaces, setNamespaceAware, setNamespaces, setSchema, setSchema, setValidatingDtd, setXIncludeAware, validate, validate, validate, validate
-
Methods inherited from class org.restlet.representation.CharacterRepresentation
getChannel, getStream, write, write
-
Methods inherited from class org.restlet.representation.Representation
append, exhaust, getAvailableSize, getDigest, getDisposition, getExpirationDate, getRange, getRegistration, getSize, getText, hasKnownSize, isAvailable, isEmpty, isSelectable, isTransient, setAvailable, setDigest, setDisposition, setExpirationDate, setListener, setRange, setSize, setTransient
-
Methods inherited from class org.restlet.representation.RepresentationInfo
getModificationDate, getTag, setModificationDate, setTag
-
-
-
-
Field Detail
-
APP_NAMESPACE
public static final java.lang.String APP_NAMESPACE
Atom Publishing Protocol namespace.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
Service
public Service(org.restlet.Client clientDispatcher)
Constructor.- Parameters:
clientDispatcher
- The client HTTP dispatcher.
-
Service
public Service(org.restlet.Client clientDispatcher, java.lang.String serviceUri) throws java.io.IOException
Constructor.- Parameters:
clientDispatcher
- The client HTTP dispatcher.serviceUri
- The service URI.- Throws:
java.io.IOException
-
Service
public Service(org.restlet.Context context, java.lang.String serviceUri) throws java.io.IOException
Constructor.- Parameters:
context
- The context from which the client dispatcher will be retrieved.serviceUri
- The service URI.- Throws:
java.io.IOException
-
Service
public Service(org.restlet.representation.Representation xmlService) throws java.io.IOException
Constructor.- Parameters:
xmlService
- The XML introspection document.- Throws:
java.io.IOException
-
Service
public Service(org.restlet.Restlet clientDispatcher, java.lang.String serviceUri, org.restlet.representation.Representation xmlService) throws java.io.IOException
Constructor.- Parameters:
clientDispatcher
- The client HTTP dispatcher.serviceUri
- The service URI.xmlService
- The XML introspection document.- Throws:
java.io.IOException
-
Service
public Service(java.lang.String serviceUri) throws java.io.IOException
Constructor.- Parameters:
serviceUri
- The service URI.- Throws:
java.io.IOException
-
Service
public Service(java.lang.String serviceUri, org.restlet.representation.Representation xmlService) throws java.io.IOException
Constructor.- Parameters:
serviceUri
- The service URI.xmlService
- The XML introspection document.- Throws:
java.io.IOException
-
-
Method Detail
-
deleteResource
public org.restlet.data.Status deleteResource(java.lang.String uri)
Deletes a resource.- Parameters:
uri
- The resource URI.- Returns:
- The result status.
-
getBaseReference
public org.restlet.data.Reference getBaseReference()
Returns the base reference used to resolve relative references found within the scope of the xml:base attribute.- Returns:
- The base reference used to resolve relative references found within the scope of the xml:base attribute.
-
getClientDispatcher
public org.restlet.Restlet getClientDispatcher()
Returns the client HTTP dispatcher.- Returns:
- The client HTTP dispatcher.
-
getReference
public org.restlet.data.Reference getReference()
Returns the hypertext reference.- Returns:
- The hypertext reference.
-
getResource
public org.restlet.representation.Representation getResource(java.lang.String uri)
Retrieves a resource representation.- Parameters:
uri
- The resource URI.- Returns:
- The resource representation.
-
getWorkspaces
public java.util.List<Workspace> getWorkspaces()
Returns the list of workspaces.- Returns:
- The list of workspaces.
-
setBaseReference
public void setBaseReference(org.restlet.data.Reference baseReference)
Sets the base reference used to resolve relative references found within the scope of the xml:base attribute.- Parameters:
baseReference
- The base reference used to resolve relative references found within the scope of the xml:base attribute.
-
setClientDispatcher
public void setClientDispatcher(org.restlet.Client clientDispatcher)
Sets the client HTTP dispatcher.- Parameters:
clientDispatcher
- The client HTTP dispatcher.
-
setReference
public void setReference(org.restlet.data.Reference ref)
Sets the hypertext reference.- Parameters:
ref
- The hypertext reference.
-
updateResource
public org.restlet.data.Status updateResource(java.lang.String uri, org.restlet.representation.Representation updatedRepresentation)
Updates a resource representation.- Parameters:
uri
- The resource URI.- Returns:
- The resource representation.
-
write
public void write(XmlWriter writer) throws java.io.IOException
Writes the representation to a XML writer.- Overrides:
write
in classSaxRepresentation
- Parameters:
writer
- The XML writer to write to.- Throws:
java.io.IOException
-
-