org.xiruss.repository.api
Class NullStorageManager

java.lang.Object
  extended by org.xiruss.repository.api.NullStorageManager
All Implemented Interfaces:
StorageManager, RepositoryObject

public class NullStorageManager
extends java.lang.Object
implements StorageManager


Constructor Summary
NullStorageManager()
           
 
Method Summary
 void accept(RepositoryVisitor visitor)
           
 int compareTo(java.lang.Object arg0)
           
 java.lang.String getId()
           
 java.lang.String getName()
           
 java.util.Map getProperties()
           
 java.lang.Object getProperty(java.lang.String propertyName)
           
 java.util.Set getPropertyNames()
           
 Repository getRepository()
           
 StorageObjectData getStorageObjectData(StorageObject so)
          Creates a new storage object version.
 int getType()
           
 boolean hasProperty(java.lang.String propertyName)
           
 void initialize(Repository rep, java.lang.String objId, java.lang.String name)
          Initialize the object with the specified object ID and name.
 boolean isNull()
           
 void setId(java.lang.String id)
          Sets the ID on a newly-created repository object.
 java.lang.String setName(java.lang.String newName)
          Sets the name of object.
 void setProperty(java.lang.String propertyName, java.lang.Object propertyValue)
           
 void setStorageObjectData(StorageObject so)
          Sets the storage object data for a storage object version.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.xiruss.snapcm.api.RepositoryObject
toString
 

Constructor Detail

NullStorageManager

public NullStorageManager()
Method Detail

getStorageObjectData

public StorageObjectData getStorageObjectData(StorageObject so)
                                       throws java.io.IOException
Description copied from interface: StorageManager
Creates a new storage object version.

Specified by:
getStorageObjectData in interface StorageManager
Returns:
Throws:
java.io.IOException

setStorageObjectData

public void setStorageObjectData(StorageObject so)
                          throws java.io.IOException
Description copied from interface: StorageManager
Sets the storage object data for a storage object version.

Specified by:
setStorageObjectData in interface StorageManager
Parameters:
so - StorageObject to set the data on.
Throws:
java.io.IOException

initialize

public void initialize(Repository rep,
                       java.lang.String objId,
                       java.lang.String name)
                throws ObjectMutationException
Description copied from interface: RepositoryObject
Initialize the object with the specified object ID and name. This method is for the benefit of repositories that need to construct new objects using no-argument constructors.

Specified by:
initialize in interface RepositoryObject
Throws:
ObjectMutationException - If object already has an assigned ID, indicating that is has already been constructed.

setId

public void setId(java.lang.String id)
           throws ObjectMutationException
Description copied from interface: RepositoryObject
Sets the ID on a newly-created repository object. This is write-once property.

Specified by:
setId in interface RepositoryObject
Parameters:
id - Object ID (assigned by the owning repository)
Throws:
ObjectMutationException - If object already has an assigned ID, indicating that is has already been constructed.

getName

public java.lang.String getName()
Specified by:
getName in interface RepositoryObject

setName

public java.lang.String setName(java.lang.String newName)
Description copied from interface: RepositoryObject
Sets the name of object. Returns the old object name.

Specified by:
setName in interface RepositoryObject
Parameters:
newName - New name to set on the object.
Returns:
Old object name

getId

public java.lang.String getId()
Specified by:
getId in interface RepositoryObject

getRepository

public Repository getRepository()
Specified by:
getRepository in interface RepositoryObject
Returns:

hasProperty

public boolean hasProperty(java.lang.String propertyName)
Specified by:
hasProperty in interface RepositoryObject
Returns:

getProperty

public java.lang.Object getProperty(java.lang.String propertyName)
Specified by:
getProperty in interface RepositoryObject
Parameters:
propertyName - The name of the property to retrieve.
Returns:
The property value object.

setProperty

public void setProperty(java.lang.String propertyName,
                        java.lang.Object propertyValue)
Specified by:
setProperty in interface RepositoryObject

compareTo

public int compareTo(java.lang.Object arg0)
Specified by:
compareTo in interface RepositoryObject

getType

public int getType()
Specified by:
getType in interface RepositoryObject
Returns:

isNull

public boolean isNull()
Specified by:
isNull in interface RepositoryObject

getPropertyNames

public java.util.Set getPropertyNames()
Specified by:
getPropertyNames in interface RepositoryObject

accept

public void accept(RepositoryVisitor visitor)
            throws java.lang.Throwable
Specified by:
accept in interface RepositoryObject
Throws:
java.lang.Throwable

getProperties

public java.util.Map getProperties()
Specified by:
getProperties in interface RepositoryObject