|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.arsdigita.domain.DomainObject
com.arsdigita.domain.ObservableDomainObject
com.arsdigita.kernel.ACSObject
com.arsdigita.kernel.SiteNode
Application
instead.
A SiteNode represents a part of the URL hierarchy on a server. Each instance of a SiteNode may be mapped to an application instance for the purpose of providing access to that application.
For example, the URL "http://www.example.com/news/" can be broken down into:
www.example.com
. /news/
The hierarchy is delimited by slashes (/).
SiteNode
, the parent of
all other site nodes on the system.SiteNode
that is a
child of the root SiteNode
with a name of "news."
Field Summary | |
static String |
versionId
Deprecated. |
Fields inherited from class com.arsdigita.kernel.ACSObject |
BASE_DATA_OBJECT_TYPE, CONTAINER, DEFAULT_DOMAIN_CLASS, DISPLAY_NAME, ID, OBJECT_TYPE |
Constructor Summary | |
SiteNode()
Deprecated. Default constructor. |
|
SiteNode(BigDecimal id)
Deprecated. Retrieves the SiteNode with the specified ID. |
|
SiteNode(DataObject dataObject)
Deprecated. Creates a new DomainObject instance to encapsulate a given data object. |
|
SiteNode(OID oid)
Deprecated. Retrieves a SiteNode that corresponds to the specified OID. |
Method Summary | |
void |
addStylesheet(Stylesheet sheet)
Deprecated. |
void |
afterDelete()
Deprecated. |
protected void |
beforeSave()
Deprecated. Overrides the default save method. |
static SiteNode |
createSiteNode(String name)
Deprecated. |
static SiteNode |
createSiteNode(String name,
SiteNode parent)
Deprecated. |
protected String |
getBaseDataObjectType()
Deprecated. Returns the base data object type for this domain object class. |
SiteNodeCollection |
getChildren()
Deprecated. |
String |
getDisplayName()
Deprecated. Returns a display name for this site node. |
String |
getName()
Deprecated. |
BigDecimal |
getNodeId()
Deprecated. |
PackageInstance |
getPackageInstance()
Deprecated. |
SiteNode |
getParent()
Deprecated. |
static SiteNode |
getRootSiteNode()
Deprecated. |
static SiteNode |
getSiteNode(String path)
Deprecated. Finds the site node corresponding to the largest portion of the specified path. |
static SiteNode |
getSiteNode(String path,
boolean readOnly)
Deprecated. Finds the site node corresponding to the largest portion of the specified path. |
Stylesheet |
getStylesheet(Locale locale,
String outputType)
Deprecated. |
Stylesheet[] |
getStylesheets(Locale locale,
String outputType)
Deprecated. |
String |
getURL()
Deprecated. |
String |
getUrl(javax.servlet.http.HttpServletRequest req)
Deprecated. |
String |
getURL(javax.servlet.http.HttpServletRequest req)
Deprecated. Gets the URL of the site note. |
String |
getUrl(String contextPath)
Deprecated. |
String |
getURL(String contextPath)
Deprecated. |
String |
getURLNoContext()
Deprecated. |
protected void |
initialize()
Deprecated. Called from base class (DomainObject) constructors. |
boolean |
isDirectory()
Deprecated. |
boolean |
isPattern()
Deprecated. |
void |
mountPackage(PackageInstance pkg)
Deprecated. |
void |
removeStylesheet(Stylesheet sheet)
Deprecated. |
static void |
repopulateCache()
Deprecated. for testing, it is necessary to remove all statically cached site nodes. |
void |
setName(String name)
Deprecated. |
void |
setParent(SiteNode siteNode)
Deprecated. |
String |
toString()
Deprecated. Return the OID plus the flags N,M,D,U depending on
whether the object is new, modified, deleted, or unknown. |
void |
unMountPackage()
Deprecated. |
Methods inherited from class com.arsdigita.kernel.ACSObject |
assertPrivilege, checkPrivilege, doCreateCheck, doWriteCheck, getContainer, getDefaultDomainClass, getID, getSpecificObjectType, getSpecificOID, gimmeContainer, isContainerModified, setID, setID |
Methods inherited from class com.arsdigita.domain.ObservableDomainObject |
addObserver, getObservers |
Methods inherited from class com.arsdigita.domain.DomainObject |
add, add, addToAssociation, 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 |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final String versionId
Constructor Detail |
public SiteNode()
DataObject
is
initialized with a new DataObject
with an
ObjectType
of "SiteNode".
DataObject
,
ObjectType
public SiteNode(DataObject dataObject)
dataObject
- the data object to encapsulate in the new domain
objectSession.retrieve(String)
public SiteNode(BigDecimal id) throws DataObjectNotFoundException
id
- a SiteNode ID
DataObjectNotFoundException
- if the ID does not match
a SiteNode in the system.public SiteNode(OID oid) throws DataObjectNotFoundException
oid
- the OID for the retrieved instanceDomainObject.DomainObject(OID)
,
OID
Method Detail |
protected String getBaseDataObjectType()
DomainObject
getBaseDataObjectType
in class ACSObject
protected void initialize()
ACSObject
initialize
in class ACSObject
public String getURL(javax.servlet.http.HttpServletRequest req)
req
- Servlet request. This is needed to get the context
path, in case the servlet is not mounted at /.
public String getUrl(javax.servlet.http.HttpServletRequest req)
public String getURL(String contextPath)
public String getUrl(String contextPath)
public String getURL()
public String getURLNoContext()
public BigDecimal getNodeId()
public void setName(String name)
public void setParent(SiteNode siteNode)
public String getName()
public String getDisplayName()
getDisplayName
in class ACSObject
ACSObject.getDisplayName()
public boolean isDirectory()
true
if this SiteNode can have children; false
otherwise.public boolean isPattern()
true
if the SiteNode supports patterns; false
otherwise.public PackageInstance getPackageInstance()
public void mountPackage(PackageInstance pkg)
public void unMountPackage()
public SiteNode getParent()
public SiteNodeCollection getChildren()
public static SiteNode getRootSiteNode()
public static void repopulateCache()
public static SiteNode getSiteNode(String path, boolean readOnly) throws DataObjectNotFoundException
path
- an absolute path to find the site node ofreadOnly
- if true, we return a read-only site node
from our cache, which may be disconnected from a db session and
can't be modified or deleted. (This is the desired behavior
the majority of the time.)
DataObjectNotFoundException
- if the path does not start
with a slash (probably the wrong behavior) or if the
RootSiteNode was requested but couldn't be found (also
probably wrong).public static SiteNode getSiteNode(String path) throws DataObjectNotFoundException
path
- an absolute path to find the site node of
DataObjectNotFoundException
- if the path does not start
with a slash (probably the wrong behavior) or if the
RootSiteNode was requested but couldn't be found (also
probably wrong).public static SiteNode createSiteNode(String name)
protected void beforeSave()
beforeSave
in class ACSObject
public void afterDelete()
afterDelete
in class DomainObject
public static SiteNode createSiteNode(String name, SiteNode parent)
public String toString()
DomainObject
OID
plus the flags N,M,D,U depending on
whether the object is new, modified, deleted, or unknown. Unknown is for
objects that have been invalidated.
toString
in class DomainObject
public void addStylesheet(Stylesheet sheet)
public Stylesheet[] getStylesheets(Locale locale, String outputType)
public Stylesheet getStylesheet(Locale locale, String outputType)
public void removeStylesheet(Stylesheet sheet)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |