This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
uf:proximities [2008/09/04 16:41] elisag created |
uf:proximities [2009/11/30 16:42] dharnie proper |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ===== Proximity ===== | ||
- | |||
- | Proximity is a “function” that determine whether or not a user is proximate. There are several predefined functions: | ||
- | * isNearby: physical proximity | ||
- | * isFriend: static encoding of friendship relationships | ||
- | * doesProfileMatch: | ||
- | |||
- | Other functions can be defined as combinations of existing functions by means or combinators: | ||
- | |||
- | As a first implementation of the RETE-network, | ||
- | |||
- | < | ||
- | def flockrTemplate := template: { | ||
- | def name := *; // wildcard, can be anything | ||
- | def age := constraint: { _ < 25 }; // must be younger than 25 | ||
- | def address := template: { | ||
- | def street := *; //any street,but street name must be filled | ||
- | def city := " | ||
- | }; | ||
- | def greet(); // person must have a greet method | ||
- | } taggedAs: [ Flockr ]; // object must be tagged as a Flockr | ||
- | </ | ||