org.nuxeo.core.resources.model.impl
Class Site
java.lang.Object
org.eclipse.core.runtime.PlatformObject
org.nuxeo.core.resources.model.impl.SiteResource
org.nuxeo.core.resources.model.impl.SiteFolder
org.nuxeo.core.resources.model.impl.Site
- All Implemented Interfaces:
- org.eclipse.core.runtime.IAdaptable, IContainer, ISite, ISiteFolder, ISiteResource
public class Site
- extends SiteFolder
- implements ISite
- Author:
- Bogdan Stefanescu
|
Constructor Summary |
Site(java.lang.String uri)
|
|
Method Summary |
boolean |
accept(ISiteResourceVisitor visitor,
java.lang.Object context)
Accept a visitor on this node of the resource tree |
java.lang.String |
getAuthority()
Get the authority part from the site URI |
ISiteController |
getController()
Get the controller that is managing this site
* Site controllers are registered on site schemas. |
java.lang.String |
getPath()
The path of the resource relative to the owner site |
java.lang.String |
getPath(java.lang.String uri)
Get the absolute path in this site for the given URI |
java.lang.String |
getScheme()
Get the site scheme. |
int |
getType()
Get the resource type. |
java.lang.String |
getURI()
Get the Unique resource identifier |
| Methods inherited from class org.eclipse.core.runtime.PlatformObject |
getAdapter |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
getAdapter |
Site
public Site(java.lang.String uri)
getType
public int getType()
- Description copied from interface:
ISiteResource
- Get the resource type.
- Specified by:
getType in interface ISiteResource- Overrides:
getType in class SiteFolder
- Returns:
- the resource type
getScheme
public final java.lang.String getScheme()
- Description copied from interface:
ISite
- Get the site scheme. The site scheme is defining the site type.
The site scheme (i.e. type) is used to bound the site to a controller.
- Specified by:
getScheme in interface ISite
- Returns:
- the site scheme
getPath
public final java.lang.String getPath()
- Description copied from interface:
ISiteResource
- The path of the resource relative to the owner site
- Specified by:
getPath in interface ISiteResource- Overrides:
getPath in class SiteResource
- Returns:
- Returns the path.
getAuthority
public final java.lang.String getAuthority()
- Description copied from interface:
ISite
- Get the authority part from the site URI
- Specified by:
getAuthority in interface ISite
- Returns:
- the host part
getURI
public java.lang.String getURI()
- Description copied from interface:
ISiteResource
- Get the Unique resource identifier
- Specified by:
getURI in interface ISiteResource- Overrides:
getURI in class SiteResource
- Returns:
- the resource URI. Cannot be null
getPath
public java.lang.String getPath(java.lang.String uri)
- Description copied from interface:
ISite
- Get the absolute path in this site for the given URI
- Specified by:
getPath in interface ISite
- Parameters:
uri - the URI. the given URI should be in a normalized form
(should not contains "../" or "./").
- Returns:
- the path in this site of the given URI or null if this URI is not under this site
getController
public ISiteController getController()
- Description copied from interface:
ISite
- Get the controller that is managing this site
* Site controllers are registered on site schemas.
- Specified by:
getController in interface ISite- Overrides:
getController in class SiteResource
- Returns:
- the controller. If no controller is asscoiated to this type of sites
the NullSiteController is returned
accept
public boolean accept(ISiteResourceVisitor visitor,
java.lang.Object context)
- Description copied from interface:
ISiteResource
- Accept a visitor on this node of the resource tree
- Specified by:
accept in interface ISiteResource- Overrides:
accept in class SiteFolder
- Parameters:
visitor - the visitorcontext - a context object to be used by the visitor or null
- Returns:
- true if the traversal must continue otherwise false