view src/main/java/alice/test/topology/aquarium/fx/FishInfo.java @ 388:cef1e0a46bb9 multicast

add setter
author sugi
date Mon, 16 Jun 2014 20:31:07 +0900
parents 878d397904da
children e29cf08ad1f3
line wrap: on
line source

package alice.test.topology.aquarium.fx;

import org.msgpack.annotation.Message;

@Message
public class FishInfo {
	// public fields are serialized.
	public double x = 0;
	public double y = 0;
	public double z = 0;
	public String name;
	public int size = 1;
	public String type = "defalut"; // use select object type. after implement may be...
	
	public FishInfo(){
		// this constructor is nothing to do, but need for serializing with MessagePack
	}
	
	public FishInfo(double x,double y,double z){
		this.x = x;
		this.y = y;
		this.z = z;
	}
	
	public void setName(String name){
		this.name = name;
	}
	
	public void setSize(int size){
		this.size = size;
	}
	
	public double getX(){
		return this.x;
	}
	
	public void setX(double x){
		this.x = x;
	}
	
	public double getY(){
		return this.y;
	}
	
	public void setY(double y){
		this.y = y;
	}
	
	public double getZ(){
		return this.z;
	}
	
	public void setZ(double z){
		this.z = z;
	} 
}