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

namespace Rv\Analytics\UI\Toolbar\TextStyle\Change;

use UnexpectedValueException;

/**
 * Protobuf type <code>rv.analytics.UI.Toolbar.TextStyle.Change.Property</code>
 */
class Property
{
    /**
     * Generated from protobuf enum <code>PROPERTY_UNKNOWN = 0;</code>
     */
    const PROPERTY_UNKNOWN = 0;
    /**
     * Generated from protobuf enum <code>PROPERTY_FONT_TYPEFACE = 1;</code>
     */
    const PROPERTY_FONT_TYPEFACE = 1;
    /**
     * Generated from protobuf enum <code>PROPERTY_FONT_WEIGHT = 2;</code>
     */
    const PROPERTY_FONT_WEIGHT = 2;
    /**
     * Generated from protobuf enum <code>PROPERTY_FONT_CAPITALIZATION = 3;</code>
     */
    const PROPERTY_FONT_CAPITALIZATION = 3;
    /**
     * Generated from protobuf enum <code>PROPERTY_FONT_SIZE = 4;</code>
     */
    const PROPERTY_FONT_SIZE = 4;
    /**
     * Generated from protobuf enum <code>PROPERTY_FONT_COLOR = 5;</code>
     */
    const PROPERTY_FONT_COLOR = 5;
    /**
     * Generated from protobuf enum <code>PROPERTY_HORIZONTAL_ALIGNMENT = 6;</code>
     */
    const PROPERTY_HORIZONTAL_ALIGNMENT = 6;
    /**
     * Generated from protobuf enum <code>PROPERTY_VERTICAL_ALIGNMENT = 7;</code>
     */
    const PROPERTY_VERTICAL_ALIGNMENT = 7;
    /**
     * Generated from protobuf enum <code>PROPERTY_STROKE_ENABLE = 8;</code>
     */
    const PROPERTY_STROKE_ENABLE = 8;
    /**
     * Generated from protobuf enum <code>PROPERTY_STROKE_WIDTH = 9;</code>
     */
    const PROPERTY_STROKE_WIDTH = 9;
    /**
     * Generated from protobuf enum <code>PROPERTY_STROKE_COLOR = 10;</code>
     */
    const PROPERTY_STROKE_COLOR = 10;
    /**
     * Generated from protobuf enum <code>PROPERTY_SHADOW_ENABLE = 11;</code>
     */
    const PROPERTY_SHADOW_ENABLE = 11;
    /**
     * Generated from protobuf enum <code>PROPERTY_SHADOW_BLUR = 12;</code>
     */
    const PROPERTY_SHADOW_BLUR = 12;
    /**
     * Generated from protobuf enum <code>PROPERTY_SHADOW_OPACITY = 13;</code>
     */
    const PROPERTY_SHADOW_OPACITY = 13;
    /**
     * Generated from protobuf enum <code>PROPERTY_SHADOW_COLOR = 14;</code>
     */
    const PROPERTY_SHADOW_COLOR = 14;
    /**
     * Generated from protobuf enum <code>PROPERTY_SHADOW_ANGLE = 15;</code>
     */
    const PROPERTY_SHADOW_ANGLE = 15;
    /**
     * Generated from protobuf enum <code>PROPERTY_SHADOW_OFFSET = 16;</code>
     */
    const PROPERTY_SHADOW_OFFSET = 16;

    private static $valueToName = [
        self::PROPERTY_UNKNOWN => 'PROPERTY_UNKNOWN',
        self::PROPERTY_FONT_TYPEFACE => 'PROPERTY_FONT_TYPEFACE',
        self::PROPERTY_FONT_WEIGHT => 'PROPERTY_FONT_WEIGHT',
        self::PROPERTY_FONT_CAPITALIZATION => 'PROPERTY_FONT_CAPITALIZATION',
        self::PROPERTY_FONT_SIZE => 'PROPERTY_FONT_SIZE',
        self::PROPERTY_FONT_COLOR => 'PROPERTY_FONT_COLOR',
        self::PROPERTY_HORIZONTAL_ALIGNMENT => 'PROPERTY_HORIZONTAL_ALIGNMENT',
        self::PROPERTY_VERTICAL_ALIGNMENT => 'PROPERTY_VERTICAL_ALIGNMENT',
        self::PROPERTY_STROKE_ENABLE => 'PROPERTY_STROKE_ENABLE',
        self::PROPERTY_STROKE_WIDTH => 'PROPERTY_STROKE_WIDTH',
        self::PROPERTY_STROKE_COLOR => 'PROPERTY_STROKE_COLOR',
        self::PROPERTY_SHADOW_ENABLE => 'PROPERTY_SHADOW_ENABLE',
        self::PROPERTY_SHADOW_BLUR => 'PROPERTY_SHADOW_BLUR',
        self::PROPERTY_SHADOW_OPACITY => 'PROPERTY_SHADOW_OPACITY',
        self::PROPERTY_SHADOW_COLOR => 'PROPERTY_SHADOW_COLOR',
        self::PROPERTY_SHADOW_ANGLE => 'PROPERTY_SHADOW_ANGLE',
        self::PROPERTY_SHADOW_OFFSET => 'PROPERTY_SHADOW_OFFSET',
    ];

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

