Class Incident
Original entity name from the Odata EDM: Incident
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classHelper class to allow for fluent creation of Incident instances. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final IncidentSelectableSelector for all available fields of Incident.static final IncidentField<UUID>Use with available fluent helpers to apply the EHSLocationUUID field to query operations.static final IncidentField<Boolean>Use with available fluent helpers to apply the FilterByCurrentUser field to query operations.static final IncidentField<String>Use with available fluent helpers to apply the IncidentCategory field to query operations.static final IncidentField<String>Use with available fluent helpers to apply the IncidentDescriptionOfEvents field to query operations.static final IncidentField<String>Use with available fluent helpers to apply the IncidentID field to query operations.static final IncidentField<String>Use with available fluent helpers to apply the IncidentLocationDescription field to query operations.static final IncidentField<String>Use with available fluent helpers to apply the IncidentStatus field to query operations.static final IncidentField<String>Use with available fluent helpers to apply the IncidentTitle field to query operations.static final IncidentField<ZonedDateTime>Use with available fluent helpers to apply the IncidentUTCDateTime field to query operations.static final IncidentField<UUID>Use with available fluent helpers to apply the IncidentUUID field to query operations.static final IncidentLink<Attachment>Use with available fluent helpers to apply the to_Attachments navigation property to query operations.static final IncidentOneToOneLink<Location>Use with available fluent helpers to apply the to_Location navigation property to query operations.static final IncidentLink<Person>Use with available fluent helpers to apply the to_Persons navigation property to query operations.Fields inherited from class com.sap.cloud.sdk.datamodel.odata.helper.VdmObject
changedOriginalFields -
Constructor Summary
ConstructorsConstructorDescriptionIncident()Incident(String incidentID, Boolean filterByCurrentUser, UUID incidentUUID, ZonedDateTime incidentUTCDateTime, String incidentTitle, String incidentStatus, String incidentLocationDescription, String incidentDescriptionOfEvents, String incidentCategory, UUID eHSLocationUUID, Location toLocation, List<Person> toPersons, List<Attachment> toAttachments) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAttachments(Attachment... entity) Adds elements to the list of associated Attachment entities.voidaddPersons(Person... entity) Adds elements to the list of associated Person entities.voidattachToService(String servicePath, HttpDestinationProperties destination) static Incident.IncidentBuilderbuilder()protected booleanbooleanFetches the Attachment entities (one to many) associated with this entity.Fetches the Location entity (one to one) associated with this entity.Fetches the Person entities (one to many) associated with this entity.static <T,DomainT>
IncidentField<T>field(String fieldName, TypeConverter<T, DomainT> typeConverter) Use with available fluent helpers to apply an extension field to query operations.static <T> IncidentField<T>Use with available fluent helpers to apply an extension field to query operations.protected voidio.vavr.control.Option<List<Attachment>>Retrieval of associated Attachment entities (one to many).Retrieval of associated Attachment entities (one to many).protected StringConstraints: noneprotected StringConstraints: noneConstraints: Not nullable, Maximum length: 3Constraints: Not nullable, Maximum length: 999999Constraints: Not nullable, Maximum length: 20Constraints: Not nullable, Maximum length: 80Constraints: Not nullable, Maximum length: 40Constraints: Not nullable, Maximum length: 255Constraints: Not nullable, Precision: 0(Key Field) Constraints: Not nullablegetKey()io.vavr.control.Option<Location>Retrieval of associated Location entity (one to one).Retrieval of associated Location entity (one to one).Retrieval of associated Person entities (one to many).Retrieval of associated Person entities (one to many).getType()inthashCode()voidsetAttachments(List<Attachment> value) Overwrites the list of associated Attachment entities for the loaded navigation property to_Attachments.voidsetEHSLocationUUID(UUID eHSLocationUUID) Constraints: nonevoidsetFilterByCurrentUser(Boolean filterByCurrentUser) Constraints: nonevoidsetIncidentCategory(String incidentCategory) Constraints: Not nullable, Maximum length: 3voidsetIncidentDescriptionOfEvents(String incidentDescriptionOfEvents) Constraints: Not nullable, Maximum length: 999999voidsetIncidentID(String incidentID) Constraints: Not nullable, Maximum length: 20voidsetIncidentLocationDescription(String incidentLocationDescription) Constraints: Not nullable, Maximum length: 80voidsetIncidentStatus(String incidentStatus) Constraints: Not nullable, Maximum length: 40voidsetIncidentTitle(String incidentTitle) Constraints: Not nullable, Maximum length: 255voidsetIncidentUTCDateTime(ZonedDateTime incidentUTCDateTime) Constraints: Not nullable, Precision: 0voidsetIncidentUUID(UUID incidentUUID) (Key Field) Constraints: Not nullablevoidsetLocation(Location value) Overwrites the associated Location entity for the loaded navigation property to_Location.voidsetPersons(List<Person> value) Overwrites the list of associated Person entities for the loaded navigation property to_Persons.protected voidsetServicePathForFetch(String servicePathForFetch) toString()Methods inherited from class com.sap.cloud.sdk.datamodel.odata.helper.VdmEntity
fetchFieldAsList, fetchFieldAsSingle, getServicePathForFetch, getVersionIdentifier, setDestinationForFetch, setVersionIdentifierMethods inherited from class com.sap.cloud.sdk.datamodel.odata.helper.VdmObject
getChangedFields, getCustomField, getCustomField, getCustomFieldNames, getCustomFields, getSetOfCustomFields, getSetOfFields, getSetOfNavigationProperties, hasCustomField, hasCustomField, rememberChangedField, resetChangedFields, setCustomField, setCustomField, toMap, toMapOfCustomFields
-
Field Details
-
ALL_FIELDS
Selector for all available fields of Incident. -
INCIDENT_ID
Use with available fluent helpers to apply the IncidentID field to query operations. -
FILTER_BY_CURRENT_USER
Use with available fluent helpers to apply the FilterByCurrentUser field to query operations. -
INCIDENT_UUID
Use with available fluent helpers to apply the IncidentUUID field to query operations. -
INCIDENT_UTC_DATE_TIME
Use with available fluent helpers to apply the IncidentUTCDateTime field to query operations. -
INCIDENT_TITLE
Use with available fluent helpers to apply the IncidentTitle field to query operations. -
INCIDENT_STATUS
Use with available fluent helpers to apply the IncidentStatus field to query operations. -
INCIDENT_LOCATION_DESCRIPTION
Use with available fluent helpers to apply the IncidentLocationDescription field to query operations. -
INCIDENT_DESCRIPTION_OF_EVENTS
Use with available fluent helpers to apply the IncidentDescriptionOfEvents field to query operations. -
INCIDENT_CATEGORY
Use with available fluent helpers to apply the IncidentCategory field to query operations. -
EHS_LOCATION_UUID
Use with available fluent helpers to apply the EHSLocationUUID field to query operations. -
TO_LOCATION
Use with available fluent helpers to apply the to_Location navigation property to query operations. -
TO_PERSONS
Use with available fluent helpers to apply the to_Persons navigation property to query operations. -
TO_ATTACHMENTS
Use with available fluent helpers to apply the to_Attachments navigation property to query operations.
-
-
Constructor Details
-
Incident
public Incident() -
Incident
public Incident(@Nullable String incidentID, @Nullable Boolean filterByCurrentUser, @Nullable UUID incidentUUID, @Nullable ZonedDateTime incidentUTCDateTime, @Nullable String incidentTitle, @Nullable String incidentStatus, @Nullable String incidentLocationDescription, @Nullable String incidentDescriptionOfEvents, @Nullable String incidentCategory, @Nullable UUID eHSLocationUUID, @Nullable Location toLocation, List<Person> toPersons, List<Attachment> toAttachments)
-
-
Method Details
-
getType
-
setIncidentID
Constraints: Not nullable, Maximum length: 20Original property name from the Odata EDM: IncidentID
- Parameters:
incidentID- Incident ID
-
setFilterByCurrentUser
Constraints: noneOriginal property name from the Odata EDM: FilterByCurrentUser
- Parameters:
filterByCurrentUser- Filter by Current User
-
setIncidentUUID
(Key Field) Constraints: Not nullableOriginal property name from the Odata EDM: IncidentUUID
- Parameters:
incidentUUID- Incident Global Identification
-
setIncidentUTCDateTime
Constraints: Not nullable, Precision: 0Original property name from the Odata EDM: IncidentUTCDateTime
- Parameters:
incidentUTCDateTime- Incident Start Date/Time (UTC)
-
setIncidentTitle
Constraints: Not nullable, Maximum length: 255Original property name from the Odata EDM: IncidentTitle
- Parameters:
incidentTitle- Incident Title
-
setIncidentStatus
Constraints: Not nullable, Maximum length: 40Original property name from the Odata EDM: IncidentStatus
- Parameters:
incidentStatus- Incident Status
-
setIncidentLocationDescription
Constraints: Not nullable, Maximum length: 80Original property name from the Odata EDM: IncidentLocationDescription
- Parameters:
incidentLocationDescription- Additional Description of Incident Location
-
setIncidentDescriptionOfEvents
Constraints: Not nullable, Maximum length: 999999Original property name from the Odata EDM: IncidentDescriptionOfEvents
- Parameters:
incidentDescriptionOfEvents- Description
-
setIncidentCategory
Constraints: Not nullable, Maximum length: 3Original property name from the Odata EDM: IncidentCategory
- Parameters:
incidentCategory- Incident Category
-
setEHSLocationUUID
Constraints: noneOriginal property name from the Odata EDM: EHSLocationUUID
- Parameters:
eHSLocationUUID- Location Global Identification
-
getEntityCollection
- Specified by:
getEntityCollectionin classVdmEntity<Incident>
-
getKey
-
toMapOfFields
- Overrides:
toMapOfFieldsin classVdmObject<Incident>
-
fromMap
-
field
@Nonnull public static <T> IncidentField<T> field(@Nonnull String fieldName, @Nonnull Class<T> fieldType) Use with available fluent helpers to apply an extension field to query operations.- Type Parameters:
T- The type of the extension field when performing value comparisons.- Parameters:
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.- Returns:
- A representation of an extension field from this entity.
-
field
@Nonnull public static <T,DomainT> IncidentField<T> field(@Nonnull String fieldName, @Nonnull TypeConverter<T, DomainT> typeConverter) Use with available fluent helpers to apply an extension field to query operations.- Type Parameters:
T- The type of the extension field when performing value comparisons.DomainT- The type of the extension field as returned by the OData service.- Parameters:
typeConverter- A TypeConverter<T, DomainT> instance whose first generic type matches the Java type of the fieldfieldName- The name of the extension field as returned by the OData service.- Returns:
- A representation of an extension field from this entity, holding a reference to the given TypeConverter.
-
getDestinationForFetch
- Overrides:
getDestinationForFetchin classVdmEntity<Incident>
-
setServicePathForFetch
- Overrides:
setServicePathForFetchin classVdmEntity<Incident>
-
attachToService
public void attachToService(@Nullable String servicePath, @Nonnull HttpDestinationProperties destination) - Overrides:
attachToServicein classVdmEntity<Incident>
-
getDefaultServicePath
- Overrides:
getDefaultServicePathin classVdmEntity<Incident>
-
fetchLocation
Fetches the Location entity (one to one) associated with this entity. This corresponds to the OData navigation property to_Location.Please note: This method will not cache or persist the query results.
- Returns:
- The single associated Location entity, or
nullif an entity is not associated. - Throws:
com.sap.cloud.sdk.datamodel.odata.client.exception.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.
-
getLocationOrFetch
Retrieval of associated Location entity (one to one). This corresponds to the OData navigation property to_Location.If the navigation property to_Location of a queried Incident 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.
- Returns:
- List of associated Location entity.
- Throws:
com.sap.cloud.sdk.datamodel.odata.client.exception.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.
-
getLocationIfPresent
Retrieval of associated Location entity (one to one). This corresponds to the OData navigation property to_Location.If the navigation property for an entity Incident has not been resolved yet, this method will not query further information. Instead its
Optionresult state will beempty.- Returns:
- If the information for navigation property to_Location is already loaded, the result will contain
the Location entity. If not, an
Optionwith result stateemptyis returned.
-
setLocation
Overwrites the associated Location entity for the loaded navigation property to_Location.- Parameters:
value- New Location entity.
-
fetchPersons
Fetches the Person entities (one to many) associated with this entity. This corresponds to the OData navigation property to_Persons.Please note: This method will not cache or persist the query results.
- Returns:
- List containing one or more associated Person entities. If no entities are associated then an empty list is returned.
- Throws:
com.sap.cloud.sdk.datamodel.odata.client.exception.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.
-
getPersonsOrFetch
Retrieval of associated Person entities (one to many). This corresponds to the OData navigation property to_Persons.If the navigation property to_Persons of a queried Incident 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.
- Returns:
- List of associated Person entities.
- Throws:
com.sap.cloud.sdk.datamodel.odata.client.exception.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.
-
getPersonsIfPresent
Retrieval of associated Person entities (one to many). This corresponds to the OData navigation property to_Persons.If the navigation property for an entity Incident has not been resolved yet, this method will not query further information. Instead its
Optionresult state will beempty.- Returns:
- If the information for navigation property to_Persons is already loaded, the result will contain
the Person entities. If not, an
Optionwith result stateemptyis returned.
-
setPersons
Overwrites the list of associated Person entities for the loaded navigation property to_Persons.If the navigation property to_Persons of a queried Incident 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.
- Parameters:
value- List of Person entities.
-
addPersons
Adds elements to the list of associated Person entities. This corresponds to the OData navigation property to_Persons.If the navigation property to_Persons of a queried Incident 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.
- Parameters:
entity- Array of Person entities.
-
fetchAttachments
Fetches the Attachment entities (one to many) associated with this entity. This corresponds to the OData navigation property to_Attachments.Please note: This method will not cache or persist the query results.
- Returns:
- List containing one or more associated Attachment entities. If no entities are associated then an empty list is returned.
- Throws:
com.sap.cloud.sdk.datamodel.odata.client.exception.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.
-
getAttachmentsOrFetch
Retrieval of associated Attachment entities (one to many). This corresponds to the OData navigation property to_Attachments.If the navigation property to_Attachments of a queried Incident 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.
- Returns:
- List of associated Attachment entities.
- Throws:
com.sap.cloud.sdk.datamodel.odata.client.exception.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.
-
getAttachmentsIfPresent
Retrieval of associated Attachment entities (one to many). This corresponds to the OData navigation property to_Attachments.If the navigation property for an entity Incident has not been resolved yet, this method will not query further information. Instead its
Optionresult state will beempty.- Returns:
- If the information for navigation property to_Attachments is already loaded, the result will
contain the Attachment entities. If not, an
Optionwith result stateemptyis returned.
-
setAttachments
Overwrites the list of associated Attachment entities for the loaded navigation property to_Attachments.If the navigation property to_Attachments of a queried Incident 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.
- Parameters:
value- List of Attachment entities.
-
addAttachments
Adds elements to the list of associated Attachment entities. This corresponds to the OData navigation property to_Attachments.If the navigation property to_Attachments of a queried Incident 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.
- Parameters:
entity- Array of Attachment entities.
-
builder
-
getIncidentID
Constraints: Not nullable, Maximum length: 20Original property name from the Odata EDM: IncidentID
- Returns:
- Incident ID
-
getFilterByCurrentUser
Constraints: noneOriginal property name from the Odata EDM: FilterByCurrentUser
- Returns:
- Filter by Current User
-
getIncidentUUID
(Key Field) Constraints: Not nullableOriginal property name from the Odata EDM: IncidentUUID
- Returns:
- Incident Global Identification
-
getIncidentUTCDateTime
Constraints: Not nullable, Precision: 0Original property name from the Odata EDM: IncidentUTCDateTime
- Returns:
- Incident Start Date/Time (UTC)
-
getIncidentTitle
Constraints: Not nullable, Maximum length: 255Original property name from the Odata EDM: IncidentTitle
- Returns:
- Incident Title
-
getIncidentStatus
Constraints: Not nullable, Maximum length: 40Original property name from the Odata EDM: IncidentStatus
- Returns:
- Incident Status
-
getIncidentLocationDescription
Constraints: Not nullable, Maximum length: 80Original property name from the Odata EDM: IncidentLocationDescription
- Returns:
- Additional Description of Incident Location
-
getIncidentDescriptionOfEvents
Constraints: Not nullable, Maximum length: 999999Original property name from the Odata EDM: IncidentDescriptionOfEvents
- Returns:
- Description
-
getIncidentCategory
Constraints: Not nullable, Maximum length: 3Original property name from the Odata EDM: IncidentCategory
- Returns:
- Incident Category
-
getEHSLocationUUID
Constraints: noneOriginal property name from the Odata EDM: EHSLocationUUID
- Returns:
- Location Global Identification
-
toString
-
equals
-
canEqual
-
hashCode
public int hashCode()
-