Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.huguesjohnson.tiamat
Class Target

    java.lang.Object
      com.huguesjohnson.tiamat.Target

    public class Target

extends java.lang.Object

Target - represents the target of a Skill or Item

Author:
  Hugues Johnson

Field Summary
`static int` | `AFFECTED_ENTITY_ENEMY_ALL` AFFECTED_ENTITY constants specify who this target effects.
`static int` | `AFFECTED_ENTITY_ENEMY_SINGLE` AFFECTED_ENTITY constants specify who this target effects.
`static int` | `AFFECTED_ENTITY_EVERYONE` AFFECTED_ENTITY constants specify who this target effects.
`static int` | `AFFECTED_ENTITY_PARTY_ALL` AFFECTED_ENTITY constants specify who this target effects.
`static int` | `AFFECTED_ENTITY_PARTY_SINGLE` AFFECTED_ENTITY constants specify who this target effects.
`static int` | `AFFECTED_ENTITY_USER` AFFECTED_ENTITY constants specify who this target effects.
`static int` | `DEFAULT_AFFECTED_ENTITY` AFFECTED_ENTITY constants specify who this target effects.

Constructor Summary
`Target(java.lang.String targetPath, long value)` Create a new Target, uses DEFAULT_AFFECTED_ENTITY.
`Target(java.lang.String targetPath, long value, int affectedEntity)` Create a new Target, uses DEFAULT_AFFECTED_ENTITY.

Method Summary
`int` | `getAffectedEntity()` Returns who this target affects.
`java.lang.String` | `getTargetPath()` Returns the path of the item or attribute being modified.
`long` | `getValue()` Returns how much to modify the target.
`void` | `setAffectedEntity(int affectedEntity)` Sets who this target affects.
`void` | `setTargetPath(java.lang.String targetPath)` Sets the path of the item or attribute being modified.
`void` | `setValue(long value)` Sets how much to modify the target.
`java.lang.String` | `toString()` Returns a string representation of the object.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### AFFECTED_ENTITY_USER

    public static final int AFFECTED_ENTITY_USER

  AFFECTED_ENTITY constants specify who this target effects. AFFECTED_ENTITY_USER - the character that used the item.

  See Also:
    Constant Field Values

### AFFECTED_ENTITY_PARTY_SINGLE

    public static final int AFFECTED_ENTITY_PARTY_SINGLE

  AFFECTED_ENTITY constants specify who this target effects. AFFECTED_ENTITY_PARTY_SINGLE - a single member of the character’s party.

  See Also:
    Constant Field Values

### AFFECTED_ENTITY_PARTY_ALL

    public static final int AFFECTED_ENTITY_PARTY_ALL

  AFFECTED_ENTITY constants specify who this target effects. AFFECTED_ENTITY_PARTY_ALL - all members of the character’s party.

  See Also:
    Constant Field Values

### AFFECTED_ENTITY_ENEMY_SINGLE

    public static final int AFFECTED_ENTITY_ENEMY_SINGLE

  AFFECTED_ENTITY constants specify who this target effects. AFFECTED_ENTITY_ENEMY_SINGLE - a single enemy.

  See Also:
    Constant Field Values

### AFFECTED_ENTITY_ENEMY_ALL

    public static final int AFFECTED_ENTITY_ENEMY_ALL

  AFFECTED_ENTITY constants specify who this target effects. AFFECTED_ENTITY_ENEMY_ALL - all enemies.

  See Also:
    Constant Field Values

### AFFECTED_ENTITY_EVERYONE

    public static final int AFFECTED_ENTITY_EVERYONE

  AFFECTED_ENTITY constants specify who this target effects. AFFECTED_ENTITY_EVERYONE - everyone is effected.

  See Also:
    Constant Field Values

### DEFAULT_AFFECTED_ENTITY

    public static final int DEFAULT_AFFECTED_ENTITY

  AFFECTED_ENTITY constants specify who this target effects. DEFAULT_AFFECTED_ENTITY - AFFECTED_ENTITY_USER.

  See Also:
    Constant Field Values

Constructor Detail

### Target

    public Target(java.lang.String targetPath,
                  long value)

  Create a new Target, uses DEFAULT_AFFECTED_ENTITY.

  Parameters:
    `targetPath` - The path of the item or attribute being modified.
    `value` - How much to modify the target.

### Target

    public Target(java.lang.String targetPath,
                  long value,
                  int affectedEntity)

  Create a new Target, uses DEFAULT_AFFECTED_ENTITY.

  Parameters:
    `targetPath` - The path of the item or attribute being modified.
    `value` - How much to modify the target.
    `affectedEntity` - Who this Target effects, see AFFECTED_ENTITY constants.

Method Detail

### setTargetPath

    public void setTargetPath(java.lang.String targetPath)

  Sets the path of the item or attribute being modified.

  Parameters:
    `targetPath` - The path of the item or attribute being modified.

### getTargetPath

    public java.lang.String getTargetPath()

  Returns the path of the item or attribute being modified.

  Returns:
    The path of the item or attribute being modified.

### setValue

    public void setValue(long value)

  Sets how much to modify the target.

  Parameters:
    `value` - How much to modify the target.

### getValue

    public long getValue()

  Returns how much to modify the target.

  Returns:
    How much to modify the target.

### setAffectedEntity

    public void setAffectedEntity(int affectedEntity)

  Sets who this target affects.

  Parameters:
    `affectedEntity` - Who this Target effects, see AFFECTED_ENTITY constants.

### getAffectedEntity

    public int getAffectedEntity()

  Returns who this target affects.

  Returns:
    Who this target affects, see AFFECTED_ENTITY constants.

### toString

    public java.lang.String toString()

  Returns a string representation of the object.

  Overrides:
    `toString` in class `java.lang.Object`
  Returns:
    A string representation of the object.

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD