Package com.bc.ceres.glayer.support
Class ShapeLayer.Type
- java.lang.Object
-
- com.bc.ceres.core.ExtensibleObject
-
- com.bc.ceres.glayer.LayerType
-
- com.bc.ceres.glayer.support.ShapeLayer.Type
-
- All Implemented Interfaces:
Extensible
- Enclosing class:
- ShapeLayer
@LayerTypeMetadata(name="ShapeLayerType", aliasNames="com.bc.ceres.glayer.support.ShapeLayer$Type") public static class ShapeLayer.Type extends LayerType
-
-
Field Summary
Fields Modifier and Type Field Description static String
PROPERTY_SHAPE_LIST
static String
PROPTERY_SHAPE_TO_MODEL_TRANSFORM
-
Constructor Summary
Constructors Constructor Description Type()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Layer
createLayer(LayerContext ctx, PropertySet configuration)
Creates a layer instance for the given application provided context and the given layer configuration.PropertySet
createLayerConfig(LayerContext ctx)
Creates a default configuration instance for the type of layers this type can create.boolean
isValidFor(LayerContext ctx)
Tests if this type can create layers for the given application provided context.-
Methods inherited from class com.bc.ceres.glayer.LayerType
createWithSceneView, getAliases, getName
-
Methods inherited from class com.bc.ceres.core.ExtensibleObject
getExtension
-
-
-
-
Field Detail
-
PROPERTY_SHAPE_LIST
public static final String PROPERTY_SHAPE_LIST
- See Also:
- Constant Field Values
-
PROPTERY_SHAPE_TO_MODEL_TRANSFORM
public static final String PROPTERY_SHAPE_TO_MODEL_TRANSFORM
- See Also:
- Constant Field Values
-
-
Method Detail
-
isValidFor
public boolean isValidFor(LayerContext ctx)
Description copied from class:LayerType
Tests if this type can create layers for the given application provided context. Note that some applications may provide their context through the extension object interface (seeExtensibleObject.getExtension(Class)
).- Specified by:
isValidFor
in classLayerType
- Parameters:
ctx
- An application-dependent layer context.- Returns:
true
if the type is valid with respect to the given context.
-
createLayer
public Layer createLayer(LayerContext ctx, PropertySet configuration)
Description copied from class:LayerType
Creates a layer instance for the given application provided context and the given layer configuration. The configuration may contain both, inmutable construction parameters passed to specific layer constructor as well as mutable layer properties.- Specified by:
createLayer
in classLayerType
- Parameters:
ctx
- An application provided context, may benull
. The parameter may be ignored by many layer types.configuration
- The layer configuration.- Returns:
- A new layer instance.
-
createLayerConfig
public PropertySet createLayerConfig(LayerContext ctx)
Description copied from class:LayerType
Creates a default configuration instance for the type of layers this type can create. After a default configuration has been created it is usually modified to specify a layer's construction parameters, e.g. for an image layer this could be the file path to the image file. Then, an application will pass the configuration to theLayerType.createLayer(com.bc.ceres.glayer.LayerContext, com.bc.ceres.binding.PropertySet)
method in order to create a new layer instance.- Specified by:
createLayerConfig
in classLayerType
- Parameters:
ctx
- An application provided context, may benull
. The parameter may be ignored by many layer types.- Returns:
- A new layer (default) configuration.
-
-