public static class Locations.DualLocation extends LocationImpl implements TypedLocation
LocationImpl.EffectivelyFinalLocation<T extends Location>, LocationImpl.InternalLongLocation, LocationImpl.TypedObjectLocation<T extends Location & ObjectLocation>| Modifier and Type | Field and Description |
|---|---|
protected LayoutImpl |
layout |
protected ObjectLocation |
objectLocation |
protected LocationImpl.InternalLongLocation |
primitiveLocation |
| Constructor and Description |
|---|
Locations.DualLocation(LocationImpl.InternalLongLocation primitiveLocation,
ObjectLocation objectLocation,
LayoutImpl layout) |
Locations.DualLocation(LocationImpl.InternalLongLocation primitiveLocation,
ObjectLocation objectLocation,
LayoutImpl layout,
java.lang.Class<?> type) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canStore(java.lang.Object value)
Returns
true if the location is compatible with the value. |
Locations.DualLocation |
changeType(java.lang.Class<?> newType) |
boolean |
equals(java.lang.Object obj) |
java.lang.Object |
get(DynamicObject store,
boolean condition)
Get object value as object at this location in store.
|
ObjectLocation |
getObjectLocation() |
java.lang.Class<?> |
getType()
The type of this location.
|
int |
hashCode() |
boolean |
isNonNull() |
int |
objectArrayCount()
Get the number of object array elements this location requires.
|
int |
objectFieldCount()
Get the number of in-object
Object fields this location requires. |
int |
primitiveArrayCount()
Get the number of primitive array elements this location requires.
|
int |
primitiveFieldCount()
Get the number of in-object primitive fields this location requires.
|
void |
setInternal(DynamicObject store,
java.lang.Object value)
Like
Location.set(DynamicObject, Object, Shape), but does not invalidate final locations. |
java.lang.String |
toString() |
canSet, canStoreFinal, getInternal, getWhereString, isConstant, isFinal, set, valueEqualscheckShape, finalLocation, get, incompatibleLocation, set, setclone, finalize, getClass, notify, notifyAll, wait, wait, waitget, set, set, setprotected final LocationImpl.InternalLongLocation primitiveLocation
protected final ObjectLocation objectLocation
protected final LayoutImpl layout
public Locations.DualLocation(LocationImpl.InternalLongLocation primitiveLocation, ObjectLocation objectLocation, LayoutImpl layout)
public Locations.DualLocation(LocationImpl.InternalLongLocation primitiveLocation, ObjectLocation objectLocation, LayoutImpl layout, java.lang.Class<?> type)
public java.lang.Object get(DynamicObject store, boolean condition)
BaseLocationBaseLocation.get(DynamicObject, Shape) instead.get in interface BaseLocationget in class Locationcondition - the result of a shape check or falseBaseLocation.get(DynamicObject, Shape)public void setInternal(DynamicObject store, java.lang.Object value) throws IncompatibleLocationException
LocationLocation.set(DynamicObject, Object, Shape), but does not invalidate final locations. For
internal use only and subject to change, use DynamicObjectFactory to create objects
with predefined properties.setInternal in class LocationImplIncompatibleLocationException - if value is of non-assignable typepublic int primitiveFieldCount()
LocationImplprimitiveFieldCount in class LocationImplpublic int primitiveArrayCount()
LocationImplprimitiveArrayCount in class LocationImplpublic int objectFieldCount()
LocationImplObject fields this location requires.objectFieldCount in class LocationImplpublic int objectArrayCount()
LocationImplobjectArrayCount in class LocationImplpublic java.lang.String toString()
toString in class LocationImplpublic boolean equals(java.lang.Object obj)
equals in class LocationImplpublic int hashCode()
hashCode in class LocationImplpublic ObjectLocation getObjectLocation()
public Locations.DualLocation changeType(java.lang.Class<?> newType)
public java.lang.Class<?> getType()
TypedLocationgetType in interface TypedLocationpublic boolean isNonNull()
public boolean canStore(java.lang.Object value)
Locationtrue if the location is compatible with the value.
The value may still be rejected if Location.canSet(DynamicObject, Object) returns false.canStore in class LocationImplvalue - the value in question