Class Reference
- java.lang.Object
-
- io.openapiprocessor.jsonschema.schema.Reference
-
public class Reference extends java.lang.Objectresolved $ref.- $ref string must be an uri.
- fragment of $ref is a json pointer ('~' encoded as '~0', '/' encoded as '~1').
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.net.URIgetAbsoluteRefUri()get full ref uri with scope and json pointer.java.net.URIgetDocumentUri()the uri of the referenced document.JsonPointergetPointer()@Nullable java.lang.ObjectgetRawValue()the raw value of the reference.java.lang.StringgetRefValue()the value of the reference.<T> @Nullable TgetValue()ScopegetValueScope()the scope at the reference value.java.lang.StringtoString()
-
-
-
Method Detail
-
getDocumentUri
public java.net.URI getDocumentUri()
the uri of the referenced document.- Returns:
- the referenced document.
-
getAbsoluteRefUri
public java.net.URI getAbsoluteRefUri()
get full ref uri with scope and json pointer.- Returns:
- the full ref uri
-
getRefValue
public java.lang.String getRefValue()
the value of the reference.- Returns:
- $ref value
-
getValueScope
public Scope getValueScope()
the scope at the reference value.- Returns:
- scope of $ref
-
getRawValue
public @Nullable java.lang.Object getRawValue()
the raw value of the reference. Maybe a simple value, array or map.- Returns:
- the raw value.
-
getValue
public <T> @Nullable T getValue()
-
getPointer
public JsonPointer getPointer()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-