com.bea.content.manager.servlets.common
Class ContentPropertyHelper

java.lang.Object
  extended by com.bea.content.manager.servlets.common.ContentPropertyHelper

public class ContentPropertyHelper
extends Object

Helper class for routine taglib methods.


Method Summary
static String convertString(String conversionType, String in)
          Convert a string according to the specified convertType.
static Property getPropertyFromNode(Node node, String propertyName)
          Convenience method to retrieve a property by name from a node.
static Property getPropertyFromNode(Node node, Version version, String propertyName)
          Convenience method to retrieve a property by name from a node.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getPropertyFromNode

public static Property getPropertyFromNode(Node node,
                                           String propertyName)
                                    throws AuthorizationException,
                                           RepositoryException
Convenience method to retrieve a property by name from a node.

If the following standard properties are used as the property name then the corresponding value from the Node will be returned. These standard properties are not used if a particular version of the node is being used by specifying the version attribute.

  • cm_nodeName
  • cm_path
  • cm_createdBy
  • cm_modifiedBy
  • cm_createdDate
  • cm_modifiedDate

    Parameters
    node -
    propertyName -
    Returns
    property
    Throws
    AuthorizationException
    RepositoryException

  • getPropertyFromNode

    public static Property getPropertyFromNode(Node node,
                                               Version version,
                                               String propertyName)
                                        throws AuthorizationException,
                                               RepositoryException
    Convenience method to retrieve a property by name from a node.

    If the following standard properties are used as the property name then the corresponding value from the Node will be returned. These standard properties are not used if a particular version of the node is being used by specifying the version attribute.

  • cm_nodeName
  • cm_path
  • cm_createdBy
  • cm_modifiedBy
  • cm_createdDate
  • cm_modifiedDate

    It is important to note that some explicit properties are not versioned and will be retrieved from the node itself. These include:

  • cm_nodeName
  • cm_createdBy
  • cm_createdDate
  • cm_path All other implicit properties will be returned via the version.

    Parameters
    node - the node to retrieve the property from
    version - the version of the node to retrieve the property from.
    propertyName - the name of the property to retrieve.
    Returns
    the associated property
    Throws
    AuthorizationException
    RepositoryException

  • convertString

    public static String convertString(String conversionType,
                                       String in)
    Convert a string according to the specified convertType.

    Parameters
    conversionType - "html", "url", or anything else for no encoding.
    in - the string
    Returns
    the converted string.


    Copyright © 2011, Oracle. All rights reserved.