Skip to content

RangeWithValue

Under Construction

This documentation is auto-generated, and is a work in progress. Please see the source code at https://github.com/phetsims/dot/blob/main/js/RangeWithValue.ts for the most up-to-date information.

Overview

A numeric range with a required default value.

@author Chris Malley (PixelZoom, Inc.) @author Chris Klusendorf (PhET Interactive Simulations)

Class RangeWithValue

import { RangeWithValue } from 'scenerystack/dot';

Constructor

new RangeWithValue( min : number, max : number, defaultValue : number )

Instance Methods

getDefaultValue() : number

Getter for defaultValue

setMin( min : number )

Setter for min

setMax( max : number )

Setter for max

setMinMax( min : number, max : number ) : this

Setter for min and max

toString() : string

Converts the attributes of this range to a string

equals( object : IntentionalAny ) : boolean

Determines if this RangeWithValue is equal to some object.

Source Code

See the source for RangeWithValue.ts in the dot repository.