org.boxed_economy.components.cell
クラス Cell

java.lang.Object
  拡張org.boxed_economy.components.cell.Cell
すべての実装インタフェース:
Information, java.io.Serializable

public class Cell
extends java.lang.Object
implements Information

1セルを表すクラスです。2次元セルなので、X,Y座標を持ち距離を計算する ことができます。

バージョン:
$Id: Cell.java,v 1.1 2004/03/21 12:07:47 macchan Exp $
作成者:
Yc & Macchan
関連項目:
直列化された形式

フィールドの概要
 
インタフェース org.boxed_economy.besp.model.fmfw.Information から継承したフィールド
serialVersionUID
 
コンストラクタの概要
Cell(int x, int y)
          Constructor for Cell.
 
メソッドの概要
 boolean equals(java.lang.Object o)
           
 int getX()
          セルのX座標を返します。
 int getY()
          セルのY座標を返します。
 double measureDistance(Cell target)
          targetとの距離を計算して返します。
 java.lang.String toString()
           
 
クラス java.lang.Object から継承したメソッド
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

コンストラクタの詳細

Cell

public Cell(int x,
            int y)
Constructor for Cell.

メソッドの詳細

getX

public int getX()
セルのX座標を返します。

戻り値:
int セルのX座標

getY

public int getY()
セルのY座標を返します。

戻り値:
int セルのY座標

measureDistance

public double measureDistance(Cell target)
targetとの距離を計算して返します。 Javaのint型の制限を越えるような距離を計算することはできません。

パラメータ:
target - 測定targetのlocation
戻り値:
測定結果

equals

public boolean equals(java.lang.Object o)
関連項目:
Object.equals(Object)

toString

public java.lang.String toString()
関連項目:
Object.toString()