public class DemandData
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private boolean[] |
activeDays
Array indicating which day types are active.
|
private boolean[] |
activeMonths
Array indicating which months are active in the Reliability Reporting
Period.
|
private float[][] |
demands
2D Array holding demand multipliers for each demand combination (month -
day of week).
|
private int |
endDay
Ending day of the ending month of the Reliability Reporting Period.
|
private int |
endMonth
Ending month of the Reliability Reporting Period.
|
private float[][] |
i40DefaultValues |
private float[][] |
ruralDefaultValues |
private Seed |
seed
Seed instance for the Reliability Analysis.
|
private int |
startDay
Starting day of the starting month Reliability Reporting Period.
|
private int |
startMonth
Starting month of the Reliability Reporting Period.
|
private int |
type
Type indicating whether the instance is associated with General Purpose
(GP) demand or Managed Lane (ML) demand.
|
static int |
TYPE_GP
Identifier for General Purpose (GP) type.
|
static int |
TYPE_ML
Identifier for Managed Lane (ML) type.
|
private float[][] |
urbanDefaultValues |
private int |
year
Year of the Reliability Reporting Period.
|
Constructor and Description |
---|
DemandData(int type)
Constructor for empty DemandData instance.
|
DemandData(int year,
int startMonth,
int startDay,
int endMonth,
int endDay,
int type)
Constructor specifying the Reliability Reporting Period.
|
DemandData(Seed seed,
int type)
Constructor that pulls any existing demand data from the seed.
|
Modifier and Type | Method and Description |
---|---|
boolean[] |
getActiveDays() |
int |
getActiveDaysCount()
Returns the number of active days
|
boolean[] |
getActiveMonths() |
boolean |
getDayActive(int day) |
CEDate |
getEndDate()
Returns a CEDate instance of the Reliability Reporting Period end date.
|
int |
getEndDay() |
int |
getEndMonth() |
float |
getMaxValue() |
float |
getMinValue() |
boolean |
getMonthActive(int month) |
Seed |
getSeed()
Returns the seed associated with the demand data instance
|
float |
getSeedTotalVMT() |
float[][] |
getSpecifiedDemand() |
CEDate |
getStartDate()
Returns a CEDate instance of the Reliability Reporting Period start date.
|
int |
getStartDay() |
int |
getStartMonth() |
float |
getValue(int month,
int day) |
int |
getYear() |
void |
setDayActive(int day,
boolean active)
Set whether a specified day is active for a reliability analysis.
|
void |
setEndDay(int day) |
void |
setEndMonth(int month) |
void |
setMonthActive(int month,
boolean active) |
void |
setStartDay(int day) |
void |
setStartMonth(int month) |
void |
setValue(int month,
int day,
float val) |
void |
setYear(int year) |
void |
useAllDays() |
void |
useAllMonths() |
void |
useFacilitySpecificDefaults() |
void |
useI40Defaults() |
void |
useRuralDefaults() |
void |
useSeedValues() |
void |
useUrbanDefaults() |
void |
useWeekDays() |
private final float[][] demands
private final boolean[] activeDays
private final boolean[] activeMonths
private int year
private int startMonth
private int startDay
private int endMonth
private int endDay
private Seed seed
private final int type
public static final int TYPE_GP
public static final int TYPE_ML
private final float[][] urbanDefaultValues
private final float[][] ruralDefaultValues
private final float[][] i40DefaultValues
public DemandData(int type)
type
- Indicates GP or ML type.public DemandData(int year, int startMonth, int startDay, int endMonth, int endDay, int type)
year
- startMonth
- startDay
- endMonth
- endDay
- type
- public DemandData(Seed seed, int type)
seed
- type
- - Designates whether the object is for general purpose (GP)
segments or for managed lane (ML) segments.public int getYear()
public int getStartMonth()
public int getStartDay()
public CEDate getStartDate()
public int getEndMonth()
public int getEndDay()
public CEDate getEndDate()
public boolean[] getActiveDays()
public int getActiveDaysCount()
public boolean[] getActiveMonths()
public boolean getDayActive(int day)
day
- public float getMaxValue()
public float getMinValue()
public boolean getMonthActive(int month)
month
- public float getValue(int month, int day)
month
- day
- public float[][] getSpecifiedDemand()
public float getSeedTotalVMT()
public Seed getSeed()
public void setStartMonth(int month)
month
- public void setStartDay(int day)
day
- public void setEndMonth(int month)
month
- public void setEndDay(int day)
day
- public void setYear(int year)
year
- public void setDayActive(int day, boolean active)
day
- active
- public void setMonthActive(int month, boolean active)
month
- active
- public void setValue(int month, int day, float val)
month
- day
- val
- public void useUrbanDefaults()
public void useI40Defaults()
public void useRuralDefaults()
public void useFacilitySpecificDefaults()
public void useSeedValues()
public final void useAllDays()
public final void useWeekDays()
public final void useAllMonths()