@inrupt/solid-client / thing/add
Module: thing/add#
Type Aliases#
AddOfType#
Ƭ AddOfType<Type
>: <T>(thing
: T
, property
: Url
| UrlString
, value
: Type
) => T
Type parameters#
Name |
---|
|
Type declaration#
▸ <T
>(thing
, property
, value
): T
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a value to. |
|
Property on which to add the given value. |
|
|
|
Value to add to |
Returns#
T
Defined in#
Functions#
addBoolean#
▸ addBoolean<T
>(thing
, property
, value
): T
Create a new Thing with a boolean added for a Property.
This preserves existing values for the given Property. To replace them, see [[setBoolean]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a boolean value to. |
|
|
Property for which to add the given boolean value. |
|
|
Boolean to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Defined in#
addDate#
▸ addDate<T
>(thing
, property
, value
): T
Create a new Thing with a date added for a Property.
This preserves existing values for the given Property. To replace them, see [[setDate]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a date value to. |
|
|
Property for which to add the given date value. |
|
|
Date to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Since
1.10.0
Defined in#
addDatetime#
▸ addDatetime<T
>(thing
, property
, value
): T
Create a new Thing with a datetime added for a Property.
This preserves existing values for the given Property. To replace them, see [[setDatetime]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a datetime value to. |
|
|
Property for which to add the given datetime value. |
|
|
Datetime to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Defined in#
addDecimal#
▸ addDecimal<T
>(thing
, property
, value
): T
Create a new Thing with a decimal added for a Property.
This preserves existing values for the given Property. To replace them, see [[setDecimal]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a decimal value to. |
|
|
Property for which to add the given decimal value. |
|
|
Decimal to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Defined in#
addInteger#
▸ addInteger<T
>(thing
, property
, value
): T
Create a new Thing with an integer added for a Property.
This preserves existing values for the given Property. To replace them, see [[setInteger]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add an integer value to. |
|
|
Property for which to add the given integer value. |
|
|
Integer to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Defined in#
addStringEnglish#
▸ addStringEnglish<T
>(thing
, property
, value
): T
Create a new Thing with an English string added for a Property.
This preserves existing values for the given Property. To replace them, see [[setStringEnglish]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a localised string value to. |
|
|
Property for which to add the given string value. |
|
|
String to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Since
1.13.0
Defined in#
addStringNoLocale#
▸ addStringNoLocale<T
>(thing
, property
, value
): T
Create a new Thing with an unlocalised string added for a Property.
This preserves existing values for the given Property. To replace them, see [[setStringNoLocale]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add an unlocalised string value to. |
|
|
Property for which to add the given string value. |
|
|
String to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Defined in#
addStringWithLocale#
▸ addStringWithLocale<T
>(thing
, property
, value
, locale
): T
Create a new Thing with a localised string added for a Property.
This preserves existing values for the given Property. To replace them, see [[setStringWithLocale]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a localised string value to. |
|
|
Property for which to add the given string value. |
|
|
String to add to |
|
|
Locale of the added string. |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Defined in#
addTime#
▸ addTime<T
>(thing
, property
, value
): T
Create a new Thing with a time added for a Property.
This preserves existing values for the given Property. To replace them, see [[setDatetime]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a datetime value to. |
|
|
Property for which to add the given datetime value. |
|
|
time to add to |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.
Since
1.10.0
Defined in#
addUrl#
▸ addUrl<T
>(thing
, property
, value
): T
Create a new Thing with a URL added for a Property.
This preserves existing values for the given Property. To replace them, see [[setUrl]].
The original thing
is not modified; this function returns a cloned Thing with updated values.
Type parameters#
Name |
Type |
---|---|
|
extends |
Parameters#
Name |
Type |
Description |
---|---|---|
|
|
Thing to add a URL value to. |
|
|
Property for which to add the given URL value. |
|
|
- |
Returns#
T
A new Thing equal to the input Thing with the given value added for the given Property.