1// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates.  All rights reserved.
2// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
3// Code generated. DO NOT EDIT.
4
5// Oracle Cloud VMware Solution API
6//
7// Use this API to manage the Oracle Cloud VMware Solution.
8//
9
10package ocvp
11
12import (
13	"github.com/oracle/oci-go-sdk/common"
14)
15
16// WorkRequest An asynchronous work request.
17type WorkRequest struct {
18
19	// The asynchronous operation tracked by this work request.
20	OperationType OperationTypesEnum `mandatory:"true" json:"operationType"`
21
22	// The status of the work request.
23	Status OperationStatusEnum `mandatory:"true" json:"status"`
24
25	// The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request.
26	Id *string `mandatory:"true" json:"id"`
27
28	// The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment that
29	// contains the work request.
30	CompartmentId *string `mandatory:"true" json:"compartmentId"`
31
32	// The resources that are affected by this work request.
33	Resources []WorkRequestResource `mandatory:"true" json:"resources"`
34
35	// The percentage complete of the operation tracked by this work request.
36	PercentComplete *float32 `mandatory:"true" json:"percentComplete"`
37
38	// The date and time the work request was created, in the format defined by
39	// RFC3339 (https://tools.ietf.org/html/rfc3339).
40	// Example: `2016-08-25T21:10:29.600Z`
41	TimeAccepted *common.SDKTime `mandatory:"true" json:"timeAccepted"`
42
43	// The date and time the work request transitioned from `ACCEPTED` to `IN_PROGRESS`,
44	// in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339).
45	TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"`
46
47	// The date and time the work request reached a terminal state, either `FAILED` OR
48	// `SUCCEEDED`. Format is defined by RFC3339 (https://tools.ietf.org/html/rfc3339).
49	TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"`
50}
51
52func (m WorkRequest) String() string {
53	return common.PointerString(m)
54}
55