org.proteinshader.structure.enums
Enum RegionColorEnum

java.lang.Object
  extended by java.lang.Enum<RegionColorEnum>
      extended by org.proteinshader.structure.enums.RegionColorEnum
All Implemented Interfaces:
Serializable, Comparable<RegionColorEnum>

public enum RegionColorEnum
extends Enum<RegionColorEnum>

PrProvides default colors for regions of protein secondary structure (alpha-helices, beta-strands and general loop regions).

The RGB values are shown below on a 0 to 255 scale, but they are converted to floats on a scale from 0.0 to 1.0 by the private constructor for RegionColorEnum.


Enum Constant Summary
BRIGHT_GREEN
          Bright green = (10, 230, 10) will be used for beta-strands.
BRIGHT_RED
          Bright red = (230, 10, 10) will be used for alpha-helices.
GRAY
          Gray = (128, 128, 128) will be used for loops.
 
Method Summary
 float getBlue()
          Returns the blue component of the RGBA color as a float in the range from 0.0 to 1.0, inclusive.
 float getGreen()
          Returns the green component of the RGBA color as a float in the range from 0.0 to 1.0, inclusive.
 float getRed()
          Returns the red component of the RGBA color as a float in the range from 0.0 to 1.0, inclusive.
static RegionColorEnum valueOf(String name)
          Returns the enum constant of this type with the specified name.
static RegionColorEnum[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

GRAY

public static final RegionColorEnum GRAY
Gray = (128, 128, 128) will be used for loops.


BRIGHT_RED

public static final RegionColorEnum BRIGHT_RED
Bright red = (230, 10, 10) will be used for alpha-helices.


BRIGHT_GREEN

public static final RegionColorEnum BRIGHT_GREEN
Bright green = (10, 230, 10) will be used for beta-strands.

Method Detail

values

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

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

valueOf

public static RegionColorEnum 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

getRed

public float getRed()
Returns the red component of the RGBA color as a float in the range from 0.0 to 1.0, inclusive.

Returns:
The red value as a float.

getGreen

public float getGreen()
Returns the green component of the RGBA color as a float in the range from 0.0 to 1.0, inclusive.

Returns:
The green value as a float.

getBlue

public float getBlue()
Returns the blue component of the RGBA color as a float in the range from 0.0 to 1.0, inclusive.

Returns:
The blue value as a float.


Copyright © 2007-2008