- java.lang.Object
-
- org.praxislive.core.Value
-
- org.praxislive.core.types.PResource
-
- All Implemented Interfaces:
Comparable<PResource>
public final class PResource extends Value implements Comparable<PResource>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
PResource.Resolver
-
Nested classes/interfaces inherited from class org.praxislive.core.Value
Value.Type<T extends Value>
-
-
Field Summary
Fields Modifier and Type Field Description static String
KEY_ALLOW_EMPTY
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(PResource o)
boolean
equals(Object obj)
Values must override the default equals method.static Optional<PResource>
from(Value arg)
int
hashCode()
Values must override the default hashcode method.static ArgumentInfo
info()
static ArgumentInfo
info(boolean allowEmpty)
static PResource
of(URI uri)
static PResource
parse(String str)
List<URI>
resolve(Lookup lookup)
String
toString()
Values must override the default method to return a string representation that is immutable.URI
value()
-
Methods inherited from class org.praxislive.core.Value
equivalent, isEmpty, ofObject, type
-
-
-
-
Field Detail
-
KEY_ALLOW_EMPTY
public static final String KEY_ALLOW_EMPTY
- See Also:
- Constant Field Values
-
-
Method Detail
-
value
public URI value()
-
toString
public String toString()
Description copied from class:Value
Values must override the default method to return a string representation that is immutable.
-
hashCode
public int hashCode()
Description copied from class:Value
Values must override the default hashcode method.
-
equals
public boolean equals(Object obj)
Description copied from class:Value
Values must override the default equals method. This method should only returntrue
if the supplied Object is of the same type as the implementing Value. Values of an unknown type should be coerced before calling this method. This method does not have to guarantee thatthis.equals(that) == this.toString().equals(that.toString())
-
parse
public static PResource parse(String str) throws ValueFormatException
- Throws:
ValueFormatException
-
info
public static ArgumentInfo info()
-
info
public static ArgumentInfo info(boolean allowEmpty)
-
compareTo
public int compareTo(PResource o)
- Specified by:
compareTo
in interfaceComparable<PResource>
-
-