|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.gentics.api.contentnode.parttype.AbstractExtensiblePartType
public abstract class AbstractExtensiblePartType
Abstract base implementation of
ExtensiblePartType
. This class
should be the base class for all new implementations of PartTypes.
To use extensible parttypes you need to insert a row into the type table of the cms database.
Please note that once the row has been inserted, any changes to the row, such as updating
the class name, require a tomcat restart (the part type information is cached internally).
To avoid id conflicts please calculate your personal id range for now:
take the 1st 4 characters of one of the customers cms license keys.
convert them from hex to dec.
multiply by 1000. this is the lowest allowed id.
add 999. thid is the highest allowed id.
eg: license key is A2B4-xxxx-xxxx...
hex a2b4 is 41652 in decimal.
your personal id range is 41652000 - 41652999.
Constructor Summary | |
---|---|
AbstractExtensiblePartType()
|
Method Summary | |
---|---|
void |
cleanAfterRender()
Perform cleanup operations after rendering. |
void |
clearCache()
Clear the cache |
protected com.gentics.contentnode.object.parttype.CMSResolver |
createCMSResolver()
Creates a new cms resolver and adds it to the stack. |
Map |
createContext(boolean wrapRenderables)
Get the context of the parttype. |
Object |
getCachedObject(Object key)
Get the object cached for this parttype class with the given key |
protected String |
getCacheGroup()
Get the cache group name (=classname) |
void |
putObjectIntoCache(Object key,
Object object)
Put the given object into the cache |
void |
removeObjectFromCache(Object key)
Remove the object with the given key from the cache |
Object |
resolve(String path)
Helper method to resolve property paths in the context of the part |
String |
resolveToString(String path)
Help method to resolve a property and return it's string representation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.gentics.api.contentnode.parttype.ExtensiblePartType |
---|
render |
Constructor Detail |
---|
public AbstractExtensiblePartType()
Method Detail |
---|
protected com.gentics.contentnode.object.parttype.CMSResolver createCMSResolver() throws NodeException
NodeException
public Object resolve(String path) throws NodeException
path
- property path to resolve
NodeException
- when an error occurred while resolvingpublic String resolveToString(String path) throws NodeException
path
- property path to resolve
NodeException
- when an error occurredpublic Map createContext(boolean wrapRenderables) throws NodeException
wrapRenderables
- flag to wrap renderable objects into instances of RenderableResolvable
NodeException
public Object getCachedObject(Object key)
key
- cache key
public void putObjectIntoCache(Object key, Object object)
key
- cache keyobject
- cached objectpublic void removeObjectFromCache(Object key)
key
- cache keypublic void clearCache()
protected String getCacheGroup()
public void cleanAfterRender()
ExtensiblePartType
ExtensiblePartType.cleanAfterRender()
.
cleanAfterRender
in interface ExtensiblePartType
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |