コード例 #1
0
 @Override
 public int hashCode() {
   final int prime = 31;
   int result = 1;
   result = (prime * result) + ((end == null) ? 0 : end.hashCode());
   result = (prime * result) + ((start == null) ? 0 : start.hashCode());
   return result;
 }
コード例 #2
0
ファイル: Envelope3D.java プロジェクト: usuallycwdillon/gama
 /**
  * Returns a hash value for this envelope. This value need not remain consistent between different
  * implementations of the same class.
  */
 @Override
 public int hashCode() {
   // Algorithm from Effective Java by Joshua Bloch [Jon Aquino]
   int result = super.hashCode();
   result = 37 * result + Coordinate.hashCode(minz);
   result = 37 * result + Coordinate.hashCode(maxz);
   int code = result ^ (int) serialVersionUID;
   return code;
 }
コード例 #3
0
ファイル: NodeOsm.java プロジェクト: AnderPijoan/cat2osm
 @Override
 public int hashCode() {
   final int prime = 31;
   int result = 1;
   result = prime * result + ((coor == null) ? 0 : coor.hashCode());
   return result;
 }