All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sas.util
Class IntegerRange

    com.sas.util.IntegerRange

All Implemented Interfaces:
  com.sas.beans.PropertyChangeSource, com.sas.beans.VetoableChangeSource, ComponentInterface, LinkPropertiesInterface, ModelInterface, BoundedNumberInterface, IncrementInterface, RangeInterface, com.sas.PublicClonable, IntegerRangeInterface, ViewInterface, MultipleValueEventSourceInterface, java.beans.PropertyChangeListener, java.io.ObjectInputValidation, java.io.Serializable, java.lang.Cloneable, java.util.EventListener

Deprecated. Use com.sas.models.BoundedLong

    public class IntegerRange

implements IntegerRangeInterface, com.sas.PublicClonable, BoundedNumberInterface

A IntegerRange is an implementation of IntegerRangeInterface. It stores an integer value between a range of integers, with a value for the default increment.

- blockIncrement
- maximum
- minimum
- unitIncrement
- value

Name | blockIncrement
Type | int
Default value | 10
Short Description | blockIncrement amount
Description | Amount by which the value changes for block increments/decrements.
Read method | int getBlockIncrement()
Write method | void setBlockIncrement(int)
Linkable | true
Compare value | true
Persist | true
FieldName | blockIncrement
Constrained | false
Property editor class |
Expert | false
Hidden | false

Name | maximum
Default value | 100
Short description | maximum value
Description | Maximum amount of range value.
Read method | int getMaximum()
Write method | void setMaximum(int)
Bound | true
Linkable | true
Compare value | true
Persist | true
FieldName | maximum
Constrained | false
Property editor class |
Expert | false
Hidden | false

Name | minimum
Default value |
Short description | minimum value
Description | Minimum amount of range value.
Read method | int getMinimum()
Write method | void setMinimum(int)
Bound | true
Linkable | true
Compare value | true
Persist | true
FieldName | minimum
Constrained | false
Property editor class |
Expert | false
Hidden | false

Name | unitIncrement
Default value | 1
Short description | unit increment
Description | amount the value increments for unit (single) increments/decrements
Read method | int getUnitIncrement()
Write method | void setunitIncrement(int)
Bound | true
Linkable | true
Compare value | true
Persist | true
FieldName | unitIncrement
Constrained | false
Property editor class |
Expert | false
Hidden | false

Name | value
Default value | 1
Short description | current value
Description | Value of range
Read method | int getValue()
Write method | void setValue(int)
Bound | true
Linkable | true
Compare value | true
Persist | true
FieldName | propertyFieldName
Constrained | false
Property editor class |
Expert | false
Hidden | false

See Also:
  `IntegerRangeInterface`, Serialized Form

Field Summary

Fields inherited from interface com.sas.models.IncrementInterface
`BLOCK, UNIT`

Constructor Summary
`IntegerRange()` Deprecated. Default constructor.
`IntegerRange(int value, int min, int max, int unit, int block)` Deprecated. Creates an integer range with the specified value, unitIncrement, blockIncrement, minimum, and maximum amounts.

Method Summary
`java.lang.Object` | `clone()` Deprecated. Clone an IntegerRange object
`boolean` | `equals(IntegerRange otherRange)` Deprecated. Compare to an IntegerRange object.
`boolean` | `equals(java.lang.Object object)` Deprecated. Compare to an object.
`int` | `getBlockIncrement()` Deprecated. Gets the block value increment for the adjustable object.
`java.lang.Number` | `getBlockIncrementNumber()` Deprecated. Gets the block value increment for the adjustable object.
`static com.sas.beans.ExtendedBeanInfo` | `getExtendedBeanInfo()` Deprecated.
`int` | `getMaximum()` Deprecated. Gets the maximum value of the adjustable object.
`java.lang.Number` | `getMaximumNumber()` Deprecated. Gets the maximum value of the integer range.
`int` | `getMinimum()` Deprecated. Gets the minimum value of the adjustable object.
`java.lang.Number` | `getMinimumNumber()` Deprecated. Gets the minimum value of the integer range.
`java.lang.Number` | `getNumberValue()` Deprecated. Gets the unit value increment for the adjustable object.
`int` | `getUnitIncrement()` Deprecated. Gets the unit value increment for the adjustable object.
`java.lang.Number` | `getUnitIncrementNumber()` Deprecated. Gets the unit value increment for the adjustable object.
`int` | `getValue()` Deprecated. Gets the current value of the adjustable object.
`java.lang.Number` | `incrementBy(int increment, int incrementType)` Deprecated. Increment, by unit or block increment amount, the current value by the specified number of increments.
`void` | `setBlockIncrement(int block)` Deprecated. Sets the block value increment for the adjustable object.
`void` | `setBlockIncrementNumber(java.lang.Number block)` Deprecated. Sets the block value increment for the adjustable object.
`void` | `setDefaultValues()` Deprecated. Set the default values of all the attributes
`void` | `setMaximum(int max)` Deprecated. Sets the maximum value of the adjustable object.
`void` | `setMaximumNumber(java.lang.Number max)` Deprecated. Sets the maximum value of the adjustable object.
`void` | `setMinimum(int min)` Deprecated. Sets the minimum value of the adjustable object.
`void` | `setMinimumNumber(java.lang.Number min)` Deprecated. Sets the minimum value of the adjustable object.
`void` | `setNumberValue(java.lang.Number newValue)` Deprecated. Sets the current value of the adjustable object.
`void` | `setNumberValues(java.lang.Number newValue, java.lang.Number min, java.lang.Number max)` Deprecated. Set the value, minimum and maximum at the same time.
`void` | `setNumberValues(java.lang.Number newValue, java.lang.Number min, java.lang.Number max, java.lang.Number unit, java.lang.Number block)` Deprecated. Set the value, minimum and maximum at the same time.
`void` | `setUnitIncrement(int unit)` Deprecated. Sets the unit value increment for the adjustable object.
`void` | `setUnitIncrementNumber(java.lang.Number unit)` Deprecated. Sets the unit value increment for the adjustable object.
`void` | `setValue(int newValue)` Deprecated. Sets the current value of the adjustable object.
`void` | `setValues(int value, int min, int max)` Deprecated. Set the value, minimum and maximum at the same time.
`void` | `setValues(int value, int min, int max, int unit, int block)` Deprecated. Set the value, minimum and maximum at the same time.
`java.lang.String` | `toString()` Deprecated. Return a string representation of an IntegerRange

Methods inherited from class com.sas.Component
`addLink, addPropertyChangeListener, addVetoableChangeListener, anyPropertyChangeListeners, attachModel, attachView, beansIsDesignTime, beansSetDesignTime, clone, detachModel, detachView, dumpComponent, firePropertyChange, firePropertyChange, fireVetoableChange, getComponentDescription, getComponentSupportInfo, getEventMethod, getEventValues, getLinkInfo, getModelInterface, getRequiredInterfaces, getResources, getStringResource, getViewInterfaceSupportInfo, initialize, initializeComponent, isDesignTime, isLinked, propertyChange, queryLinks, queryLinks, refresh, removeAllLinks, removeInterfaceTraps, removeLink, removePropertyChangeListener, removeVetoableChangeListener, setComponentDescription, setComponentSupportInfo, setLinkInfo, setModelInterface, setRequiredInterfaces, setViewInterfaceSupportInfo, supportsListenerInterface, supportsRequiredInterfaces, trapInterfaceEvents, validateObject`

Constructor Detail

### IntegerRange

    public IntegerRange()

  Deprecated.
  Default constructor.

### IntegerRange

    public IntegerRange(int value,
                        int min,
                        int max,
                        int unit,
                        int block)

  Deprecated.
  Creates an integer range with the specified value, unitIncrement, blockIncrement, minimum, and maximum amounts.

  Parameters:
    `value` - initial value. If value < min it is set to min; if value > max, it is set to max
    `min` - minimum value
    `max` - maximum value
    `unit` - unit increment
    `block` - block increment
  Throws:
    `java.lang.IllegalArgumentException` - if (min > max), (unit < 0), (block < 0), (unit > range) or (block > range), where range = (max - min)

Method Detail

### getExtendedBeanInfo

    public static com.sas.beans.ExtendedBeanInfo getExtendedBeanInfo()

  Deprecated.

### equals

    public boolean equals(java.lang.Object object)

  Deprecated.
  Compare to an object.

  Overrides:
    `equals` in class `java.lang.Object`
  Parameters:
    `object` - another object
  Returns:
    true if the other object is an IntegerRage and the minimum, value, maximum, unit increment, and block increment equal; false otherwise.

### clone

    public java.lang.Object clone()
                           throws java.lang.CloneNotSupportedException

  Deprecated.
  Clone an IntegerRange object

  Specified by:
    `clone` in interface `com.sas.PublicClonable`
  Overrides:
    `clone` in class `Component`
  Returns:
    a clone of this object.
  Throws:
    `java.lang.CloneNotSupportedException` - if there is a clone exception.

### equals

    public boolean equals(IntegerRange otherRange)

  Deprecated.
  Compare to an IntegerRange object.

  Parameters:
    `otherRange` - another IntegerRange object
  Returns:
    true if the other object is not null and the minimum, value, maximum, unit increment, and block increment equal; false otherwise.

### toString

    public java.lang.String toString()

  Deprecated.
  Return a string representation of an IntegerRange

  Overrides:
    `toString` in class `java.lang.Object`
  Returns:
    the string in the format "[min,value,max],unit,block"

### setDefaultValues

    public void setDefaultValues()

  Deprecated.
  Set the default values of all the attributes

  Specified by:
    `setDefaultValues` in interface `ComponentInterface`
  Overrides:
    `setDefaultValues` in class `Component`
  See Also:
    `ComponentInterface.setDefaultValues()`

### getMaximum

    public int getMaximum()

  Deprecated.
  Gets the maximum value of the adjustable object.

  Specified by:
    `getMaximum` in interface `IntegerRangeInterface`
  Returns:
    the current range maximum

### getMinimum

    public int getMinimum()

  Deprecated.
  Gets the minimum value of the adjustable object.

  Specified by:
    `getMinimum` in interface `IntegerRangeInterface`
  Returns:
    the current range minimum

### getBlockIncrement

    public int getBlockIncrement()

  Deprecated.
  Gets the block value increment for the adjustable object.

  Specified by:
    `getBlockIncrement` in interface `IntegerRangeInterface`
  Returns:
    the current block increment

### getUnitIncrement

    public int getUnitIncrement()

  Deprecated.
  Gets the unit value increment for the adjustable object.

  Specified by:
    `getUnitIncrement` in interface `IntegerRangeInterface`
  Returns:
    the current unit increment

### getValue

    public int getValue()

  Deprecated.
  Gets the current value of the adjustable object.

  Specified by:
    `getValue` in interface `IntegerRangeInterface`
  Returns:
    the current value

### incrementBy

    public java.lang.Number incrementBy(int increment,
                                        int incrementType)

  Deprecated.
  Increment, by unit or block increment amount, the current value by the specified number of increments. The current value will be incremented( or decremented ) within the bounds of the maximum and minimum values.

  Specified by:
    `incrementBy` in interface `IncrementInterface`
  Specified by:
    `incrementBy` in interface `IntegerRangeInterface`
  Parameters:
    `increment` - The number of incrementType(unit or block) amounts to increment the current value(can be negative to decrement value).
    `incrementType` - UNIT to increment by the unit amount; BLOCK to increment by the block amount
  Returns:
    the new current value

### setMaximum

    public void setMaximum(int max)

  Deprecated.
  Sets the maximum value of the adjustable object. The maximum value is included in the range of the value. If the value is currently higher than the new maximum, it will be set to the maximum value.

  Specified by:
    `setMaximum` in interface `IntegerRangeInterface`
  Parameters:
    `max` - the maximum value
  Throws:
    `java.lang.IllegalArgumentException` - if max < minimum

### setMinimum

    public void setMinimum(int min)

  Deprecated.
  Sets the minimum value of the adjustable object. The minimum value is included in the range of the value. If the value is currently lower than the new minimum, it will be set to the maximum value.

  Specified by:
    `setMinimum` in interface `IntegerRangeInterface`
  Parameters:
    `min` - the minimum value
  Throws:
    `java.lang.IllegalArgumentException` - if min > maximum

### setBlockIncrement

    public void setBlockIncrement(int block)

  Deprecated.
  Sets the block value increment for the adjustable object.

  Specified by:
    `setBlockIncrement` in interface `IntegerRangeInterface`
  Parameters:
    `block` - the block increment
  Throws:
    `java.lang.IllegalArgumentException` - if (block < 0) or (block > (maximum - minimum))

### setUnitIncrement

    public void setUnitIncrement(int unit)

  Deprecated.
  Sets the unit value increment for the adjustable object.

  Specified by:
    `setUnitIncrement` in interface `IntegerRangeInterface`
  Parameters:
    `unit` - the unit increment
  Throws:
    `java.lang.IllegalArgumentException` - if (unit < 0) or (unit > (maximum - minimum))

### setValue

    public void setValue(int newValue)

  Deprecated.
  Sets the current value of the adjustable object. The current value will only be set to within the range of the minimum and maximum values.

  Specified by:
    `setValue` in interface `IntegerRangeInterface`
  Parameters:
    `value` - the current value

### setValues

    public void setValues(int value,
                          int min,
                          int max)

  Deprecated.
  Set the value, minimum and maximum at the same time.

  Specified by:
    `setValues` in interface `IntegerRangeInterface`
  Parameters:
    `value` - the new value
    `min` - the new minimum
    `max` - the new maximum
  Throws:
    `java.lang.IllegalArgumentException` - if (min > max), (unit < 0), (block < 0), (unit > range) or (block > range), where range = (max - min)

### setValues

    public void setValues(int value,
                          int min,
                          int max,
                          int unit,
                          int block)

  Deprecated.
  Set the value, minimum and maximum at the same time.

  Specified by:
    `setValues` in interface `IntegerRangeInterface`
  Parameters:
    `value` - the new value
    `min` - the new minimum
    `max` - the new maximum
    `unit` - the new unit increment
    `block` - the new block increment
  Throws:
    `java.lang.IllegalArgumentException` - if (min > max), (unit < 0), (block < 0), (unit > range) or (block > range), where range = (max - min)

### getMaximumNumber

    public java.lang.Number getMaximumNumber()

  Deprecated.
  Gets the maximum value of the integer range.

  Specified by:
    `getMaximumNumber` in interface `RangeInterface`
  Returns:
    the current range maximum

### getMinimumNumber

    public java.lang.Number getMinimumNumber()

  Deprecated.
  Gets the minimum value of the integer range.

  Specified by:
    `getMinimumNumber` in interface `RangeInterface`
  Returns:
    the current range minimum

### getBlockIncrementNumber

    public java.lang.Number getBlockIncrementNumber()

  Deprecated.
  Gets the block value increment for the adjustable object.

  Specified by:
    `getBlockIncrementNumber` in interface `IncrementInterface`
  Returns:
    the current block increment

### getUnitIncrementNumber

    public java.lang.Number getUnitIncrementNumber()

  Deprecated.
  Gets the unit value increment for the adjustable object.

  Specified by:
    `getUnitIncrementNumber` in interface `IncrementInterface`
  Returns:
    the current unit increment

### getNumberValue

    public java.lang.Number getNumberValue()

  Deprecated.
  Gets the unit value increment for the adjustable object.

  Specified by:
    `getNumberValue` in interface `BoundedNumberInterface`
  Returns:
    the current unit increment

### setMaximumNumber

    public void setMaximumNumber(java.lang.Number max)

  Deprecated.
  Sets the maximum value of the adjustable object. The maximum value is included in the range of the value. If the value is currently higher than the new maximum, it will be set to the maximum value.

  Specified by:
    `setMaximumNumber` in interface `RangeInterface`
  Parameters:
    `max` - the maximum value
  Throws:
    `java.lang.IllegalArgumentException` - if max < minimum

### setMinimumNumber

    public void setMinimumNumber(java.lang.Number min)

  Deprecated.
  Sets the minimum value of the adjustable object. The minimum value is included in the range of the value. If the value is currently lower than the new minimum, it will be set to the maximum value.

  Specified by:
    `setMinimumNumber` in interface `RangeInterface`
  Parameters:
    `min` - the minimum value
  Throws:
    `java.lang.IllegalArgumentException` - if min > maximum

### setBlockIncrementNumber

    public void setBlockIncrementNumber(java.lang.Number block)

  Deprecated.
  Sets the block value increment for the adjustable object.

  Specified by:
    `setBlockIncrementNumber` in interface `IncrementInterface`
  Parameters:
    `block` - the block increment
  Throws:
    `java.lang.IllegalArgumentException` - if (block < 0) or (block > (maximum - minimum))

### setUnitIncrementNumber

    public void setUnitIncrementNumber(java.lang.Number unit)

  Deprecated.
  Sets the unit value increment for the adjustable object.

  Specified by:
    `setUnitIncrementNumber` in interface `IncrementInterface`
  Parameters:
    `unit` - the unit increment
  Throws:
    `java.lang.IllegalArgumentException` - if (unit < 0) or (unit > (maximum - minimum))

### setNumberValue

    public void setNumberValue(java.lang.Number newValue)

  Deprecated.
  Sets the current value of the adjustable object. The current value will only be set to within the range of the minimum and maximum values.

  Specified by:
    `setNumberValue` in interface `BoundedNumberInterface`
  Parameters:
    `value` - the current value

### setNumberValues

    public void setNumberValues(java.lang.Number newValue,
                                java.lang.Number min,
                                java.lang.Number max)

  Deprecated.
  Set the value, minimum and maximum at the same time.

  Specified by:
    `setNumberValues` in interface `BoundedNumberInterface`
  Parameters:
    `value` - the new value
    `min` - the new minimum
    `max` - the new maximum
  Throws:
    `java.lang.IllegalArgumentException` - if (min > max), (unit < 0), (block < 0), (unit > range) or (block > range), where range = (max - min)

### setNumberValues

    public void setNumberValues(java.lang.Number newValue,
                                java.lang.Number min,
                                java.lang.Number max,
                                java.lang.Number unit,
                                java.lang.Number block)

  Deprecated.
  Set the value, minimum and maximum at the same time.

  Specified by:
    `setNumberValues` in interface `BoundedNumberInterface`
  Parameters:
    `value` - the new value
    `min` - the new minimum
    `max` - the new maximum
    `unit` - the new unit increment
    `block` - the new block increment
  Throws:
    `java.lang.IllegalArgumentException` - if (min > max), (unit < 0), (block < 0), (unit > range) or (block > range), where range = (max - min)

All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SAS Institute Inc. All Rights Reserved.