From 87e933aafc0b48d178c8a8a16aeee58c1a0049bc Mon Sep 17 00:00:00 2001 From: oblonski Date: Sun, 16 Oct 2016 21:00:44 +0200 Subject: [PATCH] add docs to location --- .../jsprit/core/problem/Location.java | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/jsprit-core/src/main/java/com/graphhopper/jsprit/core/problem/Location.java b/jsprit-core/src/main/java/com/graphhopper/jsprit/core/problem/Location.java index 4d1dbb64..f9721e15 100644 --- a/jsprit-core/src/main/java/com/graphhopper/jsprit/core/problem/Location.java +++ b/jsprit-core/src/main/java/com/graphhopper/jsprit/core/problem/Location.java @@ -70,22 +70,46 @@ public final class Location implements HasIndex, HasId { return new Builder(); } + /** + * Sets location index + * + * @param index + * @return the builder + */ public Builder setIndex(int index) { if (index < 0) throw new IllegalArgumentException("index must be >= 0"); this.index = index; return this; } + /** + * Sets coordinate of location + * + * @param coordinate + * @return + */ public Builder setCoordinate(Coordinate coordinate) { this.coordinate = coordinate; return this; } + /** + * Sets location id + * + * @param id + * @return + */ public Builder setId(String id) { this.id = id; return this; } + /** + * Adds name, e.g. street name, to location + * + * @param name + * @return + */ public Builder setName(String name){ this.name = name; return this;