object

# streamvars

> Stream variables (supporting logical, backtracable, adding and retrieving of terms).

author:
  `Nobukuni Kino and Paulo Moura`
version:
  `1.0`
date:
  `2011/8/17`

compilation flags:
  `static, context_switching_calls`

(no dependencies on other files)

## Public interface

### new/1

> Makes Variable a stream variable. Initial state will be empty.

compilation flags:
  `static`
template:
  `new(Variable)`
mode – number of proofs:
  `new(-streamvar) – one`
exceptions:
  Variable is not a variable: `type_error(variable,Variable)`

### new/2

> Makes Variable a stream variable and sets its initial state to Value.

compilation flags:
  `static`
template:
  `new(Variable,Value)`
mode – number of proofs:
  `new(-streamvar,@nonvar) – one`
exceptions:
  Variable is not a variable: `type_error(variable,Variable)`

### (<=)/2

> Sets the state of the stream variable Variable to Value (initializing the variable if needed).

compilation flags:
  `static`
template:
  `Variable<=Value`
mode – number of proofs:
  `(?streamvar)<= (@nonvar) – one`

### (=>)/2

> Unifies Value with the current state of the stream variable Variable.

compilation flags:
  `static`
template:
  `Variable=>Value`
mode – number of proofs:
  `(+streamvar)=> (?nonvar) – zero_or_one`

## Protected interface

(none)

## Private predicates

(none)

## Operators

### op(100,xfx,<=) (public)

### op(100,xfx,=>) (public)

## Remarks

### (none)