Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| ESC/Java2 © 2003,2004,2005 David Cok and Joseph Kiniry © 2005 UCD Dublin © 2003,2004 Radboud University Nijmegen © 1999,2000 Compaq Computer Corporation © 1997,1998,1999 Digital Equipment Corporation All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## escjava.prover
Class SNil

    java.lang.Object
      escjava.prover.SExp
          escjava.prover.SList
              escjava.prover.SNil

final class SNil
extends SList

The single `SNil` instance represents the empty list of `SExp`s.

Field Summary
`private static SNil` | `single` The single instance of this class, or `null` if it has not yet been allocated.

Constructor Summary
`private` | `SNil()` Instance creation is private so we can ensure that at most one instance of this class is ever created.

Method Summary
`boolean` | `equals(java.lang.Object o)`
`static SNil` | `getNil()`
`boolean` | `isEmpty()`
`int` | `length()`

Methods inherited from class escjava.prover.SList
`addEnd, addFront, append, at, fromArray, getList, getPair, isList, main, make, make, make, make, make, make, make, make, make, prettyPrint, print, reverseD, setAt`

Methods inherited from class escjava.prover.SExp
`display, fancyMake, getAtom, getInteger, isAtom, isInteger, make, print, toString`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### single

    private static SNil single

  The single instance of this class, or `null` if it has not yet been allocated.

Constructor Detail

### SNil

    private SNil()

  Instance creation is private so we can ensure that at most one instance of this class is ever created.

Method Detail

### getNil

    public static SNil getNil()

  Returns:
    the single SNil instance.

### equals

    public boolean equals(java.lang.Object o)

  Returns:
    true if the parameter is also the single instance of SNil.

### isEmpty

    public boolean isEmpty()

  Specified by:
    `isEmpty` in class `SList`
  Returns:
    a flag indicating if we are we an empty list, which is always `true` since we are the nil instance.

### length

    public int length()

  Specified by:
    `length` in class `SList`
  Returns:
    our length, which is zero since we are the nil instance.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| ESC/Java2 © 2003,2004,2005 David Cok and Joseph Kiniry © 2005 UCD Dublin © 2003,2004 Radboud University Nijmegen © 1999,2000 Compaq Computer Corporation © 1997,1998,1999 Digital Equipment Corporation All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

The ESC/Java2 Project Homepage