|
Primavera Integration API 7.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.primavera.common.value.spread.BaseSpread
public abstract class BaseSpread
The base class of all main spread classes. You can access spread data for all periods by first obtaining an iterator using the getSpreadIterator method. This iterator allows access to the SpreadPeriod objects that have been loaded with this spread object. For each SpreadPeriod, you can then call the SpreadPeriod.getUnits(), SpreadPeriod.getCumulativeUnits(), SpreadPeriod.getCost(), or SpreadPeriod.getCumulativeCost() methods, passing in the unit or cost field name. To discover the unit or cost field names that have been loaded, use the getUnitFields() and getCostFields() methods.
Method Summary | |
---|---|
void |
clearFinancialValues()
Security implementation: clear all the cost fields with a Double.NaN value. |
void |
ensureSpreadSpansDate(java.util.Date date)
Makes sure that a bucket is available for the given date, and if not, adds a bucket for it. |
java.lang.String[] |
getCostFields()
Gets the cost field names in the spread data. |
int |
getSpreadBucketType()
Gets the bucket type of spread data. |
SpreadBucketType |
getSpreadBucketTypeEnum()
Gets the bucket type of spread data in enum. |
java.util.Date |
getSpreadEnd()
Gets the end date of this batch of spread data. |
java.util.Iterator<SpreadPeriod> |
getSpreadIterator(boolean bIncludeEmptyBuckets)
Creates a spread iterator object through which to access spread data. |
SpreadPeriod |
getSpreadPeriod(java.util.Date date,
boolean bIncludeEmptyBucket)
Finds the spread period by a given date which falls in the bucket start time (inclusive) and end time (exclusive). |
java.util.Date |
getSpreadStart()
Gets the start date of this batch of spread data. |
java.lang.String[] |
getUnitFields()
Gets the unit field names in the spread data. |
boolean |
hasCumulativeData()
Indicates whether cumulative data has been loaded |
int |
size()
Gets the number of buckets in this batch of spread data. |
java.lang.String |
toString()
Returns a string representation on this object |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public boolean hasCumulativeData()
public void clearFinancialValues()
public java.lang.String[] getUnitFields()
public java.lang.String[] getCostFields()
public int size()
public java.util.Iterator<SpreadPeriod> getSpreadIterator(boolean bIncludeEmptyBuckets)
bIncludeEmptyBuckets
- when the bucket the date falls in has no spread data, if true,
return a spread period with 0 values for all period value fields, and previous
cumulative values for all cumulative value fields; if false, skip the empty buckets.
This parameter only applies to summarized spread types (EPSSpread, ProjectSpread,
and WBSSpread) and does not apply to live spreads (ResourceAssignmentSpread).
public SpreadBucketType getSpreadBucketTypeEnum()
public int getSpreadBucketType()
public java.util.Date getSpreadStart()
public java.util.Date getSpreadEnd()
public void ensureSpreadSpansDate(java.util.Date date)
date
- the date you wish to have a bucket representpublic SpreadPeriod getSpreadPeriod(java.util.Date date, boolean bIncludeEmptyBucket) throws SpreadOutOfRangeException
date
- the time when the spread period falls inbIncludeEmptyBucket
- this indicate what will be returned when there is no data in this
period. If true, returned SpreadPeriod will contain 0 for all fields for period
value (the cumulative value will be calculated from the previous bucket); if false,
it will return null.
SpreadOutOfRangeException
- if the date is out of the range of the spread start and endpublic java.lang.String toString()
toString
in class java.lang.Object
|
Primavera Integration API 7.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |