View Javadoc

1   package cz.cuni.amis.pogamut.multi.communication.worldview.property;
2   
3   import java.awt.geom.Dimension2D;
4   
5   import cz.cuni.amis.pogamut.base.communication.worldview.object.WorldObjectId;
6   import cz.cuni.amis.pogamut.multi.communication.worldview.object.ISharedProperty;
7   
8   /**
9    * Implementation of the ISharedProperty interface for Dimension2D value type.
10   * @author srlok
11   *
12   */
13  public class Dimension2DProperty extends AbstractSharedProperty<Dimension2D> {
14  	
15  	@SuppressWarnings("rawtypes")
16  	public Dimension2DProperty(WorldObjectId objId, String identifier, Dimension2D value, Class compositeClass)
17  	{
18  		super(objId, identifier, value, compositeClass);
19  	}
20  	
21  	public Dimension2DProperty(Dimension2DProperty other)
22  	{
23  		super(other);
24  	}
25  
26  	@Override
27  	public ISharedProperty clone() {
28  		return new Dimension2DProperty(this);
29  	}
30  
31  	@Override
32  	public Class getPropertyValueClass() {
33  		return Dimension2D.class;
34  	}
35  
36  	@Override
37  	protected Dimension2D cloneValue() {
38  		if (this.value == null) return null;
39  		return (Dimension2D) value.clone();
40  	}
41  		
42  }