*** This class provides Binary Compatibility only, not Source Compatibility ***

Class DavBinaryPackage

java.lang.Object
java.rmi.server.RemoteObject
java.rmi.server.RemoteServer
java.rmi.server.UnicastRemoteObject
All Implemented Interfaces:
ContentInterface, MetadataInterface, PublicObjectInterface, DavBinaryPackageInterface, PackageInterface, Serializable, Remote

@SASScope("ALL") @BinaryCompatibilityOnly public class DavBinaryPackage extends Content implements DavBinaryPackageInterface
DAV implementation of a PackageInterface (DAVBinaryPackageInterface) for a binary package.

Since:
1.0
See Also:
  • Constructor Details

    • DavBinaryPackage

      public DavBinaryPackage() throws RemoteException
      Creates a new DAVBinarypackage
      Throws:
      RemoteException - if unable to export the remote object to the RMI system.
    • DavBinaryPackage

      public DavBinaryPackage(DAVBinarypackage o) throws RemoteException
      Creates a new DAVBinarypackage that incorporates the DAV binary package object passed to the constructor
      Throws:
      RemoteException - if unable to export the remote object to the RMI system.
  • Method Details

    • getType

      public String getType() throws RemoteException
      Description copied from class: Content
      Get the smartobject type - this is a "content" provider
      Specified by:
      getType in interface MetadataInterface
      Overrides:
      getType in class Content
      Returns:
      A type string for the object.
      Throws:
      RemoteException - in the case of network failures
    • setName

      public void setName(String name) throws RemoteException
      Description copied from class: Metadata
      Set the name of the object.

      Specified by:
      setName in interface MetadataInterface
      Overrides:
      setName in class Metadata
      Parameters:
      name - The name of the object in the repository.
      Throws:
      RemoteException - in the event of remote object failure.
    • setDescription

      public void setDescription(String description) throws RemoteException
      Description copied from class: Metadata
      Set the object description.

      Specified by:
      setDescription in interface MetadataInterface
      Overrides:
      setDescription in class Metadata
      Parameters:
      description - The description String for the object.
      Throws:
      RemoteException - in the event of remote object failure.
    • getCreationDate

      public long getCreationDate() throws RemoteException
      Description copied from interface: PackageInterface
      Get the date the package was created.

      Specified by:
      getCreationDate in interface PackageInterface
      Returns:
      The package creation date and time.
      Throws:
      RemoteException - In the event of remote object failure.
    • getCreationDateString

      public String getCreationDateString() throws RemoteException
      Description copied from interface: PackageInterface
      Get a formatted string representing the date and time the package was created.

      Specified by:
      getCreationDateString in interface PackageInterface
      Returns:
      A string representing the date the package was created.
      Throws:
      RemoteException - In the event of remote object failure.
    • getExpirationDate

      public long getExpirationDate() throws RemoteException
      Description copied from interface: PackageInterface
      Get the expiration date of the package.

      Specified by:
      getExpirationDate in interface PackageInterface
      Returns:
      The date and time the package expires and the data it contains should be considered obsolete.
      Throws:
      RemoteException - In the event of remote object failure.
    • getExpirationDateString

      public String getExpirationDateString() throws RemoteException
      Description copied from interface: PackageInterface
      Get the expiration date of the package. The date is returned as a formatted string.

      Specified by:
      getExpirationDateString in interface PackageInterface
      Returns:
      The date and time the package expires and the data it contains should be considered obsolete.
      Throws:
      RemoteException - In the event of remote object failure.
    • getAbstract

      public String getAbstract() throws RemoteException
      Return the abstract. This routine strips off any quotes. Quotes are added by the publish framework at publish time and so should be stripped.
      Specified by:
      getAbstract in interface PackageInterface
      Returns:
      String The package abstract
      Throws:
      RemoteException - in the event of remote object failure.
    • getProperties

      public AttributeMapInterface getProperties() throws RemoteException
      Description copied from interface: PackageInterface
      Get the name/value pairs for this package.

      Specified by:
      getProperties in interface PackageInterface
      Returns:
      A Map of name/value pairs that describe this package.
      Throws:
      RemoteException - In the event of remote object failure.
    • getChannel

      public ChannelInterface getChannel() throws ServiceException, RemoteException
      Description copied from interface: PackageInterface
      Get the Channel that this archive belongs to, if any.
      Specified by:
      getChannel in interface PackageInterface
      Returns:
      The Channel that this package was published under.
      Throws:
      ServiceException - If a repository or service level error occurs.
      RemoteException - In the event of remote object failure.
    • getPublisher

      public PersonInterface getPublisher() throws RemoteException
      Get a com.sas.services.information.metadata.Person object which represents the publisher of the package.

      Specified by:
      getPublisher in interface PackageInterface
      Returns:
      The Person who published the package.
      Throws:
      RemoteException - in the event of remote object failure.
    • getPublisherAlias

      public String getPublisherAlias() throws RemoteException
      Get the alias for the publisher. This String is in the form of "userAccountName" "personName". The first quoted value is the proccess id (name) of the publisher. This is followed by a space, and then another quoted value which is the name of the person that published the package. If the name of the person was not available, this second quoted value will be the user name used to publish the package.

      Specified by:
      getPublisherAlias in interface PackageInterface
      Returns:
      A String containing the publisher alias information.
      Throws:
      RemoteException - in the event of remote object failure.
    • newServiceObject

      public Object newServiceObject() throws ServiceException, RemoteException
      Description copied from class: Metadata
      For objects that support it, get an "active" interface for the metadata object. For instance, com.sas.services.information.metadata.StoredProcess returns a com.sas.services.storedProcess.StoredProcess object.

      Specified by:
      newServiceObject in interface MetadataInterface
      Overrides:
      newServiceObject in class Metadata
      Returns:
      The "active" object for this metadata.
      Throws:
      ServiceException - if an error occurs
      RemoteException - in the event of remote object failure
    • getContentDestination

      public ContentDestination getContentDestination() throws RemoteException
      Get the ContentDestination that represents the archive path information.

      Specified by:
      getContentDestination in interface PackageInterface
      Returns:
      A ContentDestination which has the file system or server information.
      Throws:
      RemoteException - in the event of a remote object failure.
    • publish

      public EventDataInterface publish(ResultPackageInterface rPkg, InputStream inputStream) throws ServiceException, RemoteException
      Publishes the result package to the DAV binarypackage entity.
      Specified by:
      publish in interface DavBinaryPackageInterface
      Parameters:
      rPkg - The result package to be published
      inputStream - The stream representing the archive binary
      Returns:
      EventDataInterface Containg the SAS package event data
      Throws:
      RemoteException - in the event of remote object failure.
      ServiceException - in the event of a publish failure.
    • getDescription

      public String getDescription()
      Return the description. This overrides getDescription() in com.sas.services.information.metadata.dav.DAVPackage. When a package is published, the publish transports quote the description value as specified by the user. Because of this, we need to strip off any quotes before returning to the user.
      Specified by:
      getDescription in interface MetadataInterface
      Overrides:
      getDescription in class Metadata
      Returns:
      String The package description
    • getDisplayName

      public String getDisplayName() throws ServiceException, RemoteException
      Get the display name for this object.

      Specified by:
      getDisplayName in interface PackageInterface
      Returns:
      The object display name.
      Throws:
      ServiceException - If a repository or service level error occurs.
      RemoteException - if an error occurs
    • getDisplayDescription

      public String getDisplayDescription() throws ServiceException, RemoteException
      Get the display description for this object.

      Specified by:
      getDisplayDescription in interface PackageInterface
      Returns:
      The object display description.
      Throws:
      ServiceException - If a repository or service level error occurs.
      RemoteException - if an error occurs
    • isExpired

      public boolean isExpired() throws RemoteException, ServiceException
      Determines if the package has expired. The expiration datetime is compared with the current datetime when this method is invoked.

      Specified by:
      isExpired in interface PackageInterface
      Returns:
      true if the package has expired; otherwise false
      Throws:
      ServiceException - If a repository or service level error occurs.
      RemoteException - if an error occurs