com.limegroup.gnutella.spam
Class AddressToken
java.lang.Object
com.limegroup.gnutella.spam.Token
com.limegroup.gnutella.spam.AddressToken
- All Implemented Interfaces:
- Serializable
public class AddressToken
- extends Token
A token representing an IP address
- See Also:
- Serialized Form
| Fields inherited from class com.limegroup.gnutella.spam.Token |
rating |
|
Method Summary |
boolean |
equals(Object o)
|
protected float |
getRating()
Gets this token's spam rating |
protected float |
getWeight()
Returns a weight between 0 and 1 that determines how sensitive this
token's spam rating is to updates - 0 means an update has no effect on
the rating, while 1 means an update completely changes the rating. |
int |
hashCode()
|
String |
toString()
|
AddressToken
public AddressToken(String address,
com.google.inject.Provider<IPFilter> ipFilter)
getRating
protected float getRating()
- Description copied from class:
Token
- Gets this token's spam rating
- Overrides:
getRating in class Token
- Returns:
- a rating between 0 (not spam) and 1 (spam)
getWeight
protected float getWeight()
- Description copied from class:
Token
- Returns a weight between 0 and 1 that determines how sensitive this
token's spam rating is to updates - 0 means an update has no effect on
the rating, while 1 means an update completely changes the rating.
- Specified by:
getWeight in class Token
- Returns:
- a weight between 0 (not sensitive) and 1 (sensitive)
hashCode
public int hashCode()
- Overrides:
hashCode in class Object
equals
public boolean equals(Object o)
- Overrides:
equals in class Object
toString
public String toString()
- Overrides:
toString in class Object
Copyright © 2009. All Rights Reserved.