Search Results for

    Show / Hide Table of Contents

    Class NumberUtil

    Defines a helper class to work with numbers

    Inheritance
    java.lang.Object
    NumberUtil
    Inherited Members
    Object.clone()
    Object.equals(Object)
    Object.finalize()
    Object.getClass()
    Object.hashCode()
    Object.notify()
    Object.notifyAll()
    Object.toString()
    Object.wait()
    Object.wait(long)
    Object.wait(long,int)
    Namespace:
    Assembly: .dll
    Syntax
    public class NumberUtil

    Constructors

    NumberUtil()

    Declaration
    public NumberUtil()

    Methods

    constrain(double value, double lowerBound, double upperBound)

    Constrains the value to specified bounds

    Declaration
    public static double constrain(double value, double lowerBound, double upperBound)
    Parameters
    Type Name Description
    double value

    The value to constrain

    double lowerBound

    The lover bound

    double upperBound

    The upper bounds

    Returns
    Type Description
    double

    The constrained value

    constrain(float value, float lowerBound, float upperBound)

    Constrains the value to specified bounds

    Declaration
    public static float constrain(float value, float lowerBound, float upperBound)
    Parameters
    Type Name Description
    float value

    The value to constrain

    float lowerBound

    The lover bound

    float upperBound

    The upper bounds

    Returns
    Type Description
    float

    The constrained value

    constrain(int value, int lowerBound, int upperBound)

    Constrains the value to specified bounds

    Declaration
    public static int constrain(int value, int lowerBound, int upperBound)
    Parameters
    Type Name Description
    int value

    The value to constrain

    int lowerBound

    The lover bound

    int upperBound

    The upper bounds

    Returns
    Type Description
    int

    The constrained value

    constrain(long value, long lowerBound, long upperBound)

    Constrains the value to specified bounds

    Declaration
    public static long constrain(long value, long lowerBound, long upperBound)
    Parameters
    Type Name Description
    long value

    The value to constrain

    long lowerBound

    The lover bound

    long upperBound

    The upper bounds

    Returns
    Type Description
    long

    The constrained value

    isIntegerType(Class<?> type)

    Checks whether the specified type is an integer type

    Declaration
    public static boolean isIntegerType(Class<?> type)
    Parameters
    Type Name Description
    Class<?> type

    Type to check

    Returns
    Type Description
    boolean

    True is type is integer type

    Back to top © 2011-2025 SciChart. All rights reserved. | sitemap.xml