Class Layer
java.lang.Object
de.gurkenlabs.litiengine.environment.tilemap.xml.CustomPropertyProvider
de.gurkenlabs.litiengine.environment.tilemap.xml.Layer
- All Implemented Interfaces:
ICustomPropertyProvider,ILayer
- Direct Known Subclasses:
GroupLayer,ImageLayer,MapObjectLayer,TileLayer
public abstract class Layer
extends CustomPropertyProvider
implements ILayerConstructor Summary
Method Summary
Modifier and Type Method Description protected voidafterUnmarshal(javax.xml.bind.Unmarshaller u, java.lang.Object parent)intgetHeight()Gets the height.intgetId()IMapgetMap()java.lang.StringgetName()Gets the name.java.awt.PointgetOffset()Gets both the X and the Y offset of the layer.intgetOffsetX()Gets the horizontal offset of the layer.intgetOffsetY()Gets the vertical offset of the layer.floatgetOpacity()Gets the opacity.RenderTypegetRenderType()java.awt.DimensiongetSizeInTiles()Gets the size in tiles.intgetWidth()Gets the width.booleanisVisible()Checks if is visible.voidsetHeight(int height)protected voidsetMap(TmxMap map)voidsetName(java.lang.String name)voidsetOpacity(float opacity)voidsetRenderType(RenderType renderType)voidsetVisible(boolean visible)voidsetWidth(int width)Methods inherited from class de.gurkenlabs.litiengine.environment.tilemap.xml.CustomPropertyProvider
getBoolValue, getBoolValue, getByteValue, getByteValue, getColorValue, getColorValue, getCommaSeparatedStringValues, getDoubleValue, getDoubleValue, getEnumValue, getEnumValue, getFileValue, getFileValue, getFloatValue, getFloatValue, getIntValue, getIntValue, getLongValue, getProperties, getProperty, getShortValue, getShortValue, getStringValue, getStringValue, getTypeOfProperty, hasCustomProperty, removeProperty, setProperties, setTypeOfProperty, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValueMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.gurkenlabs.litiengine.environment.tilemap.ICustomPropertyProvider
getBoolValue, getBoolValue, getByteValue, getByteValue, getColorValue, getColorValue, getCommaSeparatedStringValues, getDoubleValue, getDoubleValue, getEnumValue, getEnumValue, getFileValue, getFileValue, getFloatValue, getFloatValue, getIntValue, getIntValue, getLongValue, getLongValue, getProperties, getProperty, getShortValue, getShortValue, getStringValue, getStringValue, getTypeOfProperty, hasCustomProperty, removeProperty, setProperties, setTypeOfProperty, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue
Constructor Details
Method Details
getHeight
public int getHeight()Gets the height.getId
public int getId()getName
public java.lang.String getName()Description copied from interface:ILayerGets the name.getOpacity
public float getOpacity()Description copied from interface:ILayerGets the opacity.- Specified by:
getOpacityin interfaceILayer- Returns:
- the opacity
getOffset
public java.awt.Point getOffset()Description copied from interface:ILayerGets both the X and the Y offset of the layer.getOffsetX
public int getOffsetX()Description copied from interface:ILayerGets the horizontal offset of the layer.- Specified by:
getOffsetXin interfaceILayer- Returns:
- the x offset
getOffsetY
public int getOffsetY()Description copied from interface:ILayerGets the vertical offset of the layer.- Specified by:
getOffsetYin interfaceILayer- Returns:
- the y offset
getRenderType
- Specified by:
getRenderTypein interfaceILayer
getSizeInTiles
public java.awt.Dimension getSizeInTiles()Description copied from interface:ILayerGets the size in tiles.- Specified by:
getSizeInTilesin interfaceILayer- Returns:
- the size in tiles
getWidth
public int getWidth()Gets the width.getMap
isVisible
public boolean isVisible()Description copied from interface:ILayerChecks if is visible.setName
public void setName(java.lang.String name)setWidth
public void setWidth(int width)setHeight
public void setHeight(int height)setOpacity
public void setOpacity(float opacity)- Specified by:
setOpacityin interfaceILayer
setRenderType
- Specified by:
setRenderTypein interfaceILayer
setVisible
public void setVisible(boolean visible)- Specified by:
setVisiblein interfaceILayer
setMap
afterUnmarshal
protected void afterUnmarshal(javax.xml.bind.Unmarshaller u, java.lang.Object parent)
