hoplugins.commons.vo
Class MatchRating

java.lang.Object
  extended byhoplugins.commons.vo.MatchRating

public class MatchRating
extends java.lang.Object

Class with holds the Ratings of a team in the 7 areas of the field

Author:
Massimiliano Amato

Constructor Summary
MatchRating()
           
 
Method Summary
 int float2HTint(float x)
          Convert reduced float rating (1.00....20.99) to original integer HT rating (1...80) one +0.5 is because of correct rounding to integer
 double getCentralAttack()
          Gets the central attack rating
 double getCentralDefense()
          Gets the central defense rating
 double getHatStats()
          Returns the calculated HatStats(3 midfield) + (sum of defence) + (sum of attack )
 double getLeftAttack()
          Gets the left attack rating
 double getLeftDefense()
          Gets the left defense rating
 double getLoddarStats(int tactic, int level)
          Returns the calculated LoddarStats
 double getMidfield()
          Gets the midfield rating
 double getPStats()
          Returns the calculated PStats (aka PeasoStats)
 double getRightAttack()
          Gets the right attack rating
 double getRightDefense()
          Gets the right defense rating
 double getSmartSquad(double stars)
          Returns the calculated Smart Squad Rating (Squad Rating / stars)
 double getSquad()
          Returns the calculated Squad Rating(2 midfield) + (sum of defence) + (sum of attack )
 void setCentralAttack(double rating)
          Sets the central attack rating
 void setCentralDefense(double rating)
          Sets the central defense rating
 void setLeftAttack(double rating)
          Sets the left attack rating
 void setLeftDefense(double rating)
          Sets the left defense rating
 void setMidfield(double rating)
          Sets the midfield rating
 void setRightAttack(double rating)
          Sets the right attack rating
 void setRightDefense(double rating)
          Sets the right defense rating
 java.lang.String toString()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MatchRating

public MatchRating()
Method Detail

setCentralAttack

public final void setCentralAttack(double rating)
Sets the central attack rating

Parameters:
rating - The rating

getCentralAttack

public final double getCentralAttack()
Gets the central attack rating

Returns:
The rating

setCentralDefense

public final void setCentralDefense(double rating)
Sets the central defense rating

Parameters:
rating - The rating

getCentralDefense

public final double getCentralDefense()
Gets the central defense rating

Returns:
The rating

getHatStats

public final double getHatStats()
Returns the calculated HatStats(3 midfield) + (sum of defence) + (sum of attack )

Returns:
the rating

setLeftAttack

public final void setLeftAttack(double rating)
Sets the left attack rating

Parameters:
rating - The rating

getLeftAttack

public final double getLeftAttack()
Gets the left attack rating

Returns:
The rating

setLeftDefense

public final void setLeftDefense(double rating)
Sets the left defense rating

Parameters:
rating - The rating

getLeftDefense

public final double getLeftDefense()
Gets the left defense rating

Returns:
The rating

getLoddarStats

public final double getLoddarStats(int tactic,
                                   int level)
Returns the calculated LoddarStats

Parameters:
tactic - The tactic code
level - The tactic rating
Returns:
the rating

setMidfield

public final void setMidfield(double rating)
Sets the midfield rating

Parameters:
rating - The rating

getMidfield

public final double getMidfield()
Gets the midfield rating

Returns:
The rating

getPStats

public final double getPStats()
Returns the calculated PStats (aka PeasoStats)

Returns:
the rating

setRightAttack

public final void setRightAttack(double rating)
Sets the right attack rating

Parameters:
rating - The rating

getRightAttack

public final double getRightAttack()
Gets the right attack rating

Returns:
The rating

setRightDefense

public final void setRightDefense(double rating)
Sets the right defense rating

Parameters:
rating - The rating

getRightDefense

public final double getRightDefense()
Gets the right defense rating

Returns:
The rating

getSmartSquad

public final double getSmartSquad(double stars)
Returns the calculated Smart Squad Rating (Squad Rating / stars)

Parameters:
stars - Team star rating
Returns:
the rating

getSquad

public final double getSquad()
Returns the calculated Squad Rating(2 midfield) + (sum of defence) + (sum of attack )

Returns:
the rating

float2HTint

public final int float2HTint(float x)
Convert reduced float rating (1.00....20.99) to original integer HT rating (1...80) one +0.5 is because of correct rounding to integer

Parameters:
x - HO float rating
Returns:
Integer HT rating

toString

public final java.lang.String toString()



Copyright © 2005 Hattrick Organizer Plugins Project. All Rights Reserved.