Package io.milton.http.webdav
Interface PropFindPropertyBuilder
- All Known Implementing Classes:
DefaultPropFindPropertyBuilder
public interface PropFindPropertyBuilder
This class performs the main part of PROPFIND processing, which is given
a field request (either named fields or an allprop request) and a target
resource, iterate over that resource and its children (depending on the
depth header) and list a list of PropFindResponse objects.
These PropFindResponse objects contain typed values for all of the known
fields, and a set of unknown fields. These will be used to build the xml
which is ultimately sent back to the client.
This class uses a list of PropertySource's, where each PropertySource represents
some mechanism to read properties from a resource.
- Author:
- brad
-
Method Summary
Modifier and TypeMethodDescriptionbuildProperties(PropFindableResource pfr, int depth, PropertiesRequest parseResult, String url) Construct a list of PropFindResponse for the given resource, using the PropertySource's injected into this class.findAllProps(PropFindableResource resource) getProperty(QName field, Resource resource) voidprocessResource(List<PropFindResponse> responses, PropFindableResource resource, PropertiesRequest parseResult, String href, int requestedDepth, int currentDepth, String collectionHref)
-
Method Details
-
buildProperties
List<PropFindResponse> buildProperties(PropFindableResource pfr, int depth, PropertiesRequest parseResult, String url) throws URISyntaxException, NotAuthorizedException, BadRequestException Construct a list of PropFindResponse for the given resource, using the PropertySource's injected into this class.- Parameters:
pfr- - the resource to interrogatedepth- - the depth header. 0 means only look at the given resource. 1 is to include childrenparseResult- - contains the list of fields, or a true boolean indicating all propertiesurl- - the URL of the given resource - MUST be correctly encoded- Returns:
- Throws:
URISyntaxExceptionNotAuthorizedExceptionBadRequestException
-
getProperty
ValueAndType getProperty(QName field, Resource resource) throws NotAuthorizedException, BadRequestException -
processResource
void processResource(List<PropFindResponse> responses, PropFindableResource resource, PropertiesRequest parseResult, String href, int requestedDepth, int currentDepth, String collectionHref) throws NotAuthorizedException, BadRequestException -
findAllProps
Set<QName> findAllProps(PropFindableResource resource) throws NotAuthorizedException, BadRequestException
-