RestfulPropertyKit Documentation Beta

Class Rest​Value​Reference

public class RestValueReference<Value> 

Class-based value wrapper to easily reference the value and avoid copying the data in certain contexts.

The REST API uses this class and its mutable counterpart for passing the data of the @Rest property wrapper to internal logic, requiring a reference to the value even if it is a struct or enum.

Initializers

init(value:​)

public init(value: Value) 

Returns a new instance of RestValueReference containing a value of type Value.

Parameters

value Value

The value to be referenced.

Returns

The newly created instance referencing the given value.