Null (query directive)

From WandoraWiki
Revision as of 10:39, 21 August 2009 by Olli (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Description

Returns then null value

Constructor

Null()

Examples

Following example gets the superclass of input topic or null if it does not have a superclass.
importPackage(org.wandora.query2);
importPackage(org.wandora.topicmap);
new If(
  new Players(XTMPSI.SUPERCLASS_SUBCLASS,XTMPSI.SUPERCLASS)
  .whereInputIs(XTMPSI.SUBCLASS),
  new Players(XTMPSI.SUPERCLASS_SUBCLASS,XTMPSI.SUPERCLASS)
  .whereInputIs(XTMPSI.SUBCLASS),
  new Null().as(XTMPSI.SUPERCLASS)
)