public class SLRouteServiceCache
extends java.lang.Object
Constructor and Description |
---|
SLRouteServiceCache(java.lang.String currentProjectId) |
Modifier and Type | Method and Description |
---|---|
void |
addResourceRow(java.lang.String name,
java.lang.String id,
java.lang.String parentid,
java.lang.String objectname,
java.lang.String refobjname,
java.lang.String objectid)
adds a row to the skdresource hashmap
|
void |
clearResourceHier()
clears the resource hierarchy caches
|
java.util.HashMap<java.lang.String,java.util.ArrayList> |
getCalendarBreaks()
returns the calendar breaks
|
java.util.HashMap<java.lang.String,java.lang.Integer> |
getDaysInShiftPattern()
returns the days in shift pattern
|
java.util.ArrayList<java.util.Date> |
getMergedWorkPeriods()
returns the merged work periods
|
com.ibm.tivoli.maximo.slroute.SLRouteServiceCache.SKDResource |
getObjKeyedResourceHier(java.lang.String refobjname,
java.lang.String objectid)
return the resource row given by refobjectname and objectid
|
java.lang.String |
getOrgId()
returns the orgid for the current project
|
java.lang.String |
getProjectName()
returns the project name (name column from skdproject)
|
java.util.HashMap<java.lang.String,com.ibm.tivoli.maximo.slroute.SLRouteServiceCache.SKDResource> |
getResourceHier()
simple getter for the resourcehierarchy
|
java.util.HashMap<java.lang.String,SKDCalendarInfo> |
getShiftCalMap()
return the shift calendar map
|
java.util.HashMap<java.lang.Long,com.ibm.tivoli.maximo.slroute.SLRouteService.ShiftInformation> |
getShiftInfo(java.lang.String shift)
returns a deep copy of the shift information from the cache, if the shift information is present
|
com.ibm.tivoli.maximo.slroute.SLRouteServiceCache.SKDResource |
getSKDResourceInstance(java.lang.String name,
java.lang.String id,
java.lang.String parentid,
java.lang.String objectname,
java.lang.String refobjname,
java.lang.String objectid)
Factories out an instance of a new SKDResource; the class is not added to the cache
|
java.lang.String |
getWorkQuery()
gets the work query string
|
boolean |
hasShiftGridInfo()
return true if we have cached shift grid information
|
boolean |
isUIDebug()
returns if we are running with the UI in debug mode
|
void |
putShiftInfo(java.lang.String shift,
java.util.HashMap<java.lang.Long,com.ibm.tivoli.maximo.slroute.SLRouteService.ShiftInformation> baseModShifts)
add the shift information hashmap for the given shift to the shift data cache
|
void |
setShiftGridInfo(java.util.HashMap<java.lang.String,SKDCalendarInfo> shiftCalMap,
java.util.HashMap<java.lang.String,java.util.ArrayList> calendarBreaks,
java.util.HashMap<java.lang.String,java.lang.Integer> daysInShiftPattern,
java.util.ArrayList<java.util.Date> mergedWorkPeriods)
Sets all of the shift background information (used by FWMShiftWorkingHourGrid) as a group
|
void |
setUIDebug(boolean isUIDebug)
set the UI debug flag
|
void |
setWorkQuery(java.lang.String workQuery)
sets the work query string
|
void |
updateResourceMaps()
updates the parent row and the refreshes the object keyed hashmap
|
void |
verifyProject(java.lang.String id,
java.lang.String calendar,
java.lang.String shift,
java.util.Date startDate,
java.util.Date endDate,
java.lang.String projectName,
java.lang.String orgId)
Verifies the project including the id, calendar, shift, and start and end dates
If anything has changed, then clear the cached information.
|
public SLRouteServiceCache(java.lang.String currentProjectId)
public void verifyProject(java.lang.String id, java.lang.String calendar, java.lang.String shift, java.util.Date startDate, java.util.Date endDate, java.lang.String projectName, java.lang.String orgId)
id
- public void putShiftInfo(java.lang.String shift, java.util.HashMap<java.lang.Long,com.ibm.tivoli.maximo.slroute.SLRouteService.ShiftInformation> baseModShifts)
org
- calendar
- shift
- baseModShifts
- public java.util.HashMap<java.lang.Long,com.ibm.tivoli.maximo.slroute.SLRouteService.ShiftInformation> getShiftInfo(java.lang.String shift)
org
- calendar
- shift
- public java.util.HashMap<java.lang.String,SKDCalendarInfo> getShiftCalMap()
public java.util.HashMap<java.lang.String,java.util.ArrayList> getCalendarBreaks()
public java.util.HashMap<java.lang.String,java.lang.Integer> getDaysInShiftPattern()
public java.util.ArrayList<java.util.Date> getMergedWorkPeriods()
public void setShiftGridInfo(java.util.HashMap<java.lang.String,SKDCalendarInfo> shiftCalMap, java.util.HashMap<java.lang.String,java.util.ArrayList> calendarBreaks, java.util.HashMap<java.lang.String,java.lang.Integer> daysInShiftPattern, java.util.ArrayList<java.util.Date> mergedWorkPeriods)
shiftCalMap
- calendarBreaks
- daysInShiftPattern
- mergedWorkPeriods
- public boolean hasShiftGridInfo()
public void addResourceRow(java.lang.String name, java.lang.String id, java.lang.String parentid, java.lang.String objectname, java.lang.String refobjname, java.lang.String objectid)
name
- id
- parentid
- objectname
- refobjname
- objectid
- public void updateResourceMaps()
public java.util.HashMap<java.lang.String,com.ibm.tivoli.maximo.slroute.SLRouteServiceCache.SKDResource> getResourceHier()
public com.ibm.tivoli.maximo.slroute.SLRouteServiceCache.SKDResource getObjKeyedResourceHier(java.lang.String refobjname, java.lang.String objectid)
refobjname
- objectid
- public void clearResourceHier()
public boolean isUIDebug()
public void setUIDebug(boolean isUIDebug)
isUIDebug
- public java.lang.String getWorkQuery()
public void setWorkQuery(java.lang.String workQuery)
public java.lang.String getProjectName()
public java.lang.String getOrgId()
public com.ibm.tivoli.maximo.slroute.SLRouteServiceCache.SKDResource getSKDResourceInstance(java.lang.String name, java.lang.String id, java.lang.String parentid, java.lang.String objectname, java.lang.String refobjname, java.lang.String objectid)
name
- id
- parentid
- objectname
- refobjname
- objectid
-