74 lines
1.8 KiB
PHP
74 lines
1.8 KiB
PHP
<?php
|
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
# source: resources/tadah.proto
|
|
|
|
namespace App\Proto;
|
|
|
|
use UnexpectedValueException;
|
|
|
|
/**
|
|
* Protobuf type <code>Tadah.AssetType</code>
|
|
*/
|
|
class AssetType
|
|
{
|
|
/**
|
|
* Generated from protobuf enum <code>CLOTHING = 0;</code>
|
|
*/
|
|
const CLOTHING = 0;
|
|
/**
|
|
* Generated from protobuf enum <code>HEAD = 1;</code>
|
|
*/
|
|
const HEAD = 1;
|
|
/**
|
|
* Generated from protobuf enum <code>MESH = 2;</code>
|
|
*/
|
|
const MESH = 2;
|
|
/**
|
|
* Generated from protobuf enum <code>PLACE = 3;</code>
|
|
*/
|
|
const PLACE = 3;
|
|
/**
|
|
* Generated from protobuf enum <code>USER = 4;</code>
|
|
*/
|
|
const USER = 4;
|
|
/**
|
|
* Generated from protobuf enum <code>HEADSHOT = 5;</code>
|
|
*/
|
|
const HEADSHOT = 5;
|
|
/**
|
|
* Generated from protobuf enum <code>XML = 6;</code>
|
|
*/
|
|
const XML = 6;
|
|
|
|
private static $valueToName = [
|
|
self::CLOTHING => 'CLOTHING',
|
|
self::HEAD => 'HEAD',
|
|
self::MESH => 'MESH',
|
|
self::PLACE => 'PLACE',
|
|
self::USER => 'USER',
|
|
self::HEADSHOT => 'HEADSHOT',
|
|
self::XML => 'XML',
|
|
];
|
|
|
|
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);
|
|
}
|
|
}
|
|
|