Google.Maps.Constants.IsExpectedScaleValue C# (CSharp) Method

IsExpectedScaleValue() public static method

public static IsExpectedScaleValue ( int value, bool throwIfOutOfRange ) : bool
value int
throwIfOutOfRange bool
return bool
        public static bool IsExpectedScaleValue(int value, bool throwIfOutOfRange)
        {
            if(Contains(S_ExpectedScaleValues, value) == true) return true;

            if(throwIfOutOfRange)
                throw new ArgumentOutOfRangeException("Scale value can only be " + ListValues(S_ExpectedScaleValues));
            else
                return false;
        }