|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.arsdigita.domain.DomainObject
com.arsdigita.kernel.PackageType
ApplicationType
instead.
Represents a package type.
Field Summary | |
static String |
BASE_DATA_OBJECT_TYPE
Deprecated. |
static String |
versionId
Deprecated. |
Constructor Summary | |
PackageType()
Deprecated. Default constructor. |
|
PackageType(DataObject dataObject)
Deprecated. Constructor in which the contained DataObject is
initialized with a new DataObject with an
ObjectType specified by the string
typeName. |
|
PackageType(OID oid)
Deprecated. Constructor in which th contained DataObject is retrieved
from the persistent storage mechanism with an OID
specified by oid. |
Method Summary | |
void |
addListener(String listenerClass)
Deprecated. Adds a listener to the events for this package. |
void |
addStylesheet(Stylesheet sheet)
Deprecated. Adds a stylesheet for this package type. |
protected void |
beforeSave()
Deprecated. |
static PackageType |
create(String key,
String displayName,
String displayPlural,
String URI)
Deprecated. Creates a package type with the specified key, display name, display plural, and URI. |
PackageInstance |
createInstance(Class instanceClass,
String displayName)
Deprecated. This convenience method is used to create an instance of this package type. |
PackageInstance |
createInstance(String displayName)
Deprecated. This convenience method is used to create an instance of this package type. |
static PackageType |
createPackageType(String key,
String displayName,
String displayPlural,
String URI)
Deprecated. |
static PackageType |
findByKey(String key)
Deprecated. Finds the package type of the specified key. |
static PackageType |
findPackageTypeByKey(String key)
Deprecated. |
static List |
getAllPackageIds()
Deprecated. |
static List |
getAllPackageKeys()
Deprecated. Returns a list of all available package keys. |
protected String |
getBaseDataObjectType()
Deprecated. Returns the base data object type for this domain object class. |
Dispatcher |
getDispatcher()
Deprecated. Gets an instance of the dispatcher registered for this class. |
String |
getDispatcherClass()
Deprecated. Gets the name of the dispatcher class for this package type. |
String |
getDisplayName()
Deprecated. |
String |
getDisplayPlural()
Deprecated. Returns the plural version of the display name. |
BigDecimal |
getID()
Deprecated. Gets the value of the ID property. |
PackageInstanceCollection |
getInstances()
Deprecated. Returns a collection of all the instances of package type. |
String |
getKey()
Deprecated. Gets the key of the package type. |
protected PackageEventListener[] |
getListeners()
Deprecated. Finds all the package event listeners registered to this class. |
String |
getPackageKey()
Deprecated. Use getKey() |
String |
getPrettyName()
Deprecated. Use getDisplayName() |
String |
getPrettyPlural()
Deprecated. |
String |
getServletPackage()
Deprecated. This information is no longer used. |
Stylesheet |
getStylesheet(Locale locale,
String outputType)
Deprecated. Gets the first stylesheet (best match) associated with this package. |
Stylesheet[] |
getStylesheets(Locale locale,
String outputType)
Deprecated. Gets all the stylesheets used for rendering this package. |
String |
getURI()
Deprecated. Gets the Unique Resource Identifier (URI) for the package. |
boolean |
hasListener(String listenerClass)
Deprecated. Checks if this package has a listener of the specified class. |
protected void |
initialize()
Deprecated. Called from all of the DomainObject constructors
to initalize or validate the new domain object or its
encapsulated data object. |
void |
removeListener(String listenerClass)
Deprecated. Removes a listener from the events for this package. |
void |
removeStylesheet(Stylesheet sheet)
Deprecated. Removes a stylesheet from the set of stylesheets used for rendering this package. |
static PackageTypeCollection |
retrieveAll()
Deprecated. Returns a collection of all defined package types. |
void |
setDispatcherClass(String dispatcherClass)
Deprecated. Sets the dispatcher class for this package type. |
void |
setDisplayName(String displayName)
Deprecated. Sets the display name of the package type. |
void |
setDisplayPlural(String displayPlural)
Deprecated. Sets the displayPlural of the package type. |
void |
setKey(String key)
Deprecated. Sets the key of the package type. |
void |
setPrettyName(String displayName)
Deprecated. |
void |
setPrettyPlural(String prettyPlural)
Deprecated. |
void |
setServletPackage(String servletPackage)
Deprecated. This information is no longer used. |
void |
setURI(String URI)
Deprecated. Sets a Unique Resource Identifier (URI) for the package. |
static boolean |
typeExists(String key)
Deprecated. |
Methods inherited from class com.arsdigita.domain.DomainObject |
add, add, addToAssociation, afterDelete, afterSave, beforeDelete, clear, delete, disconnect, equals, get, getObjectType, getOID, getSession, hashCode, isDeleted, isDisconnected, isModified, isNew, isPropertyModified, isValid, remove, remove, remove, removeFromAssociation, save, set, setAssociation, setAssociation, specializeDataObject, specializeDataObject, toString |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final String versionId
public static final String BASE_DATA_OBJECT_TYPE
Constructor Detail |
public PackageType()
DataObject
is
initialized with a new DataObject
with an
ObjectType
of "PackageType".
DataObject
,
ObjectType
public PackageType(DataObject dataObject)
DataObject
is
initialized with a new DataObject
with an
ObjectType
specified by the string
typeName.
Party.Party(ObjectType)
,
DataObject
,
ObjectType
public PackageType(OID oid) throws DataObjectNotFoundException
DataObject
is retrieved
from the persistent storage mechanism with an OID
specified by oid.
oid
- the OID
for the retrieved
DataObject
ObservableDomainObject.ObservableDomainObject(OID)
,
DataObject
,
OID
Method Detail |
protected String getBaseDataObjectType()
DomainObject
getBaseDataObjectType
in class DomainObject
protected void initialize()
DomainObject
DomainObject
constructors
to initalize or validate the new domain object or its
encapsulated data object. This was introduced in order to
support efficient validation of the encapsualted data object's
type. If the validation is typically performed in class
constructors, then redundant validation is performed in
superclass constructors. This validation now occurs here.
initialize
in class DomainObject
protected void beforeSave() throws PersistenceException
beforeSave
in class DomainObject
PersistenceException
public BigDecimal getID()
public String getKey()
setKey(String)
public void setKey(String key)
This method can only be called when the package type is intially created. After it is saved, calling this method will cause an exception to be thrown.
key
- the key of the package
RuntimeException
- if setKey() is called after the package
type has been persisted by calling the save() method.getKey()
public String getDisplayName()
public void setDisplayName(String displayName)
displayName
- the display name of the package typepublic String getDisplayPlural()
setDisplayPlural(String)
public void setDisplayPlural(String displayPlural)
displayPlural
- the plural form of the display namegetDisplayPlural()
public String getURI()
setURI(String)
public void setURI(String URI)
URI
- a Unique Resource Identifier for the packagegetURI()
public String getDispatcherClass()
setDispatcherClass(String)
,
getDispatcher()
public void setDispatcherClass(String dispatcherClass)
Dispatcher
interface.
dispatcherClass
- the string name of a dispatcher implementationgetDispatcherClass()
public Dispatcher getDispatcher() throws ClassNotFoundException, InstantiationException, IllegalAccessException, InvocationTargetException
setDispatcherClass(String)
method is used
to set which dispatcher will be returned.
ClassNotFoundException
InstantiationException
IllegalAccessException
InvocationTargetException
setDispatcherClass(String)
,
getDispatcher()
public PackageInstance createInstance(String displayName)
DomainObject.save()
method only needs to be called if it is changed.
displayName
- the display name for the package instance
public PackageInstance createInstance(Class instanceClass, String displayName)
DomainObject.save()
method only needs to be called if it is changed.
displayName
- the display name for the package instance
public void addStylesheet(Stylesheet sheet)
sheet
- a stylesheet used for rendering this packagepublic Stylesheet[] getStylesheets(Locale locale, String outputType)
locale
- the locale being used for rendering the packageoutputType
- an identification of output type, such as
"text/html"
addStylesheet(Stylesheet)
public Stylesheet getStylesheet(Locale locale, String outputType)
locale
- the locale being used for rendering the packageoutputType
- an identification of output type, such as
"text/html"
addStylesheet(Stylesheet)
public void removeStylesheet(Stylesheet sheet)
sheet
- the stylesheet to be removedpublic void addListener(String listenerClass)
listenerClass
- the name of a listener instancepublic void removeListener(String listenerClass)
listenerClass
- the name of the listener instancepublic boolean hasListener(String listenerClass)
listenerClass
- the name of a listener registered on this class
true
if the specified listener is registered,
false
otherwise.protected PackageEventListener[] getListeners()
public PackageInstanceCollection getInstances()
public static PackageType findByKey(String key) throws DataObjectNotFoundException
key
- the package key for the package
DataObjectNotFoundException
- if the key does not correspond
to an existing package type.setKey(String)
,
getKey()
public static boolean typeExists(String key)
public static PackageType create(String key, String displayName, String displayPlural, String URI)
PackageType subsite = PackageType.create ("acs-subsite", "ACS Subsite", "ACS Subsites", "http://arsdigita.com/acs-subsite/");
key
- the key for the package typedisplayName
- the display name for the package typedisplayPlural
- the plural form of the display nameURI
- the Unique Resource Identifier for this package
setKey(String)
,
setDisplayName(String)
,
setDisplayPlural(String)
,
setURI(String)
public static List getAllPackageKeys()
public static PackageTypeCollection retrieveAll()
public static List getAllPackageIds()
getAllPackageKeys()
public String getPackageKey()
getKey()
public String getServletPackage()
public void setServletPackage(String servletPackage)
public String getPrettyName()
getDisplayName()
public void setPrettyName(String displayName)
setDisplayName(String)
public String getPrettyPlural()
getDisplayPlural()
public void setPrettyPlural(String prettyPlural)
setDisplayPlural(String)
public static PackageType findPackageTypeByKey(String key) throws DataObjectNotFoundException
DataObjectNotFoundException
findByKey(String)
public static PackageType createPackageType(String key, String displayName, String displayPlural, String URI)
create(String, String, String, String)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |