다음을 통해 공유


LongBuffer Class

Definition

A long buffer.

[Android.Runtime.Register("java/nio/LongBuffer", DoNotGenerateAcw=true)]
public abstract class LongBuffer : Java.Nio.Buffer, IDisposable, Java.Interop.IJavaPeerable, Java.Lang.IComparable
[<Android.Runtime.Register("java/nio/LongBuffer", DoNotGenerateAcw=true)>]
type LongBuffer = class
    inherit Buffer
    interface IComparable
    interface IJavaObject
    interface IDisposable
    interface IJavaPeerable
Inheritance
LongBuffer
Attributes
Implements

Remarks

A long buffer.

This class defines four categories of operations upon long buffers:

<ul>

<li>

Absolute and relative #get() <i>get</i> and #put(long) <i>put</i> methods that read and write single longs;

</li>

<li>

Relative #get(long[]) <i>bulk get</i> methods that transfer contiguous sequences of longs from this buffer into an array; and

</li>

<li>

Relative #put(long[]) <i>bulk put</i> methods that transfer contiguous sequences of longs from a long array or some other long buffer into this buffer;&#32;and

</li>

<li>

Methods for #compact compacting, #duplicate duplicating, and #slice slicing a long buffer.

</li>

</ul>

Long buffers can be created either by #allocate <i>allocation</i>, which allocates space for the buffer's

content, by #wrap(long[]) <i>wrapping</i> an existing long array into a buffer, or by creating a <i>view</i> of an existing byte buffer.

Like a byte buffer, a long buffer is either <i>direct</i> or <i>non-direct</i>. A long buffer created via the wrap methods of this class will be non-direct. A long buffer created as a view of a byte buffer will be direct if, and only if, the byte buffer itself is direct. Whether or not a long buffer is direct may be determined by invoking the #isDirect isDirect method.

Methods in this class that do not otherwise have a value to return are specified to return the buffer upon which they are invoked. This allows method invocations to be chained.

Added in 1.4.

Java documentation for java.nio.LongBuffer.

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.

Constructors

LongBuffer(IntPtr, JniHandleOwnership)

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

Properties

Class

Returns the runtime class of this Object.

(Inherited from Object)
Handle

The handle to the underlying Android instance.

(Inherited from Object)
HasArray

Tells whether or not this buffer is backed by an accessible long array.

HasRemaining

Tells whether there are any elements between the current position and the limit.

(Inherited from Buffer)
IsDirect

Returns true if this is a direct buffer.

(Inherited from Buffer)
IsReadOnly

Indicates whether this buffer is read-only.

(Inherited from Buffer)
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
PeerReference (Inherited from Object)
ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Methods

Allocate(Int32)

Allocates a new long buffer.

ArrayOffset()

Returns the offset within this buffer's backing array of the first element of the buffer&nbsp;&nbsp;(optional operation).

AsReadOnlyBuffer()

Creates a new, read-only long buffer that shares this buffer's content.

Capacity()

Returns this buffer's capacity.

(Inherited from Buffer)
Clear()

Clears this buffer.

(Inherited from Buffer)
Clone()

Creates and returns a copy of this object.

(Inherited from Object)
Compact()

Compacts this buffer&nbsp;&nbsp;(optional operation).

CompareTo(LongBuffer)

Compares this buffer to another.

Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
Duplicate()

Creates a new long buffer that shares this buffer's content.

Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
Flip()

Flips this buffer.

(Inherited from Buffer)
Get()

Relative get method.

Get(Int32)

Absolute get method.

Get(Int64[], Int32, Int32)

Relative bulk get method.

Get(Int64[])

Relative bulk get method.

GetDirectBufferAddress() (Inherited from Buffer)
GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
Limit()

Returns this buffer's limit.

(Inherited from Buffer)
Limit(Int32)

Sets this buffer's limit.

(Inherited from Buffer)
Mark()

Sets this buffer's mark at its position.

(Inherited from Buffer)
Mismatch(LongBuffer)

Finds and returns the relative index of the first mismatch between this buffer and a given buffer.

Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
Order()

Retrieves this buffer's byte order.

Position()

Returns this buffer's position.

(Inherited from Buffer)
Position(Int32)

Sets this buffer's position.

(Inherited from Buffer)
Put(Int32, Int64)

Absolute put method&nbsp;&nbsp;(optional operation).

Put(Int64)

Relative put method&nbsp;&nbsp;(optional operation).

Put(Int64[], Int32, Int32)

Relative bulk put method&nbsp;&nbsp;(optional operation).

Put(Int64[])

Relative bulk put method&nbsp;&nbsp;(optional operation).

Put(LongBuffer)

Relative bulk put method&nbsp;&nbsp;(optional operation).

Remaining()

Returns the number of elements between the current position and the limit.

(Inherited from Buffer)
Reset()

Resets this buffer's position to the previously-marked position.

(Inherited from Buffer)
Rewind()

Rewinds this buffer.

(Inherited from Buffer)
SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
Slice()

Creates a new long buffer whose content is a shared subsequence of this buffer's content.

Slice(Int32, Int32)

Creates a new long buffer whose content is a shared subsequence of this buffer's content.

Slice(Int32, Int32)

Creates a new buffer whose content is a shared subsequence of this buffer's content.

(Inherited from Buffer)
ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnregisterFromRuntime() (Inherited from Object)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wrap(Int64[], Int32, Int32)

Wraps a long array into a buffer.

Wrap(Int64[])

Wraps a long array into a buffer.

Explicit Interface Implementations

IComparable.CompareTo(Object)
IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to