public class PropertyResolver extends Object
Constructor and Description |
---|
PropertyResolver() |
Modifier and Type | Method and Description |
---|---|
static void |
clearCache()
Clear the definition cache, e.g.
|
static List<QName> |
getQNamesFromPath(String propertyPath)
Split a property path into a list of
QName s. |
static LinkedList<String> |
getQueryPath(Instance instance,
String query)
Returns possible fully qualified (with namespace) paths for the given
String which could not contain all namespaces.
The path can be splitted using getQNamesFromPath(String) |
static List<List<QName>> |
getQueryPaths(TypeDefinition typeDef,
DataSet dataSet,
String query)
Returns all possible fully qualified (with namespaces) paths matching the
given query.
|
static Collection<Object> |
getValues(Instance instance,
String propertyPath)
Method for retrieving values from instances using a certain path query
for searching through the instance definitions.
|
static Collection<Object> |
getValues(Instance instance,
String propertyPath,
boolean forceValue)
Method for retrieving values from instances using a certain path query
for searching through the instance definitions.
|
static boolean |
hasProperty(Instance instance,
String query)
Determines of the given Instance contains certain definitions questioned
by a given stringquery.
|
static boolean |
isLastQueryPathUnique()
Determines if the last query path was unique.
|
public static Collection<Object> getValues(Instance instance, String propertyPath)
instance
- the instancepropertyPath
- the property pathpublic static Collection<Object> getValues(Instance instance, String propertyPath, boolean forceValue)
instance
- the instancepropertyPath
- the property pathforceValue
- if this is true
, when the object at the
end of a path is an instance, its value will be returnednull
public static List<QName> getQNamesFromPath(String propertyPath)
QName
s.propertyPath
- the property pathpublic static boolean hasProperty(Instance instance, String query)
instance
- the given instance we are searching inquery
- the given pathquery we are searching inside the
definition-treepublic static List<List<QName>> getQueryPaths(TypeDefinition typeDef, DataSet dataSet, String query)
typeDef
- the type definitiondataSet
- the data setquery
- the querypublic static LinkedList<String> getQueryPath(Instance instance, String query)
getQNamesFromPath(String)
instance
- the given instance which should contain the definitions
mentioned in the pathsquery
- the pathstring from the filterquerypublic static boolean isLastQueryPathUnique()
hasProperty(Instance, String)
was done from the current thread.
The information on the last hasProperty(Instance, String)
call
will be reset on calling this method.true
if the last query path was unique or if there
is no information on the last query path, false
otherwisepublic static void clearCache()
Build 2013-10-07_11-27-38
Revision 99b27713a799a59a21b0b166eaaea8aaefbf125a