Share via


ByteArrayInputStream Constructors

Definition

Overloads

ByteArrayInputStream(Byte[])

Creates a ByteArrayInputStream so that it uses buf as its buffer array.

ByteArrayInputStream(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

ByteArrayInputStream(Byte[], Int32, Int32)

Creates ByteArrayInputStream that uses buf as its buffer array.

ByteArrayInputStream(Byte[])

Creates a ByteArrayInputStream so that it uses buf as its buffer array.

[Android.Runtime.Register(".ctor", "([B)V", "")]
public ByteArrayInputStream (byte[]? buf);
[<Android.Runtime.Register(".ctor", "([B)V", "")>]
new Java.IO.ByteArrayInputStream : byte[] -> Java.IO.ByteArrayInputStream

Parameters

buf
Byte[]

the input buffer.

Attributes

Remarks

Creates a ByteArrayInputStream so that it uses buf as its buffer array. The buffer array is not copied. The initial value of pos is 0 and the initial value of count is the length of buf.

Java documentation for java.io.ByteArrayInputStream.ByteArrayInputStream(byte[]).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

ByteArrayInputStream(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

protected ByteArrayInputStream (IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Java.IO.ByteArrayInputStream : nativeint * Android.Runtime.JniHandleOwnership -> Java.IO.ByteArrayInputStream

Parameters

javaReference
IntPtr

nativeint

A IntPtrcontaining a Java Native Interface (JNI) object reference.

transfer
JniHandleOwnership

A JniHandleOwnershipindicating how to handle javaReference

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

ByteArrayInputStream(Byte[], Int32, Int32)

Creates ByteArrayInputStream that uses buf as its buffer array.

[Android.Runtime.Register(".ctor", "([BII)V", "")]
public ByteArrayInputStream (byte[]? buf, int offset, int length);
[<Android.Runtime.Register(".ctor", "([BII)V", "")>]
new Java.IO.ByteArrayInputStream : byte[] * int * int -> Java.IO.ByteArrayInputStream

Parameters

buf
Byte[]

the input buffer.

offset
Int32

the offset in the buffer of the first byte to read.

length
Int32

the maximum number of bytes to read from the buffer.

Attributes

Remarks

Creates ByteArrayInputStream that uses buf as its buffer array. The initial value of pos is offset and the initial value of count is the minimum of offset+length and buf.length. The buffer array is not copied. The buffer's mark is set to the specified offset.

Java documentation for java.io.ByteArrayInputStream.ByteArrayInputStream(byte[], int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to