JSON_SNAK_TYPE_NOVALUE, JSON_SNAK_TYPE_SOMEVALUE, JSON_SNAK_TYPE_VALUE| Modifier | Constructor and Description |
|---|---|
|
ValueSnakImpl(PropertyIdValue property,
Value value)
Constructor.
|
protected |
ValueSnakImpl(String property,
String datatype,
Value datavalue,
String siteIri)
Constructor used to deserialize from JSON with Jackson.
|
| Modifier and Type | Method and Description |
|---|---|
<T> T |
accept(SnakVisitor<T> snakVisitor)
Accept a SnakVisitor and return its output.
|
boolean |
equals(Object obj) |
String |
getDatatype()
Returns the JSON datatype string.
|
Value |
getDatavalue() |
protected static String |
getJsonPropertyTypeForValueType(Value value)
Infer the JSON datatype (represented as a string) from the data value.
|
String |
getSnakType() |
Value |
getValue()
Get the
Value of this Snak |
int |
hashCode() |
String |
toString() |
getProperty, getPropertyIdclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetPropertyIdpublic ValueSnakImpl(PropertyIdValue property, Value value)
property - the id of the property used in this snakvalue - the target value for this snakpublic Value getDatavalue()
public Value getValue()
ValueSnakValue of this Snakpublic String getDatatype()
public String getSnakType()
getSnakType in class SnakImplpublic <T> T accept(SnakVisitor<T> snakVisitor)
Snakprotected static String getJsonPropertyTypeForValueType(Value value)
value - the datavalue used as snak valueCopyright © 2014–2022 Wikidata Toolkit Developers. Generated from source code published under the Apache License 2.0. For more information, see the Wikidata Toolkit homepage