Class AbstractNonRdfSourceOperation

java.lang.Object
org.fcrepo.kernel.impl.operations.AbstractResourceOperation
org.fcrepo.kernel.impl.operations.AbstractNonRdfSourceOperation
All Implemented Interfaces:
org.fcrepo.kernel.api.operations.NonRdfSourceOperation, org.fcrepo.kernel.api.operations.ResourceOperation
Direct Known Subclasses:
CreateNonRdfSourceOperation, UpdateNonRdfSourceOperation

public abstract class AbstractNonRdfSourceOperation extends AbstractResourceOperation implements org.fcrepo.kernel.api.operations.NonRdfSourceOperation
An abstract operation for interacting with a non-rdf source
Author:
bbpennel
  • Constructor Details

    • AbstractNonRdfSourceOperation

      protected AbstractNonRdfSourceOperation(org.fcrepo.kernel.api.Transaction transaction, org.fcrepo.kernel.api.identifiers.FedoraId rescId, URI externalContentURI, String externalHandling)
      Constructor for external content.
      Parameters:
      rescId - the internal identifier.
      externalContentURI - the URI of the external content.
      externalHandling - the type of external content handling (REDIRECT, PROXY)
    • AbstractNonRdfSourceOperation

      protected AbstractNonRdfSourceOperation(org.fcrepo.kernel.api.Transaction transaction, org.fcrepo.kernel.api.identifiers.FedoraId rescId, InputStream content)
      Constructor for internal binaries.
      Parameters:
      rescId - the internal identifier.
      content - the stream of the content.
    • AbstractNonRdfSourceOperation

      protected AbstractNonRdfSourceOperation(org.fcrepo.kernel.api.Transaction transaction, org.fcrepo.kernel.api.identifiers.FedoraId rescId)
      Basic constructor.
      Parameters:
      rescId - The internal Fedora ID.
  • Method Details

    • getContentStream

      Specified by:
      getContentStream in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getExternalHandling

      Specified by:
      getExternalHandling in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getContentUri

      public URI getContentUri()
      Specified by:
      getContentUri in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getMimeType

      public String getMimeType()
      Specified by:
      getMimeType in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getFilename

      public String getFilename()
      Specified by:
      getFilename in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getContentDigests

      Specified by:
      getContentDigests in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getContentSize

      public long getContentSize()
      Specified by:
      getContentSize in interface org.fcrepo.kernel.api.operations.NonRdfSourceOperation
    • getContent

      protected InputStream getContent()
      Returns:
      the content
    • setContent

      protected void setContent(InputStream content)
      Parameters:
      content - the content to set
    • getExternalHandlingURI

      Returns:
      the externalHandlingURI
    • setExternalHandlingURI

      protected void setExternalHandlingURI(URI externalHandlingURI)
      Parameters:
      externalHandlingURI - the externalHandlingURI to set
    • getExternalHandlingType

      Returns:
      the externalHandlingType
    • setExternalHandlingType

      protected void setExternalHandlingType(String externalHandlingType)
      Parameters:
      externalHandlingType - the externalHandlingType to set
    • getDigests

      protected Collection<URI> getDigests()
      Returns:
      the digests
    • setDigests

      protected void setDigests(Collection<URI> digests)
      Parameters:
      digests - the digests to set
    • setMimeType

      protected void setMimeType(String mimeType)
      Parameters:
      mimeType - the mimeType to set
    • setFilename

      protected void setFilename(String filename)
      Parameters:
      filename - the filename to set
    • setContentSize

      protected void setContentSize(long contentSize)
      Parameters:
      contentSize - the contentSize to set