Miscellaneous Docs
Fall 2026
API

# o1.time

package o1.time

## Members list

### Type members

#### Classlikes

class Interval(val `start`: Moment, val `end`: Moment)

Each instance of the class `Interval` represents an interval — an inclusive range — on a timescale. An interval has a “start moment” and an “end moment”, represented as `Moment` objects. An interval always contains at least a single moment.

Each instance of the class `Interval` represents an interval — an inclusive range — on a timescale. An interval has a “start moment” and an “end moment”, represented as `Moment` objects. An interval always contains at least a single moment.

An interval object may be used to represent a range of years, a range of months, etc., as desired

An `Interval` object is immutable after it has been created. That is, its state can not be changed in any way.

## Parameters

end

  the end of the interval (that is, the last moment included in the interval); equal to or higher than `start`

start

  the start of the interval (that is, the first moment included in the interval)

## Attributes

Supertypes
  class Object
  trait Matchable
  class Any

class Moment(`time`: Int)

Each instance of the class `Moment` represents a “moment” on a timescale, identified by an integer number.

Each instance of the class `Moment` represents a “moment” on a timescale, identified by an integer number.

Different timescales may be used in different contexts. `Moment` objects could be used to represent different years, months, dates, hours, etc., depending on what is desired.

A `Moment` object is immutable after it has been created. That is, its state can not be changed in any way.

## Parameters

time

  an integer indicating which moment the object should represent (2026, for instance)

## Attributes

Supertypes
  class Object
  trait Matchable
  class Any

final class timeTest

## Attributes

Supertypes
  class Object
  trait Matchable
  class Any

### Value members

#### Concrete methods

def timeTest(): Nothing

A function that uses the classes `Moment` and `Interval` in some way that the student decides.

A function that uses the classes `Moment` and `Interval` in some way that the student decides.

## Attributes