Class MemoryInputStream
- Namespace
- Gio
- Assembly
- Gio-2.0.dll
public class MemoryInputStream : InputStream, PollableInputStream, Seekable, NativeObject, IDisposable, GTypeProvider, InstanceFactory
- Inheritance
-
MemoryInputStream
- Implements
- Inherited Members
Constructors
MemoryInputStream(params ConstructArgument[])
[Obsolete("Regular C# constructors on native classes will be removed in a future version. Please see the linked documentation for more details. It contains scenarios and possible solutions to prepare for the upcoming changes.", DiagnosticId = "GirCore1007", UrlFormat = "https://gircore.github.io/docs/integration/diagnostic/1007.html")]
public MemoryInputStream(params ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]
MemoryInputStream(CreationData)
[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected MemoryInputStream(CreationData data)
Parameters
dataCreationData
MemoryInputStream(MemoryInputStreamHandle)
protected MemoryInputStream(MemoryInputStreamHandle handle)
Parameters
handleMemoryInputStreamHandle
Methods
AddBytes(Bytes)
[Version("2.34")]
public void AddBytes(Bytes bytes)
Parameters
bytesBytes
CanPoll()
[Version("2.28")]
public bool CanPoll()
Returns
CanSeek()
public bool CanSeek()
Returns
CanTruncate()
public bool CanTruncate()
Returns
CreateSource(Cancellable?)
[Version("2.28")]
public Source CreateSource(Cancellable? cancellable)
Parameters
cancellableCancellable
Returns
GetGType()
public static Type GetGType()
Returns
IsReadable()
[Version("2.28")]
public bool IsReadable()
Returns
New()
public static MemoryInputStream New()
Returns
NewFromBytes(Bytes)
[Version("2.34")]
public static MemoryInputStream NewFromBytes(Bytes bytes)
Parameters
bytesBytes
Returns
NewFromPointer(nint, bool)
Creates a new managed MemoryInputStream instance for a given pointer.
public static MemoryInputStream NewFromPointer(nint ptr, bool ownsHandle)
Parameters
Returns
NewWithProperties(ConstructArgument[])
Creates a new MemoryInputStream and sets the properties specified by the construct arguments.
public static MemoryInputStream NewWithProperties(ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]The properties to set.
Returns
ReadNonblocking(Span<byte>, Cancellable?)
public nint ReadNonblocking(Span<byte> buffer, Cancellable? cancellable)
Parameters
bufferSpan<byte>cancellableCancellable
Returns
Seek(long, SeekType, Cancellable?)
public bool Seek(long offset, SeekType type, Cancellable? cancellable)
Parameters
offsetlongtypeSeekTypecancellableCancellable
Returns
Tell()
public long Tell()
Returns
Truncate(long, Cancellable?)
public bool Truncate(long offset, Cancellable? cancellable)
Parameters
offsetlongcancellableCancellable