Interface TypedStorageTree

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      org.rundeck.storage.api.Resource<ResourceMeta> getResourceWithType​(org.rundeck.storage.api.Path path, java.lang.String contentType)  
      boolean hasResourceWithType​(org.rundeck.storage.api.Path path, java.lang.String contentType)  
      byte[] readResourceWithType​(org.rundeck.storage.api.Path path, java.lang.String contentType)  
      • Methods inherited from interface org.rundeck.storage.api.Tree

        createResource, createResource, deleteResource, deleteResource, getPath, getPath, getResource, getResource, hasDirectory, hasDirectory, hasPath, hasPath, hasResource, hasResource, listDirectory, listDirectory, listDirectoryResources, listDirectoryResources, listDirectorySubdirs, listDirectorySubdirs, updateResource, updateResource
    • Method Detail

      • getResourceWithType

        org.rundeck.storage.api.Resource<ResourceMeta> getResourceWithType​(org.rundeck.storage.api.Path path,
                                                                           java.lang.String contentType)
        Parameters:
        path - path
        contentType - content type string
        Returns:
        contents of the resource
        Throws:
        com.dtolabs.rundeck.core.storage.WrongContentType - if the content type requested does not match
        org.rundeck.storage.api.StorageException - if underlying tree throws an exception, e.g. not found
      • hasResourceWithType

        boolean hasResourceWithType​(org.rundeck.storage.api.Path path,
                                    java.lang.String contentType)
        Parameters:
        path - path
        contentType - content type string
        Returns:
        true if the resource exists and has the specified content type
        Throws:
        com.dtolabs.rundeck.core.storage.WrongContentType - if the content type requested does not match
        org.rundeck.storage.api.StorageException - if underlying tree throws an exception, e.g. not found
      • readResourceWithType

        byte[] readResourceWithType​(org.rundeck.storage.api.Path path,
                                    java.lang.String contentType)
                             throws java.io.IOException
        Parameters:
        path - path
        contentType - content type string
        Returns:
        contents of the resource
        Throws:
        com.dtolabs.rundeck.core.storage.WrongContentType - if the content type requested does not match
        org.rundeck.storage.api.StorageException - if underlying tree throws an exception, e.g. not found
        java.io.IOException