1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- <?php
- # Generated by the protocol buffer compiler. DO NOT EDIT!
- # source: protos/ydb_table.proto
- namespace Ydb\Table\QueryStatsCollection;
- use UnexpectedValueException;
- /**
- * Protobuf type <code>Ydb.Table.QueryStatsCollection.Mode</code>
- */
- class Mode
- {
- /**
- * Generated from protobuf enum <code>STATS_COLLECTION_UNSPECIFIED = 0;</code>
- */
- const STATS_COLLECTION_UNSPECIFIED = 0;
- /**
- * Stats collection is disabled
- *
- * Generated from protobuf enum <code>STATS_COLLECTION_NONE = 1;</code>
- */
- const STATS_COLLECTION_NONE = 1;
- /**
- * Aggregated stats of reads, updates and deletes per table
- *
- * Generated from protobuf enum <code>STATS_COLLECTION_BASIC = 2;</code>
- */
- const STATS_COLLECTION_BASIC = 2;
- /**
- * Add execution stats and plan on top of STATS_COLLECTION_BASIC
- *
- * Generated from protobuf enum <code>STATS_COLLECTION_FULL = 3;</code>
- */
- const STATS_COLLECTION_FULL = 3;
- /**
- * Detailed execution stats including stats for individual tasks and channels
- *
- * Generated from protobuf enum <code>STATS_COLLECTION_PROFILE = 4;</code>
- */
- const STATS_COLLECTION_PROFILE = 4;
- private static $valueToName = [
- self::STATS_COLLECTION_UNSPECIFIED => 'STATS_COLLECTION_UNSPECIFIED',
- self::STATS_COLLECTION_NONE => 'STATS_COLLECTION_NONE',
- self::STATS_COLLECTION_BASIC => 'STATS_COLLECTION_BASIC',
- self::STATS_COLLECTION_FULL => 'STATS_COLLECTION_FULL',
- self::STATS_COLLECTION_PROFILE => 'STATS_COLLECTION_PROFILE',
- ];
- 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);
- }
- }
- // Adding a class alias for backwards compatibility with the previous class name.
- class_alias(Mode::class, \Ydb\Table\QueryStatsCollection_Mode::class);
|