Last updated

API / geotoolkit / contour / scale / RegularContourScale / RegularContourScale

Class: RegularContourScale

scale.RegularContourScale.RegularContourScale

Implements the ContourScale interface for a regular contour scale. I.e. all contour values are evenly spaced. Note: The step and count parameters must be positive or an exception will be thrown.

Hierarchy

Table of contents

Constructors
[new RegularContourScale(range, numberOfLevels)](/solutions/geotoolkit/apis/classes/geotoolkit.contour.scale.regularcontourscale.regularcontourscale.md#new regularcontourscale(range, numberoflevels))[new RegularContourScale(zero, step, count)](/solutions/geotoolkit/apis/classes/geotoolkit.contour.scale.regularcontourscale.regularcontourscale.md#new regularcontourscale(zero, step, count))
Methods

Contents

Constructors

new RegularContourScale(range, numberOfLevels)

new RegularContourScale(range, numberOfLevels)

Parameters

Name Type
rangeRange
numberOfLevelsnumber

Overrides

ContourScale.constructor


new RegularContourScale(zero, step, count)

new RegularContourScale(zero, step, count?)

Parameters

Name Type Description
zeronumberThe first (lowest) contour value
stepnumberThe interval between successive contours
Optional countnumberThe total number of contour isolines (intervals = count+1)

Overrides

ContourScale.constructor

Methods

getClassName

getClassName(): string

Returns

string

Inherited from

ContourScale.getClassName


getCount

getCount(): number

The number of intervals in this scale (=#values + 1: intervals to +/- infinity are included

Returns

number

size The number of intervals in this scale

Overrides

ContourScale.getCount


getIndex

getIndex(zValue): number

Finds the contour index representing the supplied z-value.

Parameters

Name Type Description
zValuenumberz-value for which contour index has to be found

Returns

number

index The contour index to which the z value belongs

Overrides

ContourScale.getIndex


getProperties

getProperties(): AnyRecord

Gets the scale properties

Returns

AnyRecord

properties Scale properties

Inherited from

ContourScale.getProperties


getRange

getRange(index?): Range

Returns the full range of values in the contour scale if called with no argument or returns the range of values represented by the supplied contour index.

Throws

if index argument less than zero or greater than array length

Parameters

Name Type Description
Optional indexnumberThe contour index for which to find the z-value range.

Returns

Range

range The full range of this scale.

Overrides

ContourScale.getRange


setProperties

setProperties(properties): RegularContourScale

Sets the scale properties

Parameters

Name Type Description
propertiesAnyRecordscale properties

Returns

RegularContourScale

this

Inherited from

ContourScale.setProperties


getClassName

Static getClassName(): string

Returns

string

Inherited from

ContourScale.getClassName