Changeset 681 for trunk/quest-plugin-php/src/main/java/de/ugoe/cs/quest/plugin/php/eventcore/PHPEventType.java
- Timestamp:
- 08/29/12 10:05:50 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/quest-plugin-php/src/main/java/de/ugoe/cs/quest/plugin/php/eventcore/PHPEventType.java
r655 r681 1 1 2 package de.ugoe.cs.quest.plugin.php.eventcore; 2 3 … … 27 28 * </p> 28 29 */ 29 private String path;30 private final String path; 30 31 31 32 /** … … 34 35 * </p> 35 36 */ 36 private List<String> postVars;37 private final List<String> postVars; 37 38 38 39 /** … … 41 42 * </p> 42 43 */ 43 private List<String> getVars;44 private final List<String> getVars; 44 45 45 46 /** … … 89 90 } 90 91 92 /* 93 * (non-Javadoc) 94 * 95 * @see java.lang.Object#equals(java.lang.Object) 96 */ 97 @Override 98 public boolean equals(Object obj) { 99 if (obj instanceof PHPEventType) { 100 PHPEventType other = (PHPEventType) obj; 101 return ((path == null && other.path == null) || path.equals(other.path)) && 102 ((postVars == null && other.postVars == null) || postVars.equals(other.postVars)) && 103 ((getVars == null && other.getVars == null) || getVars.equals(other.getVars)); 104 } 105 return false; 106 } 107 108 /* 109 * (non-Javadoc) 110 * 111 * @see java.lang.Object#hashCode() 112 */ 113 @Override 114 public int hashCode() { 115 int hash = 17; 116 int multiplier = 7; 117 if (path != null) { 118 hash = hash * multiplier + path.hashCode(); 119 } 120 if (postVars != null) { 121 hash = hash * multiplier + postVars.hashCode(); 122 } 123 if (getVars != null) { 124 hash = hash * multiplier + getVars.hashCode(); 125 } 126 return hash; 127 } 128 91 129 }
Note: See TracChangeset
for help on using the changeset viewer.