Package org.robwork.sdurw
Class ProximityCachePtr
- java.lang.Object
-
- org.robwork.sdurw.ProximityCachePtr
-
public class ProximityCachePtr extends java.lang.Object
Ptr stores a pointer and optionally takes ownership of the value.
-
-
Constructor Summary
Constructors Constructor Description ProximityCachePtr()
Default constructor yielding a NULL-pointer.ProximityCachePtr(long cPtr, boolean cMemoryOwn)
ProximityCachePtr(ProximityCache ptr)
Do not take ownership of ptr.
ptr can be null.
The constructor is implicit on purpose.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ProximityCache
__ref__()
Dereferencing operator.void
clear()
Clears cachevoid
delete()
ProximityCache
deref()
The pointer stored in the object.boolean
equals(ProximityCache p)
static long
getCPtr(ProximityCachePtr obj)
ProximityCache
getDeref()
Member access operator.boolean
isNull()
checks if the pointer is nullboolean
isShared()
check if this Ptr has shared ownership or none
ownershiplong
size()
Returns size of cache
-
-
-
Constructor Detail
-
ProximityCachePtr
public ProximityCachePtr(long cPtr, boolean cMemoryOwn)
-
ProximityCachePtr
public ProximityCachePtr()
Default constructor yielding a NULL-pointer.
-
ProximityCachePtr
public ProximityCachePtr(ProximityCache ptr)
Do not take ownership of ptr.
ptr can be null.
The constructor is implicit on purpose.
-
-
Method Detail
-
getCPtr
public static long getCPtr(ProximityCachePtr obj)
-
delete
public void delete()
-
deref
public ProximityCache deref()
The pointer stored in the object.
-
__ref__
public ProximityCache __ref__()
Dereferencing operator.
-
getDeref
public ProximityCache getDeref()
Member access operator.
-
equals
public boolean equals(ProximityCache p)
-
isShared
public boolean isShared()
check if this Ptr has shared ownership or none
ownership- Returns:
- true if Ptr has shared ownership, false if it has no ownership.
-
isNull
public boolean isNull()
checks if the pointer is null- Returns:
- Returns true if the pointer is null
-
size
public long size()
Returns size of cache- Returns:
- size
-
clear
public void clear()
Clears cache
-
-