Package system.io
Class Stream
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- system.MarshalByRefObject
-
- system.io.Stream
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,IJCOBridgeReflected
- Direct Known Subclasses:
AuthenticatedStream
,BrotliStream
,BufferedStream
,CryptoStream
,DeflateStream
,FileStream
,GZipStream
,MemoryStream
,NetworkStream
,PipeStream
,PrintQueueStream
,QuicStream
,UnmanagedMemoryStream
,ZLibStream
public class Stream extends MarshalByRefObject implements java.lang.AutoCloseable
The base .NET class managing System.IO.Stream, System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e..NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.IO.Stream
Powered by JCOBridge: more info at https://www.jcobridge.com
- Author:
- MASES s.r.l https://masesgroup.com
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
assemblyFullName
Fully assembly qualified name: System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798estatic java.lang.String
assemblyShortName
Assembly name: System.Private.CoreLibstatic java.lang.String
className
Qualified class name: System.IO.Streamstatic JCType
classType
The type managed from JCOBridge.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description IAsyncResult
BeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, NetObject state)
IAsyncResult
BeginRead(JCORefOut dupParam0, int dupParam1, int dupParam2, AsyncCallback dupParam3, NetObject dupParam4)
IAsyncResult
BeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, NetObject state)
IAsyncResult
BeginWrite(JCORefOut dupParam0, int dupParam1, int dupParam2, AsyncCallback dupParam3, NetObject dupParam4)
static Stream
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoStream
, a cast assert is made to check if types are compatible.void
close()
void
Close()
void
CopyTo(Stream destination)
void
CopyTo(Stream destination, int bufferSize)
Task
CopyToAsync(Stream destination)
Task
CopyToAsync(Stream destination, int bufferSize)
Task
CopyToAsync(Stream destination, int bufferSize, CancellationToken cancellationToken)
Task
CopyToAsync(Stream destination, CancellationToken cancellationToken)
void
Dispose()
ValueTask
DisposeAsync()
int
EndRead(IAsyncResult asyncResult)
void
EndWrite(IAsyncResult asyncResult)
void
Flush()
Task
FlushAsync()
Task
FlushAsync(CancellationToken cancellationToken)
boolean
getCanRead()
boolean
getCanSeek()
boolean
getCanTimeout()
boolean
getCanWrite()
java.lang.String
getJCOAssemblyName()
Returns the reflected Assembly namejava.lang.String
getJCOClassName()
Returns the reflected Class namejava.lang.Object
getJCOInstance()
Returns the instantiated classjava.lang.String
getJCOObjectName()
Returns the reflected Class name used to build the objectJCType
getJCOType()
Returns the instantiated class Typelong
getLength()
long
getPosition()
int
getReadTimeout()
int
getWriteTimeout()
int
Read(byte[] buffer, int offset, int count)
int
Read(JCORefOut dupParam0, int dupParam1, int dupParam2)
int
ReadByte()
void
ReadExactly(byte[] buffer, int offset, int count)
void
ReadExactly(JCORefOut dupParam0, int dupParam1, int dupParam2)
ValueTask
ReadExactlyAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
ValueTask
ReadExactlyAsync(JCORefOut dupParam0, int dupParam1, int dupParam2, CancellationToken dupParam3)
long
Seek(long offset, SeekOrigin origin)
void
setJCOInstance(JCObject instance)
void
SetLength(long value)
void
setPosition(long Position)
void
setReadTimeout(int ReadTimeout)
void
setWriteTimeout(int WriteTimeout)
static Stream
Synchronized(Stream stream)
void
Write(byte[] buffer, int offset, int count)
void
Write(JCORefOut dupParam0, int dupParam1, int dupParam2)
Task
WriteAsync(byte[] buffer, int offset, int count)
Task
WriteAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Task
WriteAsync(JCORefOut dupParam0, int dupParam1, int dupParam2)
Task
WriteAsync(JCORefOut dupParam0, int dupParam1, int dupParam2, CancellationToken dupParam3)
void
WriteByte(byte value)
-
Methods inherited from class system.MarshalByRefObject
GetLifetimeService, InitializeLifetimeService
-
-
-
-
Field Detail
-
assemblyFullName
public static final java.lang.String assemblyFullName
Fully assembly qualified name: System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e- See Also:
- Constant Field Values
-
assemblyShortName
public static final java.lang.String assemblyShortName
Assembly name: System.Private.CoreLib- See Also:
- Constant Field Values
-
className
public static final java.lang.String className
Qualified class name: System.IO.Stream- See Also:
- Constant Field Values
-
-
Method Detail
-
getJCOAssemblyName
public java.lang.String getJCOAssemblyName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Assembly name- Specified by:
getJCOAssemblyName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOAssemblyName
in classMarshalByRefObject
- Returns:
- A
String
representing the Fullname of reflected Assembly
-
getJCOClassName
public java.lang.String getJCOClassName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name- Specified by:
getJCOClassName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOClassName
in classMarshalByRefObject
- Returns:
- A
String
representing the Fullname of reflected Class
-
getJCOObjectName
public java.lang.String getJCOObjectName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name used to build the object- Specified by:
getJCOObjectName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOObjectName
in classMarshalByRefObject
- Returns:
- A
String
representing the name used to allocated the object in CLR context
-
getJCOInstance
public java.lang.Object getJCOInstance()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class- Specified by:
getJCOInstance
in interfaceIJCOBridgeReflected
- Overrides:
getJCOInstance
in classMarshalByRefObject
- Returns:
- An
Object
representing the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstance
in classMarshalByRefObject
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class Type- Specified by:
getJCOType
in interfaceIJCOBridgeReflected
- Overrides:
getJCOType
in classMarshalByRefObject
- Returns:
- A
JCType
representing the CLR Type of the instantiated Class
-
cast
public static Stream cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflected
instance intoStream
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
Stream
instance- Throws:
java.lang.Throwable
- in case of error during cast operation
-
EndRead
public int EndRead(IAsyncResult asyncResult) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ArgumentNullException, ObjectDisposedException, RankException, IndexOutOfRangeException, EventSourceException, TaskSchedulerException, OperationCanceledException, TaskCanceledException, AggregateException, SemaphoreFullException
- Throws:
java.lang.Throwable
ArgumentException
ArgumentOutOfRangeException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
NotSupportedException
ArgumentNullException
ObjectDisposedException
RankException
IndexOutOfRangeException
EventSourceException
TaskSchedulerException
OperationCanceledException
TaskCanceledException
AggregateException
SemaphoreFullException
-
Read
public int Read(byte[] buffer, int offset, int count) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Read
public int Read(JCORefOut dupParam0, int dupParam1, int dupParam2) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
ReadByte
public int ReadByte() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Seek
public long Seek(long offset, SeekOrigin origin) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
BeginRead
public IAsyncResult BeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, NetObject state) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskSchedulerException, TaskCanceledException, AggregateException, SemaphoreFullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskSchedulerException
TaskCanceledException
AggregateException
SemaphoreFullException
-
BeginRead
public IAsyncResult BeginRead(JCORefOut dupParam0, int dupParam1, int dupParam2, AsyncCallback dupParam3, NetObject dupParam4) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskSchedulerException, TaskCanceledException, AggregateException, SemaphoreFullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskSchedulerException
TaskCanceledException
AggregateException
SemaphoreFullException
-
BeginWrite
public IAsyncResult BeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, NetObject state) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskSchedulerException, TaskCanceledException, AggregateException, SemaphoreFullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskSchedulerException
TaskCanceledException
AggregateException
SemaphoreFullException
-
BeginWrite
public IAsyncResult BeginWrite(JCORefOut dupParam0, int dupParam1, int dupParam2, AsyncCallback dupParam3, NetObject dupParam4) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskSchedulerException, TaskCanceledException, AggregateException, SemaphoreFullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskSchedulerException
TaskCanceledException
AggregateException
SemaphoreFullException
-
Synchronized
public static Stream Synchronized(Stream stream) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
CopyToAsync
public Task CopyToAsync(Stream destination, int bufferSize, CancellationToken cancellationToken) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, FormatException, ObjectDisposedException
-
CopyToAsync
public Task CopyToAsync(Stream destination, int bufferSize) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, ArgumentOutOfRangeException, FormatException, ObjectDisposedException
-
CopyToAsync
public Task CopyToAsync(Stream destination, CancellationToken cancellationToken) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, ArgumentOutOfRangeException, FormatException, ObjectDisposedException
-
CopyToAsync
public Task CopyToAsync(Stream destination) throws java.lang.Throwable, ArgumentNullException, PlatformNotSupportedException, ArgumentOutOfRangeException, NotSupportedException, ObjectDisposedException
- Throws:
java.lang.Throwable
ArgumentNullException
PlatformNotSupportedException
ArgumentOutOfRangeException
NotSupportedException
ObjectDisposedException
-
FlushAsync
public Task FlushAsync() throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, ArgumentOutOfRangeException, PlatformNotSupportedException, InvalidOperationException, OutOfMemoryException, EventSourceException
-
FlushAsync
public Task FlushAsync(CancellationToken cancellationToken) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, OutOfMemoryException, EventSourceException
-
WriteAsync
public Task WriteAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, ArgumentOutOfRangeException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskCanceledException, AggregateException, SemaphoreFullException, IndexOutOfRangeException, InvalidOperationException, EventSourceException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
ArgumentOutOfRangeException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskCanceledException
AggregateException
SemaphoreFullException
IndexOutOfRangeException
InvalidOperationException
EventSourceException
-
WriteAsync
public Task WriteAsync(JCORefOut dupParam0, int dupParam1, int dupParam2, CancellationToken dupParam3) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, ArgumentOutOfRangeException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskCanceledException, AggregateException, SemaphoreFullException, IndexOutOfRangeException, InvalidOperationException, EventSourceException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
ArgumentOutOfRangeException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskCanceledException
AggregateException
SemaphoreFullException
IndexOutOfRangeException
InvalidOperationException
EventSourceException
-
WriteAsync
public Task WriteAsync(byte[] buffer, int offset, int count) throws java.lang.Throwable, ArgumentNullException, ArgumentOutOfRangeException, NotSupportedException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskCanceledException, AggregateException, SemaphoreFullException, TaskSchedulerException, ArgumentException, InvalidOperationException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentOutOfRangeException
NotSupportedException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskCanceledException
AggregateException
SemaphoreFullException
TaskSchedulerException
ArgumentException
InvalidOperationException
-
WriteAsync
public Task WriteAsync(JCORefOut dupParam0, int dupParam1, int dupParam2) throws java.lang.Throwable, ArgumentNullException, ArgumentOutOfRangeException, NotSupportedException, PlatformNotSupportedException, NullReferenceException, ObjectDisposedException, OperationCanceledException, TaskCanceledException, AggregateException, SemaphoreFullException, TaskSchedulerException, ArgumentException, InvalidOperationException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentOutOfRangeException
NotSupportedException
PlatformNotSupportedException
NullReferenceException
ObjectDisposedException
OperationCanceledException
TaskCanceledException
AggregateException
SemaphoreFullException
TaskSchedulerException
ArgumentException
InvalidOperationException
-
DisposeAsync
public ValueTask DisposeAsync() throws java.lang.Throwable, ArgumentNullException, PlatformNotSupportedException, NullReferenceException, NotSupportedException, ArgumentOutOfRangeException, ArgumentException, InvalidOperationException
-
ReadExactlyAsync
public ValueTask ReadExactlyAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
ReadExactlyAsync
public ValueTask ReadExactlyAsync(JCORefOut dupParam0, int dupParam1, int dupParam2, CancellationToken dupParam3) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
Close
public void Close() throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
-
CopyTo
public void CopyTo(Stream destination, int bufferSize) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, FormatException, ObjectDisposedException
-
CopyTo
public void CopyTo(Stream destination) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, ArgumentOutOfRangeException, FormatException, ObjectDisposedException
-
Dispose
public void Dispose() throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
-
EndWrite
public void EndWrite(IAsyncResult asyncResult) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ArgumentNullException, ObjectDisposedException, RankException, IndexOutOfRangeException, EventSourceException, TaskSchedulerException, OperationCanceledException, TaskCanceledException, AggregateException, SemaphoreFullException
- Throws:
java.lang.Throwable
ArgumentException
ArgumentOutOfRangeException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
NotSupportedException
ArgumentNullException
ObjectDisposedException
RankException
IndexOutOfRangeException
EventSourceException
TaskSchedulerException
OperationCanceledException
TaskCanceledException
AggregateException
SemaphoreFullException
-
Flush
public void Flush() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
ReadExactly
public void ReadExactly(byte[] buffer, int offset, int count) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException, IOException
-
ReadExactly
public void ReadExactly(JCORefOut dupParam0, int dupParam1, int dupParam2) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException, IOException
-
SetLength
public void SetLength(long value) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Write
public void Write(byte[] buffer, int offset, int count) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Write
public void Write(JCORefOut dupParam0, int dupParam1, int dupParam2) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
WriteByte
public void WriteByte(byte value) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
close
public void close() throws java.lang.Exception
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Throws:
java.lang.Exception
-
getCanRead
public boolean getCanRead() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getCanSeek
public boolean getCanSeek() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getCanTimeout
public boolean getCanTimeout() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getCanWrite
public boolean getCanWrite() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getReadTimeout
public int getReadTimeout() throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, IndexOutOfRangeException, RankException, CultureNotFoundException, ObjectDisposedException
-
setReadTimeout
public void setReadTimeout(int ReadTimeout) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, IndexOutOfRangeException, RankException, CultureNotFoundException, ObjectDisposedException
-
getWriteTimeout
public int getWriteTimeout() throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, IndexOutOfRangeException, RankException, CultureNotFoundException, ObjectDisposedException
-
setWriteTimeout
public void setWriteTimeout(int WriteTimeout) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, IndexOutOfRangeException, RankException, CultureNotFoundException, ObjectDisposedException
-
getLength
public long getLength() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getPosition
public long getPosition() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
setPosition
public void setPosition(long Position) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
-