|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.sling.adapter.SlingAdaptable
com.day.cq.wcm.core.impl.components.ComponentImpl
public class ComponentImpl
Implements a 'local' component that extends the cached one by adding support for accessing local resources.
| Field Summary | |
|---|---|
protected SystemComponent |
base
|
| Constructor Summary | |
|---|---|
ComponentImpl(org.apache.sling.api.resource.Resource resource,
SystemComponent base)
|
|
| Method Summary | ||
|---|---|---|
|
adaptTo(Class<AdapterType> type)
|
|
String |
getCellName()
Returns the cell name of this component. |
|
ComponentEditConfig |
getChildEditConfig()
Returns the child edit config of this component or the one of it's super component. |
|
String |
getComponentGroup()
Returns the name of the component group. |
|
ComponentEditConfig |
getDeclaredChildEditConfig()
Returns the child edit config of this component |
|
ComponentEditConfig |
getDeclaredEditConfig()
Returns the edit config of this component |
|
String |
getDescription()
Returns the description of this resource. |
|
String |
getDesignDialogPath()
Returns the design dialog path of this component or of an inherited one. |
|
ComponentEditConfig |
getDesignEditConfig(String cellName)
Returns the design edit config for the given cell name |
|
String |
getDialogPath()
Returns the dialog path of this component or of an inherited one. |
|
ComponentEditConfig |
getEditConfig()
Returns the edit config of this component or the one of it's super component. |
|
Map<String,String> |
getHtmlTagAttributes()
Returns additional tag attributes that are added to the surrounding html tag. |
|
String |
getIconPath()
Returns the path to an icon for this component or null if
the component does not provide an icon. |
|
org.apache.sling.api.resource.Resource |
getLocalResource(String name)
Finds the resource with the given name that is stored "in" this component. |
|
String |
getName()
Returns the name of this resource. |
|
String |
getPath()
Returns the path of this resource |
|
org.apache.sling.api.resource.ValueMap |
getProperties()
Returns the properties of
this Component. |
|
String |
getResourceType()
Returns the resource type to be used for this component. |
|
Component |
getSuperComponent()
Returns the super component if the super resource type is defined and points to a valid component. |
|
String |
getThumbnailPath()
Returns the path to a thumbnail for this component or null
if the component does not provide a thumbnail. |
|
String |
getTitle()
Returns the tile of this resource. |
|
Collection<VirtualComponent> |
getVirtualComponents()
Returns a collection of virtual components that are configured for this component. |
|
boolean |
isContainer()
Checks if this component is a container component. |
|
boolean |
isDesignable()
Checks if this component is designable. |
|
boolean |
isEditable()
Checks if this component is editable. |
|
boolean |
noDecoration()
Checks if this component does not need decoration when included. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final SystemComponent base
| Constructor Detail |
|---|
public ComponentImpl(org.apache.sling.api.resource.Resource resource,
SystemComponent base)
| Method Detail |
|---|
public String getPath()
LabeledResource
getPath in interface LabeledResourcepublic String getName()
LabeledResource
getName in interface LabeledResourcepublic String getTitle()
LabeledResource
getTitle in interface LabeledResourcenull if not defined.public String getDescription()
LabeledResource
getDescription in interface LabeledResourcenull if not defined.public String getIconPath()
Componentnull if
the component does not provide an icon.
If this component does not define a path the one of the super component
is returned.
Note: the path is a webapp relative URL. eg: /docroot/c1.gif
getIconPath in interface Componentnullpublic String getThumbnailPath()
Componentnull
if the component does not provide a thumbnail.
If this component does not define a path the one of the super component
is returned.
Note: the path is a webapp relative URL. eg: /docroot/c1.gif
getThumbnailPath in interface Componentnullpublic String getComponentGroup()
Component
getComponentGroup in interface Componentnull if not defined.public String getCellName()
Component
getCellName in interface Componentpublic String getDialogPath()
Component
getDialogPath in interface Componentnullpublic String getDesignDialogPath()
Component
getDesignDialogPath in interface Componentnullpublic boolean isEditable()
Component
isEditable in interface Componenttrue if the component is editable.public boolean isDesignable()
Component
isDesignable in interface Componenttrue if the component is designable.public boolean isContainer()
Component
isContainer in interface Componenttrue if this component is a container.public boolean noDecoration()
Component
noDecoration in interface Componenttrue if this component does not need decoration
when included.public org.apache.sling.api.resource.ValueMap getProperties()
Componentproperties of
this Component.
getProperties in interface Componentpublic ComponentEditConfig getDeclaredEditConfig()
Component
getDeclaredEditConfig in interface Componentnull if not availablepublic ComponentEditConfig getDeclaredChildEditConfig()
Component
getDeclaredChildEditConfig in interface Componentnull if not availablepublic ComponentEditConfig getEditConfig()
Component
getEditConfig in interface Componentnull if not availablepublic ComponentEditConfig getDesignEditConfig(String cellName)
Component
getDesignEditConfig in interface ComponentcellName - name of the cell
public ComponentEditConfig getChildEditConfig()
Component
getChildEditConfig in interface Componentnull if not availablepublic Map<String,String> getHtmlTagAttributes()
Component
getHtmlTagAttributes in interface Componentpublic Component getSuperComponent()
Component
getSuperComponent in interface Componentnullpublic String getResourceType()
Component
getResourceType in interface Componentpublic org.apache.sling.api.resource.Resource getLocalResource(String name)
getLocalResource in interface Componentname - name of the resource
public Collection<VirtualComponent> getVirtualComponents()
getVirtualComponents in interface Componentpublic <AdapterType> AdapterType adaptTo(Class<AdapterType> type)
adaptTo in interface org.apache.sling.api.adapter.AdaptableadaptTo in class org.apache.sling.adapter.SlingAdaptable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||