User Tools

Site Tools


Sidebar

Jump to
AmbientTalk
CRIME
iScheme

crime:examples

This is an old revision of the document!


Example Applications

The CRIME distribution comes with a suite of example applications, most of which are implemented in Java. This page describes the provided applications, how to deploy them, describes the rules they use internally and provides pointers on how to extend them.

IN/OUT Board

The IN/OUT Board is a classical context-aware application proposed by Dey et al. during their work on the context toolkit. The system visualises the location of a user (which are expected to be public facts) and derives the nearest phone to that user. When users are out of reach, the application keeps a record of when the user was last seen by the system.

Deploying the application. (available soon)
The CRIME distribution contains a script file inout.sh which launches the IN/OUT Board application which internally starts a CRIME engine. The CRIME engine will evaluate the rules specified below.
:edu.vub.crime.examples.board.SetBoard(?name, ?room, ?number) :-
	person(?id, ?name, student),
	location(?id, ?room),
	phone(?room, ?number).
	
	
:edu.vub.crime.examples.board.HistoryBoard(?name, ?room, ?phone, ?time) :-
	history(?name, ?room, ?phone, ?time).
	

:edu.vub.crime.examples.board.Notify(?name, ?room, ?number) :-
	location(?id, ?room),
	person(?id, ?name, ?type),
	phone(?room, ?number),
	notify(?name, ?room).
	

The rules above trigger the application events SetBoard, HistoryBoard and Notify. In CRIME all application events are to be prefixed with a colon.

crime/examples.1173802788.txt.gz · Last modified: 2007/03/13 22:57 (external edit)