Package org.jvnet.jaxb2_commons.locator
Interface ObjectLocator
-
- All Superinterfaces:
Reportable,ValidationEventLocator
- All Known Subinterfaces:
ItemObjectLocator,PropertyObjectLocator,RootObjectLocator
- All Known Implementing Classes:
AbstractObjectLocator,DefaultItemObjectLocator,DefaultPropertyObjectLocator,DefaultRootObjectLocator
public interface ObjectLocator extends ValidationEventLocator, Reportable
Object locator denotes a location in an object structure.- Author:
- Aleksei Valikov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ObjectLocatorgetParentLocator()ObjectLocator[]getPath()StringgetPathAsString()ItemObjectLocatoritem(int itemIndex, Object itemValue)Creates a locator for the item (like list or array item) relative to this locator.PropertyObjectLocatorproperty(String propertyName, Object propertyValue)Creates a locator for the property, relative to this locator.-
Methods inherited from interface org.jvnet.jaxb2_commons.i18n.Reportable
getMessage, getMessage, getMessageCode, getMessageParameters
-
Methods inherited from interface javax.xml.bind.ValidationEventLocator
getColumnNumber, getLineNumber, getNode, getObject, getOffset, getURL
-
-
-
-
Method Detail
-
getParentLocator
ObjectLocator getParentLocator()
- Returns:
- Parent locator, may be
null.
-
getPath
ObjectLocator[] getPath()
- Returns:
- Path to this locator from the root.
-
getPathAsString
String getPathAsString()
- Returns:
- Path to this locator in string form;
-
property
PropertyObjectLocator property(String propertyName, Object propertyValue)
Creates a locator for the property, relative to this locator.- Parameters:
propertyName- name of the property, must not benull.propertyValue- value of the property, may benull.- Returns:
- Child property locator.
-
item
ItemObjectLocator item(int itemIndex, Object itemValue)
Creates a locator for the item (like list or array item) relative to this locator.- Parameters:
itemIndex- index of the item.itemValue- value of the item.- Returns:
- Child item locator.
-
-