-
Notifications
You must be signed in to change notification settings - Fork 460
Expand file tree
/
Copy pathExecutionState.php
More file actions
82 lines (74 loc) · 2.47 KB
/
ExecutionState.php
File metadata and controls
82 lines (74 loc) · 2.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<?php
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: google/dataflow/v1beta3/metrics.proto
namespace Google\Cloud\Dataflow\V1beta3;
use UnexpectedValueException;
/**
* The state of some component of job execution.
*
* Protobuf type <code>google.dataflow.v1beta3.ExecutionState</code>
*/
class ExecutionState
{
/**
* The component state is unknown or unspecified.
*
* Generated from protobuf enum <code>EXECUTION_STATE_UNKNOWN = 0;</code>
*/
const EXECUTION_STATE_UNKNOWN = 0;
/**
* The component is not yet running.
*
* Generated from protobuf enum <code>EXECUTION_STATE_NOT_STARTED = 1;</code>
*/
const EXECUTION_STATE_NOT_STARTED = 1;
/**
* The component is currently running.
*
* Generated from protobuf enum <code>EXECUTION_STATE_RUNNING = 2;</code>
*/
const EXECUTION_STATE_RUNNING = 2;
/**
* The component succeeded.
*
* Generated from protobuf enum <code>EXECUTION_STATE_SUCCEEDED = 3;</code>
*/
const EXECUTION_STATE_SUCCEEDED = 3;
/**
* The component failed.
*
* Generated from protobuf enum <code>EXECUTION_STATE_FAILED = 4;</code>
*/
const EXECUTION_STATE_FAILED = 4;
/**
* Execution of the component was cancelled.
*
* Generated from protobuf enum <code>EXECUTION_STATE_CANCELLED = 5;</code>
*/
const EXECUTION_STATE_CANCELLED = 5;
private static $valueToName = [
self::EXECUTION_STATE_UNKNOWN => 'EXECUTION_STATE_UNKNOWN',
self::EXECUTION_STATE_NOT_STARTED => 'EXECUTION_STATE_NOT_STARTED',
self::EXECUTION_STATE_RUNNING => 'EXECUTION_STATE_RUNNING',
self::EXECUTION_STATE_SUCCEEDED => 'EXECUTION_STATE_SUCCEEDED',
self::EXECUTION_STATE_FAILED => 'EXECUTION_STATE_FAILED',
self::EXECUTION_STATE_CANCELLED => 'EXECUTION_STATE_CANCELLED',
];
public static function name($value)
{
if (!isset(self::$valueToName[$value])) {
throw new UnexpectedValueException(sprintf(
'Enum %s has no name defined for value %s', __CLASS__, $value));
}
return self::$valueToName[$value];
}
public static function value($name)
{
$const = __CLASS__ . '::' . strtoupper($name);
if (!defined($const)) {
throw new UnexpectedValueException(sprintf(
'Enum %s has no value defined for name %s', __CLASS__, $name));
}
return constant($const);
}
}