Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

Ranger Class Reference

Inheritance diagram for Ranger::

Function1 List of all members.

Public Methods

Object apply (Object stop)

Static Public Methods

OpenList range (Number start, Number stop, Number increment)

Detailed Description

A Ranger is a Function1 object that produces a list of number from a start number up to including the argument number. The start number is specified in the constructor. So a Ranger can be used as the argument to map or mappend, for example.

Definition at line 12 of file Ranger.java.


Member Function Documentation

Object Ranger::apply ( Object x ) [inline]
 

Apply this Ranger object to an Object x, which should be a Number. If x is not a number, a ClassCastException will be thrown.

Parameters:
x   the Object to which this function is applied
Returns:
a Double containing this Ranger's start times the argument's value

Reimplemented from Function1.

Definition at line 64 of file Ranger.java.

OpenList Ranger::range ( Number start,
Number stop,
Number increment ) [inline, static]
 

Create an ascending list beginning with start, up to and including stop.

Parameters:
_start   the starting Number to be used.
_stop   the ending Number to be used.
Returns:
a list consisting of start to stop, incremented by increment.

Definition at line 41 of file Ranger.java.


The documentation for this class was generated from the following file:
Generated at Wed Feb 19 23:28:37 2003 for OpenList by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001