com.sas.services.information.metadata
Class Metadata

com.sas.services.information.metadata.Metadata
All Implemented Interfaces:
MetadataInterface, PublicObjectInterface, java.io.Serializable, java.rmi.Remote
Direct Known Subclasses:
Content, Folder, com.sas.services.information.metadata.OMRConnection, OMRGridApplication, OMRHost, OMRPromptDefinition, OMRPromptGroup, OMRProxyList, com.sas.services.information.metadata.OMRSoftwareComponent, OMRTransformation, Remarks

public class Metadata
implements PublicObjectInterface, MetadataInterface, java.io.Serializable

An abstract class to represent objects that can exist in multiple types of repositories.

Users should avoid casting to this class. Instead, cast objects to MetadataInterface.

Since:
1.0
See Also:
Serialized Form

Field Summary
protected  java.util.Map _actionInterfaces
           
protected  java.util.ArrayList _children
           
protected  boolean _isCompatible
           
protected  boolean _isDestroyPending
           
protected  boolean _isReadCompatible
           
protected  long _myRefreshInterval
           
protected  int _myState
           
protected  java.util.Date _omrCreateDate
           
protected  java.util.Date _omrModifyDate
           
protected  RepositoryInterface _repository
           
protected  int _repositoryFlag
           
protected  java.lang.Object _repositoryObject
           
protected  long _treeRefreshTime
           
static java.text.SimpleDateFormat[] formats
          Date formats using for Date parsing.
protected static java.util.TimeZone gmtZone
          GMT timezone.
protected static java.lang.String OMSOBJ_STRING
           
static int REPOSITORY_DAV
          The object is from a DAV Repository.
static int REPOSITORY_LOMR
          The object is from OMI, using local jOMA
static int REPOSITORY_NONE
          No repository type has been set.
static int REPOSITORY_OMR
          The object is from an OMI Repository.
protected static java.lang.String SLASH
           
 
Fields inherited from interface com.sas.services.information.metadata.MetadataInterface
METADATA_STATE_DELETED, METADATA_STATE_DESTROYED, METADATA_STATE_NEW, METADATA_STATE_NORMAL, PERMISSION_READMETADATA, PERMISSION_WRITEMETADATA
 
Constructor Summary
  Metadata()
          Default constructor.
protected Metadata(java.lang.Class theClass)
          Constructs an instance using the specified class to determine appropriate RMI socket factories.
  Metadata(java.lang.Object o)
          Construct a new Metadata object with Object o.
protected Metadata(java.lang.Object o, java.lang.Class theClass)
          Construct a new Metadata object with Object o.
 
Method Summary
 void add()
          Add a new metadata item to the repository.
 void addAccessControl(AccessControlEntryInterface ace)
          Add an Access Control item to this object.
 void addAttribute(java.lang.String key, java.lang.String value)
          Add an attribute with the given name and value
 void addAttributes(java.util.Map attributeMap)
          Add a number of attributes - names and values are given in the map.
 void addDocument(DocumentInterface doc)
          Add an associated Document to this object.
 void addExtension(java.lang.String name, java.lang.String value, java.lang.String type)
          Add an extension to the current set of extensions
 void addGroup(GroupInterface group)
          Add this object to a group.
 void addImplementor(SoftwareComponentInterface softwareComponent)
          Add a SoftwareComponent as an implementor of this object.
 void addKeyword(java.lang.String keyword)
          Add a keyword to this object.
 TextStoreInterface addNoteTextStore(java.lang.String name, java.lang.String role, java.lang.String type, java.lang.String text)
          Creates a TextStore note and adds it to this object.
 void addNoteTextStore(TextStoreInterface note)
          Add an associated TextStore note to this object.
 void addObjectProperty(PropertyInterface property)
          Add a property to this object.
 void addObjectProperty(java.lang.String name, java.lang.String propertyName, java.lang.String value, java.lang.String type)
          Add a new property to this metadata object.
 void addPermissions(java.util.List identities, java.util.List permissions)
          Add a set of permissions for a set of identities for this metadata object.
 void addProcessorInterface(java.lang.String interfaceClassName, com.sas.services.information.publicobject.ProcessorInterface actionInterface)
          Add an action interface to this class.
 void addPrompt(BaseOMRPromptInterface prompt)
          Add a prompt to this object.
 void addPropertySet(PropertySetInterface propertySet)
          Add a property set to this object.
 void addRemark(RemarksInterface remark)
          Add a remark to this smart object
 void addResponsibleParty(com.sas.services.information.publicobject.Responsibility newResponsibility)
          Add a new responsibleParty to this object.
protected  void addToList(java.util.List list, java.lang.Object o)
           
 void addTransactionListener(MetadataInterface mi)
          Add a listener to receive event notifications when a transaction is committed or rolled back.
 void addUsedByPrototype(MetadataInterface prototyped)
          Add an object which uses this object as a prototype.
 void checkin()
          Check out the item
 void checkout()
          Check out the item
protected  void checkPulse(boolean dieOnDeleted)
          Check the state of this object instance.
static void clearInformationService()
           
 void commit()
          Commit changes that have been made to this object to the parent.
 MetadataInterface copyTo(FolderInterface folder, java.lang.String name)
          Make a copy of this object.
 int countAssociatedObjects(java.lang.String association)
          Count the objects associated to this one via a named association.
 void delete()
          Delete this object from its repository.
 void deleteAttribute(java.lang.String key)
          Delete a specific attribute
 void deleteAttributes(java.util.List attributes)
          Delete a list of attributes.
protected  void deleteRootObject(com.sas.metadata.remote.Root object)
           
 void destroy()
          Destroy this object, clearing any object references, freeing any resources in use, and rendering it unusable for future use.
static MetadataInterface fromByteArray(RepositoryInterface ri, byte[] data)
           
 java.util.List getAccessControls()
          Get a list of the Access Controls on this object.
 java.lang.String getAttribute(java.lang.String key)
          Get the value of the attribute with the given key/name.
 java.util.Map getAttributes()
          Get a list of all the attributes.
 AuthorizationUtilInterface getAuthorizationUtil()
          Obtain the AuthorizationUtil Interface for this object
 PublicObjectContainerInterface getContainer()
          Returns the container or parent object.
 java.util.Date getCreateDate()
          Get a Date object representing the time the metadata was created.
 java.lang.String getCreatedBy()
          Gets the name of the user that created the object.
protected  com.sas.storage.editableproperties.PropertyList getDefaultLocalizableProperties()
           
 java.lang.String getDescription()
          Get the object description.
 java.util.List getDocuments()
          Get the List of Documents associated with this object.
 java.lang.String getEntityKey()
          Get the entity key for this item.
 java.lang.String getEntityURL()
          Get a "standard" URL for a metadata object.
 java.util.List getExtensions()
          Get the extensions for this object.
 java.util.List getGroups()
          Get the list of groups this object is a member of.
 java.lang.String getGUID()
          Get a string representing a unique Identifier for this object.
 java.lang.String getIdentifier()
          Get the unique ID of this object.
 java.util.List getIdentities()
          Get all the identities that are associated to this metadata object through permissions.
 java.util.List getImplementors()
          Get a List of the SoftwareComponent Implementors for this object.
static InformationServiceInterface getInformationService()
          Get an instance of the Information Service.
 java.util.List getKeywords()
          Get a list of keywords associated with this object.
 java.lang.String getLockedBy()
          Get the value of the LockedBy attribute for a metadata object.
 java.lang.String getModifiedBy()
          Gets the name of the user that modified the object.
 java.util.Date getModifyDate()
          Get a Date object representing the time the metadata was last updated.
 java.lang.String getName()
          Gets the name of the object.
 TextStoreInterface getNoteTextStore(java.lang.String name, java.lang.String textRole)
          Return a named TextStore note associated with this object or null if the TextStore does not exist.
 java.util.List<TextStoreInterface> getNoteTextStores()
          Get the List of TextStore notes associated with this object.
 java.util.List<TextStoreInterface> getNoteTextStoresByRole(java.lang.String textRoleFilter)
          Return a list of TextStore notes associated with this object filtered by TextRole.
 java.util.List getObjectProperties()
          Get the Property objects associated with this metadata object.
 java.net.URI getObjectURI()
          This method is currently not being implemented and is reserved for future use.
 FolderInterface getParent()
          Return the FolderInterface that contains this object.
 java.lang.String getParentPath(java.lang.String rootFolderName)
          Get the parent path for this object.
 java.util.List getParents()
          Return a List of Folder objects that represent the parent(s) of this object in the hierarchy.
 java.lang.String getPath(java.lang.String rootFolderName)
          Get the path of this object from the root folder, including the object name.
 java.util.List getPaths(java.lang.String rootFolderName)
          Deprecated. This method goes back to when there was not a single, canonical root in the metadata. Now that there is, there can only be one path. And since it had a guaranteed NPE for metadata objects I'm pretty sure no one is using it, so don't start.
 PathUrl getPathUrl()
          Get the SBIP URL.
 PathUrl getPathUrl(java.lang.String rootTreeName)
          Get the SBIP URL.
 PermissionInterface getPermission(IdentityInterface identity, PermissionInterface permission)
          Get a permission that matches the requested permission for the requested identity on this metadata object.
 java.util.List getPermissions(IdentityInterface identity)
          Get all the permissions that apply to this object.
 java.util.List getPermissions(IdentityInterface identity, java.lang.String[] inheritedPermissions)
          Get all the permissions that apply to this object.
 java.util.List getPreviousVersionNames()
          Gets a list of previous version names
 PropertyGroupInterface getPrimaryPropertyGroup()
          Get this object's primary PropertyGroup object.
 com.sas.services.information.publicobject.ProcessorInterface getProcessorInterface(java.lang.String interfaceClassName)
          Get the specified action interface.
 BaseOMRPromptInterface getPrompt()
          Get the first prompt on this object.
 java.util.List getPrompts()
          Get the List of prompts associated with this object.
 com.sas.services.information.metadata.propertybag.PropertyBagInterface getPropertyBag()
          Get a "bag" of properties from the metadata object.
 java.util.List getPropertySets()
          Get a List of the property sets that are associated with this object.
 java.util.List getRemarksList()
          Return a List of Remarks objects that represent the dicussion threads related to this object.
 java.lang.String getReposId()
          Get the repository identifier for this object.
 RepositoryInterface getRepository()
          Get the handle to the repository for this object.
 java.lang.Object getRepositoryEntity()
          Get the object that was returned directly from the repository.
 java.lang.String getRepositoryName()
          Get the repository name that this object resides in.
 java.lang.String getReposKey()
          Get a String that can be passed directly to a RepositoryInterface.fetch method.
 java.util.List getResponsibleParties()
          Get the responsible parties for this object.
 int getState()
          Get the state of this metadata object.
 int getTrackingId()
          Deprecated. Tracking ids are no longer supported.
static long getTreeRefresh()
          Get the interval for keeping the parent tree information before forcing a trip to the server to refresh it.
 java.lang.String getType()
          Get the object type.
 TypeDescriptorInterface getTypeDescriptor()
          Get the type descriptor which should have the information from the Type Dictionary in metadata available for the clients.
 com.sas.util.UsageVersion getUsageVersion()
          Return the usage version of the metadata.
 java.util.List getUsedByPrototypes()
          Get the List of objects which use this object as a prototype.
 MetadataInterface getUsingPrototype()
          Get the prototype which this object uses for description/validation.
 MetadataInterface getVersion(java.lang.String versionName)
          Return a smart object that represents a particular version
 int hashCode()
           
 boolean isAuthorized(java.lang.String permission)
          Check for a specific permission on this object by the user that owns the connection to the repository.
 boolean isCompatible()
          Return a boolean indicating if this object is fully compatible with the version of the metadata.
protected  boolean isConnectionException(java.lang.Throwable ex)
           
 boolean isDeleted()
          Returns true if the delete method has been called on this object.
 boolean isDestroyed()
          Returns true if the backing connection, or infrastructure has been closed, rendering this object unusable.
 boolean isLoggingEnabled(int level, java.lang.String context)
           
 boolean isLoggingEnabled(org.apache.log4j.Level level, java.lang.String context)
           
 boolean isObjectAlive()
          Check to be sure the object still exists in the metadata server.
 boolean isReadCompatible()
          Return a boolean indicating if this object is read compatible with the version of the metadata.
 void logFormat(int level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0)
          Deprecated. Use the version that takes an org.apache.log4j.Level.
 void logFormat(int level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0, java.lang.Object arg1)
          Deprecated. Use the version that takes an org.apache.log4j.Level.
 void logFormat(int level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2)
          Deprecated. Use the version that takes an org.apache.log4j.Level.
 void logFormat(int level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2, java.lang.Object arg3)
          Deprecated. Use the version that takes an org.apache.log4j.Level.
 void logFormat(org.apache.log4j.Level level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0)
           
 void logFormat(org.apache.log4j.Level level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0, java.lang.Object arg1)
           
 void logFormat(org.apache.log4j.Level level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2)
           
 void logFormat(org.apache.log4j.Level level, java.lang.String context, java.util.ResourceBundle bundle, java.lang.String key, java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2, java.lang.Object arg3)
           
 void logMessage(int level, java.lang.String message)
          Deprecated. Use the version that takes an org.apache.log4j.Level instead.
 void logMessage(int level, java.lang.String message, java.lang.String context, java.lang.Throwable t)
          Deprecated. Use the version that takes an org.apache.log4j.Level instead.
 void logMessage(org.apache.log4j.Level level, java.lang.String message)
           
 void logMessage(org.apache.log4j.Level level, java.lang.String message, java.lang.String context, java.lang.Throwable t)
           
 void logThrowable(int level, java.lang.String message, java.lang.String context, java.lang.Throwable t)
          Deprecated. Use the version that takes an org.apache.log4j.Level.
 void logThrowable(org.apache.log4j.Level level, java.lang.String message, java.lang.String context, java.lang.Throwable t)
           
 java.lang.String mapNameToFilesystem(int hostOS, java.lang.String prefix, java.lang.String suffix)
          Map the metadata object name to a file system path.
 java.lang.String mapUrlToFilesystem(int hostOS, java.lang.String prefix, java.lang.String suffix)
          Map the metadata object's SBIP Url to a file system path.
 void moveTo(FolderInterface folder)
          Move this object to a new folder.
 java.lang.Object newServiceObject()
          For objects that support it, get an "active" interface for the metadata object.
protected  void notifyTransactionListeners()
           
 void refresh()
          Refresh the data for this object from the repository.
 void removeAccessControl(AccessControlEntryInterface ace)
          Remove an Access Control item from this object.
 void removeDocument(DocumentInterface doc)
          Remove a document from this object's Documents association.
 void removeExtension(java.lang.String name)
          Remove an Extension from the current extension set.
protected  void removeFromList(java.util.List list, java.lang.Object o)
           
 void removeGroup(GroupInterface group)
          Remove this object from a group.
 void removeImplementor(SoftwareComponentInterface softwareComponent)
          Remove a SoftwareComponent from the list of implementors on this object.
 void removeKeyword(java.lang.String keyword)
          Remove a keyword from this object.
 void removeNoteTextStore(TextStoreInterface note)
          Remove a TextStore note from this object's Notes association.
 void removeObjectProperty(PropertyInterface property)
          Remove a Property from this object.
 void removePermissions(java.util.List identities, java.util.List permissions)
          Remove permissions matching the identities and permission list.
 void removePrompt(BaseOMRPromptInterface prompt)
          Remove a prompt from this object.
 void removePropertySet(PropertySetInterface propertySet)
          Remove a property set from this object.
 void removeResponsibleParty(com.sas.services.information.publicobject.Responsibility responsibility)
          Remove a responsible party from this metadata object.
 void removeResponsiblePartyByIdentity(com.sas.services.information.publicobject.Responsibility responsibility)
          Remove a responsible party from this metadata object.
 void removeUsedByPrototype(MetadataInterface prototyped)
          Remove an object from the list prototyped by this object.
protected  void reset()
           
 void rollback()
          Roll back changes to this object, and all objects that have been updated or created in the child repository.
 void setAttribute(java.lang.String key, java.lang.String value)
          Set the value of an attribute to the given value
 void setAttributes(java.util.Map attributeMap)
          Set a number of attributes - names and values are given in the map
protected  void setCompatibility(com.sas.util.UsageVersion oldestVersion, com.sas.util.UsageVersion currentVersion)
           
protected  void setDefaultLocalizableProperties(com.sas.storage.editableproperties.PropertyMap map)
           
 void setDeleted()
          Mark this object deleted.
 void setDescription(java.lang.String description)
          Set the object description.
 void setDocuments(java.util.List docs)
          Set the list of Documents associated with this object.
 void setExtensions(java.util.List extensionList)
          Set the list of extensions on this metadata object.
 void setGroups(java.util.List groups)
          Set the list of groups this object belongs to.
 void setGUID(java.lang.String guid)
          Set the GUID string for this object.
 void setKeywords(java.util.List keywords)
          Set the keyword collection on this object.
 void setName(java.lang.String name)
          Set the name of the object.
 void setNoteTextStores(java.util.List<TextStoreInterface> notes)
          Set the list of TextStores associated as Notes for this object.
 void setObjectProperties(java.util.List propertyList)
          Set the collection of Properties associated with this object.
 void setPermission(IdentityInterface identity, PermissionInterface permission)
          Set a new permission on this metadata object.
 void setPrimaryPropertyGroup(PropertyGroupInterface pgroup)
          Set this object's primary property group object.
 void setPrompt(BaseOMRPromptInterface prompt)
          Set the prompt on this object.
 void setPrompts(java.util.List prompts)
          Set the List of Prompts on this object.
 void setRemarksList(java.util.List remarks)
          Sets the list of Remarks objects that represent the dicussion threads related to this object.
 void setRepository(RepositoryInterface repository)
          Set the repository that this item exists in.
static void setTreeRefresh(long interval)
          Set the interval for keeping the parent tree information before forcing a trip to the server to refresh it.
 void setUsingPrototype(MetadataInterface prototype)
          Set the prototype which is used by this object for description/validation.
 MetadataInterface startTransaction()
          Start a Transaction for this Metadata object.
 byte[] toByteArray()
          Write the state of the object to a byte array.
 java.lang.String toString()
           
 void transactionEvent(MetadataInterface mi)
          Notify this object that a child transaction has completed either because of a commit or a rollback.
 void uncheckout()
          Check out the item
 void update()
          Persist any changes to the object back to the repository.
 void updateFromBag(com.sas.services.information.metadata.propertybag.PropertyBagInterface propertyBag)
           
protected  void validateNameAndFolder(FolderInterface targetFolder)
           
protected  void validateNameAndFolder(FolderInterface targetFolder, MetadataNameConstraint constraint)
           
 void version()
          Version control the item
 

Field Detail

REPOSITORY_NONE

public static final int REPOSITORY_NONE
No repository type has been set. Probably the object is uninitialized.

See Also:
Constant Field Values

REPOSITORY_OMR

public static final int REPOSITORY_OMR
The object is from an OMI Repository.

See Also:
Constant Field Values

REPOSITORY_DAV

public static final int REPOSITORY_DAV
The object is from a DAV Repository.

See Also:
Constant Field Values

REPOSITORY_LOMR

public static final int REPOSITORY_LOMR
The object is from OMI, using local jOMA

See Also:
Constant Field Values

formats

public static final java.text.SimpleDateFormat[] formats
Date formats using for Date parsing.


gmtZone

protected static final java.util.TimeZone gmtZone
GMT timezone.


OMSOBJ_STRING

protected static final java.lang.String OMSOBJ_STRING
See Also:
Constant Field Values

SLASH

protected static final java.lang.String SLASH
See Also:
Constant Field Values

_repositoryFlag

protected int _repositoryFlag

_repositoryObject

protected java.lang.Object _repositoryObject

_repository

protected RepositoryInterface _repository

_children

protected java.util.ArrayList _children

_treeRefreshTime

protected long _treeRefreshTime

_myRefreshInterval

protected long _myRefreshInterval

_omrCreateDate

protected java.util.Date _omrCreateDate

_omrModifyDate

protected java.util.Date _omrModifyDate

_myState

protected int _myState

_isDestroyPending

protected boolean _isDestroyPending

_actionInterfaces

protected java.util.Map _actionInterfaces

_isCompatible

protected boolean _isCompatible

_isReadCompatible

protected boolean _isReadCompatible
Constructor Detail

Metadata

protected Metadata(java.lang.Class theClass)
            throws java.rmi.RemoteException
Constructs an instance using the specified class to determine appropriate RMI socket factories.

Parameters:
theClass - Class which will be used to determine the appropriate RMI socket factories.
Throws:
java.rmi.RemoteException - if unable to export the remote object.

Metadata

public Metadata()
         throws java.rmi.RemoteException
Default constructor. There's no entity or repository. This isn't an interesting object yet.

Throws:
java.rmi.RemoteException - if unable to export the remote object.

Metadata

protected Metadata(java.lang.Object o,
                   java.lang.Class theClass)
            throws java.rmi.RemoteException
Construct a new Metadata object with Object o. Figure out what kind of repository it came from to set the the repository flag.

Use this constructor if you want to determine RMI socket factories using the subclass's class instead of this object's class. Use Metadata(Object) if you want to employ RMI socket factories based on this class instead of the subclass's class.

Parameters:
o - The object used to initialize this object.
theClass - The subclass's class which will be used to determine appropriate RMI socket factories.
Throws:
java.rmi.RemoteException - if unable to export a remote object.

Metadata

public Metadata(java.lang.Object o)
         throws java.rmi.RemoteException
Construct a new Metadata object with Object o. Figure out what kind of repository it came from to set the the repository flag.

Use this constructor if you want to determine RMI socket factories using this object's class instead of the subsclass's class. Use Metadata(Object, Class) if you want to employ RMI socket factories based on the subclass instead of this class.

Parameters:
o - The object used to initialize this object.
Throws:
java.rmi.RemoteException - in the event of remote object failure.
Method Detail

setTreeRefresh

public static void setTreeRefresh(long interval)
Set the interval for keeping the parent tree information before forcing a trip to the server to refresh it.

Parameters:
interval - The interval in milliseconds to keep the cached tree information

getTreeRefresh

public static long getTreeRefresh()
Get the interval for keeping the parent tree information before forcing a trip to the server to refresh it.

Returns:
The interval in milliseconds to keep the cached tree information.

getInformationService

public static InformationServiceInterface getInformationService()
                                                         throws ServiceException
Get an instance of the Information Service.

Returns:
An InformationService instance.
Throws:
ServiceException - in the event of a discovery error.

clearInformationService

public static void clearInformationService()

getState

public int getState()
             throws java.rmi.RemoteException
Get the state of this metadata object.

Specified by:
getState in interface MetadataInterface
Returns:
An int represtenting the state of this object. Will be one of the MetadataInterface.METADATA_STATE_* statics.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

isDeleted

public boolean isDeleted()
                  throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Returns true if the delete method has been called on this object.

Specified by:
isDeleted in interface MetadataInterface
Returns:
True if delete has been called, false otherwise.
Throws:
java.rmi.RemoteException

setDeleted

public void setDeleted()
                throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Mark this object deleted. This gets done automatically if delete is called through the MetadataInterface, but if the object is deleted through some other mechanism, this will indicate that the smart object is no longer usable. Clients should generally not use this method. It doesn't actually delete the object. Use the delete method for that.

Specified by:
setDeleted in interface MetadataInterface
Throws:
java.rmi.RemoteException - In the event of remote object failure.

isDestroyed

public boolean isDestroyed()
                    throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Returns true if the backing connection, or infrastructure has been closed, rendering this object unusable.

Specified by:
isDestroyed in interface MetadataInterface
Returns:
True if the object has been destroyed.
Throws:
java.rmi.RemoteException

destroy

public void destroy()
             throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Destroy this object, clearing any object references, freeing any resources in use, and rendering it unusable for future use.

Specified by:
destroy in interface MetadataInterface
Throws:
java.rmi.RemoteException

getLockedBy

public java.lang.String getLockedBy()
                             throws ServiceException,
                                    java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the value of the LockedBy attribute for a metadata object. This represents the user who has checked an object out. If the object is not checked out, this will return an empty string.

Specified by:
getLockedBy in interface MetadataInterface
Returns:
The user with the object checked out, or "".
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getName

public java.lang.String getName()
                         throws java.rmi.RemoteException
Gets the name of the object.

Specified by:
getName in interface PublicObjectInterface
Returns:
The name String for the object.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

setName

public void setName(java.lang.String name)
             throws java.rmi.RemoteException
Set the name of the object.

Specified by:
setName in interface MetadataInterface
Parameters:
name - The name of the object in the repository.
Throws:
java.lang.RuntimeException - If a rename would cause a naming collision in the parent folder.
java.rmi.RemoteException - in the event of remote object failure.

getDescription

public java.lang.String getDescription()
                                throws java.rmi.RemoteException
Get the object description.

Specified by:
getDescription in interface MetadataInterface
Returns:
The object description String.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

setDescription

public void setDescription(java.lang.String description)
                    throws java.rmi.RemoteException
Set the object description.

Specified by:
setDescription in interface MetadataInterface
Parameters:
description - The description String for the object.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

getGUID

public java.lang.String getGUID()
                         throws java.rmi.RemoteException
Get a string representing a unique Identifier for this object.

Specified by:
getGUID in interface MetadataInterface
Returns:
A unique identifier string for this object, or null if none was set.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

setGUID

public void setGUID(java.lang.String guid)
             throws java.rmi.RemoteException,
                    java.lang.IllegalStateException
Set the GUID string for this object.

Specified by:
setGUID in interface MetadataInterface
Parameters:
guid - The guid string for this object.
Throws:
java.rmi.RemoteException - in the event of remote object failure.
java.lang.IllegalStateException - if the object already has an assigned GUID.

getReposId

public java.lang.String getReposId()
                            throws java.rmi.RemoteException
Get the repository identifier for this object. The repository ID uniquely identifies the object within the repository.

Specified by:
getReposId in interface MetadataInterface
Returns:
A String with the repository identifier.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

getRepositoryName

public java.lang.String getRepositoryName()
                                   throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the repository name that this object resides in. If this is an OMR object, it returns the repository name, otherwise it returns the repository's Information Service configured name.

Specified by:
getRepositoryName in interface MetadataInterface
Returns:
The repository name.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

getReposKey

public java.lang.String getReposKey()
                             throws ServiceException,
                                    java.rmi.RemoteException
Get a String that can be passed directly to a RepositoryInterface.fetch method. This string will have the repository ID plus the type (separated by a "/").

Specified by:
getReposKey in interface MetadataInterface
Returns:
A String with the repository ID and type that can be passed to the fetch method.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getType

public java.lang.String getType()
                         throws java.rmi.RemoteException
Get the object type. Subclasses of Metadata will return a repository-neutral type string. If no subclass exists, Metadata returns the repository-specific type.

Specified by:
getType in interface MetadataInterface
Returns:
A type string for the object.
Throws:
java.rmi.RemoteException - in the event of remote object failure

add

public void add()
         throws ServiceException,
                java.rmi.RemoteException
Add a new metadata item to the repository.

Specified by:
add in interface MetadataInterface
Throws:
ServiceException - If there's a repository error.
java.rmi.RemoteException - in the event of a network error.

update

public void update()
            throws ServiceException,
                   java.rmi.RemoteException
Persist any changes to the object back to the repository. This is not done automatically in most cases. Any change to metadata requires an update call to write it to the back end server.

Specified by:
update in interface MetadataInterface
Throws:
ServiceException - if an error occurs in the repository.
java.rmi.RemoteException - in the event of remote object failure

reset

protected void reset()
              throws ServiceException,
                     java.rmi.RemoteException
Throws:
ServiceException
java.rmi.RemoteException

refresh

public void refresh()
             throws ServiceException,
                    java.rmi.RemoteException
Refresh the data for this object from the repository.

Specified by:
refresh in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

delete

public void delete()
            throws ServiceException,
                   java.rmi.RemoteException
Delete this object from its repository. This may be overridden by subclasses to perform clean up operations on other objects that may be dependent on this one.

Specified by:
delete in interface MetadataInterface
Throws:
ServiceException - in the event of a repository failure.
java.rmi.RemoteException - in the event of a network failure.

deleteRootObject

protected void deleteRootObject(com.sas.metadata.remote.Root object)
                         throws ServiceException,
                                java.rmi.RemoteException
Throws:
ServiceException
java.rmi.RemoteException

getTrackingId

public final int getTrackingId()
                        throws java.rmi.RemoteException
Deprecated. Tracking ids are no longer supported.

Get the tracking ID for this object. This is generated on a per-JVM basis, and incremented for every MetadataInterface object that gets instantiated.

Specified by:
getTrackingId in interface MetadataInterface
Returns:
The tracking ID.
Throws:
java.rmi.RemoteException - in the event of remote object failure

getRepositoryEntity

public final java.lang.Object getRepositoryEntity()
                                           throws java.rmi.RemoteException
Get the object that was returned directly from the repository. In the case of OMR data, this will be a CMetadata subclass.

Specified by:
getRepositoryEntity in interface MetadataInterface
Returns:
The repository-specific object.
Throws:
java.rmi.RemoteException - in the event of remote object failure

getEntityKey

public java.lang.String getEntityKey()
                              throws java.lang.IllegalStateException,
                                     ServiceException,
                                     java.rmi.RemoteException
Get the entity key for this item. The key should have sufficient information to look up the object again at a later time.

Specified by:
getEntityKey in interface MetadataInterface
Returns:
The entity key.
Throws:
java.lang.IllegalStateException - If the repository hasn't been set on this object.
ServiceException - If an error occurs getting the repository URL.
java.rmi.RemoteException - in the event of remote object failure

getEntityURL

public java.lang.String getEntityURL()
                              throws ServiceException,
                                     java.rmi.RemoteException
Get a "standard" URL for a metadata object. The entity key, while in a URL-ish format, has some extra stuff on it. This method returns a string that can be passed as-is to the Information Service fetchEntityByURL method.

Specified by:
getEntityURL in interface MetadataInterface
Returns:
A URL string representing this metadata object.
Throws:
ServiceException - In the event of a service failure.
java.rmi.RemoteException - In the event of remote object failure.

getPathUrl

public PathUrl getPathUrl()
                   throws java.lang.IllegalStateException,
                          ServiceException,
                          java.rmi.RemoteException
Get the SBIP URL. This is an object that contains the repository name, the path from a root to the object, the object's name and the object's type. In the SAS Metadata Server, an object is in a rooted Tree if it has a path to a Tree that's associated to a SoftwareComponent with a ClassIdentifier of "E5F27790-2149-11D6-8828-AA0004006D06", and a name of "BIP Service".

Specified by:
getPathUrl in interface PublicObjectInterface
Returns:
a PathUrl value with the object's location in a rooted tree. If the object isn't in a rooted tree, null is returned.
Throws:
java.lang.IllegalStateException - if the repository was never set on this object.
ServiceException - if a repository error occurs.
java.rmi.RemoteException - if a remote object error occurs.

getPathUrl

public PathUrl getPathUrl(java.lang.String rootTreeName)
                   throws java.lang.IllegalStateException,
                          ServiceException,
                          java.rmi.RemoteException
Get the SBIP URL. This is an object that contains the repository name, the path from a root to the object, the object's name and the object's type. In the SAS Metadata Server, an object is in a rooted Tree if it has a path to a Tree that's associated to a SoftwareComponent with a ClassIdentifier of "E5F27790-2149-11D6-8828-AA0004006D06", and a name of "BIP Service". This method looks for a path to a specific root folder.

Parameters:
rootTreeName - The name of the tree rooted at the BIP SoftwareComponent.
Returns:
a PathUrl value with the object's location in the rooted tree. If the object isn't in a tree with the given name, rooted at the BIP SoftwareComponent, null is returned.
Throws:
java.lang.IllegalStateException - if the repository was never set on this object.
ServiceException - if a repository error occurs.
java.rmi.RemoteException - if a remote object error occurs.

setRepository

public void setRepository(RepositoryInterface repository)
                   throws java.lang.IllegalStateException,
                          java.rmi.RemoteException
Set the repository that this item exists in.

Specified by:
setRepository in interface MetadataInterface
Parameters:
repository - A handle to the repository for this object.
Throws:
java.lang.IllegalStateException - If the repository has already been set.
java.rmi.RemoteException - in the event of remote object failure

getRepository

public RepositoryInterface getRepository()
                                  throws java.rmi.RemoteException
Get the handle to the repository for this object.

Specified by:
getRepository in interface MetadataInterface
Returns:
A handle to the repository this item exists in.
Throws:
java.rmi.RemoteException - in the event of remote object failure

getKeywords

public java.util.List getKeywords()
                           throws java.rmi.RemoteException
Get a list of keywords associated with this object.

Specified by:
getKeywords in interface MetadataInterface
Returns:
A List of String keywords.
Throws:
java.rmi.RemoteException - in the event of remote object failure.

addKeyword

public void addKeyword(java.lang.String keyword)
                throws ServiceException,
                       java.rmi.RemoteException
Add a keyword to this object.

Specified by:
addKeyword in interface MetadataInterface
Parameters:
keyword - a new String to add as a keyword.
Throws:
ServiceException - if an error occurs in the repository.
java.rmi.RemoteException - in the event of remote object failure

removeKeyword

public void removeKeyword(java.lang.String keyword)
                   throws java.rmi.RemoteException
Remove a keyword from this object.

Specified by:
removeKeyword in interface MetadataInterface
Parameters:
keyword - The keyword to remove.
Throws:
java.rmi.RemoteException - in the event of remote object failure

setKeywords

public void setKeywords(java.util.List keywords)
                 throws ServiceException,
                        java.rmi.RemoteException
Set the keyword collection on this object.

Specified by:
setKeywords in interface MetadataInterface
Parameters:
keywords - The list of keywords to set on this object.
Throws:
ServiceException - In the event of repository failure.
java.rmi.RemoteException - In the event of network failure.

getObjectProperties

public java.util.List getObjectProperties()
                                   throws ServiceException,
                                          java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the Property objects associated with this metadata object. This method only returns the properties that are directly associated with this object, not through PropertySets or PropertGroups.

Specified by:
getObjectProperties in interface MetadataInterface
Returns:
A List of PropertyInterface objects. If there are no properties associated with this object, an empty list will be returned.
Throws:
ServiceException - In the event of repository errors.
java.rmi.RemoteException - In the event of remote object failure.

addObjectProperty

public void addObjectProperty(PropertyInterface property)
                       throws ServiceException,
                              java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add a property to this object.

Specified by:
addObjectProperty in interface MetadataInterface
Parameters:
property - The Property to add.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addObjectProperty

public void addObjectProperty(java.lang.String name,
                              java.lang.String propertyName,
                              java.lang.String value,
                              java.lang.String type)
                       throws ServiceException,
                              java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add a new property to this metadata object. The new property metadata is created and associated to this metadata object.

Specified by:
addObjectProperty in interface MetadataInterface
Parameters:
name - The name of the property object.
propertyName - The PropertyName attribute of the property.
value - The DefaultValue attribute of the property.
type - The Type from ISDefs. This should be one of: PROPERTYTYPE_BOOLEAN, PROPERTYTYPE_INTEGER, PROPERTYTYPE_STRING, PROPERTYTYPE_MULTILINE, PROPERTYTYPE_FLOAT, PROPERTYTYPE_DATE, PROPERTYTYPE_COLOR, PROPERTYTYPE_FILENAME, PROPERTYTYPE_GENERIC.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

removeObjectProperty

public void removeObjectProperty(PropertyInterface property)
                          throws ServiceException,
                                 java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove a Property from this object.

Specified by:
removeObjectProperty in interface MetadataInterface
Parameters:
property - The Property to remove.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setObjectProperties

public void setObjectProperties(java.util.List propertyList)
                         throws ServiceException,
                                java.rmi.RemoteException
Set the collection of Properties associated with this object. Any properties currently associated with this object that aren't in the list will be deleted if they would be orphaned.

Specified by:
setObjectProperties in interface MetadataInterface
Parameters:
propertyList - The new List of Properties to associate with this object.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getPropertySets

public java.util.List getPropertySets()
                               throws ServiceException,
                                      java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get a List of the property sets that are associated with this object.

Specified by:
getPropertySets in interface MetadataInterface
Returns:
A List of PropertySetInterface objects. If no property sets are associated with this object, an empty list is returned.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addPropertySet

public void addPropertySet(PropertySetInterface propertySet)
                    throws ServiceException,
                           java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add a property set to this object.

Specified by:
addPropertySet in interface MetadataInterface
Parameters:
propertySet - A PropertySetInterface to associate with this object.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removePropertySet

public void removePropertySet(PropertySetInterface propertySet)
                       throws ServiceException,
                              java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove a property set from this object.

Specified by:
removePropertySet in interface MetadataInterface
Parameters:
propertySet - The PropertySet to remote from this object.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getPath

public java.lang.String getPath(java.lang.String rootFolderName)
                         throws ServiceException,
                                java.rmi.RemoteException
Get the path of this object from the root folder, including the object name. Clients should consider using the getPathUrl method to get path information.

Specified by:
getPath in interface MetadataInterface
Parameters:
rootFolderName - The name of the root folder for the path. If null is passed in, the default BIP Tree name is used.
Returns:
A String path or null if no valid path exists from the specified root folder to the current object.
Throws:
ServiceException - in the event of repository failure.
java.rmi.RemoteException - in the event of remote object failure.

getParentPath

public java.lang.String getParentPath(java.lang.String rootFolderName)
                               throws ServiceException,
                                      java.rmi.RemoteException
Get the parent path for this object. It includes the path from the root tree object to the folder that contains this object. The object name itself isn't included. Clients should consider using the getPathUrl method to get path information.

Specified by:
getParentPath in interface MetadataInterface
Parameters:
rootFolderName - Name of the root folder for the path. If null is passed in, the default BIP tree name is used.
Returns:
A string path or null if no valid path exists from the specified root folder to the current object.
Throws:
ServiceException - in the event of repository errors.
java.rmi.RemoteException - in the event of remote object failure.

getPaths

public java.util.List getPaths(java.lang.String rootFolderName)
                        throws ServiceException,
                               java.rmi.RemoteException
Deprecated. This method goes back to when there was not a single, canonical root in the metadata. Now that there is, there can only be one path. And since it had a guaranteed NPE for metadata objects I'm pretty sure no one is using it, so don't start.

Get all valid paths for this object.

Specified by:
getPaths in interface MetadataInterface
Parameters:
rootFolderName - Name of the root folder for the path.
Returns:
A List of String paths or null if no valid path exists from the specified root folder to the current object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

newServiceObject

public java.lang.Object newServiceObject()
                                  throws ServiceException,
                                         java.rmi.RemoteException
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
Returns:
The "active" object for this metadata.
Throws:
ServiceException - if an error occurs
java.rmi.RemoteException - in the event of remote object failure

getParents

public java.util.List getParents()
                          throws ServiceException,
                                 java.rmi.RemoteException
Return a List of Folder objects that represent the parent(s) of this object in the hierarchy.

Specified by:
getParents in interface MetadataInterface
Returns:
a List value
Throws:
ServiceException - if an error occurs
java.rmi.RemoteException - in the event of remote object failure

getParent

public FolderInterface getParent()
                          throws ServiceException,
                                 java.rmi.RemoteException
Description copied from interface: MetadataInterface
Return the FolderInterface that contains this object. For objects in the SAS Folder hierarchy, there should be exactly one parent folder.

Specified by:
getParent in interface MetadataInterface
Returns:
The FolderInterface that contains this object as a member.
Throws:
ServiceException - if an error occurs
java.rmi.RemoteException - if an error occurs

getCreateDate

public java.util.Date getCreateDate()
                             throws ServiceException,
                                    java.rmi.RemoteException
Get a Date object representing the time the metadata was created.

Specified by:
getCreateDate in interface MetadataInterface
Returns:
a Date with the date/time the metadata was created.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getCreatedBy

public java.lang.String getCreatedBy()
                              throws ServiceException,
                                     java.rmi.RemoteException
Description copied from interface: MetadataInterface
Gets the name of the user that created the object.

Specified by:
getCreatedBy in interface MetadataInterface
Returns:
created by name
Throws:
ServiceException
java.rmi.RemoteException

getModifyDate

public java.util.Date getModifyDate()
                             throws ServiceException,
                                    java.rmi.RemoteException
Get a Date object representing the time the metadata was last updated.

Specified by:
getModifyDate in interface MetadataInterface
Returns:
a Date with the time the metadata was last updated.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getModifiedBy

public java.lang.String getModifiedBy()
                               throws ServiceException,
                                      java.rmi.RemoteException
Description copied from interface: MetadataInterface
Gets the name of the user that modified the object.

Specified by:
getModifiedBy in interface MetadataInterface
Returns:
modified by name
Throws:
ServiceException
java.rmi.RemoteException

getRemarksList

public java.util.List getRemarksList()
                              throws ServiceException,
                                     java.rmi.RemoteException
Return a List of Remarks objects that represent the dicussion threads related to this object.

Specified by:
getRemarksList in interface MetadataInterface
Returns:
List of Remarks. The discussion threads related to this object
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

setRemarksList

public void setRemarksList(java.util.List remarks)
                    throws ServiceException,
                           java.rmi.RemoteException
Sets the list of Remarks objects that represent the dicussion threads related to this object.

Specified by:
setRemarksList in interface MetadataInterface
Parameters:
remarks - The discussion threads related to this object
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getPermission

public PermissionInterface getPermission(IdentityInterface identity,
                                         PermissionInterface permission)
                                  throws ServiceException,
                                         java.rmi.RemoteException
Get a permission that matches the requested permission for the requested identity on this metadata object. If none exists, return null.

Specified by:
getPermission in interface MetadataInterface
Parameters:
identity - An IdentityInterface for the identity to find the permission for.
permission - The permission to look for.
Returns:
A matching Permission, or null if none was found.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

setPermission

public void setPermission(IdentityInterface identity,
                          PermissionInterface permission)
                   throws ServiceException,
                          java.rmi.RemoteException
Set a new permission on this metadata object.

Specified by:
setPermission in interface MetadataInterface
Parameters:
identity - An IdentityInterface for the identity for the new permission.
permission - The new permission to add.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getPermissions

public java.util.List getPermissions(IdentityInterface identity)
                              throws ServiceException,
                                     java.rmi.RemoteException
Get all the permissions that apply to this object.

Specified by:
getPermissions in interface MetadataInterface
Parameters:
identity - The identity to get permissions for.
Returns:
a List of com.sas.services.security.Permission objects that apply to this object.
Throws:
ServiceException - in the event of repository error.
java.rmi.RemoteException - in the event of remote object failure.

getPermissions

public java.util.List getPermissions(IdentityInterface identity,
                                     java.lang.String[] inheritedPermissions)
                              throws ServiceException,
                                     java.rmi.RemoteException
Get all the permissions that apply to this object.

Specified by:
getPermissions in interface MetadataInterface
Parameters:
identity - The identity to get permissions for.
inheritedPermissions - An array of Strings containing the inherited permissions to look for.
Returns:
a List of com.sas.services.security.Permission objects that apply to this object.
Throws:
ServiceException - in the event of repository error.
java.rmi.RemoteException - in the event of remote object failure.

getIdentities

public java.util.List getIdentities()
                             throws ServiceException,
                                    java.rmi.RemoteException
Get all the identities that are associated to this metadata object through permissions.

Specified by:
getIdentities in interface MetadataInterface
Returns:
a List of IdentityInterface objects that have some permission defined for this object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

addPermissions

public void addPermissions(java.util.List identities,
                           java.util.List permissions)
                    throws ServiceException,
                           java.rmi.RemoteException
Add a set of permissions for a set of identities for this metadata object. All the identities in the List will get all the permissions provided.

Specified by:
addPermissions in interface MetadataInterface
Parameters:
identities - A List of IdentityInterface objects for whom to set the provided permissions.
permissions - a List of com.sas.services.security.Permission objects that specify the permissions to set for these identities.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

removePermissions

public void removePermissions(java.util.List identities,
                              java.util.List permissions)
                       throws ServiceException,
                              java.rmi.RemoteException
Remove permissions matching the identities and permission list.

Specified by:
removePermissions in interface MetadataInterface
Parameters:
identities - A List of com.sas.services.information.metadata.IdentityInterface objects for whom to remove the permissions.
permissions - A List of com.sas.services.security.PermissionInterface objects to remove for the identities.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getAccessControls

public java.util.List getAccessControls()
                                 throws ServiceException,
                                        java.rmi.RemoteException
Get a list of the Access Controls on this object.

Specified by:
getAccessControls in interface MetadataInterface
Returns:
A List of AccessControlEntryInterface objects.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

addAccessControl

public void addAccessControl(AccessControlEntryInterface ace)
                      throws ServiceException,
                             java.rmi.RemoteException
Add an Access Control item to this object.

Specified by:
addAccessControl in interface MetadataInterface
Parameters:
ace - An AccessControlInterface object to add to this object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

removeAccessControl

public void removeAccessControl(AccessControlEntryInterface ace)
                         throws ServiceException,
                                java.rmi.RemoteException
Remove an Access Control item from this object.

Specified by:
removeAccessControl in interface MetadataInterface
Parameters:
ace - An AccessControl object to remove from this object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

moveTo

public void moveTo(FolderInterface folder)
            throws ServiceException,
                   java.rmi.RemoteException
Move this object to a new folder. Any current parent folders will be removed, and replaced with the one provided. If folder is null, no action will be taken.

Specified by:
moveTo in interface MetadataInterface
Parameters:
folder - The new parent Folder of this object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

copyTo

public MetadataInterface copyTo(FolderInterface folder,
                                java.lang.String name)
                         throws ServiceException,
                                java.rmi.RemoteException
Make a copy of this object. A new object will be created with all attributes, and keywords copied from the original. The new object's name will be set from the name argument. If the folder is null, if this object has only one parent, the new object will have the same parent Folder. If it has no parent, or more than one, the new object will not have a parent.

Specified by:
copyTo in interface MetadataInterface
Parameters:
folder - The folder to be the parent of the new object.
name - The name of the new object.
Returns:
The new copy of this object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getExtensions

public java.util.List getExtensions()
                             throws ServiceException,
                                    java.rmi.RemoteException
Get the extensions for this object.

Specified by:
getExtensions in interface MetadataInterface
Returns:
a List of ExtensionInterface objects.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

addExtension

public void addExtension(java.lang.String name,
                         java.lang.String value,
                         java.lang.String type)
                  throws ServiceException,
                         java.rmi.RemoteException
Add an extension to the current set of extensions

Specified by:
addExtension in interface MetadataInterface
Parameters:
name - The new extension name.
value - The new extension value.
type - The new extension value type.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

removeExtension

public void removeExtension(java.lang.String name)
                     throws ServiceException,
                            java.rmi.RemoteException
Remove an Extension from the current extension set.

Specified by:
removeExtension in interface MetadataInterface
Parameters:
name - The name of the extension to remove.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

setExtensions

public void setExtensions(java.util.List extensionList)
                   throws ServiceException,
                          java.rmi.RemoteException
Set the list of extensions on this metadata object. All existing extensions are deleted, and the new set is added.

Specified by:
setExtensions in interface MetadataInterface
Parameters:
extensionList - A List of ExtensionInterface objects. The order of creation needs to be create all of the Extensions, then call this method, then call update.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

isAuthorized

public boolean isAuthorized(java.lang.String permission)
                     throws ServiceException,
                            java.rmi.RemoteException
Check for a specific permission on this object by the user that owns the connection to the repository.

Specified by:
isAuthorized in interface MetadataInterface
Parameters:
permission - The permission string to check for.
Returns:
true if the permission is granted by the server, false otherwise.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

countAssociatedObjects

public int countAssociatedObjects(java.lang.String association)
                           throws ServiceException,
                                  java.rmi.RemoteException
Description copied from interface: MetadataInterface
Count the objects associated to this one via a named association. This count is done without security checks on.

Specified by:
countAssociatedObjects in interface MetadataInterface
Parameters:
association - The association name to count.
Returns:
The count of objects in the association.
Throws:
ServiceException
java.rmi.RemoteException

startTransaction

public MetadataInterface startTransaction()
                                   throws ServiceException,
                                          java.rmi.RemoteException
Start a Transaction for this Metadata object. This will create a child repository to the current repository, move a copy of this object to the child, and return the new MetadataInterface object. This new object can be updated without changing the current cache. The updates can be committed, or rolled back.

Specified by:
startTransaction in interface MetadataInterface
Returns:
a new MetadataInterface object that exists in the temporary child repository.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

commit

public void commit()
            throws ServiceException,
                   java.rmi.RemoteException
Commit changes that have been made to this object to the parent. This will update the parent cache and disable the child repository that this object is using. If this object isn't in a child repository, a ServiceException will be thrown. If an exception is thrown during the commit, you must perform a rollback to close the transaction.

Specified by:
commit in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs. If a ServiceException is thrown, you must perform a rollback to close the transaction.
java.rmi.RemoteException - in the event of remote object failure.

rollback

public void rollback()
              throws ServiceException,
                     java.rmi.RemoteException
Roll back changes to this object, and all objects that have been updated or created in the child repository. This will dispose of the changes and disable the child repository. If this object isn't in a child repository, a ServiceException will be thrown.

Specified by:
rollback in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

transactionEvent

public void transactionEvent(MetadataInterface mi)
                      throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Notify this object that a child transaction has completed either because of a commit or a rollback.

Specified by:
transactionEvent in interface MetadataInterface
Parameters:
mi - The child object that has completed its transaction.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

addTransactionListener

public void addTransactionListener(MetadataInterface mi)
                            throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add a listener to receive event notifications when a transaction is committed or rolled back. This method is intended for use by the Metadata class, and should not be used by external classes.

Specified by:
addTransactionListener in interface MetadataInterface
Parameters:
mi - The metadata object to alert that a transaction has committed or rolled back.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

notifyTransactionListeners

protected void notifyTransactionListeners()
                                   throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logMessage

public void logMessage(int level,
                       java.lang.String message,
                       java.lang.String context,
                       java.lang.Throwable t)
                throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level instead.

Specified by:
logMessage in interface MetadataInterface
Parameters:
level - The level at which to log this message: LoggerInterface.WARN, LoggerInterface.ERROR, etc.
message - The formatted message to output.
context - The logging context for which to output this message. This is usually the fully qualified java class name. If null or zero length, this will default to "com.sas.services.information.metadata".
t - An optional exception to log.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

logMessage

public void logMessage(org.apache.log4j.Level level,
                       java.lang.String message,
                       java.lang.String context,
                       java.lang.Throwable t)
                throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logThrowable

public void logThrowable(int level,
                         java.lang.String message,
                         java.lang.String context,
                         java.lang.Throwable t)
                  throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level.

Parameters:
level -
message -
context -
t -
Throws:
java.rmi.RemoteException

logThrowable

public void logThrowable(org.apache.log4j.Level level,
                         java.lang.String message,
                         java.lang.String context,
                         java.lang.Throwable t)
                  throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(int level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0)
               throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level.

Parameters:
level -
context -
bundle -
key -
arg0 -
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(org.apache.log4j.Level level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0)
               throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(int level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0,
                      java.lang.Object arg1)
               throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level.

Parameters:
level -
context -
bundle -
key -
arg0 -
arg1 -
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(org.apache.log4j.Level level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0,
                      java.lang.Object arg1)
               throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(int level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0,
                      java.lang.Object arg1,
                      java.lang.Object arg2)
               throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level.

Parameters:
level -
context -
bundle -
key -
arg0 -
arg1 -
arg2 -
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(org.apache.log4j.Level level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0,
                      java.lang.Object arg1,
                      java.lang.Object arg2)
               throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(int level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0,
                      java.lang.Object arg1,
                      java.lang.Object arg2,
                      java.lang.Object arg3)
               throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level.

Parameters:
level -
context -
bundle -
key -
arg0 -
arg1 -
arg2 -
arg3 -
Throws:
java.rmi.RemoteException

logFormat

public void logFormat(org.apache.log4j.Level level,
                      java.lang.String context,
                      java.util.ResourceBundle bundle,
                      java.lang.String key,
                      java.lang.Object arg0,
                      java.lang.Object arg1,
                      java.lang.Object arg2,
                      java.lang.Object arg3)
               throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

logMessage

public void logMessage(int level,
                       java.lang.String message)
                throws java.rmi.RemoteException
Deprecated. Use the version that takes an org.apache.log4j.Level instead.

Parameters:
level -
message -
Throws:
java.rmi.RemoteException

logMessage

public void logMessage(org.apache.log4j.Level level,
                       java.lang.String message)
                throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

addRemark

public void addRemark(RemarksInterface remark)
               throws ServiceException,
                      java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add a remark to this smart object

Specified by:
addRemark in interface MetadataInterface
Parameters:
remark - The remark to be added to this smart object
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

isLoggingEnabled

public boolean isLoggingEnabled(org.apache.log4j.Level level,
                                java.lang.String context)
                         throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

isLoggingEnabled

public boolean isLoggingEnabled(int level,
                                java.lang.String context)
                         throws java.rmi.RemoteException
Specified by:
isLoggingEnabled in interface MetadataInterface
Parameters:
level - The level to check: LoggerInterface.WARN, LoggerInterface.ERROR, etc.
context - The logging context to check the level for. This is usually the fully qualified java class name.
Returns:
True if logging enabled at the given level for the given context.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

mapNameToFilesystem

public java.lang.String mapNameToFilesystem(int hostOS,
                                            java.lang.String prefix,
                                            java.lang.String suffix)
                                     throws java.rmi.RemoteException,
                                            java.lang.IllegalArgumentException
Map the metadata object name to a file system path.

Specified by:
mapNameToFilesystem in interface MetadataInterface
Parameters:
hostOS - The host operating system. Valid values include Names.UNKNOWN, Names.WINDOWS, Names.UNIX, Names.ZOS_HFS, Names.ZOS_PDS and Names.WEBDAV.
prefix - The prefix to use when creating the file system path.
suffix - The suffix to use when creating the file system path.
Returns:
String The file system path.
Throws:
java.rmi.RemoteException - In the event of remote object failure.
java.lang.IllegalArgumentException - If a null name is specified or if an invalid host operating system value is specified.

mapUrlToFilesystem

public java.lang.String mapUrlToFilesystem(int hostOS,
                                           java.lang.String prefix,
                                           java.lang.String suffix)
                                    throws ServiceException,
                                           java.rmi.RemoteException,
                                           java.lang.IllegalArgumentException
Map the metadata object's SBIP Url to a file system path.

Specified by:
mapUrlToFilesystem in interface MetadataInterface
Parameters:
hostOS - The host operating system. Valid values include Names.UNKNOWN, Names.WINDOWS, Names.UNIX, Names.ZOS_HFS, Names.ZOS_PDS and Names.WEBDAV.
prefix - The prefix to use when creating the file system path.
suffix - The suffix to use when creating the file system path.
Returns:
String The file system path.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.
java.lang.IllegalArgumentException - If a null name is specified or if an invalid host operating system value is specified.

getPropertyBag

public com.sas.services.information.metadata.propertybag.PropertyBagInterface getPropertyBag()
                                                                                      throws ServiceException,
                                                                                             java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get a "bag" of properties from the metadata object. A Map contains the attributes applicable to the metadata object. The default implementation is to load the map with the default simple attributes. All the values are String objects. Subclasses may override this and return complex objects.

Specified by:
getPropertyBag in interface MetadataInterface
Returns:
A Map of attributes for this object.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

updateFromBag

public void updateFromBag(com.sas.services.information.metadata.propertybag.PropertyBagInterface propertyBag)
                   throws ServiceException,
                          java.rmi.RemoteException
Specified by:
updateFromBag in interface MetadataInterface
Throws:
ServiceException
java.rmi.RemoteException

addToList

protected void addToList(java.util.List list,
                         java.lang.Object o)

removeFromList

protected void removeFromList(java.util.List list,
                              java.lang.Object o)

toString

public java.lang.String toString()
Overrides:
toString in class java.rmi.server.RemoteObject

hashCode

public int hashCode()
Overrides:
hashCode in class java.rmi.server.RemoteObject

checkPulse

protected void checkPulse(boolean dieOnDeleted)
                   throws java.lang.IllegalStateException
Check the state of this object instance. If it's been destroyed, throw an IllegalStateException which will get surfaced to the client application and hopefully handled.

Parameters:
dieOnDeleted - Throw IllegalStateException if the object has been deleted.
Throws:
java.lang.IllegalStateException - if the instance has been destroyed.

getAttribute

public java.lang.String getAttribute(java.lang.String key)
                              throws ServiceException,
                                     java.rmi.RemoteException
Get the value of the attribute with the given key/name.

Specified by:
getAttribute in interface MetadataInterface
Parameters:
key - The name of the attribute to return.
Returns:
The value of the named attribute. Null if none exists.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getAttributes

public java.util.Map getAttributes()
                            throws ServiceException,
                                   java.rmi.RemoteException
Get a list of all the attributes.

Specified by:
getAttributes in interface MetadataInterface
Returns:
A Map of all the attributes of this object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

setAttribute

public void setAttribute(java.lang.String key,
                         java.lang.String value)
                  throws ServiceException,
                         java.rmi.RemoteException
Set the value of an attribute to the given value

Specified by:
setAttribute in interface MetadataInterface
Parameters:
key - The attribute name to set.
value - The value to set on the attribute.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

addAttribute

public void addAttribute(java.lang.String key,
                         java.lang.String value)
                  throws ServiceException,
                         java.rmi.RemoteException
Add an attribute with the given name and value

Specified by:
addAttribute in interface MetadataInterface
Parameters:
key - The name of the attribute to set.
value - The value to set on the attribute.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

deleteAttribute

public void deleteAttribute(java.lang.String key)
                     throws ServiceException,
                            java.rmi.RemoteException
Delete a specific attribute

Specified by:
deleteAttribute in interface MetadataInterface
Parameters:
key - The name of the attribute to delete.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

setAttributes

public void setAttributes(java.util.Map attributeMap)
                   throws ServiceException,
                          java.rmi.RemoteException
Set a number of attributes - names and values are given in the map

Specified by:
setAttributes in interface MetadataInterface
Parameters:
attributeMap - A Map of attributes to set on the object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

addAttributes

public void addAttributes(java.util.Map attributeMap)
                   throws ServiceException,
                          java.rmi.RemoteException
Add a number of attributes - names and values are given in the map.

Specified by:
addAttributes in interface MetadataInterface
Parameters:
attributeMap - A Map of attributes to add to the object.
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

deleteAttributes

public void deleteAttributes(java.util.List attributes)
                      throws ServiceException,
                             java.rmi.RemoteException
Delete a list of attributes.

Specified by:
deleteAttributes in interface MetadataInterface
Parameters:
attributes - List (of String) property names
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

toByteArray

public byte[] toByteArray()
                   throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Write the state of the object to a byte array.

Specified by:
toByteArray in interface MetadataInterface
Returns:
The byte array containing the state of the object.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

fromByteArray

public static MetadataInterface fromByteArray(RepositoryInterface ri,
                                              byte[] data)
                                       throws java.rmi.RemoteException,
                                              ServiceException
Throws:
java.rmi.RemoteException
ServiceException

version

public void version()
             throws ServiceException,
                    java.rmi.RemoteException
Version control the item

Specified by:
version in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

checkout

public void checkout()
              throws ServiceException,
                     java.rmi.RemoteException
Check out the item

Specified by:
checkout in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

checkin

public void checkin()
             throws ServiceException,
                    java.rmi.RemoteException
Check out the item

Specified by:
checkin in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

uncheckout

public void uncheckout()
                throws ServiceException,
                       java.rmi.RemoteException
Check out the item

Specified by:
uncheckout in interface MetadataInterface
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getPreviousVersionNames

public java.util.List getPreviousVersionNames()
                                       throws ServiceException,
                                              java.rmi.RemoteException
Gets a list of previous version names

Specified by:
getPreviousVersionNames in interface MetadataInterface
Returns:
List of previous version names
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

getVersion

public MetadataInterface getVersion(java.lang.String versionName)
                             throws ServiceException,
                                    java.rmi.RemoteException
Return a smart object that represents a particular version

Specified by:
getVersion in interface MetadataInterface
Parameters:
versionName - The name of the version to return
Returns:
MetadataInterface A smart object representing the requested version
Throws:
ServiceException - if a repository error occurs.
java.rmi.RemoteException - in the event of remote object failure.

addDocument

public void addDocument(DocumentInterface doc)
                 throws ServiceException,
                        java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add an associated Document to this object.

Specified by:
addDocument in interface MetadataInterface
Parameters:
doc - The document to associate with this object.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removeDocument

public void removeDocument(DocumentInterface doc)
                    throws ServiceException,
                           java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove a document from this object's Documents association.

Specified by:
removeDocument in interface MetadataInterface
Parameters:
doc - The document to remove from the Documents association.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setDocuments

public void setDocuments(java.util.List docs)
                  throws ServiceException,
                         java.rmi.RemoteException
Description copied from interface: MetadataInterface
Set the list of Documents associated with this object.

Specified by:
setDocuments in interface MetadataInterface
Parameters:
docs - A List of DocumentInterface objects to associate with this object.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getDocuments

public java.util.List getDocuments()
                            throws ServiceException,
                                   java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the List of Documents associated with this object.

Specified by:
getDocuments in interface MetadataInterface
Returns:
A List of DocumentInterface objects.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addNoteTextStore

public void addNoteTextStore(TextStoreInterface note)
                      throws ServiceException,
                             java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add an associated TextStore note to this object.

Specified by:
addNoteTextStore in interface MetadataInterface
Parameters:
note - The TextStore to associate with this object.
Throws:
ServiceException - If a service level error occurs or if a TextStore with the same Name and TextRole already exists on this object.
java.rmi.RemoteException - In the event of remote object failure.

addNoteTextStore

public TextStoreInterface addNoteTextStore(java.lang.String name,
                                           java.lang.String role,
                                           java.lang.String type,
                                           java.lang.String text)
                                    throws ServiceException,
                                           java.rmi.RemoteException
Description copied from interface: MetadataInterface
Creates a TextStore note and adds it to this object.

Specified by:
addNoteTextStore in interface MetadataInterface
Parameters:
name - note name
role - note TextRole
type - note TextType
text - note text
Returns:
TextStoreInterface for new note
Throws:
ServiceException - If a service level error occurs or if a TextStore with the same Name and TextRole already exists on this object.
java.rmi.RemoteException - In the event of remote object failure.

removeNoteTextStore

public void removeNoteTextStore(TextStoreInterface note)
                         throws ServiceException,
                                java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove a TextStore note from this object's Notes association.

Specified by:
removeNoteTextStore in interface MetadataInterface
Parameters:
note - The TextStore to remove from the Notes association.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setNoteTextStores

public void setNoteTextStores(java.util.List<TextStoreInterface> notes)
                       throws ServiceException,
                              java.rmi.RemoteException
Description copied from interface: MetadataInterface
Set the list of TextStores associated as Notes for this object.

Specified by:
setNoteTextStores in interface MetadataInterface
Parameters:
notes - A List of TextStoreInterface objects to associate with this object.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getNoteTextStores

public java.util.List<TextStoreInterface> getNoteTextStores()
                                                     throws ServiceException,
                                                            java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the List of TextStore notes associated with this object.

Specified by:
getNoteTextStores in interface MetadataInterface
Returns:
A List of TextStoreInterface objects.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getNoteTextStoresByRole

public java.util.List<TextStoreInterface> getNoteTextStoresByRole(java.lang.String textRoleFilter)
                                                           throws ServiceException,
                                                                  java.rmi.RemoteException
Description copied from interface: MetadataInterface
Return a list of TextStore notes associated with this object filtered by TextRole.

Specified by:
getNoteTextStoresByRole in interface MetadataInterface
Parameters:
textRoleFilter - returned TextStore notes must have the specified TextRole attribute.
Returns:
A list of TextStoreInterface objects.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getNoteTextStore

public TextStoreInterface getNoteTextStore(java.lang.String name,
                                           java.lang.String textRole)
                                    throws ServiceException,
                                           java.rmi.RemoteException
Description copied from interface: MetadataInterface
Return a named TextStore note associated with this object or null if the TextStore does not exist. The first matched TextStore is returned if more than one matching TextStore is found.

Specified by:
getNoteTextStore in interface MetadataInterface
Parameters:
name - name of the TextStore note.
textRole - TextRole attribute of the named TextStore note. May be null if the TextRole value is not known.
Returns:
named TextStore note
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addGroup

public void addGroup(GroupInterface group)
              throws ServiceException,
                     java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add this object to a group.

Specified by:
addGroup in interface MetadataInterface
Parameters:
group - The group to add this object to.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removeGroup

public void removeGroup(GroupInterface group)
                 throws ServiceException,
                        java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove this object from a group.

Specified by:
removeGroup in interface MetadataInterface
Parameters:
group - The group to remove this object from.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setGroups

public void setGroups(java.util.List groups)
               throws ServiceException,
                      java.rmi.RemoteException
Description copied from interface: MetadataInterface
Set the list of groups this object belongs to.

Specified by:
setGroups in interface MetadataInterface
Parameters:
groups - The set of groups this object belongs to. Upon successful completion, this object will be a member of the listed groups, and no others. If this list is empty, or null, the object will be removed from all groups.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getGroups

public java.util.List getGroups()
                         throws ServiceException,
                                java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the list of groups this object is a member of.

Specified by:
getGroups in interface MetadataInterface
Returns:
The List of GroupInterface objects this object is a member of.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getPrimaryPropertyGroup

public PropertyGroupInterface getPrimaryPropertyGroup()
                                               throws ServiceException,
                                                      java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get this object's primary PropertyGroup object.

Specified by:
getPrimaryPropertyGroup in interface MetadataInterface
Returns:
A PropertyGroupInterface object; this object's primary property group.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setPrimaryPropertyGroup

public void setPrimaryPropertyGroup(PropertyGroupInterface pgroup)
                             throws ServiceException,
                                    java.rmi.RemoteException
Description copied from interface: MetadataInterface
Set this object's primary property group object.

Specified by:
setPrimaryPropertyGroup in interface MetadataInterface
Parameters:
pgroup - The PropertyGroupInterface object which is this object's primary property group.
Throws:
ServiceException - If a service level error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getImplementors

public java.util.List getImplementors()
                               throws ServiceException,
                                      java.rmi.RemoteException
Get a List of the SoftwareComponent Implementors for this object.

Specified by:
getImplementors in interface MetadataInterface
Returns:
A List of SoftwareComponentInterface objects associated to this object as Implementors.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addImplementor

public void addImplementor(SoftwareComponentInterface softwareComponent)
                    throws ServiceException,
                           java.rmi.RemoteException
Add a SoftwareComponent as an implementor of this object.

Specified by:
addImplementor in interface MetadataInterface
Parameters:
softwareComponent - The SoftwareComponent implementor.
Throws:
ServiceException - If a repository error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removeImplementor

public void removeImplementor(SoftwareComponentInterface softwareComponent)
                       throws ServiceException,
                              java.rmi.RemoteException
Remove a SoftwareComponent from the list of implementors on this object.

Specified by:
removeImplementor in interface MetadataInterface
Parameters:
softwareComponent - The SoftwareComponentInterface to remove from the implementors list.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getUsingPrototype

public MetadataInterface getUsingPrototype()
                                    throws ServiceException,
                                           java.rmi.RemoteException
Get the prototype which this object uses for description/validation.

Specified by:
getUsingPrototype in interface MetadataInterface
Returns:
A PrototypeInterface object which this object uses for its definition.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setUsingPrototype

public void setUsingPrototype(MetadataInterface prototype)
                       throws ServiceException,
                              java.rmi.RemoteException
Set the prototype which is used by this object for description/validation.

Specified by:
setUsingPrototype in interface MetadataInterface
Parameters:
prototype - The MetadataInterface object which defines the parameters, associations, and properties appropriate to this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getUsedByPrototypes

public java.util.List getUsedByPrototypes()
                                   throws ServiceException,
                                          java.rmi.RemoteException
Get the List of objects which use this object as a prototype.

Specified by:
getUsedByPrototypes in interface MetadataInterface
Returns:
A List of objects that use this object as a prototype.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addUsedByPrototype

public void addUsedByPrototype(MetadataInterface prototyped)
                        throws ServiceException,
                               java.rmi.RemoteException
Add an object which uses this object as a prototype.

Specified by:
addUsedByPrototype in interface MetadataInterface
Parameters:
prototyped - An object which is prototyped by this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removeUsedByPrototype

public void removeUsedByPrototype(MetadataInterface prototyped)
                           throws ServiceException,
                                  java.rmi.RemoteException
Remove an object from the list prototyped by this object.

Specified by:
removeUsedByPrototype in interface MetadataInterface
Parameters:
prototyped - The object which is no longer prototyped by this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getPrompts

public java.util.List getPrompts()
                          throws ServiceException,
                                 java.rmi.RemoteException
Get the List of prompts associated with this object.

Specified by:
getPrompts in interface MetadataInterface
Returns:
A List of BaseOMRPromptInterface objects associated with this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setPrompts

public void setPrompts(java.util.List prompts)
                throws ServiceException,
                       java.rmi.RemoteException
Set the List of Prompts on this object.

Specified by:
setPrompts in interface MetadataInterface
Parameters:
prompts - A List of BaseOMRPromptInterface objects.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addPrompt

public void addPrompt(BaseOMRPromptInterface prompt)
               throws ServiceException,
                      java.rmi.RemoteException
Add a prompt to this object.

Specified by:
addPrompt in interface MetadataInterface
Parameters:
prompt - A BaseOMRPromptInterface object to add to this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removePrompt

public void removePrompt(BaseOMRPromptInterface prompt)
                  throws ServiceException,
                         java.rmi.RemoteException
Remove a prompt from this object.

Specified by:
removePrompt in interface MetadataInterface
Parameters:
prompt - The BaseOMRPromptInterface to remove from this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getPrompt

public BaseOMRPromptInterface getPrompt()
                                 throws ServiceException,
                                        java.rmi.RemoteException
Get the first prompt on this object. If more than one prompt is associated to this object, only the first one is returned.

Specified by:
getPrompt in interface MetadataInterface
Returns:
The first prompt associated to this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

setPrompt

public void setPrompt(BaseOMRPromptInterface prompt)
               throws ServiceException,
                      java.rmi.RemoteException
Set the prompt on this object. If there are already prompts associated with this object, they are removed and only this prompt will be associated to the object.

Specified by:
setPrompt in interface MetadataInterface
Parameters:
prompt - The prompt object to associate to this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addProcessorInterface

public void addProcessorInterface(java.lang.String interfaceClassName,
                                  com.sas.services.information.publicobject.ProcessorInterface actionInterface)
                           throws ServiceException
Add an action interface to this class.

Specified by:
addProcessorInterface in interface PublicObjectInterface
Parameters:
interfaceClassName -
actionInterface -
Throws:
ServiceException

getProcessorInterface

public com.sas.services.information.publicobject.ProcessorInterface getProcessorInterface(java.lang.String interfaceClassName)
                                                                                   throws ServiceException,
                                                                                          java.rmi.RemoteException
Get the specified action interface.

Specified by:
getProcessorInterface in interface PublicObjectInterface
Parameters:
interfaceClassName -
Returns:
Processor.
Throws:
ServiceException
java.rmi.RemoteException

getIdentifier

public java.lang.String getIdentifier()
                               throws ServiceException,
                                      java.rmi.RemoteException
Description copied from interface: PublicObjectInterface
Get the unique ID of this object.

Specified by:
getIdentifier in interface PublicObjectInterface
Returns:
String
Throws:
ServiceException
java.rmi.RemoteException

getContainer

public PublicObjectContainerInterface getContainer()
                                            throws ServiceException,
                                                   java.rmi.RemoteException
Returns the container or parent object. In most cases, this method will return the parent folder that contains this object. However, this method should be overridden by any object type that is contained by a non-folder object.

Specified by:
getContainer in interface PublicObjectInterface
Returns:
PublicObjectContainerInterface
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

getTypeDescriptor

public TypeDescriptorInterface getTypeDescriptor()
                                          throws ServiceException,
                                                 java.rmi.RemoteException
Description copied from interface: PublicObjectInterface
Get the type descriptor which should have the information from the Type Dictionary in metadata available for the clients.

Specified by:
getTypeDescriptor in interface PublicObjectInterface
Returns:
TypeDescriptorInterface
Throws:
ServiceException
java.rmi.RemoteException

getObjectURI

public java.net.URI getObjectURI()
                          throws ServiceException
Description copied from interface: PublicObjectInterface
This method is currently not being implemented and is reserved for future use.

Get the location of this object in the SAS Tree. This should be of the form sasds://xxx/xxx/xxx/

Specified by:
getObjectURI in interface PublicObjectInterface
Returns:
java.net.URI
Throws:
ServiceException

getResponsibleParties

public java.util.List getResponsibleParties()
                                     throws ServiceException,
                                            java.rmi.RemoteException
Description copied from interface: MetadataInterface
Get the responsible parties for this object.

Specified by:
getResponsibleParties in interface MetadataInterface
Returns:
A List of Responsibility objects representing the responsible parties for this object.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

addResponsibleParty

public void addResponsibleParty(com.sas.services.information.publicobject.Responsibility newResponsibility)
                         throws ServiceException,
                                java.rmi.RemoteException
Description copied from interface: MetadataInterface
Add a new responsibleParty to this object.

Specified by:
addResponsibleParty in interface MetadataInterface
Parameters:
newResponsibility - The new responsible party to add.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removeResponsibleParty

public void removeResponsibleParty(com.sas.services.information.publicobject.Responsibility responsibility)
                            throws ServiceException,
                                   java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove a responsible party from this metadata object.

Specified by:
removeResponsibleParty in interface MetadataInterface
Parameters:
responsibility - The responsible party to remove.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

removeResponsiblePartyByIdentity

public void removeResponsiblePartyByIdentity(com.sas.services.information.publicobject.Responsibility responsibility)
                                      throws ServiceException,
                                             java.rmi.RemoteException
Description copied from interface: MetadataInterface
Remove a responsible party from this metadata object. The identity of the responsibility as well as the role must match a responsible party in metadata for it to be removed.

Specified by:
removeResponsiblePartyByIdentity in interface MetadataInterface
Parameters:
responsibility - The responsible party to remove.
Throws:
ServiceException - If a server error occurs.
java.rmi.RemoteException - In the event of remote object failure.

isCompatible

public boolean isCompatible()
                     throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Return a boolean indicating if this object is fully compatible with the version of the metadata.

Specified by:
isCompatible in interface MetadataInterface
Returns:
true if the metadata and object are fully compatible, false otherwise.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

isReadCompatible

public boolean isReadCompatible()
                         throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Return a boolean indicating if this object is read compatible with the version of the metadata. Read compatibility is a subset of full compatibility. A fully compatible object is always read compatible, but a read compatible object is not always fully compatible.

Specified by:
isReadCompatible in interface MetadataInterface
Returns:
true if the metadata and object are read compatible, false otherwise.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

getUsageVersion

public com.sas.util.UsageVersion getUsageVersion()
                                          throws java.rmi.RemoteException
Description copied from interface: MetadataInterface
Return the usage version of the metadata.

Specified by:
getUsageVersion in interface MetadataInterface
Returns:
The metadata usage version.
Throws:
java.rmi.RemoteException - In the event of remote object failure.

setCompatibility

protected void setCompatibility(com.sas.util.UsageVersion oldestVersion,
                                com.sas.util.UsageVersion currentVersion)
                         throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

isConnectionException

protected boolean isConnectionException(java.lang.Throwable ex)

getDefaultLocalizableProperties

protected com.sas.storage.editableproperties.PropertyList getDefaultLocalizableProperties()

setDefaultLocalizableProperties

protected void setDefaultLocalizableProperties(com.sas.storage.editableproperties.PropertyMap map)

isObjectAlive

public boolean isObjectAlive()
                      throws ServiceException,
                             java.rmi.RemoteException
Description copied from interface: MetadataInterface
Check to be sure the object still exists in the metadata server. This forces a trip to the server, but does not update the object in memory. If you want to refresh the object, use refresh. It only checks to see if the object is still there, but not that the user can still read it.

Specified by:
isObjectAlive in interface MetadataInterface
Returns:
true if the object is found. False otherwise.
Throws:
ServiceException - In the event of repository failure.
java.rmi.RemoteException - In the event of remote object failure.

validateNameAndFolder

protected void validateNameAndFolder(FolderInterface targetFolder)
                              throws ServiceException,
                                     java.rmi.RemoteException
Throws:
ServiceException
java.rmi.RemoteException

validateNameAndFolder

protected void validateNameAndFolder(FolderInterface targetFolder,
                                     MetadataNameConstraint constraint)
                              throws ServiceException,
                                     java.rmi.RemoteException
Throws:
ServiceException
java.rmi.RemoteException

getAuthorizationUtil

public AuthorizationUtilInterface getAuthorizationUtil()
                                                throws ServiceException,
                                                       java.rmi.RemoteException
Obtain the AuthorizationUtil Interface for this object

Specified by:
getAuthorizationUtil in interface MetadataInterface
Returns:
an AuthorizationUtilInterface
Throws:
ServiceException - If a metadata server error occurs.
java.rmi.RemoteException - In the event of remote object failure.



Copyright © 2009 SAS Institute Inc. All Rights Reserved.