Package com.graphhopper.reader
Class ReaderElement
java.lang.Object
com.graphhopper.reader.ReaderElement
- Direct Known Subclasses:
OSMFileHeader,ReaderNode,ReaderRelation,ReaderWay
Base class for all network objects
- Author:
- Nop, Peter
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedReaderElement(long id, ReaderElement.Type type) protectedReaderElement(long id, ReaderElement.Type type, Map<String, Object> properties) -
Method Summary
Modifier and TypeMethodDescriptionvoidintgetFirstIndex(List<String> searchedTags) getFirstValue(List<String> searchedTags) Returns the first existing value of the specified list of keys where the order is important.longgetId()<T> TgetTags()getType()booleanCheck that the object has a given tag with a given value.booleanCheck that a given tag has one of the specified values.final booleanhasTag(String key, Collection<String> values) Check that a given tag has one of the specified values.booleanCheck a number of tags in the given order if their value is equal to the specified value.booleanhasTag(List<String> keyList, Collection<String> values) Check a number of tags in the given order for any of the given values.booleanhasTags()voidvoidvoidprotected StringtoString()
-
Constructor Details
-
ReaderElement
-
ReaderElement
-
-
Method Details
-
getId
public long getId() -
tagsToString
-
getTags
-
setTags
-
hasTags
public boolean hasTags() -
getTag
-
getTag
-
setTag
-
hasTag
Check that the object has a given tag with a given value. -
hasTag
Check that a given tag has one of the specified values. If no values are given, just checks for presence of the tag -
hasTag
Check that a given tag has one of the specified values. -
hasTag
Check a number of tags in the given order for any of the given values. -
hasTag
Check a number of tags in the given order if their value is equal to the specified value. -
getFirstValue
Returns the first existing value of the specified list of keys where the order is important.- Returns:
- an empty string if nothing found
-
getFirstIndex
- Returns:
- -1 if not found
-
removeTag
-
clearTags
public void clearTags() -
getType
-
toString
-