Class SnakImpl
java.lang.Object
org.wikidata.wdtk.datamodel.implementation.SnakImpl
- All Implemented Interfaces:
Snak
- Direct Known Subclasses:
NoValueSnakImpl
,SomeValueSnakImpl
,ValueSnakImpl
Abstract Jackson implementation of
Snak
.- Author:
- Fredo Erxleben, Antonin Delpeuch
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionprotected
Constructor.SnakImpl
(PropertyIdValue property) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionReturns the property id string.Get the id of the property that this snak refers to.abstract String
-
Field Details
-
JSON_SNAK_TYPE_VALUE
Type string used to denote value snaks in JSON.- See Also:
-
JSON_SNAK_TYPE_SOMEVALUE
Type string used to denote somevalue snaks in JSON.- See Also:
-
JSON_SNAK_TYPE_NOVALUE
Type string used to denote novalue snaks in JSON.- See Also:
-
-
Constructor Details
-
SnakImpl
Constructor. -
SnakImpl
Constructor. Creates an empty object that can be populated during JSON deserialization. Should only be used by Jackson for this very purpose. This is not marked as JsonCreator because only concrete subclasses will be deserialized directly.
-
-
Method Details
-
getProperty
Returns the property id string. Only for use by Jackson during serialization.- Returns:
- the property id string
-
getPropertyId
Description copied from interface:Snak
Get the id of the property that this snak refers to.- Specified by:
getPropertyId
in interfaceSnak
- Returns:
- PropertyId of this Snak
-
getSnakType
-