com.silverpeas.pdc.web.beans
Class ClassificationPlan

java.lang.Object
  extended by com.silverpeas.pdc.web.beans.ClassificationPlan

public class ClassificationPlan
extends Object

It represents the PdC to use in the tests. As such it defines the differents axis and their values. Axis values can be either some single terms or some hierarchical semantic trees.


Method Summary
static ClassificationPlan aClassificationPlan()
          Gets an instance of the classification plan to use in the tests.
protected static Value aValue(String id, String treeId, String name, String path, int level, int order, String fatherId)
           
 List<Axis> getAxis()
          Gets the axis of this classification plan.
 UsedAxis getAxis(String axisId)
           
 AxisHeader getAxisHeader(String axisId)
          Gets some meta information about the specified axis.
 List<AxisHeader> getAxisHeaders(String type)
          Gets the headers of the axis of this classification plan.
 List<UsedAxis> getAxisUsedInClassification()
          Gets the axis of this classification plan that are used in the classification of a content.
 List<Value> getPathInTreeOfValue(Value aValue)
          Gets the path in the hierarchic tree of the specified value.
 List<UsedAxis> getUsedAxis()
          Gets the axis of this classification plan ready to be used in a classification.
 List<Value> getValuesOfAxisById(String anAxisId)
          Gets the values of the axis identified by the specified identifier.
 List<Value> getValuesOfAxisByName(String axisName)
          Gets the values of the axis identified by the specified name.
 List<Value> getValuesUsedInClassification(String axisId)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

aClassificationPlan

public static ClassificationPlan aClassificationPlan()
Gets an instance of the classification plan to use in the tests.

Returns:
a ClassificationPlan instance.

getUsedAxis

public List<UsedAxis> getUsedAxis()
Gets the axis of this classification plan ready to be used in a classification.

Returns:
an unmodifiable list with the axis of this classification plan.

getAxis

public List<Axis> getAxis()
Gets the axis of this classification plan.

Returns:
an unmodifiable list with the axis of this classification plan.

getAxisUsedInClassification

public List<UsedAxis> getAxisUsedInClassification()
Gets the axis of this classification plan that are used in the classification of a content.

Returns:
the axis used in a classification of contents.

getAxis

public UsedAxis getAxis(String axisId)

getAxisHeaders

public List<AxisHeader> getAxisHeaders(String type)
Gets the headers of the axis of this classification plan.

Parameters:
type - the type of axis: primary or secondary. If null, both are taken into account.
Returns:
a list of AxisHeader instances.

getAxisHeader

public AxisHeader getAxisHeader(String axisId)
Gets some meta information about the specified axis.

Parameters:
axisId - the unique identifier of the axis in the classification plan.
Returns:
an AxisHeader instance.

getValuesUsedInClassification

public List<Value> getValuesUsedInClassification(String axisId)

getValuesOfAxisByName

public List<Value> getValuesOfAxisByName(String axisName)
Gets the values of the axis identified by the specified name.

Parameters:
axisName - the name of the axis.
Returns:
an unmodifiable list of the axis' values or null if no such axis exists with the specified name.

getValuesOfAxisById

public List<Value> getValuesOfAxisById(String anAxisId)
Gets the values of the axis identified by the specified identifier.

Parameters:
anAxisId - the unique identifier of the axis.
Returns:
a unmodifiable list of the axis' values or null if no such axis exists with the specified identifier.

getPathInTreeOfValue

public List<Value> getPathInTreeOfValue(Value aValue)
Gets the path in the hierarchic tree of the specified value.

Parameters:
aValue - the value.
Returns:
a list of values, each of them representing a node in the path in the tree upto the specified value.

aValue

protected static Value aValue(String id,
                              String treeId,
                              String name,
                              String path,
                              int level,
                              int order,
                              String fatherId)


Copyright © 2016 Silverpeas. All Rights Reserved.