Table of Contents

Class Value

Namespace
GObject
Assembly
GObject-2.0.dll
public sealed class Value : IDisposable, BoxedRecord, IEquatable<Value>
Inheritance
Value
Implements
Inherited Members

Constructors

Value()

public Value()

Value(Variant)

public Value(Variant value)

Parameters

value Variant

Value(ValueOwnedHandle)

public Value(ValueOwnedHandle handle)

Parameters

handle ValueOwnedHandle

Value(Object)

public Value(Object value)

Parameters

value Object

Value(Type)

public Value(Type type)

Parameters

type Type

Value(bool)

public Value(bool value)

Parameters

value bool

Value(double)

public Value(double value)

Parameters

value double

Value(Enum)

public Value(Enum value)

Parameters

value Enum

Value(int)

public Value(int value)

Parameters

value int

Value(long)

public Value(long value)

Parameters

value long

Value(float)

public Value(float value)

Parameters

value float

Value(string)

public Value(string value)

Parameters

value string

Value(string[])

public Value(string[] value)

Parameters

value string[]

Value(uint)

public Value(uint value)

Parameters

value uint

Properties

Handle

public ValueOwnedHandle Handle { get; }

Property Value

ValueOwnedHandle

Methods

Copy(Value)

public void Copy(Value destValue)

Parameters

destValue Value

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

DupBoxed()

public IntPtr DupBoxed()

Returns

IntPtr

DupObject()

public Object? DupObject()

Returns

Object

DupParam()

public ParamSpec DupParam()

Returns

ParamSpec

DupString()

public string? DupString()

Returns

string

DupVariant()

[Version("2.26")]
public Variant? DupVariant()

Returns

Variant

Equals(Value?)

Indicates whether the current object is equal to another object of the same type.

public bool Equals(Value? other)

Parameters

other Value

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Determines whether the specified object is equal to the current object.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

FitsPointer()

public bool FitsPointer()

Returns

bool

GetBoolean()

public bool GetBoolean()

Returns

bool

GetBoxed()

public IntPtr GetBoxed()

Returns

IntPtr

GetBoxed(nuint)

public object? GetBoxed(nuint type)

Parameters

type nuint

Returns

object

GetChar()

public sbyte GetChar()

Returns

sbyte

GetDouble()

public double GetDouble()

Returns

double

GetEnum()

public int GetEnum()

Returns

int

GetEnum<T>()

public T GetEnum<T>() where T : Enum

Returns

T

Type Parameters

T

GetFlags()

public uint GetFlags()

Returns

uint

GetFlags<T>()

public T GetFlags<T>() where T : Enum

Returns

T

Type Parameters

T

GetFloat()

public float GetFloat()

Returns

float

GetGType()

public static Type GetGType()

Returns

Type

GetGtype()

[Version("2.12")]
public Type GetGtype()

Returns

Type

GetHashCode()

Serves as the default hash function.

public override int GetHashCode()

Returns

int

A hash code for the current object.

GetInt()

public int GetInt()

Returns

int

GetInt64()

public long GetInt64()

Returns

long

GetLong()

public long GetLong()

Returns

long

GetObject()

public Object? GetObject()

Returns

Object

GetParam()

public ParamSpec GetParam()

Returns

ParamSpec

GetPointer()

public IntPtr GetPointer()

Returns

IntPtr

GetSchar()

[Version("2.32")]
public sbyte GetSchar()

Returns

sbyte

GetString()

public string? GetString()

Returns

string

GetStringArray()

public string[]? GetStringArray()

Returns

string[]

GetUchar()

public byte GetUchar()

Returns

byte

GetUint()

public uint GetUint()

Returns

uint

GetUint64()

public ulong GetUint64()

Returns

ulong

GetUlong()

public ulong GetUlong()

Returns

ulong

GetVariant()

[Version("2.26")]
public Variant? GetVariant()

Returns

Variant

Init(Type)

public Value Init(Type gType)

Parameters

gType Type

Returns

Value

InitFromInstance(TypeInstance)

[Version("2.42")]
public void InitFromInstance(TypeInstance instance)

Parameters

instance TypeInstance

PeekPointer()

public IntPtr PeekPointer()

Returns

IntPtr

Reset()

public Value Reset()

Returns

Value

SetBoolean(bool)

public void SetBoolean(bool vBoolean)

Parameters

vBoolean bool

SetBoxed(IntPtr)

public void SetBoxed(IntPtr vBoxed)

Parameters

vBoxed IntPtr

SetBoxedTakeOwnership(IntPtr)

public void SetBoxedTakeOwnership(IntPtr vBoxed)

Parameters

vBoxed IntPtr

SetChar(sbyte)

public void SetChar(sbyte vChar)

Parameters

vChar sbyte

SetDouble(double)

public void SetDouble(double vDouble)

Parameters

vDouble double

SetEnum(Enum)

public void SetEnum(Enum e)

Parameters

e Enum

SetEnum(int)

public void SetEnum(int vEnum)

Parameters

vEnum int

SetFlags(Enum)

public void SetFlags(Enum e)

Parameters

e Enum

SetFlags(uint)

public void SetFlags(uint vFlags)

Parameters

vFlags uint

SetFloat(float)

public void SetFloat(float vFloat)

Parameters

vFloat float

SetGtype(Type)

[Version("2.12")]
public void SetGtype(Type vGtype)

Parameters

vGtype Type

SetInstance(IntPtr)

public void SetInstance(IntPtr instance)

Parameters

instance IntPtr

SetInt(int)

public void SetInt(int vInt)

Parameters

vInt int

SetInt64(long)

public void SetInt64(long vInt64)

Parameters

vInt64 long

SetInternedString(string?)

[Version("2.66")]
public void SetInternedString(string? vString)

Parameters

vString string

SetLong(long)

public void SetLong(long vLong)

Parameters

vLong long

SetObject(Object?)

public void SetObject(Object? vObject)

Parameters

vObject Object

SetObjectTakeOwnership(IntPtr)

public void SetObjectTakeOwnership(IntPtr vObject)

Parameters

vObject IntPtr

SetParam(ParamSpec?)

public void SetParam(ParamSpec? param)

Parameters

param ParamSpec

SetParamTakeOwnership(ParamSpec?)

public void SetParamTakeOwnership(ParamSpec? param)

Parameters

param ParamSpec

SetPointer(IntPtr)

public void SetPointer(IntPtr vPointer)

Parameters

vPointer IntPtr

SetSchar(sbyte)

[Version("2.32")]
public void SetSchar(sbyte vChar)

Parameters

vChar sbyte

SetStaticBoxed(IntPtr)

public void SetStaticBoxed(IntPtr vBoxed)

Parameters

vBoxed IntPtr

SetStaticString(string?)

public void SetStaticString(string? vString)

Parameters

vString string

SetString(string?)

public void SetString(string? vString)

Parameters

vString string

SetStringTakeOwnership(string?)

public void SetStringTakeOwnership(string? vString)

Parameters

vString string

SetUchar(byte)

public void SetUchar(byte vUchar)

Parameters

vUchar byte

SetUint(uint)

public void SetUint(uint vUint)

Parameters

vUint uint

SetUint64(ulong)

public void SetUint64(ulong vUint64)

Parameters

vUint64 ulong

SetUlong(ulong)

public void SetUlong(ulong vUlong)

Parameters

vUlong ulong

SetVariant(Variant?)

[Version("2.26")]
public void SetVariant(Variant? variant)

Parameters

variant Variant

StealString()

[Version("2.80")]
public string? StealString()

Returns

string

TakeBoxed(IntPtr)

[Version("2.4")]
public void TakeBoxed(IntPtr vBoxed)

Parameters

vBoxed IntPtr

TakeObject(IntPtr)

[Version("2.4")]
public void TakeObject(IntPtr vObject)

Parameters

vObject IntPtr

TakeParam(ParamSpec?)

[Version("2.4")]
public void TakeParam(ParamSpec? param)

Parameters

param ParamSpec

TakeString(string?)

[Version("2.4")]
public void TakeString(string? vString)

Parameters

vString string

TakeVariant(Variant?)

[Version("2.26")]
public void TakeVariant(Variant? variant)

Parameters

variant Variant

Transform(Value)

public bool Transform(Value destValue)

Parameters

destValue Value

Returns

bool

TypeCompatible(Type, Type)

public static bool TypeCompatible(Type srcType, Type destType)

Parameters

srcType Type
destType Type

Returns

bool

TypeTransformable(Type, Type)

public static bool TypeTransformable(Type srcType, Type destType)

Parameters

srcType Type
destType Type

Returns

bool

Unset()

public void Unset()