Class ConditionFactory.PseudoClasses
- java.lang.Object
-
- org.openstreetmap.josm.gui.mappaint.mapcss.ConditionFactory.PseudoClasses
-
- Enclosing class:
- ConditionFactory
public static final class ConditionFactory.PseudoClasses extends java.lang.Object
Like CSS pseudo classes, MapCSS pseudo classes are written in lower case with dashes between words.
-
-
Field Summary
Fields Modifier and Type Field Description private static java.util.function.Predicate<OsmPrimitive>IN_DOWNLOADED_AREA
-
Constructor Summary
Constructors Modifier Constructor Description privatePseudoClasses()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description (package private) static boolean_new(Environment e):newtests whether the object is new.(package private) static booleananticlockwise(Environment e):anticlockwisewhether the way is closed and oriented anticlockwise, or non-closed and the 1st, 2nd and last node are in anticlockwise order.(package private) static booleanareaStyle(Environment e):area-styletests whether the object has an area style.(package private) static booleanclockwise(Environment e):clockwisewhether the way is closed and oriented clockwise, or non-closed and the 1st, 2nd and last node are in clockwise order.(package private) static booleanclosed(Environment e):closedtests whether the way is closed or the relation is a closed multipolygon(package private) static booleanclosed2(Environment e)(package private) static booleancompletely_downloaded(Environment e):completely_downloadedtests whether the object is completely downloaded(package private) static booleanconnection(Environment e):connectiontests whether the object is a connection node.(package private) static booleanhighlighted(Environment e):highlightedtests whether the object is highlighted (i.e.(package private) static booleaninDownloadedArea(Environment e):in-downloaded-areatests whether the object is within source area ("downloaded area").(package private) static booleanmodified(Environment e):modifiedtests whether the object has been modified.(package private) static booleanrighthandtraffic(Environment e):righthandtrafficchecks if there is right-hand traffic at the current location.(package private) static booleansameTags(Environment e):same-tagstests whether the object has the same tags as its child/parent.(package private) static booleanselected(Environment e):selectedtests whether the object is selected in the editor(package private) static booleantagged(Environment e):taggedtests whether the object is tagged.(package private) static booleanunclosed_multipolygon(Environment e):unclosed-multipolygontests whether the object is an unclosed multipolygon.(package private) static booleanunconnected(Environment e):unconnectedtests whether the object is an unconnected node.
-
-
-
Field Detail
-
IN_DOWNLOADED_AREA
private static final java.util.function.Predicate<OsmPrimitive> IN_DOWNLOADED_AREA
-
-
Constructor Detail
-
PseudoClasses
private PseudoClasses()
-
-
Method Detail
-
closed
static boolean closed(Environment e)
:closedtests whether the way is closed or the relation is a closed multipolygon- Parameters:
e- MapCSS environment- Returns:
trueif the way is closed or the relation is a closed multipolygon
-
modified
static boolean modified(Environment e)
:modifiedtests whether the object has been modified.- Parameters:
e- MapCSS environment- Returns:
trueif the object has been modified- See Also:
IPrimitive.isModified()
-
_new
static boolean _new(Environment e)
:newtests whether the object is new.- Parameters:
e- MapCSS environment- Returns:
trueif the object is new- See Also:
PrimitiveId.isNew()
-
connection
static boolean connection(Environment e)
:connectiontests whether the object is a connection node.- Parameters:
e- MapCSS environment- Returns:
trueif the object is a connection node- See Also:
INode.isConnectionNode()
-
tagged
static boolean tagged(Environment e)
:taggedtests whether the object is tagged.- Parameters:
e- MapCSS environment- Returns:
trueif the object is tagged- See Also:
IPrimitive.isTagged()
-
sameTags
static boolean sameTags(Environment e)
:same-tagstests whether the object has the same tags as its child/parent.- Parameters:
e- MapCSS environment- Returns:
trueif the object has the same tags as its child/parent- See Also:
IPrimitive.hasSameInterestingTags(IPrimitive)
-
areaStyle
static boolean areaStyle(Environment e)
:area-styletests whether the object has an area style. This is useful for validators.- Parameters:
e- MapCSS environment- Returns:
trueif the object has an area style- See Also:
ElemStyles.hasAreaElemStyle(IPrimitive, boolean)
-
unconnected
static boolean unconnected(Environment e)
:unconnectedtests whether the object is an unconnected node.- Parameters:
e- MapCSS environment- Returns:
trueif the object is an unconnected node
-
righthandtraffic
static boolean righthandtraffic(Environment e)
:righthandtrafficchecks if there is right-hand traffic at the current location.- Parameters:
e- MapCSS environment- Returns:
trueif there is right-hand traffic at the current location- See Also:
Functions.is_right_hand_traffic(Environment)
-
clockwise
static boolean clockwise(Environment e)
:clockwisewhether the way is closed and oriented clockwise, or non-closed and the 1st, 2nd and last node are in clockwise order.- Parameters:
e- MapCSS environment- Returns:
trueif the way clockwise- See Also:
Functions.is_clockwise(Environment)
-
anticlockwise
static boolean anticlockwise(Environment e)
:anticlockwisewhether the way is closed and oriented anticlockwise, or non-closed and the 1st, 2nd and last node are in anticlockwise order.- Parameters:
e- MapCSS environment- Returns:
trueif the way clockwise- See Also:
Functions.is_anticlockwise(Environment)
-
unclosed_multipolygon
static boolean unclosed_multipolygon(Environment e)
:unclosed-multipolygontests whether the object is an unclosed multipolygon.- Parameters:
e- MapCSS environment- Returns:
trueif the object is an unclosed multipolygon
-
inDownloadedArea
static boolean inDownloadedArea(Environment e)
:in-downloaded-areatests whether the object is within source area ("downloaded area").- Parameters:
e- MapCSS environment- Returns:
trueif the object is within source area ("downloaded area")- See Also:
SearchCompiler.InDataSourceArea
-
completely_downloaded
static boolean completely_downloaded(Environment e)
:completely_downloadedtests whether the object is completely downloaded- Parameters:
e- MapCSS environment- Returns:
trueif the object is completely downloaded
-
closed2
static boolean closed2(Environment e)
-
selected
static boolean selected(Environment e)
:selectedtests whether the object is selected in the editor- Parameters:
e- MapCSS environment- Returns:
trueif the object is selected
-
highlighted
static boolean highlighted(Environment e)
:highlightedtests whether the object is highlighted (i.e. is hovered over)- Parameters:
e- The MapCSS environment- Returns:
trueif the object is highlighted- Since:
- 17862
- See Also:
IPrimitive.isHighlighted()
-
-