ContentDeserializerProtocol

public protocol ContentDeserializerProtocol : AsyncResultProtocol, ObjectProtocol

The ContentDeserializerProtocol protocol exposes the methods and properties of an underlying GdkContentDeserializer 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 ContentDeserializer. Alternatively, use ContentDeserializerRef as a lighweight, unowned reference if you already have an instance you just want to use.

A GdkContentDeserializer is used to deserialize content received via inter-application data transfers.

The GdkContentDeserializer transforms serialized content that is identified by a mime type into an object identified by a GType.

GTK provides serializers and deserializers for common data types such as text, colors, images or file lists. To register your own deserialization functions, use [funccontent_register_deserializer].

Also see [classGdk.ContentSerializer].

  • ptr

    Untyped pointer to the underlying GdkContentDeserializer instance.

    Declaration

    Swift

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

    Typed pointer to the underlying GdkContentDeserializer instance.

    Default Implementation

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

    Declaration

    Swift

    var content_deserializer_ptr: UnsafeMutablePointer<GdkContentDeserializer>! { get }
  • Required Initialiser for types conforming to ContentDeserializerProtocol

    Declaration

    Swift

    init(raw: UnsafeMutableRawPointer)

ContentDeserializer Class: ContentDeserializerProtocol extension (methods and fields)

  • getCancellable() Extension method

    Gets the cancellable for the current operation.

    This is the GCancellable that was passed to [funccontent_deserialize_async].

    Declaration

    Swift

    @inlinable
    func getCancellable() -> GIO.CancellableRef!
  • getGtype() Extension method

    Gets the GType to create an instance of.

    Declaration

    Swift

    @inlinable
    func getGtype() -> GType
  • getInputStream() Extension method

    Gets the input stream for the current operation.

    This is the stream that was passed to [funccontent_deserialize_async].

    Declaration

    Swift

    @inlinable
    func getInputStream() -> GIO.InputStreamRef!
  • getMimeType() Extension method

    Gets the mime type to deserialize from.

    Declaration

    Swift

    @inlinable
    func getMimeType() -> String!
  • getPriority() Extension method

    Gets the I/O priority for the current operation.

    This is the priority that was passed to [funccontent_deserialize_async].

    Declaration

    Swift

    @inlinable
    func getPriority() -> Int
  • getTaskData() Extension method

    Gets the data that was associated with the current operation.

    See [methodGdk.ContentDeserializer.set_task_data].

    Declaration

    Swift

    @inlinable
    func getTaskData() -> gpointer!
  • getUserData() Extension method

    Gets the user data that was passed when the deserializer was registered.

    Declaration

    Swift

    @inlinable
    func getUserData() -> gpointer!
  • getValue() Extension method

    Gets the GValue to store the deserialized object in.

    Declaration

    Swift

    @inlinable
    func getValue() -> GLibObject.ValueRef!
  • return_(error:) Extension method

    Indicate that the deserialization has ended with an error.

    This function consumes error.

    Declaration

    Swift

    @inlinable
    func return_<GLibErrorT>(error: GLibErrorT) where GLibErrorT : ErrorProtocol
  • returnSuccess() Extension method

    Indicate that the deserialization has been successfully completed.

    Declaration

    Swift

    @inlinable
    func returnSuccess()
  • setTask(data:notify:) Extension method

    Associate data with the current deserialization operation.

    Declaration

    Swift

    @inlinable
    func setTask(data: gpointer! = nil, notify: GDestroyNotify?)
  • cancellable Extension method

    Gets the cancellable for the current operation.

    This is the GCancellable that was passed to [funccontent_deserialize_async].

    Declaration

    Swift

    @inlinable
    var cancellable: GIO.CancellableRef! { get }
  • gtype Extension method

    Gets the GType to create an instance of.

    Declaration

    Swift

    @inlinable
    var gtype: GType { get }
  • inputStream Extension method

    Gets the input stream for the current operation.

    This is the stream that was passed to [funccontent_deserialize_async].

    Declaration

    Swift

    @inlinable
    var inputStream: GIO.InputStreamRef! { get }
  • mimeType Extension method

    Gets the mime type to deserialize from.

    Declaration

    Swift

    @inlinable
    var mimeType: String! { get }
  • priority Extension method

    Gets the I/O priority for the current operation.

    This is the priority that was passed to [funccontent_deserialize_async].

    Declaration

    Swift

    @inlinable
    var priority: Int { get }
  • taskData Extension method

    Gets the data that was associated with the current operation.

    See [methodGdk.ContentDeserializer.set_task_data].

    Declaration

    Swift

    @inlinable
    var taskData: gpointer! { get }
  • userData Extension method

    Gets the user data that was passed when the deserializer was registered.

    Declaration

    Swift

    @inlinable
    var userData: gpointer! { get }
  • value Extension method

    Gets the GValue to store the deserialized object in.

    Declaration

    Swift

    @inlinable
    var value: GLibObject.ValueRef! { get }