NLI: Function: get

Background: NLI, Expressions, Functions
Related: Examples

Description:
The get function gets 0 to many things based on specified inputs.
When the function has one input, it returns specified thing if it exists in db.
When the function has two or more inputs, it returns specified sequence.
When the function has two or more inputs, one of them can be an asterisk.
The * identifies the sequence element to get.
When a get expression is submitted from the GUI, the returned things are highlighted successively in the tree.

General Format:
(get thing1 [thing2] ...)

Examples:
(; Get one thing)
(get john)

(; Get specified sequence)
(get john like mary)

(; Get all instances of person)
(get person instances *)

(; Following assumes db has data indicating that john's gender is male, mary's gender is female and male and female are opposites)
(; Get things whose gender is opposite john's)
(; Gets mary)
(get * gender (get (get john gender *) opposite *))

One way to interpret the above query is:
(get * gender Q1) where Q1 is (get Q2 opposite *) where Q2 is (get john gender *)

above simplifies to:
(get * gender Q1) where Q1 is (get Q2 opposite *) where Q2 is male

above simplifies to:
(get * gender Q1) where Q1 is (get male opposite *)

above simplifies to:
(get * gender Q1) where Q1 is female

above simplifies to:
(get * gender female)

above simplifies to:
mary

Notes:

CM ©2000-2007

air max polski

airmaxpolski

Tanie Nike Air Max