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

com.sas.services.information.metadata
Class FilteredFolder

java.lang.Object
  |
  +--java.rmi.server.RemoteObject
        |
        +--java.rmi.server.RemoteServer
              |
              +--java.rmi.server.UnicastRemoteObject
                    |
                    +--com.sas.services.information.metadata.Metadata
                          |
                          +--com.sas.services.information.metadata.Folder
                                |
                                +--com.sas.services.information.metadata.FilteredFolder
All Implemented Interfaces:
FilteredFolderInterface, FolderInterface, MetadataInterface,
Direct Known Subclasses:
FilteredRepository

public class FilteredFolder
extends Folder
implements FilteredFolderInterface, java.io.Serializable

This is a generic interface for interacting with a Folder object. This class is specifically intended to represent results coming from a search where not all items within a folder will be represented.

Since:
1.0
See Also:
Serialized Form

Fields inherited from class com.sas.services.information.metadata.Metadata
_repository, _repositoryFlag, _repositoryObject, formats, gmtZone, REPOSITORY_DAV, REPOSITORY_LDAP, REPOSITORY_NONE, REPOSITORY_OMR
 
Fields inherited from class java.rmi.server.RemoteObject
ref
 
Fields inherited from interface com.sas.services.information.metadata.FolderInterface
FOLDER_TYPE_BIP
 
Fields inherited from interface com.sas.services.information.metadata.MetadataInterface
PERMISSION_READMETADATA, PERMISSION_WRITEMETADATA
 
Constructor Summary
  FilteredFolder(FilteredFolderInterface p, FolderInterface f)
          Construct a new FilteredFolder with a parent and a "real" folder.
protected FilteredFolder(FilteredFolderInterface p, FolderInterface f, Class theClass)
          Construct a new FilteredFolder with a parent and a "real" folder.
 
Method Summary
 void addLocalItem(MetadataInterface obj)
          Add a filtered result object to this folder.
 void addSubfolder(FolderInterface folder)
          Add a subfolder to this FilteredFolder.
 FolderInterface getFolder()
          Get the "real" folder with the unfiltered contents that this folder represents.
 MetadataInterface getItem(String name)
          Get a named item from the folder.
 MetadataInterface getItem(String name, Class itemClass)
          Deprecated. in favor of getItemByClass
 MetadataInterface getItem(String name, String metadataType)
          Deprecated. in favor of getItemByType.
 MetadataInterface getItemByClass(String name, Class itemClass)
          Get a named item from the folder.
 MetadataInterface getItemByType(String name, String metadataType)
          Get a named item from the folder.
 List getItems()
          List all items in the folder.
 List getItems(Class itemClass)
          Deprecated. in favor of getItemsByClass.
 List getItems(String metadataType)
          Deprecated. in favor of getItemsByType.
 List getItemsByClass(Class itemClass)
          List the items in the folder that match the Class passed in as a parameter.
 List getItemsByType(String metadataType)
          Get a list of items in the folder of a specific type.
 String getName()
          Get the name for this object.
 FolderInterface getParent()
          Get the parent FilteredFolder to this folder.
 String getReposId()
          Get the repository ID for the item.
 FolderInterface getSubfolder(String name)
          Get a named subfolder.
 List getSubfolders()
          Get all the folders immediately below this one in the hiearchy.
 String getType()
          Return a type string to identify this object.
 
Methods inherited from class com.sas.services.information.metadata.Folder
addItem, addNewItem, delete, deleteItem, deleteSubfolder, getFolderRefresh, getFolderType, getItemRefresh, getPath, makeSubfolder, mapNameToFilesystem, mapUrlToFilesystem, removeItem, removeSubfolder, setFolderRefresh, setFolderType, setItemRefresh, setName, setRepository
 
Methods inherited from class com.sas.services.information.metadata.Metadata
add, addAccessControl, addAttribute, addAttributes, addExtension, addKeyword, addPermissions, addRemark, addTransactionListener, checkin, checkout, clearInformationService, commit, copyTo, deleteAttribute, deleteAttributes, getAccessControls, getAttribute, getAttributes, getCreateDate, getDescription, getEntityKey, getEntityURL, getExtensions, getGUID, getIdentities, getInformationService, getKeywords, getModifyDate, getParentPath, getParents, getPath, getPaths, getPathUrl, getPathUrl, getPermission, getPermissions, getPermissions, getPreviousVersionNames, getRemarksList, getRepository, getRepositoryEntity, getReposKey, getTrackingId, getTreeRefresh, getVersion, isAuthorized, isLoggingEnabled, logMessage, moveTo, newServiceObject, notifyTransactionListeners, refresh, removeAccessControl, removeExtension, removeKeyword, removePermissions, rollback, setAttribute, setAttributes, setDescription, setGUID, setKeywords, setPermission, setRemarksList, setTreeRefresh, startTransaction, transactionEvent, uncheckout, update, version
 
Methods inherited from class java.rmi.server.UnicastRemoteObject
clone, exportObject, exportObject, exportObject, unexportObject
 
Methods inherited from class java.rmi.server.RemoteServer
getClientHost, getLog, setLog
 
Methods inherited from class java.rmi.server.RemoteObject
equals, getRef, hashCode, toString, toStub
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.sas.services.information.metadata.FolderInterface
addItem, addNewItem, deleteItem, deleteSubfolder, getFolderType, getPath, makeSubfolder, removeItem, removeSubfolder, setFolderType
 
Methods inherited from interface com.sas.services.information.metadata.MetadataInterface
add, addAccessControl, addAttribute, addAttributes, addExtension, addKeyword, addPermissions, addRemark, addTransactionListener, checkin, checkout, commit, copyTo, delete, deleteAttribute, deleteAttributes, getAccessControls, getAttribute, getAttributes, getCreateDate, getDescription, getEntityKey, getEntityURL, getExtensions, getGUID, getIdentities, getKeywords, getModifyDate, getParentPath, getParents, getPath, getPaths, getPathUrl, getPathUrl, getPermission, getPermissions, getPermissions, getPreviousVersionNames, getRemarksList, getRepository, getRepositoryEntity, getReposKey, getTrackingId, getVersion, isAuthorized, isLoggingEnabled, logMessage, mapNameToFilesystem, mapUrlToFilesystem, moveTo, newServiceObject, refresh, removeAccessControl, removeExtension, removeKeyword, removePermissions, rollback, setAttribute, setAttributes, setDescription, setGUID, setKeywords, setName, setPermission, setRemarksList, setRepository, startTransaction, transactionEvent, uncheckout, update, version
 

Constructor Detail

FilteredFolder

public FilteredFolder(FilteredFolderInterface p,
                      FolderInterface f)
               throws RemoteException
Construct a new FilteredFolder with a parent and a "real" folder.

Parameters:
p - The FilteredFolderInterface for the parent of this FilteredFolder.
f - The FolderInterface from the repository that contains the unfiltered contents.
Throws:
RemoteException - in the event of remote object failure.

FilteredFolder

protected FilteredFolder(FilteredFolderInterface p,
                         FolderInterface f,
                         Class theClass)
                  throws RemoteException
Construct a new FilteredFolder with a parent and a "real" folder.

Parameters:
p - The FilteredFolderInterface for the parent of this FilteredFolder.
f - The FolderInterface from the repository that contains the unfiltered contents.
Throws:
RemoteException - in the event of remote object failure.
Method Detail

getName

public String getName()
               throws RemoteException
Description copied from interface: MetadataInterface
Get the name for this object.

Specified by:
getName in interface MetadataInterface
Overrides:
getName in class Metadata
Following copied from interface: com.sas.services.information.metadata.MetadataInterface
Returns:
The object name.
Throws:
RemoteException - if an error occurs

getReposId

public String getReposId()
                  throws RemoteException
Description copied from interface: MetadataInterface
Get the repository ID for the item. This should be a string that uniquely identifies the object within this repository.

Specified by:
getReposId in interface MetadataInterface
Overrides:
getReposId in class Metadata
Following copied from interface: com.sas.services.information.metadata.MetadataInterface
Returns:
The repository identifier for this object.
Throws:
RemoteException - if an error occurs

addSubfolder

public void addSubfolder(FolderInterface folder)
                  throws ServiceException,
                         RemoteException
Add a subfolder to this FilteredFolder. This isn't an actual persisted add, just an add to a collection.

Specified by:
addSubfolder in interface FolderInterface
Overrides:
addSubfolder in class Folder
Parameters:
folder - The FolderInterface to add to this folder.
Throws:
RemoteException - in the event of remote object failure.

addLocalItem

public void addLocalItem(MetadataInterface obj)
                  throws RemoteException
Add a filtered result object to this folder.

Specified by:
addLocalItem in interface FilteredFolderInterface
Parameters:
obj - The object to add.
Throws:
RemoteException - in the event of remote object failure.

getFolder

public FolderInterface getFolder()
                          throws RemoteException
Get the "real" folder with the unfiltered contents that this folder represents.

Specified by:
getFolder in interface FilteredFolderInterface
Returns:
The FolderInterface for the repository folder with the unfiltered contents.
Throws:
RemoteException - in the event of remote object failure.

getType

public String getType()
               throws RemoteException
Return a type string to identify this object.

Specified by:
getType in interface MetadataInterface
Overrides:
getType in class Folder
Returns:
The type string ("Folder").
Throws:
RemoteException - in the event of remote object failure.

getParent

public FolderInterface getParent()
                          throws RemoteException
Get the parent FilteredFolder to this folder.

Specified by:
getParent in interface FolderInterface
Overrides:
getParent in class Folder
Returns:
The FilteredFolder that's the parent to this folder, or null if this folder doesn't have a parent.
Throws:
RemoteException - in the event of remote object failure.

getItems

public List getItems()
              throws ServiceException,
                     RemoteException
List all items in the folder. These are only the individual items. Subfolders will be returned separately.

Specified by:
getItems in interface FolderInterface
Overrides:
getItems in class Folder
Returns:
A List of MetadataInterface objects in this folder.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItems

public List getItems(String metadataType)
              throws ServiceException,
                     RemoteException
Deprecated. in favor of getItemsByType.

Get a list of items in the folder of a specific type.

Parameters:
metadataType - A String that will match the output from the object's getType method.
Returns:
A List of MetadataInterface objects whose getType() method returns the string specified by metadataType. If there aren't any matching objects, an empty List is returned.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItemsByType

public List getItemsByType(String metadataType)
                    throws ServiceException,
                           RemoteException
Get a list of items in the folder of a specific type.

Specified by:
getItemsByType in interface FolderInterface
Overrides:
getItemsByType in class Folder
Parameters:
metadataType - A String that will match the output from the object's getType method.
Returns:
A List of MetadataInterface objects whose getType() method returns the string specified by metadataType. If there aren't any matching objects, an empty List is returned.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItems

public List getItems(Class itemClass)
              throws ServiceException,
                     RemoteException
Deprecated. in favor of getItemsByClass.

List the items in the folder that match the Class passed in as a parameter. This Class should be a subclass of MetadataInterface.

Parameters:
itemClass - The Class used to filter the folder objects to return.
Returns:
A List of MetadataInterface objects that match the itemClass. If no objects match the class, an empty List is returned.
Throws:
ServiceException - If a repository error occurs.
RemoteException - in the event of remote object failure.

getItemsByClass

public List getItemsByClass(Class itemClass)
                     throws ServiceException,
                            RemoteException
List the items in the folder that match the Class passed in as a parameter. This Class should be a subclass of MetadataInterface.

Specified by:
getItemsByClass in interface FolderInterface
Overrides:
getItemsByClass in class Folder
Parameters:
itemClass - The Class used to filter the folder objects to return.
Returns:
A List of MetadataInterface objects that match the itemClass. If no objects match the class, an empty List is returned.
Throws:
ServiceException - If a repository error occurs.
RemoteException - in the event of remote object failure.

getItem

public MetadataInterface getItem(String name)
                          throws ServiceException,
                                 RemoteException
Get a named item from the folder. With only a name, we can't guarantee that the object coming back will be the one the user wants. Even if we ask for a type, name collisions can occur.

Specified by:
getItem in interface FolderInterface
Overrides:
getItem in class Folder
Parameters:
name - The name of the object to return.
Returns:
A MetadataInterface object matching name, or null if no object with that name is in the folder.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItem

public MetadataInterface getItem(String name,
                                 String metadataType)
                          throws ServiceException,
                                 RemoteException
Deprecated. in favor of getItemByType.

Get a named item from the folder. With only a name, we can't guarantee that the object coming back will be the one the user wants. Even if we ask for a type, name collisions can occur.
Parameters:
name - The name of the object to return.
metadataType - The type of object to return.
Returns:
A MetadataInterface object that matches the name and type requested, or null if none is found.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItemByType

public MetadataInterface getItemByType(String name,
                                       String metadataType)
                                throws ServiceException,
                                       RemoteException
Get a named item from the folder. With only a name, we can't guarantee that the object coming back will be the one the user wants. Even if we ask for a type, name collisions can occur.
Specified by:
getItemByType in interface FolderInterface
Overrides:
getItemByType in class Folder
Parameters:
name - The name of the object to return.
metadataType - The type of object to return.
Returns:
A MetadataInterface object that matches the name and type requested, or null if none is found.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItem

public MetadataInterface getItem(String name,
                                 Class itemClass)
                          throws ServiceException,
                                 RemoteException
Deprecated. in favor of getItemByClass

Get a named item from the folder. It must match both the name and the Class provided. If no Class is provided on the call, the first object matching the name is retuned. If no match is found, null is returned.

Parameters:
name - The name of the object to return.
itemClass - The Class of the object to return.
Returns:
A MetadataInterface object in the folder that matches the name and Class requested or null if no match was found.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getItemByClass

public MetadataInterface getItemByClass(String name,
                                        Class itemClass)
                                 throws ServiceException,
                                        RemoteException
Get a named item from the folder. It must match both the name and the Class provided. If no Class is provided on the call, the first object matching the name is retuned. If no match is found, null is returned.

Specified by:
getItemByClass in interface FolderInterface
Overrides:
getItemByClass in class Folder
Parameters:
name - The name of the object to return.
itemClass - The Class of the object to return.
Returns:
A MetadataInterface object in the folder that matches the name and Class requested or null if no match was found.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getSubfolders

public List getSubfolders()
                   throws ServiceException,
                          RemoteException
Get all the folders immediately below this one in the hiearchy.

Specified by:
getSubfolders in interface FolderInterface
Overrides:
getSubfolders in class Folder
Returns:
A List of FolderInterface objects that are members of this folder.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

getSubfolder

public FolderInterface getSubfolder(String name)
                             throws ServiceException,
                                    RemoteException
Get a named subfolder.

Specified by:
getSubfolder in interface FolderInterface
Overrides:
getSubfolder in class Folder
Parameters:
name - The name of the folder to return.
Returns:
A FolderInterface object with the name requested, or null if it doesn't exist.
Throws:
ServiceException - if a repository error occurs.
RemoteException - in the event of remote object failure.

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




Copyright © 2006 SAS Institute Inc. All Rights Reserved.
javadoc generated Fri, 10 Feb 2006 17:28:57