values
Note
This is a point-in-time snapshot of the API documentation from January 2026. Going forward, we will not be maintaining a public copy of these references, and recommend users to refer to the built-in signature helpers available in the Hack LSP instead for complete and up-to-date information.
Returns a new ImmVector containing the values of the current ImmVector;
that is, a copy of the current ImmVector
public function values(): ImmVector<Tv>;
This method is NOT interchangeable with toImmVector() and immutable().
toImmVector() and immutable() return the current ImmVector, and do
not incur the cost of copying the current ImmVector, or the memory space
consumed by the new ImmVector. This may be significant, for large
ImmVectors.
Returns
ImmVector<Tv>- A newImmVectorcontaining the values of the currentImmVector.
Examples
See Vector::values for usage examples.