Class InvalidPiersCheck
- java.lang.Object
-
- org.openstreetmap.atlas.checks.base.BaseCheck<java.lang.Long>
-
- org.openstreetmap.atlas.checks.validation.linear.edges.InvalidPiersCheck
-
- All Implemented Interfaces:
java.io.Serializable,Check
public class InvalidPiersCheck extends BaseCheck<java.lang.Long>
This check identifies piers (OSM ways with man_made = Pier tag) that have either a linear geometry and no area = Yes tag, or a polygonal geometry and no area=Yes tag. A pier must also have (i) a highway Tag or (ii) a highway overlapping the pier at the same level/layer as the pier or (iii) be connected to a ferry route/amenity = Ferry_Terminal or (iv) be connected to a building at the same level/layer as the pier. A polygonal pier with a building tag or amenity=ferry_terminal is also valid for the check.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.openstreetmap.atlas.checks.base.BaseCheck
PARAMETER_ACCEPT_PIERS, PARAMETER_CHALLENGE, PARAMETER_DENYLIST_COUNTRIES, PARAMETER_FLAG, PARAMETER_PERMITLIST_COUNTRIES, PARAMETER_PERMITLIST_TAGS
-
-
Constructor Summary
Constructors Constructor Description InvalidPiersCheck(org.openstreetmap.atlas.utilities.configuration.Configuration configuration)The default constructor that must be supplied.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleanacceptPier()Overriding this method to not skip piers.protected java.util.Optional<CheckFlag>flag(org.openstreetmap.atlas.geography.atlas.items.AtlasObject object)This is the actual function that will check to see whether the object needs to be flagged.protected java.util.List<java.lang.String>getFallbackInstructions()Method to implement for inheriting checks to return the default set of instruction formats that will be the last resort inBaseCheck.getLocalizedInstruction(int, Object[])booleanvalidCheckForObject(org.openstreetmap.atlas.geography.atlas.items.AtlasObject object)This function will validate if the supplied atlas object is valid for the check.-
Methods inherited from class org.openstreetmap.atlas.checks.base.BaseCheck
check, checkObjectFilter, clear, clearFlaggedIdentifiers, configurationKey, configurationKey, configurationValue, configurationValue, createFlag, createFlag, createFlag, createFlag, createFlag, createFlag, createFlag, createFlag, flags, getChallenge, getCheckName, getCheckPolygonFilter, getCountries, getDenylistCountries, getFlaggedIdentifiers, getGlobalPolygonFilter, getLocale, getLocalizedInstruction, getTaskIdentifier, getTaskIdentifier, getUniqueObjectIdentifier, getUniqueOSMIdentifier, isFlagged, logStatus, markAsFlagged, validCheckForCountry
-
-
-
-
Constructor Detail
-
InvalidPiersCheck
public InvalidPiersCheck(org.openstreetmap.atlas.utilities.configuration.Configuration configuration)
The default constructor that must be supplied. The Atlas Checks framework will generate the checks with this constructor, supplying a configuration that can be used to adjust any parameters that the check uses during operation.- Parameters:
configuration- the JSON configuration for this check
-
-
Method Detail
-
validCheckForObject
public boolean validCheckForObject(org.openstreetmap.atlas.geography.atlas.items.AtlasObject object)
This function will validate if the supplied atlas object is valid for the check. Valid object for the check is a main edge with man_made=pier tag and does not have an area=yes tag.- Parameters:
object- the atlas object supplied by the Atlas-Checks framework for evaluation- Returns:
trueif this object should be checked
-
acceptPier
protected boolean acceptPier()
Overriding this method to not skip piers.- Overrides:
acceptPierin classBaseCheck<java.lang.Long>- Returns:
- true since we need the check to accept piers
-
flag
protected java.util.Optional<CheckFlag> flag(org.openstreetmap.atlas.geography.atlas.items.AtlasObject object)
This is the actual function that will check to see whether the object needs to be flagged.
-
getFallbackInstructions
protected java.util.List<java.lang.String> getFallbackInstructions()
Description copied from class:BaseCheckMethod to implement for inheriting checks to return the default set of instruction formats that will be the last resort inBaseCheck.getLocalizedInstruction(int, Object[])- Overrides:
getFallbackInstructionsin classBaseCheck<java.lang.Long>- Returns:
- The set of instructions to fall back to if configuration results in none.
-
-