|
Revision 365, 1.2 KB
(checked in by pmoura, 6 years ago)
|
|
Changed "authors" key in info/1 directive to "author".
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Author Date Id Revision
|
| Line | |
|---|
| 1 | |
|---|
| 2 | :- protocol(hierarchyp). |
|---|
| 3 | |
|---|
| 4 | |
|---|
| 5 | :- info([ |
|---|
| 6 | version is 1.0, |
|---|
| 7 | author is 'Paulo Moura', |
|---|
| 8 | date is 2000/7/24, |
|---|
| 9 | comment is 'Common hierarchy protocol for prototype and class hierarchies.']). |
|---|
| 10 | |
|---|
| 11 | |
|---|
| 12 | :- public(ancestor/1). |
|---|
| 13 | |
|---|
| 14 | :- mode(ancestor(?object), zero_or_more). |
|---|
| 15 | |
|---|
| 16 | :- info(ancestor/1, [ |
|---|
| 17 | comment is 'Returns, by backtracking, all object ancestors.', |
|---|
| 18 | argnames is ['Ancestor']]). |
|---|
| 19 | |
|---|
| 20 | |
|---|
| 21 | :- public(ancestors/1). |
|---|
| 22 | |
|---|
| 23 | :- mode(ancestors(-list), one). |
|---|
| 24 | |
|---|
| 25 | :- info(ancestors/1, [ |
|---|
| 26 | comment is 'List of all object ancestors.', |
|---|
| 27 | argnames is ['Ancestors']]). |
|---|
| 28 | |
|---|
| 29 | |
|---|
| 30 | :- public(leaf/1). |
|---|
| 31 | |
|---|
| 32 | :- mode(leaf(?object), zero_or_more). |
|---|
| 33 | |
|---|
| 34 | :- info(leaf/1, [ |
|---|
| 35 | comment is 'Returns, by backtracking, all object leaves.', |
|---|
| 36 | argnames is ['Leaf']]). |
|---|
| 37 | |
|---|
| 38 | |
|---|
| 39 | :- public(leaves/1). |
|---|
| 40 | |
|---|
| 41 | :- mode(leaves(-list), one). |
|---|
| 42 | |
|---|
| 43 | :- info(leaves/1, [ |
|---|
| 44 | comment is 'List of all object leaves.', |
|---|
| 45 | argnames is ['Leaves']]). |
|---|
| 46 | |
|---|
| 47 | |
|---|
| 48 | :- public(descendant/1). |
|---|
| 49 | |
|---|
| 50 | :- mode(descendant(?object), zero_or_more). |
|---|
| 51 | |
|---|
| 52 | :- info(descendant/1, [ |
|---|
| 53 | comment is 'Returns, by backtracking, all object descendants.', |
|---|
| 54 | argnames is ['Descendant']]). |
|---|
| 55 | |
|---|
| 56 | |
|---|
| 57 | :- public(descendants/1). |
|---|
| 58 | |
|---|
| 59 | :- mode(descendants(-list), one). |
|---|
| 60 | |
|---|
| 61 | :- info(descendants/1, [ |
|---|
| 62 | comment is 'List of all object descendants.', |
|---|
| 63 | argnames is ['Descendants']]). |
|---|
| 64 | |
|---|
| 65 | |
|---|
| 66 | :- end_protocol. |
|---|