Skip to content

Commit

Permalink
add javadoc (feature #127)
Browse files Browse the repository at this point in the history
  • Loading branch information
oblonski committed Sep 4, 2014
1 parent d80f6bc commit b4e5ce8
Showing 1 changed file with 43 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@
*/
public class JobInsertionContext {

/**
* Provides insertion context information about a particular activity.
*/
public static class ActivityContext {

private double arrivalTime;
Expand All @@ -39,26 +42,66 @@ public static class ActivityContext {

private int insertionIndex;

/**
* Returns arrival time at associated activity.
*
* @return arrival time
*/
public double getArrivalTime() {
return arrivalTime;
}

/**
* Returns end time of associated activity.
*
* @return end time
*/
public double getEndTime() {
return endTime;
}

/**
* Returns the insertion index of the associated vehicle.
*
* <p>The associated activity is not inserted yet. The actual insertion position is still to be evaluated.
* Thus this insertion index is related to the potential insertion index which is the position before
* the activity at this index in the existing route.
*
* if insertionIndex == 0, the associated activity will be inserted between start of vehicle and the first
* activity in activity sequence.
*
* if insertionIndex == relatedRoute.getActivities().size(), the associated activity will be inserted between
* the last activity in the activity sequence and the end of vehicle.
*
* @return insertion index
*/
public int getInsertionIndex() {
return insertionIndex;
}

/**
* Sets arrivalTime of associated vehicle at activity.
*
* @param arrivalTime arrival time of associated vehicle at activity
*/
public void setArrivalTime(double arrivalTime) {
this.arrivalTime = arrivalTime;
}

/**
* Sets end time of associated activity.
*
* @param endTime end time
*/
public void setEndTime(double endTime) {
this.endTime = endTime;
}

/**
* Sets insertion index of associated activity.
*
* @param insertionIndex insertion index of associated activity
*/
public void setInsertionIndex(int insertionIndex) {
this.insertionIndex = insertionIndex;
}
Expand Down

0 comments on commit b4e5ce8

Please sign in to comment.