Google Cloud Sql Admin V1 Client - Class Operation (1.2.1)

Reference documentation and code samples for the Google Cloud Sql Admin V1 Client class Operation.

An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.

Generated from protobuf message google.cloud.sql.v1.Operation

Namespace

Google \ Cloud \ Sql \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ kind string

This is always sql#operation.

↳ target_link string
↳ status int

The status of an operation.

↳ user string

The email address of the user who initiated this operation.

↳ insert_time Google\Protobuf\Timestamp

The time this operation was enqueued in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

↳ start_time Google\Protobuf\Timestamp

The time this operation actually started in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

↳ end_time Google\Protobuf\Timestamp

The time this operation finished in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

↳ error OperationErrors

If errors occurred during processing of this operation, this field will be populated.

↳ api_warning ApiWarning

An Admin API warning message.

↳ operation_type int

The type of the operation. Valid values are: * * CREATE * * DELETE * * UPDATE * * RESTART * * IMPORT * * EXPORT * * BACKUP_VOLUME * * RESTORE_VOLUME * * CREATE_USER * * DELETE_USER * * CREATE_DATABASE * * DELETE_DATABASE

↳ import_context ImportContext

The context for import operation, if applicable.

↳ export_context ExportContext

The context for export operation, if applicable.

↳ backup_context BackupContext

The context for backup operation, if applicable.

↳ name string

An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.

↳ target_id string

Name of the database instance related to this operation.

↳ self_link string

The URI of this resource.

↳ target_project string

The project ID of the target instance related to this operation.

↳ acquire_ssrs_lease_context AcquireSsrsLeaseContext

The context for acquire SSRS lease operation, if applicable.

getKind

This is always sql#operation.

Returns
Type Description
string

setKind

This is always sql#operation.

Parameter
Name Description
var string
Returns
Type Description
$this

Generated from protobuf field string target_link = 2;

Returns
Type Description
string

Generated from protobuf field string target_link = 2;

Parameter
Name Description
var string
Returns
Type Description
$this

getStatus

The status of an operation.

Returns
Type Description
int

setStatus

The status of an operation.

Parameter
Name Description
var int
Returns
Type Description
$this

getUser

The email address of the user who initiated this operation.

Returns
Type Description
string

setUser

The email address of the user who initiated this operation.

Parameter
Name Description
var string
Returns
Type Description
$this

getInsertTime

The time this operation was enqueued in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Returns
Type Description
Google\Protobuf\Timestamp|null

hasInsertTime

clearInsertTime

setInsertTime

The time this operation was enqueued in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Parameter
Name Description
var Google\Protobuf\Timestamp
Returns
Type Description
$this

getStartTime

The time this operation actually started in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Returns
Type Description
Google\Protobuf\Timestamp|null

hasStartTime

clearStartTime

setStartTime

The time this operation actually started in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Parameter
Name Description
var Google\Protobuf\Timestamp
Returns
Type Description
$this

getEndTime

The time this operation finished in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Returns
Type Description
Google\Protobuf\Timestamp|null

hasEndTime

clearEndTime

setEndTime

The time this operation finished in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Parameter
Name Description
var Google\Protobuf\Timestamp
Returns
Type Description
$this

getError

If errors occurred during processing of this operation, this field will be populated.

Returns
Type Description
OperationErrors|null

hasError

clearError

setError

If errors occurred during processing of this operation, this field will be populated.

Parameter
Name Description
var OperationErrors
Returns
Type Description
$this

getApiWarning

An Admin API warning message.

Returns
Type Description
ApiWarning|null

hasApiWarning

clearApiWarning

setApiWarning

An Admin API warning message.

Parameter
Name Description
var ApiWarning
Returns
Type Description
$this

getOperationType

The type of the operation. Valid values are:

  • CREATE
  • DELETE
  • UPDATE
  • RESTART
  • IMPORT
  • EXPORT
  • BACKUP_VOLUME
  • RESTORE_VOLUME
  • CREATE_USER
  • DELETE_USER
  • CREATE_DATABASE
  • DELETE_DATABASE
Returns
Type Description
int

setOperationType

The type of the operation. Valid values are:

  • CREATE
  • DELETE
  • UPDATE
  • RESTART
  • IMPORT
  • EXPORT
  • BACKUP_VOLUME
  • RESTORE_VOLUME
  • CREATE_USER
  • DELETE_USER
  • CREATE_DATABASE
  • DELETE_DATABASE
Parameter
Name Description
var int
Returns
Type Description
$this

getImportContext

The context for import operation, if applicable.

Returns
Type Description
ImportContext|null

hasImportContext

clearImportContext

setImportContext

The context for import operation, if applicable.

Parameter
Name Description
var ImportContext
Returns
Type Description
$this

getExportContext

The context for export operation, if applicable.

Returns
Type Description
ExportContext|null

hasExportContext

clearExportContext

setExportContext

The context for export operation, if applicable.

Parameter
Name Description
var ExportContext
Returns
Type Description
$this

getBackupContext

The context for backup operation, if applicable.

Returns
Type Description
BackupContext|null

hasBackupContext

clearBackupContext

setBackupContext

The context for backup operation, if applicable.

Parameter
Name Description
var BackupContext
Returns
Type Description
$this

getName

An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.

Returns
Type Description
string

setName

An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.

Parameter
Name Description
var string
Returns
Type Description
$this

getTargetId

Name of the database instance related to this operation.

Returns
Type Description
string

setTargetId

Name of the database instance related to this operation.

Parameter
Name Description
var string
Returns
Type Description
$this

The URI of this resource.

Returns
Type Description
string

The URI of this resource.

Parameter
Name Description
var string
Returns
Type Description
$this

getTargetProject

The project ID of the target instance related to this operation.

Returns
Type Description
string

setTargetProject

The project ID of the target instance related to this operation.

Parameter
Name Description
var string
Returns
Type Description
$this

getAcquireSsrsLeaseContext

The context for acquire SSRS lease operation, if applicable.

Returns
Type Description
AcquireSsrsLeaseContext|null

hasAcquireSsrsLeaseContext

clearAcquireSsrsLeaseContext

setAcquireSsrsLeaseContext

The context for acquire SSRS lease operation, if applicable.

Parameter
Name Description
var AcquireSsrsLeaseContext
Returns
Type Description
$this