| 1 | |
|---|
| 2 | :- protocol(systemp). |
|---|
| 3 | |
|---|
| 4 | |
|---|
| 5 | :- info([ |
|---|
| 6 | version is 1.0, |
|---|
| 7 | authors is 'Paulo Moura', |
|---|
| 8 | date is 2000/7/24, |
|---|
| 9 | comment is 'Operating system protocol.']). |
|---|
| 10 | |
|---|
| 11 | |
|---|
| 12 | :- public(make_directory/1). |
|---|
| 13 | |
|---|
| 14 | :- mode(make_directory(+atom), zero_or_one). |
|---|
| 15 | |
|---|
| 16 | :- info(make_directory/1, [ |
|---|
| 17 | comment is 'Make a new directory.', |
|---|
| 18 | argnames is ['Directory']]). |
|---|
| 19 | |
|---|
| 20 | |
|---|
| 21 | :- public(delete_directory/1). |
|---|
| 22 | |
|---|
| 23 | :- mode(delete_directory(+atom), zero_or_one). |
|---|
| 24 | |
|---|
| 25 | :- info(delete_directory/1, [ |
|---|
| 26 | comment is 'Delete a directory.', |
|---|
| 27 | argnames is ['Directory']]). |
|---|
| 28 | |
|---|
| 29 | |
|---|
| 30 | :- public(change_directory/1). |
|---|
| 31 | |
|---|
| 32 | :- mode(change_directory(+atom), zero_or_one). |
|---|
| 33 | |
|---|
| 34 | :- info(change_directory/1, [ |
|---|
| 35 | comment is 'Change working directory.', |
|---|
| 36 | argnames is ['Directory']]). |
|---|
| 37 | |
|---|
| 38 | |
|---|
| 39 | :- public(working_directory/1). |
|---|
| 40 | |
|---|
| 41 | :- mode(working_directory(?atom), zero_or_one). |
|---|
| 42 | |
|---|
| 43 | :- info(working_directory/1, [ |
|---|
| 44 | comment is 'Current working directory.', |
|---|
| 45 | argnames is ['Directory']]). |
|---|
| 46 | |
|---|
| 47 | |
|---|
| 48 | :- public(directory_files/2). |
|---|
| 49 | |
|---|
| 50 | :- mode(directory_files(+atom, -list), zero_or_one). |
|---|
| 51 | |
|---|
| 52 | :- info(directory_files/2, [ |
|---|
| 53 | comment is 'List of all directory files.', |
|---|
| 54 | argnames is ['Directory', 'Files']]). |
|---|
| 55 | |
|---|
| 56 | |
|---|
| 57 | :- public(file_exists/1). |
|---|
| 58 | |
|---|
| 59 | :- mode(file_exists(+atom), zero_or_one). |
|---|
| 60 | |
|---|
| 61 | :- info(file_exists/1, [ |
|---|
| 62 | comment is 'True if the specified file exists.', |
|---|
| 63 | argnames is ['File']]). |
|---|
| 64 | |
|---|
| 65 | |
|---|
| 66 | :- public(delete_file/1). |
|---|
| 67 | |
|---|
| 68 | :- mode(delete_file(?atom), zero_or_one). |
|---|
| 69 | |
|---|
| 70 | :- info(delete_file/1, [ |
|---|
| 71 | comment is 'Deletes a file.', |
|---|
| 72 | argnames is ['File']]). |
|---|
| 73 | |
|---|
| 74 | |
|---|
| 75 | :- public(rename_file/1). |
|---|
| 76 | |
|---|
| 77 | :- mode(rename_file(?atom), zero_or_one). |
|---|
| 78 | |
|---|
| 79 | :- info(rename_file/1, [ |
|---|
| 80 | comment is 'Renames a file.', |
|---|
| 81 | argnames is ['File']]). |
|---|
| 82 | |
|---|
| 83 | |
|---|
| 84 | :- end_protocol. |
|---|