Package system.io
Class UnmanagedMemoryAccessor
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- system.io.UnmanagedMemoryAccessor
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,IJCOBridgeReflected
- Direct Known Subclasses:
MemoryMappedViewAccessor
public class UnmanagedMemoryAccessor extends NetObject implements java.lang.AutoCloseable
The base .NET class managing System.IO.UnmanagedMemoryAccessor, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e..NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.IO.UnmanagedMemoryAccessor
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=8.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.UnmanagedMemoryAccessorstatic JCType
classType
The type managed from JCOBridge.
-
Constructor Summary
Constructors Constructor Description UnmanagedMemoryAccessor()
UnmanagedMemoryAccessor(java.lang.Object instance)
Internal constructor.UnmanagedMemoryAccessor(SafeBuffer buffer, long offset, long capacity)
UnmanagedMemoryAccessor(SafeBuffer buffer, long offset, long capacity, FileAccess access)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static UnmanagedMemoryAccessor
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoUnmanagedMemoryAccessor
, a cast assert is made to check if types are compatible.void
close()
void
Dispose()
boolean
getCanRead()
boolean
getCanWrite()
long
getCapacity()
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 Typeboolean
ReadBoolean(long position)
byte
ReadByte(long position)
char
ReadChar(long position)
Decimal
ReadDecimal(long position)
double
ReadDouble(long position)
short
ReadInt16(long position)
int
ReadInt32(long position)
long
ReadInt64(long position)
SByte
ReadSByte(long position)
Single
ReadSingle(long position)
UInt16
ReadUInt16(long position)
UInt32
ReadUInt32(long position)
UInt64
ReadUInt64(long position)
void
setJCOInstance(JCObject instance)
void
Write(long position, boolean value)
void
Write(long position, byte value)
void
Write(long position, char value)
void
Write(long position, double value)
void
Write(long position, int value)
void
Write(long position, long value)
void
Write(long position, short value)
void
Write(long position, Decimal value)
void
Write(long position, SByte value)
void
Write(long position, Single value)
void
Write(long position, UInt16 value)
void
Write(long position, UInt32 value)
void
Write(long position, UInt64 value)
-
-
-
Field Detail
-
assemblyFullName
public static final java.lang.String assemblyFullName
Fully assembly qualified name: System.Private.CoreLib, Version=8.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.UnmanagedMemoryAccessor- See Also:
- Constant Field Values
-
-
Constructor Detail
-
UnmanagedMemoryAccessor
public UnmanagedMemoryAccessor(java.lang.Object instance) throws java.lang.Throwable
Internal constructor. Use with caution- Throws:
java.lang.Throwable
-
UnmanagedMemoryAccessor
public UnmanagedMemoryAccessor() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
UnmanagedMemoryAccessor
public UnmanagedMemoryAccessor(SafeBuffer buffer, long offset, long capacity, FileAccess access) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, IndexOutOfRangeException, PlatformNotSupportedException, FormatException, ObjectDisposedException
-
UnmanagedMemoryAccessor
public UnmanagedMemoryAccessor(SafeBuffer buffer, long offset, long capacity) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, IndexOutOfRangeException, PlatformNotSupportedException, FormatException, ObjectDisposedException
-
-
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 classNetObject
- 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 classNetObject
- 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 classNetObject
- 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 classNetObject
- Returns:
- An
Object
representing the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstance
in classNetObject
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class Type- Specified by:
getJCOType
in interfaceIJCOBridgeReflected
- Overrides:
getJCOType
in classNetObject
- Returns:
- A
JCType
representing the CLR Type of the instantiated Class
-
cast
public static UnmanagedMemoryAccessor cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflected
instance intoUnmanagedMemoryAccessor
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
UnmanagedMemoryAccessor
instance- Throws:
java.lang.Throwable
- in case of error during cast operation
-
ReadBoolean
public boolean ReadBoolean(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadByte
public byte ReadByte(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
ReadChar
public char ReadChar(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadDouble
public double ReadDouble(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadInt16
public short ReadInt16(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
ReadInt32
public int ReadInt32(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
ReadInt64
public long ReadInt64(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
ReadSByte
public SByte ReadSByte(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadSingle
public Single ReadSingle(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadDecimal
public Decimal ReadDecimal(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, IndexOutOfRangeException, FormatException
-
ReadUInt16
public UInt16 ReadUInt16(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadUInt32
public UInt32 ReadUInt32(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
ReadUInt64
public UInt64 ReadUInt64(long position) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
Dispose
public void Dispose() throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
-
Write
public void Write(long position, boolean value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
Write
public void Write(long position, byte value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
Write
public void Write(long position, char value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
Write
public void Write(long position, double value) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, PlatformNotSupportedException, ObjectDisposedException, ArgumentNullException, FormatException
-
Write
public void Write(long position, short value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
Write
public void Write(long position, int value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
Write
public void Write(long position, long value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException
-
Write
public void Write(long position, SByte value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
Write
public void Write(long position, Single value) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, PlatformNotSupportedException, ObjectDisposedException, ArgumentNullException, FormatException
-
Write
public void Write(long position, Decimal value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, IndexOutOfRangeException
-
Write
public void Write(long position, UInt16 value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
Write
public void Write(long position, UInt32 value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
Write
public void Write(long position, UInt64 value) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, NotSupportedException, ObjectDisposedException, RankException, IndexOutOfRangeException
-
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
-
getCanWrite
public boolean getCanWrite() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getCapacity
public long getCapacity() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
-