クラス Particle

java.lang.Object
  上位を拡張 java.awt.geom.Point2D
      上位を拡張 java.awt.Point
          上位を拡張 Particle
すべての実装されたインタフェース:
java.io.Serializable, java.lang.Cloneable

public class Particle
extends java.awt.Point

粒子クラス

関連項目:
直列化された形式

入れ子のクラスの概要
 
クラス java.awt.geom.Point2D から継承された入れ子のクラス/インタフェース
java.awt.geom.Point2D.Double, java.awt.geom.Point2D.Float
 
フィールドの概要
protected  boolean add
          粒子の状態 核に接触した場合は true
static int DOWN
          下を表すフィールド
static int LEFT
          左を表すフィールド
static int RIGHT
          右を表すフィールド
static int UP
          上を表すフィールド
 
クラス java.awt.Point から継承されたフィールド
x, y
 
コンストラクタの概要
Particle(int x, int y)
          粒子オブジェクトを構築する
 
メソッドの概要
 void addCore()
          核に接触させる
 boolean isAddCore()
          核に接触しているかどうかを返す
 void move(int direction)
          粒子を移動させる
 
クラス java.awt.Point から継承されたメソッド
equals, getLocation, getX, getY, move, setLocation, setLocation, setLocation, toString, translate
 
クラス java.awt.geom.Point2D から継承されたメソッド
clone, distance, distance, distance, distanceSq, distanceSq, distanceSq, hashCode, setLocation
 
クラス java.lang.Object から継承されたメソッド
finalize, getClass, notify, notifyAll, wait, wait, wait
 

フィールドの詳細

UP

public static final int UP
上を表すフィールド

関連項目:
定数フィールド値

DOWN

public static final int DOWN
下を表すフィールド

関連項目:
定数フィールド値

LEFT

public static final int LEFT
左を表すフィールド

関連項目:
定数フィールド値

RIGHT

public static final int RIGHT
右を表すフィールド

関連項目:
定数フィールド値

add

protected boolean add
粒子の状態 核に接触した場合は true

コンストラクタの詳細

Particle

public Particle(int x,
                int y)
粒子オブジェクトを構築する

パラメータ:
x - 粒子の x 座標
y - 粒子の y 座標
メソッドの詳細

move

public void move(int direction)
粒子を移動させる

パラメータ:
direction - 粒子を移動させる方向を表すフィールド

addCore

public void addCore()
核に接触させる


isAddCore

public boolean isAddCore()
核に接触しているかどうかを返す

戻り値:
核に接触している場合は true