Instance Propertyswift-bson 0.3.1BSONABI

utf8

Attempts to unwrap an instance of UTF8View from this variant. Its UTF-8 code units will not be validated, which allowes this method to return in constant time.

BSON.AnyValue.swift:433
var utf8: BSON.UTF8View<ArraySlice<UInt8>>? { get }

Returns

The payload of this variant if it matches either string(_:) or javascript(_:), nil otherwise.