public abstract class LayoutImpl extends Layout
Layout.Builder, Layout.ImplicitCast| Modifier and Type | Field and Description |
|---|---|
protected Class<? extends DynamicObject> |
clazz |
protected LayoutStrategy |
strategy |
OPTION_PREFIX| Modifier | Constructor and Description |
|---|---|
protected |
LayoutImpl(EnumSet<Layout.ImplicitCast> allowedImplicitCasts,
Class<? extends DynamicObjectImpl> clazz,
LayoutStrategy strategy) |
| Modifier and Type | Method and Description |
|---|---|
abstract Shape.Allocator |
createAllocator()
Create an allocator for static property creation.
|
Shape |
createShape(ObjectType objectType)
Create a root shape.
|
Shape |
createShape(ObjectType objectType,
Object sharedData)
Create a root shape.
|
protected abstract Location |
getObjectArrayLocation() |
protected abstract int |
getObjectFieldCount() |
protected abstract Location |
getPrimitiveArrayLocation() |
protected abstract int |
getPrimitiveFieldCount() |
LayoutStrategy |
getStrategy() |
Class<? extends DynamicObject> |
getType() |
protected abstract boolean |
hasObjectExtensionArray() |
protected abstract boolean |
hasPrimitiveExtensionArray() |
boolean |
isAllowedIntToDouble() |
boolean |
isAllowedIntToLong() |
abstract DynamicObject |
newInstance(Shape shape) |
protected int |
objectFieldIndex(Location location) |
createLayout, createShape, getAllowedImplicitCasts, getFactory, getPolymorphicUnboxing, newLayoutprotected final LayoutStrategy strategy
protected final Class<? extends DynamicObject> clazz
protected LayoutImpl(EnumSet<Layout.ImplicitCast> allowedImplicitCasts, Class<? extends DynamicObjectImpl> clazz, LayoutStrategy strategy)
public abstract DynamicObject newInstance(Shape shape)
newInstance in class Layoutpublic Class<? extends DynamicObject> getType()
public final Shape createShape(ObjectType objectType, Object sharedData)
LayoutcreateShape in class LayoutobjectType - that describes the object instance with this shape.sharedData - for language-specific usepublic final Shape createShape(ObjectType objectType)
LayoutcreateShape in class LayoutobjectType - that describes the object instance with this shape.public boolean isAllowedIntToDouble()
public boolean isAllowedIntToLong()
protected abstract boolean hasObjectExtensionArray()
protected abstract boolean hasPrimitiveExtensionArray()
protected abstract int getObjectFieldCount()
protected abstract int getPrimitiveFieldCount()
protected abstract Location getObjectArrayLocation()
protected abstract Location getPrimitiveArrayLocation()
protected int objectFieldIndex(Location location)
public abstract Shape.Allocator createAllocator()
LayoutcreateAllocator in class Layoutpublic LayoutStrategy getStrategy()