Class RaterRatingPK
- java.lang.Object
-
- org.silverpeas.core.WAPrimaryKey
-
- org.silverpeas.core.ResourceReference
-
- org.silverpeas.core.contribution.rating.model.ContributionRatingPK
-
- org.silverpeas.core.contribution.rating.model.RaterRatingPK
-
- All Implemented Interfaces:
Serializable
,Cloneable
,ComponentResourceIdentifier
,ResourceIdentifier
public class RaterRatingPK extends ContributionRatingPK
This class represents a technical primary key of a rater rating.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.silverpeas.core.ResourceReference
UNKNOWN_ID
-
Fields inherited from class org.silverpeas.core.WAPrimaryKey
componentName, id, space
-
-
Constructor Summary
Constructors Constructor Description RaterRatingPK(String id, String componentId, String type, UserDetail rater)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object other)
Comparison between two notation primary key.UserDetail
getRater()
int
hashCode()
Gets the hash code of this reference.String
toString()
Converts the contents of the key into a readable String.-
Methods inherited from class org.silverpeas.core.contribution.rating.model.ContributionRatingPK
getContributionId, getContributionType, setContributionType
-
Methods inherited from class org.silverpeas.core.ResourceReference
asString, getComponentInstanceId, getLocalId, to
-
Methods inherited from class org.silverpeas.core.WAPrimaryKey
clone, getComponentName, getId, getInstanceId, getRootTableName, getSpace, getSpaceId, getTableName, getTableName, setComponentName, setId, setSpace, toResourceReference
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.silverpeas.core.ComponentResourceIdentifier
toReference
-
-
-
-
Constructor Detail
-
RaterRatingPK
public RaterRatingPK(String id, String componentId, String type, UserDetail rater)
-
-
Method Detail
-
getRater
public UserDetail getRater()
-
hashCode
public int hashCode()
Description copied from class:ResourceReference
Gets the hash code of this reference.- Overrides:
hashCode
in classContributionRatingPK
- Returns:
- an integer
-
equals
public boolean equals(Object other)
Comparison between two notation primary key. Since various attributes of the both elements can be null, using toString() method to compare the elements avoids to check null cases for each attribute.- Overrides:
equals
in classContributionRatingPK
- Parameters:
other
-- Returns:
- true if other is equals to this reference. False otherwise.
-
toString
public String toString()
Description copied from class:WAPrimaryKey
Converts the contents of the key into a readable String.- Overrides:
toString
in classContributionRatingPK
- Returns:
- The string representation of this object
-
-