org.bukkit.potion
Enum PotionType

java.lang.Object
  extended by java.lang.Enum<PotionType>
      extended by org.bukkit.potion.PotionType
All Implemented Interfaces:
Serializable, Comparable<PotionType>

public enum PotionType
extends Enum<PotionType>


Enum Constant Summary
FIRE_RESISTANCE
           
INSTANT_DAMAGE
           
INSTANT_HEAL
           
INVISIBILITY
           
NIGHT_VISION
           
POISON
           
REGEN
           
SLOWNESS
           
SPEED
           
STRENGTH
           
WATER
           
WATER_BREATHING
           
WEAKNESS
           
 
Method Summary
static PotionType getByDamageValue(int damage)
          Deprecated. Magic value
static PotionType getByEffect(PotionEffectType effectType)
           
 int getDamageValue()
          Deprecated. Magic value
 PotionEffectType getEffectType()
           
 int getMaxLevel()
           
 boolean isInstant()
           
static PotionType valueOf(String name)
          Returns the enum constant of this type with the specified name.
static PotionType[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

WATER

public static final PotionType WATER

REGEN

public static final PotionType REGEN

SPEED

public static final PotionType SPEED

FIRE_RESISTANCE

public static final PotionType FIRE_RESISTANCE

POISON

public static final PotionType POISON

INSTANT_HEAL

public static final PotionType INSTANT_HEAL

NIGHT_VISION

public static final PotionType NIGHT_VISION

WEAKNESS

public static final PotionType WEAKNESS

STRENGTH

public static final PotionType STRENGTH

SLOWNESS

public static final PotionType SLOWNESS

INSTANT_DAMAGE

public static final PotionType INSTANT_DAMAGE

WATER_BREATHING

public static final PotionType WATER_BREATHING

INVISIBILITY

public static final PotionType INVISIBILITY
Method Detail

values

public static PotionType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (PotionType c : PotionType.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static PotionType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getEffectType

public PotionEffectType getEffectType()

getDamageValue

@Deprecated
public int getDamageValue()
Deprecated. Magic value


getMaxLevel

public int getMaxLevel()

isInstant

public boolean isInstant()

getByDamageValue

@Deprecated
public static PotionType getByDamageValue(int damage)
Deprecated. Magic value


getByEffect

public static PotionType getByEffect(PotionEffectType effectType)


Copyright © 2014. All rights reserved.