mirror of
https://gitlab.com/oeffi/public-transport-enabler.git
synced 2025-07-14 08:40:29 +00:00
Remove Location.assertId() as IDs are now strings.
This commit is contained in:
parent
d6c5d98d8a
commit
5910c13c75
1 changed files with 0 additions and 14 deletions
|
@ -33,8 +33,6 @@ public final class Location implements Serializable
|
|||
|
||||
public Location(final LocationType type, final String id, final int lat, final int lon, final String place, final String name)
|
||||
{
|
||||
assertId(id);
|
||||
|
||||
this.type = type;
|
||||
this.id = id;
|
||||
this.lat = lat;
|
||||
|
@ -45,8 +43,6 @@ public final class Location implements Serializable
|
|||
|
||||
public Location(final LocationType type, final String id, final String place, final String name)
|
||||
{
|
||||
assertId(id);
|
||||
|
||||
this.type = type;
|
||||
this.id = id;
|
||||
this.lat = 0;
|
||||
|
@ -57,8 +53,6 @@ public final class Location implements Serializable
|
|||
|
||||
public Location(final LocationType type, final String id, final int lat, final int lon)
|
||||
{
|
||||
assertId(id);
|
||||
|
||||
this.type = type;
|
||||
this.id = id;
|
||||
this.lat = lat;
|
||||
|
@ -69,8 +63,6 @@ public final class Location implements Serializable
|
|||
|
||||
public Location(final LocationType type, final String id)
|
||||
{
|
||||
assertId(id);
|
||||
|
||||
this.type = type;
|
||||
this.id = id;
|
||||
this.lat = 0;
|
||||
|
@ -195,10 +187,4 @@ public final class Location implements Serializable
|
|||
return 0;
|
||||
return o.hashCode();
|
||||
}
|
||||
|
||||
private static void assertId(final String id)
|
||||
{
|
||||
if (id != null && Integer.parseInt(id) <= 0)
|
||||
throw new IllegalStateException("assert failed: id=" + id);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue