java.lang.Object
java.lang.Record
club.doki7.ffm.ptr.CLongPtr
@ValueBasedCandidate
@UnsafeConstructor
public record CLongPtr(MemorySegment segment)
extends Record
implements IPointer, Iterable<Long>
-
Constructor Summary
ConstructorsConstructorDescriptionCLongPtr(MemorySegment segment) Creates an instance of aCLongPtrrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull CLongPtrstatic @NotNull CLongPtrstatic @Nullable CLongPtrchecked(@NotNull MemorySegment segment) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.iterator()@NotNull CLongPtroffset(long offset) longread()longread(long index) @NotNull CLongPtrreinterpret(long newSize) segment()Returns the value of thesegmentrecord component.longsize()@NotNull CLongPtrslice(long end) @NotNull CLongPtrslice(long start, long end) final StringtoString()Returns a string representation of this record class.voidwrite(long value) voidwrite(long index, long value) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
CLongPtr
Creates an instance of aCLongPtrrecord class.- Parameters:
segment- the value for thesegmentrecord component
-
-
Method Details
-
size
public long size() -
read
public long read() -
write
public void write(long value) -
read
public long read(long index) -
write
public void write(long index, long value) -
reinterpret
-
offset
-
slice
-
slice
-
iterator
-
checked
-
allocate
-
allocate
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
segment
Returns the value of thesegmentrecord component.
-