Members
#
(static) DataType :string
#
(static) ValueType :string
#
property :string
Methods
#
(static) fromDataValue(property, datatype, datavalue) → {WikidataPain.Snak}
#
(static) fromEntity(property, entityId) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
entityId |
string
|
|
#
(static) fromMonolingualText(property, languageCode, text) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
languageCode |
string
|
|
text |
string
|
|
Parameters:
Name |
Type |
Description |
property |
string
|
|
#
(static) fromQuantity(property, amount, precision, unit) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
amount |
string
|
|
precision |
string
|
|
unit |
string
|
|
#
(static) fromQuickStatements(property, value) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
value |
string
|
|
Parameters:
Name |
Type |
Description |
raw |
Object
|
|
#
(static) fromSomevalue(property) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
#
(static) fromSparql(property, sparql) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
sparql |
Object
|
|
#
(static) fromString(property, string) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
string |
string
|
|
#
(static) fromTime(property, year, monthopt, dayopt) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Attributes |
Default |
Description |
property |
string
|
|
|
|
year |
number
|
|
|
|
month |
number
|
<optional>
|
null
|
|
day |
number
|
<optional>
|
null
|
|
#
(static) fromTimestamp(property, timestamp) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
timestamp |
string
|
|
#
(static) fromToday(property, precision) → {WikidataPain.Snak}
Parameters:
Name |
Type |
Description |
property |
string
|
|
precision |
number
|
|
Compares the precision of this Snak with another Snak's precision.
#
equals(other) → {boolean}
Compares this Snak with another Snak.
Returns:
`true` if equal, otherwise `false`.
-
Type
-
boolean
#
filterByTimeInterval(start, end) → {boolean}
Parameters:
Name |
Type |
Description |
start |
Array.<number>
|
|
end |
Array.<number>
|
|
#
merge(other) → {boolean}
Returns:
Whether a change occured.
-
Type
-
boolean
#
toJSON() → {Object}
#
toString() → {string}