Enum Class Alignment
- All Implemented Interfaces:
Serializable
,Comparable<Alignment>
,Constable
Alignment enumeration.
- Since:
- 2014-05-19
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic Alignment
getFromChar
(char c) Convert a letter to alignment.static Alignment
Convert a string to an alignment.static Alignment
randomBias
(Alignment align) Randomize an alignment biased toward a given one.static Alignment
Randomize a Chaotic-biased alignment.static Alignment
Randomize a Lawful-biased alignment.static Alignment
Randomize a normally-distributed alignment.static Alignment
Randomize a uniformly-distributed alignment.static Alignment
Returns the enum constant of this class with the specified name.static Alignment[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
Lawful
-
Neutral
-
Chaotic
-
-
Constructor Details
-
Alignment
private Alignment()
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException
- if the argument is null
-
getFromChar
Convert a letter to alignment. -
getFromString
Convert a string to an alignment. -
randomNormal
Randomize a normally-distributed alignment. -
randomUniform
Randomize a uniformly-distributed alignment. -
randomLawfulBias
Randomize a Lawful-biased alignment. -
randomChaoticBias
Randomize a Chaotic-biased alignment. -
randomBias
Randomize an alignment biased toward a given one.
-