Uses of Class
com.janeirodigital.shapetrees.core.exceptions.ShapeTreeException
Packages that use ShapeTreeException
Package
Description
Implementation of
client-side
shape tree validation using the OkHttp HTTP client for Java.
-
Uses of ShapeTreeException in com.janeirodigital.shapetrees.client.okhttp
Methods in com.janeirodigital.shapetrees.client.okhttp with parameters of type ShapeTreeExceptionModifier and TypeMethodDescriptionstatic okhttp3.Response
OkHttpHelper.createErrorResponse
(okhttp3.Request nativeRequest, ShapeTreeException exception) Methods in com.janeirodigital.shapetrees.client.okhttp that throw ShapeTreeExceptionModifier and TypeMethodDescriptionstatic okhttp3.Response
OkHttpHelper.checkResponse
(okhttp3.Response response) Check the providedresponse
for viabilitystatic okhttp3.Response
OkHttpHelper.createInvalidResponse
(okhttp3.Request nativeRequest, ContainingValidationResult containingResult) static okhttp3.Response
OkHttpHelper.createInvalidResponse
(okhttp3.Request nativeRequest, ValidationResult result) OkHttpResourceAccessor.createResource
(ShapeTreeContext context, URL url, ResourceAttributes attributes, String body, String contentType) static okhttp3.Response
OkHttpHelper.deleteHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials) CallOkHttpHelper.deleteHttpResource(OkHttpClient, URL, String, Headers)
without any additional headers suppliedstatic okhttp3.Response
OkHttpHelper.deleteHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, okhttp3.Headers headers) Perform an HTTP DELETE on the resource aturl
.OkHttpResourceAccessor.deleteResource
(ShapeTreeContext context, InstanceResource deleteResource) Deletes the providedInstanceResource
deleteResource
static ShapeTreeManager
OkHttpShapeTreeClient.discover
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL resourceUrl) Discover the ShapeTreeManager associated with a given target resource.static okhttp3.OkHttpClient
OkHttpValidatingClientFactory.get()
Customized the basic OkHttpClient received from the configuredOkHttpClientFactory
with an interceptor to provide client-side shape tree validation.static OkHttpClientFactory
OkHttpClientFactoryManager.getFactory()
static okhttp3.Response
OkHttpHelper.getHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials) CallsOkHttpHelper.getHttpResource(OkHttpClient, URL, String, Headers)
without any additional headers supplied.static okhttp3.Response
OkHttpHelper.getHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, okhttp3.Headers headers) Perform an HTTP GET on the resource aturl
.okhttp3.OkHttpClient
OkHttpClientFactory.getOkHttpClient()
Reuses or constructs a new regular OkHttpClientOkHttpResourceAccessor.getResource
(ShapeTreeContext context, URL url) Get aInstanceResource
at the providedurl
, which may or may not exist.OkHttpExternalDocumentLoader.loadExternalDocument
(URL resourceUrl) Load a non-POD document This fulfils the ExternalDocumentLoader interface, so this factory can be use in DocumentLoaderManager.setLoader(new OkHttpShapeTreeClientFactory(...));static okhttp3.Response
OkHttpShapeTreeClient.patch
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL resourceUrl, List<URL> focusNodes, String body) static okhttp3.Response
OkHttpHelper.patchHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, String body, ContentType contentType) CallOkHttpHelper.patchHttpResource(OkHttpClient, URL, String, Headers, String, ContentType)
without any additional headers suppliedstatic okhttp3.Response
OkHttpHelper.patchHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, okhttp3.Headers headers, String body, ContentType contentType) Perform an HTTP PATCH on the resource aturl
.static okhttp3.Response
OkHttpShapeTreeClient.plant
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL resourceUrl, URL shapeTreeUrl, URL focusNodeUrl) Shape Trees, §4.2: This operation marks an existing resource as being managed by one or more shape trees, by associating a shape tree manager with the resource, and turning it into a managed resource.static okhttp3.Response
OkHttpShapeTreeClient.post
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL parentContainer, List<URL> focusNodes, List<URL> targetShapeTrees, String slug, boolean isContainer, String body, ContentType contentType) static okhttp3.Response
OkHttpHelper.postHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, String body, ContentType contentType) CallOkHttpHelper.postHttpResource(OkHttpClient, URL, String, Headers, String, ContentType)
without any additional headers supplied.static okhttp3.Response
OkHttpHelper.postHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, okhttp3.Headers headers, String body, ContentType contentType) Perform an HTTP POST on the resource aturl
.static okhttp3.Response
OkHttpShapeTreeClient.put
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL resourceUrl, List<URL> focusNodes, String body, ContentType contentType) static okhttp3.Response
OkHttpShapeTreeClient.put
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL resourceUrl, List<URL> focusNodes, List<URL> targetShapeTrees, Boolean isContainer, String body, ContentType contentType) static okhttp3.Response
OkHttpHelper.putHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, String body, ContentType contentType) CallOkHttpHelper.putHttpResource(OkHttpClient, URL, String, Headers, String, ContentType)
without any additional headers suppliedstatic okhttp3.Response
OkHttpHelper.putHttpResource
(okhttp3.OkHttpClient okHttpClient, URL url, String credentials, okhttp3.Headers headers, String body, ContentType contentType) Perform an HTTP PUT on the resource aturl
.static okhttp3.Response
OkHttpShapeTreeClient.unplant
(okhttp3.OkHttpClient okHttpClient, ShapeTreeContext context, URL resourceUrl, URL shapeTreeUrl) OkHttpResourceAccessor.updateResource
(ShapeTreeContext context, InstanceResource updateResource, String body) protected abstract Optional<okhttp3.Response>
OkHttpValidatingMethodHandler.validateRequest
(okhttp3.Request nativeRequest, ShapeTreeRequest shapeTreeRequest, ShapeTreeContext shapeTreeContext, ManageableInstance requestInstance) protected Optional<okhttp3.Response>
OkHttpValidatingPatchMethodHandler.validateRequest
(okhttp3.Request nativeRequest, ShapeTreeRequest shapeTreeRequest, ShapeTreeContext shapeTreeContext, ManageableInstance targetInstance) protected Optional<okhttp3.Response>
OkHttpValidatingPostMethodHandler.validateRequest
(okhttp3.Request nativeRequest, ShapeTreeRequest shapeTreeRequest, ShapeTreeContext shapeTreeContext, ManageableInstance targetInstance) protected Optional<okhttp3.Response>
OkHttpValidatingPutMethodHandler.validateRequest
(okhttp3.Request nativeRequest, ShapeTreeRequest shapeTreeRequest, ShapeTreeContext shapeTreeContext, ManageableInstance targetInstance) Constructors in com.janeirodigital.shapetrees.client.okhttp that throw ShapeTreeException -
Uses of ShapeTreeException in com.janeirodigital.shapetrees.core.contentloaders
Methods in com.janeirodigital.shapetrees.core.contentloaders that throw ShapeTreeExceptionModifier and TypeMethodDescriptionstatic ExternalDocumentLoader
DocumentLoaderManager.getLoader()
Return an ExternalDocumentLoader that was previously set and stored staticallyExternalDocumentLoader.loadExternalDocument
(URL resourceUrl) Describes the retrieval of a remote documentHttpExternalDocumentLoader.loadExternalDocument
(URL resourceUrl) -
Uses of ShapeTreeException in com.janeirodigital.shapetrees.core.helpers
Methods in com.janeirodigital.shapetrees.core.helpers that throw ShapeTreeExceptionModifier and TypeMethodDescriptionstatic void
DocumentResponseHelper.checkStringAsUrl
(String urlString) Check the validity of a URL string valuestatic org.apache.jena.graph.Graph
RequestHelper.getIncomingBodyGraph
(ShapeTreeRequest shapeTreeRequest, URL baseUrl, InstanceResource targetResource) Loads body of request into graphRequestHelper.getIncomingFocusNodes
(ShapeTreeRequest shapeTreeRequest, URL baseUrl) static URL
RequestHelper.getIncomingParentContainerUrl
(ShapeTreeRequest shapeTreeRequest) Get the URL of the incoming resource target's parent containerstatic ShapeTreeResourceType
RequestHelper.getIncomingResourceType
(ShapeTreeRequest shapeTreeRequest) Determines the type of resource represented by an incoming ShapeTreeRequest.static ShapeTreeManager
RequestHelper.getIncomingShapeTreeManager
(ShapeTreeRequest shapeTreeRequest, ManagerResource managerResource) RequestHelper.getIncomingTargetShapeTrees
(ShapeTreeRequest shapeTreeRequest, URL baseUrl) Gets target shape tree / hint from request headerstatic org.apache.jena.graph.Triple
Create a new triple statement with stringsstatic org.apache.jena.graph.Triple
Create a new triple statement with URIsstatic URL
GraphHelper.nodeToUrl
(org.apache.jena.graph.Node node) Convert an RDFNode value to URLstatic URL
RequestHelper.normalizeSolidResourceUrl
(URL url, String requestedName, ShapeTreeResourceType resourceType) Normalizes the BaseURL to use for a request based on the incoming request.static org.apache.jena.graph.Graph
GraphHelper.readStringIntoGraph
(URI baseURI, String rawContent, String contentType) Deserializes a string into a Graphstatic org.apache.jena.rdf.model.Model
GraphHelper.readStringIntoModel
(URI baseURI, String rawContent, String contentType) Deserializes a string into a Modelstatic URL
DocumentResponseHelper.stringToUrl
(String urlString) Convert the provided URL string value to URLstatic URL
DocumentResponseHelper.stringToUrl
(URL context, String urlString) Convert the provided URL string value to a URL, using the provided URLcontext
-
Uses of ShapeTreeException in com.janeirodigital.shapetrees.core.resources
Methods in com.janeirodigital.shapetrees.core.resources that throw ShapeTreeExceptionModifier and TypeMethodDescriptionstatic URL
ManageableInstance.calculateManagedUrl
(URL managerUrl, ResourceAttributes attributes) Looks for the presence of the http://www.w3.org/ns/shapetrees#manages HTTP Link Relation in the providedattributes
, with a valid target URL of aManagedResource
.static ManageableInstance
ManageableInstance.createInstanceResource
(ResourceAccessor accessor, ShapeTreeContext context, URL resourceUrl, ResourceAttributes headers, String body, String contentType) Creates the resource identified by the providedresourceUrl
and gets a correspondingManageableInstance
.ResourceAccessor.createResource
(ShapeTreeContext context, URL resourceUrl, ResourceAttributes headers, String body, String contentType) Creates a specificInstanceResource
identified by the providedresourceUrl
.ResourceAccessor.deleteResource
(ShapeTreeContext context, InstanceResource deleteResource) Deletes a specificInstanceResource
identified by the providedupdatedResource
ManageableInstance.getContainedInstances()
Gets a list ofManageableInstance
s contained in a managed resource that is a container.org.apache.jena.graph.Graph
Get an RDF graph of the body of the InstanceResource.static ManageableInstance
ManageableInstance.getInstance
(ResourceAccessor accessor, ShapeTreeContext context, URL resourceUrl) Return aManageableInstance
constructed starting with the resource identified by the providedresourceUrl
.ManagerResource.getManager()
Get a ShapeTreeManager from the body of the ManagerResourceResourceAccessor.getResource
(ShapeTreeContext context, URL resourceUrl) Gets a specificInstanceResource
identified by the providedresourceUrl
.static ManageableInstance
ManageableInstance.reloadInstance
(ManageableInstance originalInstance) Return a new version of providedManageableInstance
originalInstance
ResourceAccessor.updateResource
(ShapeTreeContext context, InstanceResource updatedResource, String body) Updates a specificInstanceResource
identified by the providedupdatedResource
-
Uses of ShapeTreeException in com.janeirodigital.shapetrees.core.validation
Methods in com.janeirodigital.shapetrees.core.validation that throw ShapeTreeExceptionModifier and TypeMethodDescriptionvoid
ShapeTreeManager.addAssignment
(ShapeTreeAssignment assignment) Add aShapeTreeAssignment
to the ShapeTreeManager.static ValidationResult
ShapeTreeRequestProcessor.assign
(ResourceAccessor accessor, ManageableInstance manageableInstance, ShapeTreeContext shapeTreeContext, ShapeTreeManager rootManager, ShapeTreeAssignment rootAssignment, ShapeTreeAssignment parentAssignment, ValidationResult advanceValidationResult) static void
SchemaCache.clearCache()
static ShapeTreeAssignment
ShapeTreeManagerDelta.containsSameUrl
(ShapeTreeAssignment assignment, List<ShapeTreeAssignment> targetAssignments) static boolean
SchemaCache.containsSchema
(URL schemaUrl) static ShapeTreeManagerDelta
ShapeTreeManagerDelta.evaluate
(ShapeTreeManager existingManager, ShapeTreeManager updatedManager) Compares an updated ShapeTreeManager (updatedManager) with an existing one (existingManager).static ShapeTreeReference
ShapeTreeReference.findChildReference
(ShapeTree shapeTree, URL childUrl) ShapeTreeManager.getContainingAssignments()
static ShapeTreeAssignment
ShapeTreeAssignment.getFromGraph
(URL url, org.apache.jena.graph.Graph managerGraph) static ShapeTreeManager
ShapeTreeManager.getFromGraph
(URL id, org.apache.jena.graph.Graph managerGraph) org.apache.jena.graph.Graph
ShapeTreeManager.getGraph()
Get the ShapeTreeManager as an RDF Graphstatic org.apache.jena.rdf.model.Property
ShapeTreeReference.getPropertyFromReference
(ShapeTreeReference reference) ShapeTree.getReferencedShapeTrees()
ShapeTree.getReferencedShapeTrees
(RecursionMethod recursionMethod) static ShapeTreeAssignment
ShapeTreeRequestProcessor.getRootAssignment
(ResourceAccessor accessor, ShapeTreeContext shapeTreeContext, ShapeTreeAssignment assignment) static org.apache.jena.shex.ShexSchema
static ShapeTree
ShapeTreeFactory.getShapeTree
(URL shapeTreeUrl) Looks up and parses the shape tree atshapeTreeUrl
.static ShapeTreeResource
ShapeTreeResource.getShapeTreeResource
(URL resourceUrl) Looks up and caches the shape tree resource atresourceUrl
.boolean
ShapeTreeManager.hasContainingAssignments()
static ValidationResult
ShapeTreeRequestProcessor.plant
(ResourceAccessor accessor, ManageableInstance manageableInstance, ShapeTreeContext shapeTreeContext, ShapeTreeManager updatedRootManager, ShapeTreeManagerDelta delta) Plants a shape tree on an existing resourcestatic void
static ValidationResult
ShapeTreeRequestProcessor.unassign
(ResourceAccessor accessor, ManageableInstance manageableInstance, ShapeTreeContext shapeTreeContext, ShapeTreeAssignment rootAssignment) static void
SchemaCache.unInitializeCache()
static ValidationResult
ShapeTreeRequestProcessor.unplant
(ResourceAccessor accessor, ManageableInstance manageableInstance, ShapeTreeContext shapeTreeContext, ShapeTreeManagerDelta delta) static ValidationResult
ShapeTreeRequestProcessor.updateManager
(ResourceAccessor accessor, ManageableInstance manageableInstance, ShapeTreeRequest shapeTreeRequest) ShapeTree.validateContainedResource
(ManageableResource containedResource) ShapeTree.validateContainedResource
(ManageableResource containedResource, List<URL> targetShapeTreeUrls, List<URL> focusNodeUrls) ShapeTree.validateContainedResource
(String requestedName, ShapeTreeResourceType resourceType, List<URL> targetShapeTreeUrls, org.apache.jena.graph.Graph bodyGraph, List<URL> focusNodeUrls) static ContainingValidationResult
ShapeTreeRequestProcessor.validateCreate
(ResourceAccessor accessor, ManageableInstance targetInstance, ManageableInstance parentContainer, ShapeTreeRequest shapeTreeRequest, String proposedName) ShapeTree.validateGraph
(org.apache.jena.graph.Graph graph, List<URL> focusNodeUrls) ShapeTree.validateResource
(ManageableResource targetResource) ShapeTree.validateResource
(ManageableResource targetResource, List<URL> focusNodeUrls) ShapeTree.validateResource
(String requestedName, ShapeTreeResourceType resourceType, org.apache.jena.graph.Graph bodyGraph, List<URL> focusNodeUrls) static ValidationResult
ShapeTreeRequestProcessor.validateUpdate
(ResourceAccessor accessor, ManageableInstance targetInstance, ShapeTreeRequest shapeTreeRequest) Constructors in com.janeirodigital.shapetrees.core.validation that throw ShapeTreeException