Package net.sf.gridarta.model.mapmodel
Interface MapPath
-
- All Superinterfaces:
java.io.Serializable
- All Known Implementing Classes:
AbsoluteMapPath,RelativeMapPath
public interface MapPath extends java.io.SerializableRepresents a maps directory local map path.
-
-
Field Summary
Fields Modifier and Type Field Description static @NotNull java.util.regex.PatternSEPARATORAPatternto split a map path's string representation into components.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description @Nullable java.lang.StringgetMapComponent()Returns the initial path component of a map path.@NotNull java.lang.StringgetPath()Returns the map path information.@NotNull RelativeMapPathgetRelativeMapPathFrom(@NotNull AbsoluteMapPath mapPath)Returns this map path relative to another map path.
-
-
-
Method Detail
-
getPath
@NotNull @NotNull java.lang.String getPath()
Returns the map path information.- Returns:
- the map path information; it does not include a leading "/" for absolute paths
-
getMapComponent
@Nullable @Nullable java.lang.String getMapComponent()
Returns the initial path component of a map path. "/path/to/map" returns "path", "/map" returnsnull. Relative map paths always returnnull.- Returns:
- the initial path component
-
getRelativeMapPathFrom
@NotNull @NotNull RelativeMapPath getRelativeMapPathFrom(@NotNull @NotNull AbsoluteMapPath mapPath)
Returns this map path relative to another map path.- Parameters:
mapPath- the other map path- Returns:
- the relative map path from this map path to the other map path
-
-