DEPRECATED
Object
Helper class for dealing with Content, ContentManagers, and the possible subclasses.
Object
ContentHelper
Field Summary |
public static final |
|
public static final |
|
public static final boolean |
|
public static final |
|
public static final |
|
public static final |
|
public static final |
|
public static boolean |
|
Constructor Summary |
Method Summary |
public static |
|
public static |
|
public static |
|
public static |
|
public static |
|
public static |
|
public static |
|
public static |
|
public static |
|
public static int |
|
public static |
|
public static |
|
public static |
|
public static |
|
public static |
Methods from class java.lang. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String
DEF_CONTENT_HOME
public static final String
DEF_CONTENT_MANAGER_HOME
This points to "java:comp/env/ejb/ContentManager", which is the closest <ejb-ref>'ed ContentManager home. The <ejb-ref> should be configured either in your EJB ejb-jar.xml deployment descriptor or in your webapp's web.xml deployment descriptor.
public static final boolean DEF_CONTENT_READONLY
public static final String
DEF_CONTENT_SCHEMA_HOME
public static final String
DEF_DOCUMENT_HOME
public static final String
DEF_DOCUMENT_MANAGER_HOME
This points to "java:comp/env/ejb/DocumentManager", which is the closest <ejb-ref>'ed DocumentManager home. The <ejb-ref> should be configured either in your EJB ejb-jar.xml deployment descriptor or in your webapp's web.xml deployment descriptor.
public static final String
DEF_DOCUMENT_SCHEMA_HOME
public static boolean USE_SOFT_HASH_MAP
Constructor Detail |
public ContentHelper()
Method Detail |
public staticReturn an array of Content from the ContentManager at the given name.Content
[] getContent(String
homeName,Search
s)
throwsNamingException
,RemoteException
,FinderException
,IllegalArgumentException
If homeName points to a home for a ContentManager (or subclass), then the home's create() method will be invoked and the ContentManager's getContent() method will be used. The resulting enumeration will be put into an array.
NamingException
RemoteException
FinderException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String)
DEPRECATED Use new Search instead
public staticReturn an array of Content from the ContentManager at the given name.Content
[] getContent(String
homeName,Search
s)
throwsNamingException
,RemoteException
,FinderException
,IllegalArgumentException
If homeName points to a home for a ContentManager (or subclass), then the home's create() method will be invoked and the ContentManager's getContent() method will be used. The resulting enumeration will be put into an array.
NamingException
RemoteException
FinderException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String)
Search
DEPRECATED Use getContent(String, Search) instead.
public staticReturn an array of Content from the ContentManager or ContentHome at the given name.Content
[] getContent(String
homeName,Search
s, boolean readOnly)
throwsNamingException
,RemoteException
,FinderException
,IllegalArgumentException
If homeName points to a home for a ContentManager (or subclass), then the home's create() method will be invoked and the ContentManager's getContent() method will be used. If homeName points to a home for Content (or subclasses), then it's findBySearchParams() method will used. The resulting enumeration will be put into an array.
NamingException
RemoteException
FinderException
IllegalArgumentException
Related Topics
ContentHelper.getContent(String, Search)
DEPRECATED Use new content expressions and getContent(String, Search) instead.
public staticReturn an array of Content from the ContentManager or ContentHome at the given name.Content
[] getContent(String
homeName,Search
s, boolean readOnly)
throwsNamingException
,RemoteException
,FinderException
,IllegalArgumentException
If homeName points to a home for a ContentManager (or subclass), then the home's create() method will be invoked and the ContentManager's getContent() method will be used. If homeName points to a home for Content (or subclasses), then it's findBySearchParams() method will used. The resulting enumeration will be put into an array.
NamingException
RemoteException
FinderException
IllegalArgumentException
Related Topics
ContentHelper.getContent(String, Search)
DEPRECATED use getContentManager(homeName, home).getContent(s) instead.
public staticSearch for content from a ContentManager.Enumeration
getContentFromManager(String
homeName,EJBHome
home,Search
s)
throwsRemoteException
,IllegalArgumentException
RemoteException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String, EJBHome)
DEPRECATED use new content search and getContentManager(homeName, home).getContent(s) instead.
public staticSearch for content from a ContentManager.Enumeration
getContentFromManager(String
homeName,EJBHome
home,Search
s)
throwsRemoteException
,IllegalArgumentException
RemoteException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String, EJBHome)
DEPRECATED Use getContentManager(homeName, home).getContent(s);
public staticSearch for content from a ContentManager.Enumeration
getContentFromManager(String
homeName,EJBHome
home,Search
s, boolean readOnly)
throwsRemoteException
,IllegalArgumentException
RemoteException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String, EJBHome)
DEPRECATED Use new content expressions and getContentManager(homeName, home).getContent(s);
public staticSearch for content from a ContentManager.Enumeration
getContentFromManager(String
homeName,EJBHome
home,Search
s, boolean readOnly)
throwsRemoteException
,IllegalArgumentException
RemoteException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String, EJBHome)
public staticReturn an rray of Content from the ContentManager or ContentHome at the given name.Collection
getContentIds(String
homeName,Search
s)
throwsNamingException
,RemoteException
,FinderException
,IllegalArgumentException
If homeName points to a home for a ContentManager (or subclass), then the home's create() method will be invoked and the ContentManager's getContentIds() method will be used.
NamingException
RemoteException
FinderException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String)
public static int getContentLength(long docSize, int bytesLen)Return the correct content length. Since the getContent() method of Document does not guarentee that the resulting array will be the correct size (it might be larger), this method will tell what the actual number of bytes to use from that array is.
Related Topics
public staticGet a ContentManager from a JNDI home name.ContentManager
getContentManager(String
homeName)
throwsNamingException
,CreateException
,RemoteException
,IllegalArgumentException
NamingException
CreateException
RemoteException
IllegalArgumentException
Related Topics
ContentHelper.getContentManager(String, EJBHome)
public staticGet a ContentManager from an EJBHome.ContentManager
getContentManager(String
homeName,EJBHome
home)
throwsCreateException
,RemoteException
,IllegalArgumentException
CreateException
RemoteException
IllegalArgumentException
public staticCorrectly URLEncode a path-info string.String
pathInfoEncode(String
pathInfo)
This can be used to pass a contentId as Path-Info to the ShowDocServlet.
This will url encode the pathInfo, but will leave "/"'s alone.
public staticTurn an Enumeration of Content into an array.Content
[] toArray(Enumeration
e)
public staticConvert an arbitrary string to HTML which will display as the original string intended.String
toHTML(String
in)
This will replace the characters '&', '"', '<', and '>' with '&', "', '<', and '>', respectively.