Interface PrefixMap
-
- All Known Implementing Classes:
PrefixMapImpl
public interface PrefixMap
This models a map of URI prefixes.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description scala.Option<URI>
get(URI key)
Returns the expansion for the given prefix.scala.collection.immutable.Seq<URI>
getKeys()
Returns a sequence to iterate on the keys.scala.Option<URI>
getPrefixFor(URI uri)
Returns an optional with the prefix for the given URI, or empty if there is none.URI
getWithoutPrefix(URI uri)
Returns a URI without the prefix, i.e.URI
getWithPrefix(URI uri)
Returns a URI with the prefix, i.e.boolean
isEmpty()
Returnstrue
if and only if this map does not contain associations.String
PrefixAmpersand()
Start of the prefix.String
PrefixSemicolon()
End of the prefix.int
size()
Returns the size of this prefix map.
-
-
-
Method Detail
-
PrefixAmpersand
String PrefixAmpersand()
Start of the prefix.- Returns:
- (undocumented)
-
PrefixSemicolon
String PrefixSemicolon()
End of the prefix.- Returns:
- (undocumented)
-
get
scala.Option<URI> get(URI key)
Returns the expansion for the given prefix.- Parameters:
key
- the prefix- Returns:
- expansion for the given prefix
-
getKeys
scala.collection.immutable.Seq<URI> getKeys()
Returns a sequence to iterate on the keys.- Returns:
- a sequence to iterate on the keys
-
getPrefixFor
scala.Option<URI> getPrefixFor(URI uri)
Returns an optional with the prefix for the given URI, or empty if there is none.- Parameters:
uri
- URI- Returns:
- an optional with the prefix for the given URI, or empty if there is none
-
getWithPrefix
URI getWithPrefix(URI uri)
Returns a URI with the prefix, i.e. a shortened URI.- Parameters:
uri
- URI- Returns:
- a URI with the prefix
-
getWithoutPrefix
URI getWithoutPrefix(URI uri)
Returns a URI without the prefix, i.e. with the prefix already expanded.- Parameters:
uri
- uri- Returns:
- a URI without the prefix
-
isEmpty
boolean isEmpty()
Returnstrue
if and only if this map does not contain associations.- Returns:
true
if and only if this map does not contain associations
-
size
int size()
Returns the size of this prefix map.- Returns:
- the size of this prefix map
-
-