Table of Contents

Class Bytes

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

Constructors

Bytes(BytesOwnedHandle)

public Bytes(BytesOwnedHandle handle)

Parameters

handle BytesOwnedHandle

Properties

Handle

public BytesOwnedHandle Handle { get; }

Property Value

BytesOwnedHandle

Methods

Compare(Bytes)

[Version("2.32")]
public int Compare(Bytes bytes2)

Parameters

bytes2 Bytes

Returns

int

Dispose()

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

public void Dispose()

Equal(Bytes)

[Version("2.32")]
public bool Equal(Bytes bytes2)

Parameters

bytes2 Bytes

Returns

bool

Equals(Bytes?)

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

public bool Equals(Bytes? other)

Parameters

other Bytes

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.

GetGType()

public static Type GetGType()

Returns

Type

GetHashCode()

Serves as the default hash function.

public override int GetHashCode()

Returns

int

A hash code for the current object.

GetRegion(nuint, nuint, nuint)

[Version("2.70")]
public IntPtr GetRegion(nuint elementSize, nuint offset, nuint nElements)

Parameters

elementSize nuint
offset nuint
nElements nuint

Returns

IntPtr

GetSize()

[Version("2.32")]
public nuint GetSize()

Returns

nuint

Hash()

[Version("2.32")]
public uint Hash()

Returns

uint

New(Span<byte>)

[Version("2.32")]
public static Bytes New(Span<byte> data)

Parameters

data Span<byte>

Returns

Bytes

NewFromBytes(nuint, nuint)

[Version("2.32")]
public Bytes NewFromBytes(nuint offset, nuint length)

Parameters

offset nuint
length nuint

Returns

Bytes

NewStatic(Span<byte>)

[Version("2.32")]
public static Bytes NewStatic(Span<byte> data)

Parameters

data Span<byte>

Returns

Bytes

NewTake(Span<byte>)

[Version("2.32")]
public static Bytes NewTake(Span<byte> data)

Parameters

data Span<byte>

Returns

Bytes

Ref()

[Version("2.32")]
public Bytes Ref()

Returns

Bytes

Unref()

[Version("2.32")]
public void Unref()