<?php

namespace CustomerManagement\EnumType;

/**
 * This class stands for PropertyTypeEnum EnumType
 * @subpackage Enumerations
 */
class PropertyTypeEnum
{
    /**
     * Constant for value 'NotSet'
     * @return string 'NotSet'
     */
    const VALUE_NOT_SET = 'NotSet';
    /**
     * Constant for value 'SingleFamilyHouse'
     * @return string 'SingleFamilyHouse'
     */
    const VALUE_SINGLE_FAMILY_HOUSE = 'SingleFamilyHouse';
    /**
     * Constant for value 'Townhouse'
     * @return string 'Townhouse'
     */
    const VALUE_TOWNHOUSE = 'Townhouse';
    /**
     * Constant for value 'Condo'
     * @return string 'Condo'
     */
    const VALUE_CONDO = 'Condo';
    /**
     * Constant for value 'Business'
     * @return string 'Business'
     */
    const VALUE_BUSINESS = 'Business';
    /**
     * Return true if value is allowed
     * @uses self::getValidValues()
     * @param mixed $value value
     * @return bool true|false
     */
    public static function valueIsValid($value)
    {
        return ($value === null) || in_array($value, self::getValidValues(), true);
    }
    /**
     * Return allowed values
     * @uses self::VALUE_NOT_SET
     * @uses self::VALUE_SINGLE_FAMILY_HOUSE
     * @uses self::VALUE_TOWNHOUSE
     * @uses self::VALUE_CONDO
     * @uses self::VALUE_BUSINESS
     * @return string[]
     */
    public static function getValidValues()
    {
        return array(
            self::VALUE_NOT_SET,
            self::VALUE_SINGLE_FAMILY_HOUSE,
            self::VALUE_TOWNHOUSE,
            self::VALUE_CONDO,
            self::VALUE_BUSINESS,
        );
    }
    /**
     * Method returning the class name
     * @return string __CLASS__
     */
    public function __toString()
    {
        return __CLASS__;
    }
}
