<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: WAProto.proto

namespace PhpWA\Protocol\Proto\ClientPayload\UserAgent;

use UnexpectedValueException;

/**
 * Protobuf type <code>proto.ClientPayload.UserAgent.Platform</code>
 */
class Platform
{
    /**
     * Generated from protobuf enum <code>ANDROID = 0;</code>
     */
    const ANDROID = 0;
    /**
     * Generated from protobuf enum <code>IOS = 1;</code>
     */
    const IOS = 1;
    /**
     * Generated from protobuf enum <code>WINDOWS_PHONE = 2;</code>
     */
    const WINDOWS_PHONE = 2;
    /**
     * Generated from protobuf enum <code>BLACKBERRY = 3;</code>
     */
    const BLACKBERRY = 3;
    /**
     * Generated from protobuf enum <code>BLACKBERRYX = 4;</code>
     */
    const BLACKBERRYX = 4;
    /**
     * Generated from protobuf enum <code>S40 = 5;</code>
     */
    const S40 = 5;
    /**
     * Generated from protobuf enum <code>S60 = 6;</code>
     */
    const S60 = 6;
    /**
     * Generated from protobuf enum <code>PYTHON_CLIENT = 7;</code>
     */
    const PYTHON_CLIENT = 7;
    /**
     * Generated from protobuf enum <code>TIZEN = 8;</code>
     */
    const TIZEN = 8;
    /**
     * Generated from protobuf enum <code>ENTERPRISE = 9;</code>
     */
    const ENTERPRISE = 9;
    /**
     * Generated from protobuf enum <code>SMB_ANDROID = 10;</code>
     */
    const SMB_ANDROID = 10;
    /**
     * Generated from protobuf enum <code>KAIOS = 11;</code>
     */
    const KAIOS = 11;
    /**
     * Generated from protobuf enum <code>SMB_IOS = 12;</code>
     */
    const SMB_IOS = 12;
    /**
     * Generated from protobuf enum <code>WINDOWS = 13;</code>
     */
    const WINDOWS = 13;
    /**
     * Generated from protobuf enum <code>WEB = 14;</code>
     */
    const WEB = 14;
    /**
     * Generated from protobuf enum <code>PORTAL = 15;</code>
     */
    const PORTAL = 15;
    /**
     * Generated from protobuf enum <code>GREEN_ANDROID = 16;</code>
     */
    const GREEN_ANDROID = 16;
    /**
     * Generated from protobuf enum <code>GREEN_IPHONE = 17;</code>
     */
    const GREEN_IPHONE = 17;
    /**
     * Generated from protobuf enum <code>BLUE_ANDROID = 18;</code>
     */
    const BLUE_ANDROID = 18;
    /**
     * Generated from protobuf enum <code>BLUE_IPHONE = 19;</code>
     */
    const BLUE_IPHONE = 19;
    /**
     * Generated from protobuf enum <code>FBLITE_ANDROID = 20;</code>
     */
    const FBLITE_ANDROID = 20;
    /**
     * Generated from protobuf enum <code>MLITE_ANDROID = 21;</code>
     */
    const MLITE_ANDROID = 21;
    /**
     * Generated from protobuf enum <code>IGLITE_ANDROID = 22;</code>
     */
    const IGLITE_ANDROID = 22;
    /**
     * Generated from protobuf enum <code>PAGE = 23;</code>
     */
    const PAGE = 23;
    /**
     * Generated from protobuf enum <code>MACOS = 24;</code>
     */
    const MACOS = 24;
    /**
     * Generated from protobuf enum <code>OCULUS_MSG = 25;</code>
     */
    const OCULUS_MSG = 25;
    /**
     * Generated from protobuf enum <code>OCULUS_CALL = 26;</code>
     */
    const OCULUS_CALL = 26;
    /**
     * Generated from protobuf enum <code>MILAN = 27;</code>
     */
    const MILAN = 27;
    /**
     * Generated from protobuf enum <code>CAPI = 28;</code>
     */
    const CAPI = 28;
    /**
     * Generated from protobuf enum <code>WEAROS = 29;</code>
     */
    const WEAROS = 29;
    /**
     * Generated from protobuf enum <code>ARDEVICE = 30;</code>
     */
    const ARDEVICE = 30;
    /**
     * Generated from protobuf enum <code>VRDEVICE = 31;</code>
     */
    const VRDEVICE = 31;
    /**
     * Generated from protobuf enum <code>BLUE_WEB = 32;</code>
     */
    const BLUE_WEB = 32;
    /**
     * Generated from protobuf enum <code>IPAD = 33;</code>
     */
    const IPAD = 33;
    /**
     * Generated from protobuf enum <code>TEST = 34;</code>
     */
    const TEST = 34;
    /**
     * Generated from protobuf enum <code>SMART_GLASSES = 35;</code>
     */
    const SMART_GLASSES = 35;
    /**
     * Generated from protobuf enum <code>BLUE_VR = 36;</code>
     */
    const BLUE_VR = 36;
    /**
     * Generated from protobuf enum <code>AR_WRIST = 37;</code>
     */
    const AR_WRIST = 37;

    private static $valueToName = [
        self::ANDROID => 'ANDROID',
        self::IOS => 'IOS',
        self::WINDOWS_PHONE => 'WINDOWS_PHONE',
        self::BLACKBERRY => 'BLACKBERRY',
        self::BLACKBERRYX => 'BLACKBERRYX',
        self::S40 => 'S40',
        self::S60 => 'S60',
        self::PYTHON_CLIENT => 'PYTHON_CLIENT',
        self::TIZEN => 'TIZEN',
        self::ENTERPRISE => 'ENTERPRISE',
        self::SMB_ANDROID => 'SMB_ANDROID',
        self::KAIOS => 'KAIOS',
        self::SMB_IOS => 'SMB_IOS',
        self::WINDOWS => 'WINDOWS',
        self::WEB => 'WEB',
        self::PORTAL => 'PORTAL',
        self::GREEN_ANDROID => 'GREEN_ANDROID',
        self::GREEN_IPHONE => 'GREEN_IPHONE',
        self::BLUE_ANDROID => 'BLUE_ANDROID',
        self::BLUE_IPHONE => 'BLUE_IPHONE',
        self::FBLITE_ANDROID => 'FBLITE_ANDROID',
        self::MLITE_ANDROID => 'MLITE_ANDROID',
        self::IGLITE_ANDROID => 'IGLITE_ANDROID',
        self::PAGE => 'PAGE',
        self::MACOS => 'MACOS',
        self::OCULUS_MSG => 'OCULUS_MSG',
        self::OCULUS_CALL => 'OCULUS_CALL',
        self::MILAN => 'MILAN',
        self::CAPI => 'CAPI',
        self::WEAROS => 'WEAROS',
        self::ARDEVICE => 'ARDEVICE',
        self::VRDEVICE => 'VRDEVICE',
        self::BLUE_WEB => 'BLUE_WEB',
        self::IPAD => 'IPAD',
        self::TEST => 'TEST',
        self::SMART_GLASSES => 'SMART_GLASSES',
        self::BLUE_VR => 'BLUE_VR',
        self::AR_WRIST => 'AR_WRIST',
    ];

    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);
    }
}

