Esri Geoportal Server
1.0

com.esri.gpt.catalog.schema.indexable
Class IndexableProperty

java.lang.Object
  extended by com.esri.gpt.catalog.schema.indexable.IndexableProperty

public class IndexableProperty
extends Object

An indexable property associated with a metadata schema.


Constructor Summary
IndexableProperty()
          Default constructor.
IndexableProperty(IndexableProperty objectToDuplicate)
          Construct by duplicating an existing object.
 
Method Summary
protected  void addValue(IndexableContext context, PropertyMeaning meaning, String value)
          Adds an evaluated value to the collection.
 void configure(CfgContext context, Node node, NamedNodeMap attributes)
          Configures the object based upon a node loaded from a schema configuration XML.
 void evaluate(Schema schema, IndexableContext context, Document dom, Node parent, XPath xpath)
          Evaluates the property based upon the supplied metadata document.
 List<IndexableProperty> getChildren()
          Gets the child properties.
 String getEvaluatedValue()
          Gets the first evaluated value.
 List<String> getEvaluatedValues()
          Gets the evaluated values.
 String getMeaningName()
          Gets the meaning name.
protected  String getTextContent(Node node, boolean first)
          Gets the text associated with a node.
 String getXPathExpression()
          Gets the XPath expression.
 String getXPathType()
          Gets the XPath expression result type.
 void resolve(Schema schema, IndexableContext context, IndexableProperty parent)
          Resolves an evaluated property.
 void setChildren(List<IndexableProperty> children)
          Sets the child properties.
 void setEvaluatedValues(List<String> values)
          Sets the evaluated values.
 void setMeaningName(String name)
          Sets the meaning name.
 void setXPathExpression(String expression)
          Sets the XPath expression.
 void setXPathType(String xpathType)
          Sets the XPath expression result type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IndexableProperty

public IndexableProperty()
Default constructor.


IndexableProperty

public IndexableProperty(IndexableProperty objectToDuplicate)
Construct by duplicating an existing object.

Parameters:
objectToDuplicate - the object to duplicate
Method Detail

getChildren

public List<IndexableProperty> getChildren()
Gets the child properties.

Returns:
the child properties

setChildren

public void setChildren(List<IndexableProperty> children)
Sets the child properties.

Parameters:
children - the child properties

getEvaluatedValue

public String getEvaluatedValue()
Gets the first evaluated value.

Returns:
the first evaluated value (can be null)

getEvaluatedValues

public List<String> getEvaluatedValues()
Gets the evaluated values.

Returns:
the evaluated values

setEvaluatedValues

public void setEvaluatedValues(List<String> values)
Sets the evaluated values.

Parameters:
values - the evaluated values

getMeaningName

public String getMeaningName()
Gets the meaning name.

Returns:
the meaning name

setMeaningName

public void setMeaningName(String name)
Sets the meaning name.

Parameters:
name - the meaning name

getXPathExpression

public String getXPathExpression()
Gets the XPath expression.

Returns:
the XPath expression

setXPathExpression

public void setXPathExpression(String expression)
Sets the XPath expression.

Parameters:
expression - the XPath expression

getXPathType

public String getXPathType()
Gets the XPath expression result type.
BOOLEAN NODE NODESET NUMBER STRING

Returns:
the XPath expression result type

setXPathType

public void setXPathType(String xpathType)
Sets the XPath expression result type.
BOOLEAN NODE NODESET NUMBER STRING

Parameters:
xpathType - the expression result type

addValue

protected void addValue(IndexableContext context,
                        PropertyMeaning meaning,
                        String value)
Adds an evaluated value to the collection.

Parameters:
context - the active indexable context
meaning - the associated property meaning
value - the evaluated value

configure

public void configure(CfgContext context,
                      Node node,
                      NamedNodeMap attributes)
Configures the object based upon a node loaded from a schema configuration XML.

The following attributes are configured:
meaning xpathType xpath

The following child nodes are configured:
property

Parameters:
context - the configuration context
node - the configuration node
attributes - the attributes of the configuration node

evaluate

public void evaluate(Schema schema,
                     IndexableContext context,
                     Document dom,
                     Node parent,
                     XPath xpath)
              throws XPathExpressionException
Evaluates the property based upon the supplied metadata document.

Parameters:
schema - the schema being evaluated
context - the active indexable context
dom - the metadata document
parent - the metadata document node the is actively being processed (can be null)
xpath - an XPath object configured with an appropriate Namespace context for the schema
Throws:
XPathExpressionException - if an evaluation expression fails

getTextContent

protected String getTextContent(Node node,
                                boolean first)
Gets the text associated with a node.

Parameters:
node - the subject node
first - if true, get the first text node associated with an element node
Returns:
the text (can be null)

resolve

public void resolve(Schema schema,
                    IndexableContext context,
                    IndexableProperty parent)
Resolves an evaluated property.

Parameters:
schema - the schema being evaluated
context - the active indexable context
parent - the parent property

Esri Geoportal Server
1.0

Copyright 2011 Environmental Systems Research Institute. All rights reserved. Use is subject to license terms.