Class AbstractK2DElementFactory
java.lang.Object
com.kheops.jmap.client.graphics2D.AbstractK2DElementFactory
- All Implemented Interfaces:
K2DElementFactory,Serializable
- See Also:
-
Field Summary
Fields inherited from interface com.kheops.jmap.client.graphics2D.K2DElementFactory
serialVersionUID -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract K2DElementcreateElement(Geometry geometry, Object[] values, long id, int elementType) Creates a new instance of K2DElement based on the specified element type.abstract intgetDefaultType(int geometryType) Returns the element type that this element factory will create for the specified geometry type.abstract int[]getSupportedTypes(int geometryType) Returns all element types that this element factory can create for the specified geometry type.voidsetLayerInfo(LayerInfo layerInfo)
-
Constructor Details
-
AbstractK2DElementFactory
public AbstractK2DElementFactory()
-
-
Method Details
-
createElement
public abstract K2DElement createElement(Geometry geometry, Object[] values, long id, int elementType) throws IllegalArgumentException Description copied from interface:K2DElementFactoryCreates a new instance of K2DElement based on the specified element type. That new element will be initialized will use the specified id, geometry and attributes.- Specified by:
createElementin interfaceK2DElementFactory- Parameters:
geometry- the element geoemtry.values- element attributes.id- the element unique id.elementType- the element type to create.- Returns:
- a newly created K2DElement.
- Throws:
IllegalArgumentException
-
getSupportedTypes
public abstract int[] getSupportedTypes(int geometryType) Description copied from interface:K2DElementFactoryReturns all element types that this element factory can create for the specified geometry type.- Specified by:
getSupportedTypesin interfaceK2DElementFactory- Parameters:
geometryType- a geometry type.- Returns:
- an array of element types.
-
getDefaultType
public abstract int getDefaultType(int geometryType) Description copied from interface:K2DElementFactoryReturns the element type that this element factory will create for the specified geometry type.- Specified by:
getDefaultTypein interfaceK2DElementFactory- Parameters:
geometryType- a geometry type.- Returns:
- the element type.
-
setLayerInfo
-
getLayerInfo
-