Uni-Logo

Function Contracts

back to Contracts

Function Contract

(TreatJS 1.x)

Description

FunctionContract ( objectContract, contract );

Parameters

objectContract, , ...
Object Contract.
range
Range Contract.

Simple Function Contract

(TreatJS 1.x)

Description

SimpleFunctionContract ( [contract1[, contract2[, ...]]], contractn );

Parameters

contract1, contract2, ...
Argument Contract.
contractn
Range Contract.

Advanced Function Contract

(TreatJS 1.x)

Description

AdvancedFunctionContract ( domain, range[, strict] );

Parameters

domain
JavaScript Array or JavaScript Object.
range
Range Contract.
strict
Invoke strict mode.