|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--haifa.shopsim.GeneralShopDataArray
An implementation of a general shopData using arrays.
| Field Summary | |
private int |
I
Number of machines |
private int[] |
jobRoutes
The length of this array is numJobTypes. |
private int[] |
numJobs
The length of this array is numJobTypes, each element determines how many jobs are from each type. |
private int |
numJobTypes
The different number of jobs types in the job shop |
private int[][] |
routes
Array of routes, each route being an array of operations |
private double[][] |
stepDurations
This is a ragged array of job durations per each step. |
| Constructor Summary | |
GeneralShopDataArray(java.io.Reader reader)
Read according to file format as specified in example shop.dat |
|
| Method Summary | |
java.util.List |
getCi(int i)
Returns a List of all operation in machine i. |
int |
getI()
Returns number of machines. |
java.lang.String[] |
getJobsOfRoute(int r)
Returns all of of route r. |
java.lang.String[] |
getJobsOfType(int t)
Returns all of the jobs of type t. |
int |
getK()
Returns the total number of steps/classes/buffers (sum of Kr) |
int |
getKr(int r)
Returns number of steps in route r |
int |
getMachine(Operation op)
Returns the machine that performs the following operation. |
int |
getN()
Returns total number of jobs |
int |
getNr(int r)
Returns number of jobs in route r |
int |
getNt(int t)
Returns the number of jobs of type t |
int |
getR()
Returns number of routes. |
java.util.List |
getRoute(int r)
Returns a List of all ShopData.Operation instances in route r |
int |
getRouteOfType(int t)
Returns the route of type t. |
int |
getSizeCi(int i)
Returns the number of operations in machine i. |
int |
getT()
Returns number of job types. |
int |
getTr(int r)
Returns the number of types of jobs that are on route r. |
int[] |
getTypesOfRoute(int r)
Returns an array of type numbers of jobs that are on route r. |
double |
getXto(int t,
int o)
Returns the processing time of job of type t, on step o of it's route. |
boolean |
isIdenticalJobs()
Ask if the shop has identical jobs. |
boolean |
isMostGeneralJobShop()
Ask if the shop is most general, not necessarily proportional nor similar. reply is true. |
boolean |
isProportinalJobs()
Ask if the shop has proportional jobs. |
boolean |
isSingleRoute()
Ask is shop is a jobshop with a single route same as getR()==1 |
static void |
main(java.lang.String[] args)
For testing |
java.lang.String |
toString()
Returns all info regarding jobshop in a displayable string |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
private int I
private int[][] routes
private int numJobTypes
private int[] numJobs
private int[] jobRoutes
private double[][] stepDurations
| Constructor Detail |
public GeneralShopDataArray(java.io.Reader reader)
throws JobShopFileFormatException,
java.io.IOException
| Method Detail |
public int getI()
getI in interface ShopDatapublic int getR()
getR in interface ShopDatapublic int getN()
getN in interface ShopDatapublic int getT()
getT in interface ShopDatapublic int getK()
getK in interface ShopDatapublic int getNt(int t)
getNt in interface ShopDatapublic int getTr(int r)
getTr in interface ShopDatapublic int[] getTypesOfRoute(int r)
getTypesOfRoute in interface ShopDatapublic java.lang.String[] getJobsOfType(int t)
getJobsOfType in interface ShopDatapublic java.lang.String[] getJobsOfRoute(int r)
ShopDatagetJobsOfRoute in interface ShopData
public double getXto(int t,
int o)
getXto in interface ShopDatapublic int getRouteOfType(int t)
getRouteOfType in interface ShopDatapublic int getKr(int r)
ShopDatagetKr in interface ShopDatapublic int getMachine(Operation op)
ShopDatagetMachine in interface ShopDatapublic int getNr(int r)
ShopDatagetNr in interface ShopDatapublic java.util.List getCi(int i)
getCi in interface ShopDatapublic int getSizeCi(int i)
getSizeCi in interface ShopDatapublic java.util.List getRoute(int r)
getRoute in interface ShopDatapublic boolean isSingleRoute()
isSingleRoute in interface ShopDatapublic boolean isIdenticalJobs()
isIdenticalJobs in interface ShopDatapublic boolean isProportinalJobs()
isProportinalJobs in interface ShopDatapublic boolean isMostGeneralJobShop()
isMostGeneralJobShop in interface ShopDatapublic java.lang.String toString()
toString in class java.lang.Object
public static void main(java.lang.String[] args)
throws java.lang.Exception
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||