ParamSpecVariantProtocol

public protocol ParamSpecVariantProtocol : ParamSpecProtocol

The ParamSpecVariantProtocol protocol exposes the methods and properties of an underlying GParamSpecVariant instance. The default implementation of these can be found in the protocol extension below. For a concrete class that implements these methods and properties, see ParamSpecVariant. Alternatively, use ParamSpecVariantRef as a lighweight, unowned reference if you already have an instance you just want to use.

A GParamSpec derived structure that contains the meta data for GVariant properties.

When comparing values with g_param_values_cmp(), scalar values with the same type will be compared with g_variant_compare(). Other non-nil variants will be checked for equality with g_variant_equal(), and their sort order is otherwise undefined. nil is ordered before non-nil variants. Two nil values compare equal.

  • ptr

    Untyped pointer to the underlying GParamSpecVariant instance.

    Declaration

    Swift

    var ptr: UnsafeMutableRawPointer! { get }
  • param_spec_variant_ptr Default implementation

    Typed pointer to the underlying GParamSpecVariant instance.

    Default Implementation

    Return the stored, untyped pointer as a typed pointer to the GParamSpecVariant instance.

    Declaration

    Swift

    var param_spec_variant_ptr: UnsafeMutablePointer<GParamSpecVariant>! { get }

ParamSpecVariant Class: ParamSpecVariantProtocol extension (methods and fields)

  • parentInstance Extension method

    private GParamSpec portion

    Declaration

    Swift

    @inlinable
    var parentInstance: GParamSpec { get }
  • type Extension method

    a GVariantType, or nil

    Declaration

    Swift

    @inlinable
    var type: VariantTypeRef! { get }
  • defaultValue Extension method

    a GVariant, or nil

    Declaration

    Swift

    @inlinable
    var defaultValue: VariantRef! { get }