public class Workpackage extends VdmEntity<Workpackage>
Original entity name from the Odata EDM: Workpackage
Modifier and Type | Class and Description |
---|---|
static class |
Workpackage.WorkpackageBuilder
Helper class to allow for fluent creation of Workpackage instances.
|
Modifier and Type | Field and Description |
---|---|
static WorkpackageSelectable |
ALL_FIELDS
Selector for all available fields of Workpackage.
|
static WorkpackageField<String> |
CHANGED_BY
Use with available fluent helpers to apply the ChangedBy field to query operations.
|
static WorkpackageField<ZonedDateTime> |
CHANGED_ON
Use with available fluent helpers to apply the ChangedOn field to query operations.
|
static WorkpackageField<String> |
PROJECT_ID
Use with available fluent helpers to apply the ProjectID field to query operations.
|
static WorkpackageField<String> |
PROJECT_NAME
Use with available fluent helpers to apply the ProjectName field to query operations.
|
static WorkpackageField<String> |
QUANTITY
Use with available fluent helpers to apply the Quantity field to query operations.
|
static WorkpackageLink<PlanData> |
TO_PLAN_DATA_SET
Use with available fluent helpers to apply the PlanDataSet navigation property to query operations.
|
static WorkpackageLink<WorkItem> |
TO_WORK_ITEM_SET
Use with available fluent helpers to apply the WorkItemSet navigation property to query operations.
|
static WorkpackageField<String> |
UNIT_OF_MEASURE
Use with available fluent helpers to apply the UnitOfMeasure field to query operations.
|
static WorkpackageField<String> |
WORK_PACKAGE_ID
Use with available fluent helpers to apply the WorkPackageID field to query operations.
|
static WorkpackageField<String> |
WORK_PACKAGE_NAME
Use with available fluent helpers to apply the WorkPackageName field to query operations.
|
static WorkpackageField<String> |
WORK_PACKAGE_TYPE
Use with available fluent helpers to apply the WorkPackageType field to query operations.
|
static WorkpackageField<String> |
WORK_PACKAGE_UNIT_TEXT
Use with available fluent helpers to apply the WorkPackageUnitText field to query operations.
|
static WorkpackageField<LocalDateTime> |
WP_END_DATE
Use with available fluent helpers to apply the WPEndDate field to query operations.
|
static WorkpackageField<LocalDateTime> |
WP_START_DATE
Use with available fluent helpers to apply the WPStartDate field to query operations.
|
changedOriginalFields
Constructor and Description |
---|
Workpackage() |
Workpackage(String workPackageUnitText,
String workPackageType,
String unitOfMeasure,
String quantity,
ZonedDateTime changedOn,
String projectID,
String changedBy,
String workPackageID,
String workPackageName,
LocalDateTime wPStartDate,
LocalDateTime wPEndDate,
String projectName,
List<WorkItem> toWorkItemSet,
List<PlanData> toPlanDataSet) |
Modifier and Type | Method and Description |
---|---|
void |
addPlanDataSet(PlanData... entity)
Adds elements to the list of associated PlanData entities.
|
void |
addWorkItemSet(WorkItem... entity)
Adds elements to the list of associated WorkItem entities.
|
void |
attachToService(String servicePath,
HttpDestinationProperties destination)
Sets the service path and destination for the fetch commands of this entity.
|
static Workpackage.WorkpackageBuilder |
builder() |
protected boolean |
canEqual(Object other) |
boolean |
equals(Object o) |
List<PlanData> |
fetchPlanDataSet()
Fetches the PlanData entities (one to many) associated with this entity.
|
List<WorkItem> |
fetchWorkItemSet()
Fetches the WorkItem entities (one to many) associated with this entity.
|
static <T> WorkpackageField<T> |
field(String fieldName,
Class<T> fieldType)
Use with available fluent helpers to apply an extension field to query operations.
|
static <T,DomainT> |
field(String fieldName,
TypeConverter<T,DomainT> typeConverter)
Use with available fluent helpers to apply an extension field to query operations.
|
protected void |
fromMap(Map<String,Object> inputValues) |
String |
getChangedBy()
Constraints: Not nullable, Maximum length: 12
|
ZonedDateTime |
getChangedOn()
Constraints: Not nullable, Precision: 7
|
protected String |
getDefaultServicePath() |
HttpDestinationProperties |
getDestinationForFetch()
Convienence field for reusing the same destination with multiple queries (e.g.
|
protected String |
getEntityCollection() |
protected Map<String,Object> |
getKey() |
io.vavr.control.Option<List<PlanData>> |
getPlanDataSetIfPresent()
Retrieval of associated PlanData entities (one to many).
|
List<PlanData> |
getPlanDataSetOrFetch()
Retrieval of associated PlanData entities (one to many).
|
String |
getProjectID()
Constraints: Not nullable, Maximum length: 40
|
String |
getProjectName()
Constraints: Not nullable, Maximum length: 40
|
String |
getQuantity()
Constraints: Not nullable, Maximum length: 15
|
Class<Workpackage> |
getType() |
String |
getUnitOfMeasure()
Constraints: Not nullable, Maximum length: 30
|
io.vavr.control.Option<List<WorkItem>> |
getWorkItemSetIfPresent()
Retrieval of associated WorkItem entities (one to many).
|
List<WorkItem> |
getWorkItemSetOrFetch()
Retrieval of associated WorkItem entities (one to many).
|
String |
getWorkPackageID()
(Key Field) Constraints: Not nullable, Maximum length: 50
|
String |
getWorkPackageName()
Constraints: Not nullable, Maximum length: 60
|
String |
getWorkPackageType()
Constraints: Not nullable, Maximum length: 1
|
String |
getWorkPackageUnitText()
Constraints: Not nullable, Maximum length: 40
|
LocalDateTime |
getWPEndDate()
Constraints: Not nullable, Precision: 7
|
LocalDateTime |
getWPStartDate()
Constraints: Not nullable, Precision: 7
|
int |
hashCode() |
void |
setChangedBy(String changedBy)
Constraints: Not nullable, Maximum length: 12
|
void |
setChangedOn(ZonedDateTime changedOn)
Constraints: Not nullable, Precision: 7
|
void |
setPlanDataSet(List<PlanData> value)
Overwrites the list of associated PlanData entities for the loaded navigation property PlanDataSet.
|
void |
setProjectID(String projectID)
Constraints: Not nullable, Maximum length: 40
|
void |
setProjectName(String projectName)
Constraints: Not nullable, Maximum length: 40
|
void |
setQuantity(String quantity)
Constraints: Not nullable, Maximum length: 15
|
protected void |
setServicePathForFetch(String servicePathForFetch)
The service path only used for the fetch commands of this entity.
|
void |
setUnitOfMeasure(String unitOfMeasure)
Constraints: Not nullable, Maximum length: 30
|
void |
setWorkItemSet(List<WorkItem> value)
Overwrites the list of associated WorkItem entities for the loaded navigation property WorkItemSet.
|
void |
setWorkPackageID(String workPackageID)
(Key Field) Constraints: Not nullable, Maximum length: 50
|
void |
setWorkPackageName(String workPackageName)
Constraints: Not nullable, Maximum length: 60
|
void |
setWorkPackageType(String workPackageType)
Constraints: Not nullable, Maximum length: 1
|
void |
setWorkPackageUnitText(String workPackageUnitText)
Constraints: Not nullable, Maximum length: 40
|
void |
setWPEndDate(LocalDateTime wPEndDate)
Constraints: Not nullable, Precision: 7
|
void |
setWPStartDate(LocalDateTime wPStartDate)
Constraints: Not nullable, Precision: 7
|
protected Map<String,Object> |
toMapOfFields() |
protected Map<String,Object> |
toMapOfNavigationProperties() |
String |
toString() |
getServicePathForFetch, getVersionIdentifier, setDestinationForFetch, setVersionIdentifier
getChangedFields, getCustomField, getCustomField, getCustomFieldNames, getCustomFields, getSetOfCustomFields, getSetOfFields, getSetOfNavigationProperties, hasCustomField, hasCustomField, rememberChangedField, resetChangedFields, setCustomField, setCustomField, toMap, toMapOfCustomFields
public static final WorkpackageSelectable ALL_FIELDS
public static final WorkpackageField<String> WORK_PACKAGE_UNIT_TEXT
public static final WorkpackageField<String> WORK_PACKAGE_TYPE
public static final WorkpackageField<String> UNIT_OF_MEASURE
public static final WorkpackageField<String> QUANTITY
public static final WorkpackageField<ZonedDateTime> CHANGED_ON
public static final WorkpackageField<String> PROJECT_ID
public static final WorkpackageField<String> CHANGED_BY
public static final WorkpackageField<String> WORK_PACKAGE_ID
public static final WorkpackageField<String> WORK_PACKAGE_NAME
public static final WorkpackageField<LocalDateTime> WP_START_DATE
public static final WorkpackageField<LocalDateTime> WP_END_DATE
public static final WorkpackageField<String> PROJECT_NAME
public static final WorkpackageLink<WorkItem> TO_WORK_ITEM_SET
public static final WorkpackageLink<PlanData> TO_PLAN_DATA_SET
public Workpackage()
public Workpackage(@Nullable String workPackageUnitText, @Nullable String workPackageType, @Nullable String unitOfMeasure, @Nullable String quantity, @Nullable ZonedDateTime changedOn, @Nullable String projectID, @Nullable String changedBy, @Nullable String workPackageID, @Nullable String workPackageName, @Nullable LocalDateTime wPStartDate, @Nullable LocalDateTime wPEndDate, @Nullable String projectName, List<WorkItem> toWorkItemSet, List<PlanData> toPlanDataSet)
@Nonnull public Class<Workpackage> getType()
getType
in class VdmObject<Workpackage>
public void setWorkPackageUnitText(@Nullable String workPackageUnitText)
Original property name from the Odata EDM: WorkPackageUnitText
workPackageUnitText
- Resource Descriptionpublic void setWorkPackageType(@Nullable String workPackageType)
Original property name from the Odata EDM: WorkPackageType
You can use the following values to indicate the type of service planned in the work package:' ' - Time based servicesU - Unit based services
workPackageType
- Indicates the type of service planned in a work package.public void setUnitOfMeasure(@Nullable String unitOfMeasure)
Original property name from the Odata EDM: UnitOfMeasure
unitOfMeasure
- Name of unit of measurement.public void setQuantity(@Nullable String quantity)
Original property name from the Odata EDM: Quantity
quantity
- Total quantity per period.public void setChangedOn(@Nullable ZonedDateTime changedOn)
Original property name from the Odata EDM: ChangedOn
changedOn
- Draft Last Changed Onpublic void setProjectID(@Nullable String projectID)
Original property name from the Odata EDM: ProjectID
projectID
- Identifies a master project.public void setChangedBy(@Nullable String changedBy)
Original property name from the Odata EDM: ChangedBy
changedBy
- Changed Bypublic void setWorkPackageID(@Nullable String workPackageID)
Original property name from the Odata EDM: WorkPackageID
workPackageID
- Plan Itempublic void setWorkPackageName(@Nullable String workPackageName)
Original property name from the Odata EDM: WorkPackageName
workPackageName
- Plan Item Descriptionpublic void setWPStartDate(@Nullable LocalDateTime wPStartDate)
Original property name from the Odata EDM: WPStartDate
Provides the planning horizon. By default, the dates are taken from the assigned master project.
wPStartDate
- Raw Textpublic void setWPEndDate(@Nullable LocalDateTime wPEndDate)
Original property name from the Odata EDM: WPEndDate
Provides the planning horizon. By default, the dates are taken from the assigned master project.
wPEndDate
- Raw Textpublic void setProjectName(@Nullable String projectName)
Original property name from the Odata EDM: ProjectName
projectName
- Customer Project Nameprotected String getEntityCollection()
getEntityCollection
in class VdmEntity<Workpackage>
@Nonnull protected Map<String,Object> getKey()
getKey
in class VdmObject<Workpackage>
@Nonnull protected Map<String,Object> toMapOfFields()
toMapOfFields
in class VdmObject<Workpackage>
protected void fromMap(Map<String,Object> inputValues)
fromMap
in class VdmObject<Workpackage>
@Nonnull public static <T> WorkpackageField<T> field(@Nonnull String fieldName, @Nonnull Class<T> fieldType)
T
- The type of the extension field when performing value comparisons.fieldName
- The name of the extension field as returned by the OData service.fieldType
- The Java type to use for the extension field when performing value comparisons.@Nonnull public static <T,DomainT> WorkpackageField<T> field(@Nonnull String fieldName, @Nonnull TypeConverter<T,DomainT> typeConverter)
T
- The type of the extension field when performing value comparisons.DomainT
- The type of the extension field as returned by the OData service.typeConverter
- A TypeConverterfieldName
- The name of the extension field as returned by the OData service.@Nullable public HttpDestinationProperties getDestinationForFetch()
VdmEntity
getDestinationForFetch
in class VdmEntity<Workpackage>
protected void setServicePathForFetch(@Nullable String servicePathForFetch)
VdmEntity
Note: Use with caution, as this can easily break the fetch call on this entity. See the interface of the corresponding service for the default service path.
setServicePathForFetch
in class VdmEntity<Workpackage>
public void attachToService(@Nullable String servicePath, @Nonnull HttpDestinationProperties destination)
VdmEntity
Note: Use with caution, as this can easily break the fetch calls on this entity. See the interface of the corresponding service for the default service path.
attachToService
in class VdmEntity<Workpackage>
servicePath
- Optional parameter. New service path to apply to this entity and any associated entities that were
previously fetched. If a null value is provided and the service path has never been set, then the
service path will be set to the default defined in the corresponding service interface.destination
- New destination to apply to this entity and any associated entities that were previously fetched.protected String getDefaultServicePath()
getDefaultServicePath
in class VdmEntity<Workpackage>
@Nonnull protected Map<String,Object> toMapOfNavigationProperties()
toMapOfNavigationProperties
in class VdmObject<Workpackage>
@Nonnull public List<WorkItem> fetchWorkItemSet() throws com.sap.cloud.sdk.odatav2.connectivity.ODataException
Please note: This method will not cache or persist the query results.
com.sap.cloud.sdk.odatav2.connectivity.ODataException
- If the entity is unmanaged, i.e. it has not been retrieved using the OData VDM's services and
therefore has no ERP configuration context assigned. An entity is managed if it has been either
retrieved using the VDM's services or returned from the VDM's services as the result of a CREATE or
UPDATE call.@Nonnull public List<WorkItem> getWorkItemSetOrFetch() throws com.sap.cloud.sdk.odatav2.connectivity.ODataException
If the navigation property WorkItemSet of a queried Workpackage is operated lazily, an ODataException can be thrown in case of an OData query error.
Please note: Lazy loading of OData entity associations is the process of asynchronous retrieval and persisting of items from a navigation property. If a lazy property is requested by the application for the first time and it has not yet been loaded, an OData query will be run in order to load the missing information and its result will get cached for future invocations.
com.sap.cloud.sdk.odatav2.connectivity.ODataException
- If the entity is unmanaged, i.e. it has not been retrieved using the OData VDM's services and
therefore has no ERP configuration context assigned. An entity is managed if it has been either
retrieved using the VDM's services or returned from the VDM's services as the result of a CREATE or
UPDATE call.@Nonnull public io.vavr.control.Option<List<WorkItem>> getWorkItemSetIfPresent()
If the navigation property for an entity Workpackage has not been resolved yet, this method will not
query further information. Instead its Option
result state will be empty
.
Option
with result state empty
is
returned.public void setWorkItemSet(@Nonnull List<WorkItem> value)
If the navigation property WorkItemSet of a queried Workpackage is operated lazily, an ODataException can be thrown in case of an OData query error.
Please note: Lazy loading of OData entity associations is the process of asynchronous retrieval and persisting of items from a navigation property. If a lazy property is requested by the application for the first time and it has not yet been loaded, an OData query will be run in order to load the missing information and its result will get cached for future invocations.
value
- List of WorkItem entities.public void addWorkItemSet(WorkItem... entity)
If the navigation property WorkItemSet of a queried Workpackage is operated lazily, an ODataException can be thrown in case of an OData query error.
Please note: Lazy loading of OData entity associations is the process of asynchronous retrieval and persisting of items from a navigation property. If a lazy property is requested by the application for the first time and it has not yet been loaded, an OData query will be run in order to load the missing information and its result will get cached for future invocations.
entity
- Array of WorkItem entities.@Nonnull public List<PlanData> fetchPlanDataSet() throws com.sap.cloud.sdk.odatav2.connectivity.ODataException
Please note: This method will not cache or persist the query results.
com.sap.cloud.sdk.odatav2.connectivity.ODataException
- If the entity is unmanaged, i.e. it has not been retrieved using the OData VDM's services and
therefore has no ERP configuration context assigned. An entity is managed if it has been either
retrieved using the VDM's services or returned from the VDM's services as the result of a CREATE or
UPDATE call.@Nonnull public List<PlanData> getPlanDataSetOrFetch() throws com.sap.cloud.sdk.odatav2.connectivity.ODataException
If the navigation property PlanDataSet of a queried Workpackage is operated lazily, an ODataException can be thrown in case of an OData query error.
Please note: Lazy loading of OData entity associations is the process of asynchronous retrieval and persisting of items from a navigation property. If a lazy property is requested by the application for the first time and it has not yet been loaded, an OData query will be run in order to load the missing information and its result will get cached for future invocations.
com.sap.cloud.sdk.odatav2.connectivity.ODataException
- If the entity is unmanaged, i.e. it has not been retrieved using the OData VDM's services and
therefore has no ERP configuration context assigned. An entity is managed if it has been either
retrieved using the VDM's services or returned from the VDM's services as the result of a CREATE or
UPDATE call.@Nonnull public io.vavr.control.Option<List<PlanData>> getPlanDataSetIfPresent()
If the navigation property for an entity Workpackage has not been resolved yet, this method will not
query further information. Instead its Option
result state will be empty
.
Option
with result state empty
is
returned.public void setPlanDataSet(@Nonnull List<PlanData> value)
If the navigation property PlanDataSet of a queried Workpackage is operated lazily, an ODataException can be thrown in case of an OData query error.
Please note: Lazy loading of OData entity associations is the process of asynchronous retrieval and persisting of items from a navigation property. If a lazy property is requested by the application for the first time and it has not yet been loaded, an OData query will be run in order to load the missing information and its result will get cached for future invocations.
value
- List of PlanData entities.public void addPlanDataSet(PlanData... entity)
If the navigation property PlanDataSet of a queried Workpackage is operated lazily, an ODataException can be thrown in case of an OData query error.
Please note: Lazy loading of OData entity associations is the process of asynchronous retrieval and persisting of items from a navigation property. If a lazy property is requested by the application for the first time and it has not yet been loaded, an OData query will be run in order to load the missing information and its result will get cached for future invocations.
entity
- Array of PlanData entities.public static Workpackage.WorkpackageBuilder builder()
@Nullable public String getWorkPackageUnitText()
Original property name from the Odata EDM: WorkPackageUnitText
@Nullable public String getWorkPackageType()
Original property name from the Odata EDM: WorkPackageType
You can use the following values to indicate the type of service planned in the work package:' ' - Time based servicesU - Unit based services
@Nullable public String getUnitOfMeasure()
Original property name from the Odata EDM: UnitOfMeasure
@Nullable public String getQuantity()
Original property name from the Odata EDM: Quantity
@Nullable public ZonedDateTime getChangedOn()
Original property name from the Odata EDM: ChangedOn
@Nullable public String getProjectID()
Original property name from the Odata EDM: ProjectID
@Nullable public String getChangedBy()
Original property name from the Odata EDM: ChangedBy
@Nullable public String getWorkPackageID()
Original property name from the Odata EDM: WorkPackageID
@Nullable public String getWorkPackageName()
Original property name from the Odata EDM: WorkPackageName
@Nullable public LocalDateTime getWPStartDate()
Original property name from the Odata EDM: WPStartDate
Provides the planning horizon. By default, the dates are taken from the assigned master project.
@Nullable public LocalDateTime getWPEndDate()
Original property name from the Odata EDM: WPEndDate
Provides the planning horizon. By default, the dates are taken from the assigned master project.
@Nullable public String getProjectName()
Original property name from the Odata EDM: ProjectName
public String toString()
toString
in class VdmObject<Workpackage>
public boolean equals(Object o)
equals
in class VdmObject<Workpackage>
protected boolean canEqual(Object other)
canEqual
in class VdmObject<Workpackage>
public int hashCode()
hashCode
in class VdmObject<Workpackage>
Copyright © 2019 SAP SE. All rights reserved.