NLI: Function: new

Background: NLI, Expressions, Functions
Related: Examples

The new function creates a new thing in the database to represent desired thing {ie john, mary, etc}.
The last new thing can be referenced by the it function in subsequent expressions.

General Format:
(new ['name] ['class1] ['class2] ...)

The first input names the new thing.
The second and remaining inputs specify the new thing's classes.
If the specified classes do not exist, they are created.

(new 'john)
(new 'mary 'person)
(new 'bob 'person 'doctor)

The expression (new 'mary 'person) is shorthand for following, assuming the class person did not already exist:

(; Create a db item named person)
(set db item (it))
(set (it) name 'person)

(; Create a person named mary)
(set person instance (it))
(set (it) name 'mary)

The creation of rolex replica the watch is inspired by the retro and elegant money of rolex replica watches the brand's round watch. The chronograph is omega replica simple and stylish, with the line features of rolex replica uk the watch series.

CM ©2000-2007