ch.sahits.game.openpatrician.model.personal
Enum ESocialRank

java.lang.Object
  extended by java.lang.Enum<ESocialRank>
      extended by ch.sahits.game.openpatrician.model.personal.ESocialRank
All Implemented Interfaces:
Serializable, Comparable<ESocialRank>

public enum ESocialRank
extends Enum<ESocialRank>

Social rank of a player

Author:
Andi Hotz, (c) Sahits GmbH, 2012 Created on Jul 23, 2012

Enum Constant Summary
ALDERMAN
           
BARGAINER
           
CHANDLER
           
COUNCILMAN
           
MAYOR
           
MERCHANT
           
PATRICIAN
           
TRADESMAN
           
 
Field Summary
private  int companyValue
           
private  int socialRank
           
 
Method Summary
 int getCompanyValue()
          Retrieve the company value needed for this social rank
 ESocialRank getNextRank()
           
 int getSocialReputation()
          Retrieve the percentage of social reputation needed for this rank
static ESocialRank valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ESocialRank[] 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

CHANDLER

public static final ESocialRank CHANDLER

BARGAINER

public static final ESocialRank BARGAINER

MERCHANT

public static final ESocialRank MERCHANT

TRADESMAN

public static final ESocialRank TRADESMAN

COUNCILMAN

public static final ESocialRank COUNCILMAN

PATRICIAN

public static final ESocialRank PATRICIAN

MAYOR

public static final ESocialRank MAYOR

ALDERMAN

public static final ESocialRank ALDERMAN
Field Detail

companyValue

private final int companyValue

socialRank

private final int socialRank
Method Detail

values

public static ESocialRank[] 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 (ESocialRank c : ESocialRank.values())
    System.out.println(c);

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

valueOf

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

getCompanyValue

public int getCompanyValue()
Retrieve the company value needed for this social rank

Returns:

getSocialReputation

public int getSocialReputation()
Retrieve the percentage of social reputation needed for this rank

Returns:

getNextRank

public ESocialRank getNextRank()


Copyright © 2011-2012 Sahits GmbH. All Rights Reserved.