Package ons
Class Batch
java.lang.Object
ons.Batch
public class Batch
extends java.lang.Object
-
Method Summary
Modifier and Type Method Description int[]getAllDataAmounts()doublegetArrivalTime()java.util.ArrayList<BulkData>getBulks()intgetCOS()intgetDataAmount(int bulkIndex)double[]getDeadlines()doublegetDeadlineTime()doublegetDepartureTime()intgetDestination()Retrieves the destination Batch.longgetID()Retrieves the unique identifier for a given Batch.long[]getIds()Retrieves the array of the unique identifiers of BulkDatas into Batch.intgetIndex(BulkData bulk)Retorna o indice relativo ao bulk do batchintgetMaxDataAmount()doublegetMaxDeadline()doublegetMaxDeparture(int[] rate)intgetMinDataAmount()doublegetMinDeadline()doublegetMinDeparture(int[] rate)doublegetServedTime()intgetSize()Retrives the size of Batch or amount of flow inside one.int[]getSources()Retrieves the all sorces.intgetSumDataAmounts()protected voidsetDepartureTime(double departureTime, int[] rate, double currentTime)protected voidsetServedTime(double servedTime)java.lang.StringtoString()java.lang.StringtoTrace()Prints all information related to the arriving Batch.
-
Method Details
-
getID
public long getID()Retrieves the unique identifier for a given Batch.- Returns:
- the value of the Batch's id attribute
-
getIds
public long[] getIds()Retrieves the array of the unique identifiers of BulkDatas into Batch.- Returns:
- the value's array of the BulkData's id attribute
-
getAllDataAmounts
public int[] getAllDataAmounts() -
getDataAmount
public int getDataAmount(int bulkIndex) -
getSumDataAmounts
public int getSumDataAmounts() -
getSources
public int[] getSources()Retrieves the all sorces.- Returns:
- the sorces's array of BulkData's calls
-
getDestination
public int getDestination()Retrieves the destination Batch.- Returns:
- the destination of BulkData's calls
-
getDeadlines
public double[] getDeadlines() -
getBulks
-
getCOS
public int getCOS() -
getSize
public int getSize()Retrives the size of Batch or amount of flow inside one.- Returns:
- the size of BatchArrivalEvent's Batch attribute
-
toTrace
public java.lang.String toTrace()Prints all information related to the arriving Batch.- Returns:
- string containing all the values of the batch's parameters
-
toString
public java.lang.String toString()- Overrides:
toStringin classjava.lang.Object
-
getIndex
Retorna o indice relativo ao bulk do batch- Parameters:
bulk-- Returns:
-
getMaxDataAmount
public int getMaxDataAmount() -
getMinDataAmount
public int getMinDataAmount() -
getMinDeadline
public double getMinDeadline() -
getMaxDeadline
public double getMaxDeadline() -
getDeadlineTime
public double getDeadlineTime() -
getArrivalTime
public double getArrivalTime() -
getServedTime
public double getServedTime() -
setServedTime
protected void setServedTime(double servedTime) -
getDepartureTime
public double getDepartureTime() -
setDepartureTime
protected void setDepartureTime(double departureTime, int[] rate, double currentTime) -
getMaxDeparture
public double getMaxDeparture(int[] rate) -
getMinDeparture
public double getMinDeparture(int[] rate)
-