Package overit.geocall.xml
Class TreeFactory
java.lang.Object
overit.geocall.xml.TreeFactory
This class implements the object used to create
XMLTree instances starting from a resource; the resource
is passed as parameter to the make methods in the form of a string defining a path. The methods will use the localization
mechanism to retrieve the correct source.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic UISchemaReturns theUISchemathat corresponds to the resource passed as parameterstatic UISchemaReturns theUISchemathat corresponds to the resource passed as parameterstatic XMLTreeCreates and returns theXMLTreethat corresponds to the resource passed as parameterstatic XMLTreeCreates and returns theXMLTreethat corresponds to the resource passed as parameterstatic XMLTreeCreates and returns theXMLTreethat corresponds to the resource passed as parameterstatic XMLTree
-
Constructor Details
-
TreeFactory
public TreeFactory()
-
-
Method Details
-
make
Creates and returns theXMLTreethat corresponds to the resource passed as parameter- Parameters:
reference- The reference class defining position and name of the desired xml resurce. This factory looks for the best instance of an xml file with the same name of the reference, searching in all layer customizations.- Returns:
- An XMLTree corresponding the reference parameter
-
make
Creates and returns theXMLTreethat corresponds to the resource passed as parameter- Parameters:
resource- The resource used to make the tree. This factory looks for the best location of this resource searching in all layer customizations. A resource starting with / is ment to be already resolved and will not be changed. A resource can be e relative name with respect to the from class or or absolute if the caller is null.from- the starting position. If it is null, theresourceis meant to be absolute- Returns:
- An XMLTree that corresponds to the resource
-
make
Creates and returns theXMLTreethat corresponds to the resource passed as parameter- Parameters:
resource- The resource used to make the tree. This factory looks for the best location of this resource searching in all layer customizations. A resource starting with // is ment to be already resolved and will not be changed. A resource can be e relative name with respect to the caller object or absolute if the caller is null.caller- The caller object- Returns:
- An XMLTree that corresponds to the resource
-
localize
Returns theUISchemathat corresponds to the resource passed as parameter- Parameters:
resource- The resource of interest. This factory looks for the best location of this resource searching in all layer customizations. A resource starting with / is ment to be already resolved and will not be changed. A resource can be e relative name with respect to the caller object or or absolute if the caller is null.caller- The caller object- Returns:
- The UISchema
-
localize
Returns theUISchemathat corresponds to the resource passed as parameter- Parameters:
resource- The resource of interest. This factory looks for the best location of this resource searching in all layer customizations. A resource starting with // is meant to be already resolved and will not be changed. A resource can be e relative name with respect to the from parameter object or or absolute if the from is null.from- the starting position. If it is null, theresourceis meant to be absolute- Returns:
- The UISchema
-
make
- Parameters:
uis- The UISchema used to make the treenormalizeAttributes-trueto normalize the attributes (collect only the well formed ones, without empty spaces),falseotherwise- Returns:
- An XMLTree that corresponds to the schema
-