Ticket #4059: HistoryRelationMemberException.patch
File HistoryRelationMemberException.patch, 1.2 KB (added by , 16 years ago) |
---|
-
src/org/openstreetmap/josm/data/osm/history/RelationMember.java
20 20 * 21 21 * @param role the role 22 22 * @param primitiveType the type (must not be null) 23 * @param primitiveId the id (>0 required)23 * @param primitiveId the id 24 24 * 25 25 * @exception IllegalArgumentException thrown, if primitiveType is null 26 * @exception IllegalArgumentException thrown, if primitiveId <= 027 26 */ 28 27 public RelationMember(String role, OsmPrimitiveType primitiveType, long primitiveId) { 29 28 this.role = (role == null ? "" : role); 30 29 if (primitiveType == null) 31 30 throw new IllegalArgumentException(tr("Parameter ''{0}'' must not be null.", "primitiveType")); 32 31 this.primitiveType = primitiveType; 33 if (primitiveId <=0)34 throw new IllegalArgumentException(tr("Parameter ''{0}'' > 0 expected. Got ''{1}''.", "primitiveId", primitiveId));35 32 this.primitiveId = primitiveId; 36 33 } 37 34