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

namespace PhpWA\Protocol\Proto\ContextInfo;

use UnexpectedValueException;

/**
 * Protobuf type <code>proto.ContextInfo.PairedMediaType</code>
 */
class PairedMediaType
{
    /**
     * Generated from protobuf enum <code>NOT_PAIRED_MEDIA = 0;</code>
     */
    const NOT_PAIRED_MEDIA = 0;
    /**
     * Generated from protobuf enum <code>SD_VIDEO_PARENT = 1;</code>
     */
    const SD_VIDEO_PARENT = 1;
    /**
     * Generated from protobuf enum <code>HD_VIDEO_CHILD = 2;</code>
     */
    const HD_VIDEO_CHILD = 2;
    /**
     * Generated from protobuf enum <code>SD_IMAGE_PARENT = 3;</code>
     */
    const SD_IMAGE_PARENT = 3;
    /**
     * Generated from protobuf enum <code>HD_IMAGE_CHILD = 4;</code>
     */
    const HD_IMAGE_CHILD = 4;
    /**
     * Generated from protobuf enum <code>MOTION_PHOTO_PARENT = 5;</code>
     */
    const MOTION_PHOTO_PARENT = 5;
    /**
     * Generated from protobuf enum <code>MOTION_PHOTO_CHILD = 6;</code>
     */
    const MOTION_PHOTO_CHILD = 6;
    /**
     * Generated from protobuf enum <code>HEVC_VIDEO_PARENT = 7;</code>
     */
    const HEVC_VIDEO_PARENT = 7;
    /**
     * Generated from protobuf enum <code>HEVC_VIDEO_CHILD = 8;</code>
     */
    const HEVC_VIDEO_CHILD = 8;

    private static $valueToName = [
        self::NOT_PAIRED_MEDIA => 'NOT_PAIRED_MEDIA',
        self::SD_VIDEO_PARENT => 'SD_VIDEO_PARENT',
        self::HD_VIDEO_CHILD => 'HD_VIDEO_CHILD',
        self::SD_IMAGE_PARENT => 'SD_IMAGE_PARENT',
        self::HD_IMAGE_CHILD => 'HD_IMAGE_CHILD',
        self::MOTION_PHOTO_PARENT => 'MOTION_PHOTO_PARENT',
        self::MOTION_PHOTO_CHILD => 'MOTION_PHOTO_CHILD',
        self::HEVC_VIDEO_PARENT => 'HEVC_VIDEO_PARENT',
        self::HEVC_VIDEO_CHILD => 'HEVC_VIDEO_CHILD',
    ];

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

