docs/ikteam: Delete most files.
[haiku.git] / docs / develop / servers / registrar / Protocols
blob4360e6b9b825a1b92be143a00f98931f764a8cca
1 Protocols
2 =========
4 Standard Replies
5 ----------------
7 standard success reply message
9 reply:          B_REG_SUCCESS
10                         [ <additional fields> ]
12 fields:
13 - <additional fields>: Request-specific fields.
15 -----------------------------------------------------------------------
17 standard error reply message
19 reply:          B_REG_ERROR
20                         "error": B_INT32_TYPE
21                         [ "error_description": B_STRING_TYPE ]
22                         [ <additional fields> ]
24 fields:
25 - "error": The error code (a status_t).
26 - "error_description": Optional human readable description.
27 - <additional fields>: Request-specific fields.
29 -----------------------------------------------------------------------
31 standard general result reply message
33 reply:          B_REG_RESULT
34                         "result": B_INT32_TYPE
35                         [ "result_description": B_STRING_TYPE ]
36                         [ <additional fields> ]
37                           
38 fields:
39 - "result": The result value (a status_t).
40 - "result_description": Optional human readable description.
41 - <additional fields>: Request-specific fields.
43 -----------------------------------------------------------------------
46 General Requests
47 ----------------
49 getting the messengers for MIME, clipboard and disk device management
50 respectively
52 target:         registrar app looper (preferred handler)
53 message:        B_REG_GET_MIME_MESSENGER/B_REG_GET_CLIPBOARD_MESSENGER
54                         /B_REG_GET_DISK_DEVICE_MESSENGER
55 reply:          standard success
56                         "messenger": B_MESSENGER_TYPE
57 on error:       - B_NO_REPLY (fatal)
58                         - standard error (fatal)
60 reply fields:
61 - "messenger": The requested messenger.
63 -----------------------------------------------------------------------
65 shut down
67 target:         registrar app looper (preferred handler)
68 message:        B_REG_SHUT_DOWN
69                         "reboot":                       B_BOOL_TYPE
70                         "confirm":                      B_BOOL_TYPE
71                         "synchronously":        B_BOOL_TYPE
72 reply:          standard success
73 on error:       - B_NO_REPLY (fatal)
74                         - standard error (fatal)
76 message fields:
77 - "reboot": If true, the system reboots instead of turning the power off.
78 - "confirm": If true, the user will be asked to confirm to shut down the system.
79 - "synchronously": If true, the request sender gets a reply only, if the
80                                    shutdown process fails. Otherwise the reply will be sent
81                                    right before asking the user for confirmation (if desired).
83 -----------------------------------------------------------------------
86 Roster Requests
87 ---------------
89 app registration (BRoster::AddApplication())
91 target:         roster
92 message:        B_REG_ADD_APP
93                         "signature":                    B_MIME_STRING_TYPE
94                         "ref":                                  B_REF_TYPE
95                         "flags":                                B_UINT32_TYPE
96                         "team":                                 B_INT32_TYPE
97                         "thread":                               B_INT32_TYPE
98                         "port":                                 B_INT32_TYPE
99                         "full_registration":    B_BOOL_TYPE
100 reply:          standard success
101                         [ "token":                              B_INT32_TYPE ]
102                         [ "other_team":                 B_INT32_TYPE ]
103 on error:       - B_NO_REPLY (fatal)
104                         - standard error
106 message fields:
107 - "signature": The application signature.
108 - "ref": An entry_ref to the application executable.
109 - "flags": The application flags.
110 - "team": The application team (team_id).
111 - "port": The app looper port (port_id).
112 - "full_registration": Whether full or pre-registration is requested.
114 reply fields:
115 - "token": If pre-registration was requested (uint32). Unique token to be
116   passed to BRoster::SetThreadAndTeam().
117 - "other_team": For single/exclusive launch applications that are launched
118   the second time. The team ID of the already running instance (team_id).
120 error reply fields:
121 - "error":
122   - B_BAD_VALUE: A request message field is missing or contains an
123     invalid value.
124   - B_ENTRY_NOT_FOUND: The entry_ref doesn't refer to a file.
125   - B_ALREADY_RUNNING: For single/exclusive launch applications
126     that are launched the second time.
127   - B_REG_ALREADY_REGISTERED: The team is already registered.
128   - ...
130 -----------------------------------------------------------------------
132 app registration (BRoster::CompleteRegistration())
134 target:         roster
135 message:        B_REG_COMPLETE_REGISTRATION
136                         "team":         B_INT32_TYPE
137                         "thread":       B_INT32_TYPE
138                         "port":         B_INT32_TYPE
139 reply:          standard success
140 on error:       - B_NO_REPLY (fatal)
141                         - standard error
143 message fields:
144 - "team": The application team (team_id).
145 - "thread": The application looper thread (thread_id).
146 - "port": The app looper port (port_id).
148 error reply fields:
149 - "error":
150   - B_BAD_VALUE: A request message field is missing or contains an
151     invalid value.
152   - B_REG_APP_NOT_PRE_REGISTERED: The team is unknown to the roster or the
153     application is already fully registered.
154   - ...
156 -----------------------------------------------------------------------
158 app registration check (BRoster::IsAppRegistered())
160 target:         roster
161 message:        B_REG_IS_APP_REGISTERED
162                         "ref":          B_REF_TYPE
163                         ( "team":       B_INT32_TYPE
164                         | "token":      B_INT32_TYPE )
165 reply:          standard success
166                         "registered":           B_BOOL_TYPE
167                         "pre-registered":       B_BOOL_TYPE
168                         [ "app_info":           flattened app_info ]
169 on error:       - B_NO_REPLY (fatal)
170                         - standard error
172 message fields:
173 - "ref": An entry_ref to the application executable.
174 - "team": The application team (team_id).
175 - "token": The application's preregistration token.
177 reply fields:
178 - "registered": true, if the app is (pre-)registered, false otherwise.
179 - "pre-registered": true, if the app is pre-registered, false otherwise.
180 - "app_info": Flattened app info, if the app is known (i.e. (pre-)registered).
182 error reply fields:
183 - "error":
184   - B_BAD_VALUE: A request message field is missing or contains an
185     invalid value.
186   - B_ENTRY_NOT_FOUND: The entry_ref doesn't refer to a file.
187   - ...
189 -----------------------------------------------------------------------
191 pre-registrated app unregistration (BRoster::RemovePreRegApp())
193 target:         roster
194 message:        B_REG_REMOVE_PRE_REGISTERED_APP
195                         "token":        B_INT32_TYPE
196 reply:          standard success
197 on error:       - B_NO_REPLY (fatal)
198                         - standard error
200 message fields:
201 - "token": The token BRoster::AddApplication() returned (uint32).
203 error reply fields:
204 - "error":
205   - B_BAD_VALUE: A request message field is missing or contains an
206     invalid value.
207   - B_REG_APP_NOT_PRE_REGISTERED: The token does not identify a pre-registered
208     application.
209   - ...
211 -----------------------------------------------------------------------
213 app unregistration (BRoster::RemoveApp())
215 target:         roster
216 message:        B_REG_REMOVE_APP
217                         "team": B_INT32_TYPE
218 reply:          standard success
219 on error:       - B_NO_REPLY (fatal)
220                         - standard error
222 message fields:
223 - "team": The application team (team_id).
225 error reply fields:
226 - "error":
227   - B_BAD_VALUE: A request message field is missing or contains an
228     invalid value.
229   - B_REG_APP_NOT_REGISTERED: The team is unknown to the roster.
230   - ...
232 -----------------------------------------------------------------------
234 app pre-registration, set thread/team (BRoster::SetThreadAndTeam())
236 target:         roster
237 message:        B_REG_SET_THREAD_AND_TEAM
238                         "token":        B_INT32_TYPE
239                         "team":         B_INT32_TYPE
240                         "thread":       B_INT32_TYPE
241 reply:          standard success
242 on error:       - B_NO_REPLY (fatal)
243                         - standard error
245 message fields:
246 - "token": The token BRoster::AddApplication() returned (uint32).
247 - "team": The application team (team_id).
248 - "thread": The application looper thread (thread_id).
250 error reply fields:
251 - "error":
252   - B_BAD_VALUE: A request message field is missing or contains an
253     invalid value.
254   - B_REG_APP_NOT_PRE_REGISTERED: The token does not identify a pre-registered
255     application.
256   - ...
258 -----------------------------------------------------------------------
260 app registration, change app signature (BRoster::SetSignature())
262 target:         roster
263 message:        B_REG_SET_SIGNATURE
264                         "team":                 B_INT32_TYPE
265                         "signature":    B_STRING_TYPE
266 reply:          standard success
267 on error:       - B_NO_REPLY (fatal)
268                         - standard error
270 message fields:
271 - "team": The application team (team_id).
272 - "signature": The application's new signature.
274 error reply fields:
275 - "error":
276   - B_BAD_VALUE: A request message field is missing or contains an
277     invalid value.
278   - B_REG_APP_NOT_REGISTERED: The team does not identify a registered
279     application.
280   - ...
282 -----------------------------------------------------------------------
284 get an app info (BRoster::Get{Running,Active,}AppInfo())
286 target:         roster
287 message:        B_REG_GET_APP_INFO
288                         [ "team":                       B_INT32_TYPE
289                           | "ref":                      B_REF_TYPE
290                           | "signature":        B_STRING_TYPE ]
291 reply:          standard success
292                         "app_info":     B_REG_APP_INFO_TYPE
293 on error:       - B_NO_REPLY (fatal)
294                         - standard error
296 message fields:
297 - "team": The application team (team_id).
298 - "ref": An entry_ref to the application executable.
299 - "signature": The application signature.
300 - If both are omitted the active application is referred to.
302 reply fields:
303 - "app_info": The requested app_info (flat_app_info).
305 error reply fields:
306 - "error":
307   - B_BAD_VALUE: A request message field is missing or contains an
308     invalid value.
309   - B_BAD_TEAM_ID: The supplied team ID does not identify a registered
310     application.
311   - B_ERROR:
312     - An entry_ref or a signature has been supplied and no such application
313       is currently running.
314     - No team ID has been supplied and currently there is no active
315       application.
316   - ...
318 -----------------------------------------------------------------------
320 get an app list (BRoster::GetAppList())
322 target:         roster
323 message:        B_REG_GET_APP_LIST
324                         [ "signature":  B_STRING_TYPE ]
325 reply:          standard success
326                         "teams":        B_INT32_TYPE[]
327 on error:       - B_NO_REPLY (fatal)
328                         - standard error
330 message fields:
331 - "signature": The application signature.
333 reply fields:
334 - "teams": The requested list of team IDs (team_id).
336 error reply fields:
337 - "error":
338   - B_BAD_VALUE: A request message field is missing or contains an
339     invalid value.
340   - ...
342 -----------------------------------------------------------------------
344 activate an app (BRoster::ActivateApp())
346 target:         roster
347 message:        B_REG_ACTIVATE_APP
348                         "team": B_INT32_TYPE
349 reply:          standard success
350 on error:       - B_NO_REPLY (fatal)
351                         - standard error
353 message fields:
354 - "team": The application team (team_id).
356 error reply fields:
357 - "error":
358   - B_BAD_VALUE: A request message field is missing or contains an
359     invalid value.
360   - B_BAD_TEAM_ID: The supplied team ID does not identify a registered
361     application.
362   - ...
364 -----------------------------------------------------------------------
366 broadcast a message (BRoster::Broadcast())
368 target:         roster
369 message:        B_REG_BROADCAST
370                         "team":                 B_INT32_TYPE
371                         "message":              B_MESSAGE_TYPE
372                         "reply_target": B_MESSENGER_TYPE
373 reply:          standard success
374 on error:       - B_NO_REPLY (fatal)
375                         - standard error
377 message fields:
378 - "team": The requesting team (team_id).
379 - "message": The message to be broadcast.
380 - "reply_target": The reply target for the message.
382 error reply fields:
383 - "error":
384   - B_BAD_VALUE: A request message field is missing or contains an
385     invalid value.
386   - ...
388 -----------------------------------------------------------------------
390 start roster watching (BRoster::StartWatching())
392 target:         roster
393 message:        B_REG_START_WATCHING
394                         "target":       B_MESSENGER_TYPE
395                         "events":       B_INT32_TYPE
396 reply:          standard success
397 on error:       - B_NO_REPLY (fatal)
398                         - standard error
400 message fields:
401 - "target": The target the event messages shall be sent to.
402 - "events": Specifies the events the caller is interested in (uint32).
404 error reply fields:
405 - "error":
406   - B_BAD_VALUE: A request message field is missing or contains an
407     invalid value.
408   - ...
410 -----------------------------------------------------------------------
412 stop roster watching (BRoster::StopWatching())
414 target:         roster
415 message:        B_REG_STOP_WATCHING
416                         "target":       B_MESSENGER_TYPE
417 reply:          standard success
418 on error:       - B_NO_REPLY (fatal)
419                         - standard error
421 message fields:
422 - "target": The target that shall not longer receive any event messages.
424 error reply fields:
425 - "error":
426   - B_BAD_VALUE: A request message field is missing or contains an
427     invalid value.
428   - ...
430 -----------------------------------------------------------------------
433 MIME Database Requests
434 ----------------------
436 install a mime type (BMimeType::Install())
438 target:         mime manager (BRoster::fMimeMess) 
439 message:        B_REG_MIME_INSTALL
440                         "type": B_STRING_TYPE
441 reply:          standard general result
443 message fields:
444 - "type": The mime type
446 reply fields:
447 - "result":
448   - B_OK: success
449   - B_FILE_EXISTS: the type is already installed
450   - ...                 
452 -----------------------------------------------------------------------
454 remove a mime type (BMimeType::Delete())
456 target:         mime manager (BRoster::fMimeMess)
457 message:        B_REG_MIME_DELETE
458                         "type": B_STRING_TYPE
459 reply:          standard general result
461 message fields:
462 - "type": The mime type
464 reply fields:
465 - "result":
466   - B_OK: success
467   - B_ENTRY_NOT_FOUND: the type was not found
468   - (other error code): failure                 
470 -----------------------------------------------------------------------
472 set a specific attribute of a mime type (BMimeType::Set*()),
473 installing if necessary
475 target:         mime manager (BRoster::fMimeMess) 
476 message:        B_REG_MIME_SET_PARAM
477                         "type": B_STRING_TYPE
478                         "which": B_INT32_TYPE
479                         [ additional fields depending upon the "which" field (see below) ]
480                         
481 reply:          standard general result
483 message fields:
484 - "type": The mime type
485 - "which": Which attribute to set. May be one of the following:
487     "which"                     additional message fields       field comments
488     -------------------------   ----------------------------    --------------------------
489         B_REG_MIME_ICON:                        "icon data": B_RAW_TYPE,        B_CMAP8 bitmap data only
490                                                                 "icon size": B_INT32_TYPE       B_{MINI,LARGE}_ICON or -1 for flat vector icon data
491         B_REG_MIME_PREFERRED_APP:       "signature": B_STRING_TYPE,
492                                                                 "app verb": B_INT32_TYPE
493         B_REG_MIME_ATTR_INFO:           "attr info": B_MESSAGE_TYPE
494         B_REG_MIME_FILE_EXTENSIONS:     "extensions": B_MESSAGE_TYPE
495         B_REG_MIME_DESCRIPTION:         "long": B_BOOL_TYPE,
496                                                                 "description": B_STRING_TYPE
497         B_REG_MIME_SNIFFER_RULE:        "sniffer rule": B_STRING_TYPE
498         B_REG_MIME_APP_HINT:            "app hint": B_REF_TYPE
499         B_REG_MIME_ICON_FOR_TYPE        "file type": B_STRING_TYPE,
500                                                                 "icon data": B_RAW_TYPE,
501                                                                 "icon size": B_INT32_TYPE
502         B_REG_MIME_SUPPORTED_TYPES:     "types": B_MESSAGE_TYPE
503         
504 reply fields:
505 - "result":
506   - B_OK: success
507   - (error code): failure                       
509 -----------------------------------------------------------------------
511 delete a specific attribute of a mime type (BMimeType::Delete*()),
513 target:         mime manager (BRoster::fMimeMess) 
514 message:        B_REG_MIME_DELETE_PARAM
515                         "type": B_STRING_TYPE
516                         "which": B_INT32_TYPE
517                         [ additional fields depending upon the "which" field (see below) ]
518                         
519 reply:          standard general result
521 message fields:
522 - "type": The mime type
523 - "which": Which attribute to delete. May be one of the following:
525     "which"                     additional message fields       field comments
526     -------------------------   ----------------------------    --------------------------
527         B_REG_MIME_ICON:                        "icon size": B_INT32_TYPE       B_{MINI,LARGE}_ICON or -1 for vector icon data
528         B_REG_MIME_PREFERRED_APP:       "app verb": B_INT32_TYPE
529         B_REG_MIME_ATTR_INFO:                   
530         B_REG_MIME_FILE_EXTENSIONS:     
531         B_REG_MIME_DESCRIPTION:         "long": B_BOOL_TYPE,
532         B_REG_MIME_SNIFFER_RULE:                
533         B_REG_MIME_APP_HINT:                    
534         B_REG_MIME_ICON_FOR_TYPE        "file type": B_STRING_TYPE,
535                                                                 "icon size": B_INT32_TYPE
536         B_REG_MIME_SUPPORTED_TYPES:     
537         
538 reply fields:
539 - "result":
540   - B_OK: success
541   - B_ENTRY_NOT_FOUND: no such attribute exists, or the type is not installed
542   - (other error code): failure                 
544 -----------------------------------------------------------------------
546 subscribe a BMessenger to the MIME monitor service (BMimeType::StartWatching())
548 target:         mime manager (BRoster::fMimeMess)
549 message:        B_REG_MIME_START_WATCHING
550                         "target": B_MESSENGER_TYPE
551 reply:          standard general result
553 message fields:
554 - "target": The BMessenger subscribing to the monitor service
556 reply fields:
557 - "result":
558   - B_OK: success
559   - (error code): failure                       
561 -----------------------------------------------------------------------
563 unsubscribe a BMessenger from the MIME monitor service (BMimeType::StopWatching())
565 target:         mime manager (BRoster::fMimeMess)
566 message:        B_REG_MIME_STOP_WATCHING
567                         "target": B_MESSENGER_TYPE
568 reply:          standard general result
570 message fields:
571 - "target": The BMessenger unsubscribing from the monitor service
573 reply fields:
574 - "result":
575   - B_OK: success
576   - B_ENTRY_NOT_FOUND: the given BMessenger was not subscribed to the service
577   - (other error code): failure                 
579 -----------------------------------------------------------------------
581 perform an update_mime_info() call
583 target:         mime manager (BRoster::fMimeMess)
584 message:        B_REG_MIME_UPDATE_MIME_INFO
585                         "entry": B_REF_TYPE
586                         "recursive": B_BOOLEAN_TYPE
587                         "synchronous": B_BOOLEAN_TYPE
588                         "force": B_INT32_TYPE
589 reply:          standard general result
591 message fields:
592 - "entry": The base entry to update.
593 - "recursive": If true and "entry" is a directory, update all entries
594   below "entry" in the hierarchy.
595 - "synchronous": If true, the call will block until the operation is
596   completed. If false, the call will return immediately and the operation
597   will run asynchronously in another thread.                 
598 - "force": Specifies how to handle entries for which a BEOS:TYPE attribute
599   already exists. Valid values are 
600   B_UPDATE_MIME_INFO_{NO_FORCE, FORCE_KEEP_TYPE, FORCE_UPDATE_ALL}.
602 reply fields:
603 - "result":
604   - B_OK: The asynchronous update_mime_info() call has been successfully
605           started (and may still be running).
606   - (error code): failure
608 -----------------------------------------------------------------------
610 perform a create_app_meta_mime() call 
612 target:         mime manager (BRoster::fMimeMess)
613 message:        B_REG_MIME_CREATE_APP_META_MIME
614                         "entry": B_REF_TYPE
615                         "recursive": B_BOOLEAN_TYPE
616                         "synchronous": B_BOOLEAN_TYPE
617                         "force": B_INT32_TYPE
618 reply:          standard general result
620 message fields:
621 - "entry": The base entry to update.
622 - "recursive": If true and "entry" is a directory, update all entries
623   below "entry" in the hierarchy.
624 - "synchronous": If true, the call will block until the operation is
625   completed. If false, the call will return immediately and the operation
626   will run asynchronously in another thread.                 
627 - "force": If != 0, also update entries for which meta app information
628   already exists.
630 reply fields:
631 - "result":
632   - B_OK: The asynchronous update_mime_info() call has been successfully
633           started (and may still be running).
634   - (error code): failure
636 -----------------------------------------------------------------------
638 notify the thread manager to perform a clean up run
640 target:         thread manager/mime manager (MIMEManager::fThreadManager/BRoster::fMimeMess)
641 message:        B_REG_MIME_UPDATE_THREAD_FINISHED
642 reply:          none (message should be sent asynchronously)
644 -----------------------------------------------------------------------
647 Message Runner Requests
648 -----------------------
650 message runner registration (BMessageRunner::InitData())
652 target:         roster
653 message:        B_REG_REGISTER_MESSAGE_RUNNER
654                         "team":                                 B_INT32_TYPE
655                         "target":                               B_MESSENGER_TYPE
656                         "message":                              B_MESSAGE_TYPE
657                         "interval":                             B_INT64_TYPE
658                         "count":                                B_INT32_TYPE
659                         "reply_target":                 B_MESSENGER_TYPE
660 reply:          standard success
661                         "token":                                B_INT32_TYPE
662 on error:       - B_NO_REPLY (fatal)
663                         - standard error
665 message fields:
666 - "team": ID of the team owning the BMessageRunner (team_id).
667 - "target": The message target.
668 - "message": The message to be sent to the target.
669 - "interval": Period of time before the first message is sent and between
670                           messages (if more than one shall be sent) in microseconds.
671 - "count": Specifies how many times the message shall be sent.
672                    A value less than 0 for an unlimited number of repetitions.
673 - "reply_target": Target replies to the delivered message(s) shall be sent to.
675 reply fields:
676 - "token": Unique token identifying the message runner.
678 error reply fields:
679 - "error":
680   - B_BAD_VALUE: A request message field is missing or contains an
681     invalid value.
682   - ...
684 -----------------------------------------------------------------------
686 message runner unregistration (BMessageRunner::~BMessageRunner())
688 target:         roster
689 message:        B_REG_UNREGISTER_MESSAGE_RUNNER
690                         "token":                                B_INT32_TYPE
691 reply:          standard success
692 on error:       - B_NO_REPLY (fatal)
693                         - standard error
695 message fields:
696 - "token": Unique token identifying the message runner. Returned by the
697                    B_REG_REGISTER_MESSAGE_RUNNER request.
699 error reply fields:
700 - "error":
701   - B_BAD_VALUE: A request message field is missing or contains an
702     invalid value.
703   - ...
705 -----------------------------------------------------------------------
707 set message runner parameters (BMessageRunner::SetParams())
709 target:         roster
710 message:        B_REG_SET_MESSAGE_RUNNER_PARAMS
711                         "token":                                B_INT32_TYPE
712                         [ "interval":                   B_INT64_TYPE ]
713                         [ "count":                              B_INT32_TYPE ]
714 reply:          standard success
715 on error:       - B_NO_REPLY (fatal)
716                         - standard error
718 message fields:
719 - "token": Unique token identifying the message runner. Returned by the
720                    B_REG_REGISTER_MESSAGE_RUNNER request.
721 - "interval": Period of time before the first message is sent and between
722                           messages (if more than one shall be sent) in microseconds.
723 - "count": Specifies how many times the message shall be sent.
724                    A value less than 0 for an unlimited number of repetitions.
726 error reply fields:
727 - "error":
728   - B_BAD_VALUE: A request message field is missing or contains an
729     invalid value.
730   - ...
732 -----------------------------------------------------------------------
734 get message runner info (BMessageRunner::InitData())
736 target:         roster
737 message:        B_REG_GET_MESSAGE_RUNNER_INFO
738                         "token":                                B_INT32_TYPE
739 reply:          standard success
740                         "interval":                             B_INT64_TYPE
741                         "count":                                B_INT32_TYPE
742 on error:       - B_NO_REPLY (fatal)
743                         - standard error
745 message fields:
746 - "token": Unique token identifying the message runner. Returned by the
747                    B_REG_REGISTER_MESSAGE_RUNNER request.
749 reply fields:
750 - "interval": Period of time before the first message is sent and between
751                           messages (if more than one shall be sent) in microseconds.
752 - "count": Specifies how many times the message still has to be sent.
753                    A value less than 0 for an unlimited number of repetitions.
755 error reply fields:
756 - "error":
757   - B_BAD_VALUE: A request message field is missing or contains an
758     invalid value.
759   - ...
761 -----------------------------------------------------------------------
764 Clipboard Handler Requests
765 --------------------------
767 add new clipboard to system (BClipboard::BClipboard())
769 target:         clipboard handler
770 message:        B_REG_ADD_CLIPBOARD
771                         "name":                                 B_STRING_TYPE
772 reply:          standard general result
774 message fields:
775 - "name": Name used to identify the particular clipboard to add
777 reply fields:
778 - "result":
779   - B_OK: B
780   - B_BAD_VALUE: name field was not specified in message
782 -----------------------------------------------------------------------
784 get clipboard write count (BClipboard::GetSystemCount())
786 target:         clipboard handler
787 message:        B_REG_GET_CLIPBOARD_COUNT
788                         "name":                                 B_STRING_TYPE
789 reply:          standard general result
790                         "count":                                B_INT32_TYPE
792 message fields:
793 - "name": Name used to identify the particular clipboard
795 reply fields:
796 - "result":
797   - B_OK: success
798   - B_BAD_VALUE: no name / no valid name specified in message
799 - "count":
800   - number of times this clipboard has been written to
802 -----------------------------------------------------------------------
804 start watching clipboard (BClipboard::StartWatching())
806 target:         clipboard handler
807 message:        B_REG_CLIPBOARD_START_WATCHING
808                         "name":                                 B_STRING_TYPE
809                         "target":                               B_MESSENGER_TYPE
810 reply:          standard general result
812 message fields:
813 - "name": Name used to identify the particular clipboard
814 - "target": Messenger pointing to the target to notify
816 reply fields:
817 - "result":
818   - B_OK: success
819   - B_BAD_VALUE: no name / no valid name specified in message
820                  no target specified
822 -----------------------------------------------------------------------
824 stop watching clipboard (BClipboard::StopWatching())
826 target:         clipboard handler
827 message:        B_REG_CLIPBOARD_STOP_WATCHING
828                         "name":                                 B_STRING_TYPE
829                         "target":                               B_MESSENGER_TYPE
830 reply:          standard general result
832 message fields:
833 - "name": Name used to identify the particular clipboard
834 - "target": Messenger pointing to the target to remove from the notify list
836 reply fields:
837 - "result":
838   - B_OK: success
839   - B_BAD_VALUE: no name / no valid name specified in message
840                  no target specified
842 -----------------------------------------------------------------------
844 download clipboard data (BClipboard::DownloadFromSystem())
846 target:         clipboard handler
847 message:        B_REG_DOWNLOAD_CLIPBOARD
848                         "name":                                 B_STRING_TYPE
849 reply:          standard general result
850                         "data":                                 B_MESSAGE_TYPE
851                         "data source":                          B_MESSENGER_TYPE
852                         "count":                                B_INT32_TYPE
854 message fields:
855 - "name": Name used to identify the particular clipboard
857 reply fields:
858 - "result":
859   - B_OK: success
860   - B_BAD_VALUE: no name / no valid name specified in message
861                  no target specified
862 - "data":
863   - message with Data fields containing the contents of the clipboard
864 - "data source":
865   - messenger to the be_app_messenger of the application which last wrote data
866 - "count":
867   - number of times this clipboard has been written to
869 -----------------------------------------------------------------------
871 upload clipboard data (BClipboard::UploadToSystem())
873 target:         clipboard handler
874 message:        B_REG_UPLOAD_CLIPBOARD
875                         "name":                                 B_STRING_TYPE
876                         "data":                                 B_MESSAGE_TYPE
877                         "data source":                          B_MESSENGER_TYPE
878 reply:          standard general result
879                         "count":                                B_INT32_TYPE
881 message fields:
882 - "name": Name used to identify the particular clipboard
883 - "data":
884   - message with Data fields containing the contents of the clipboard
885 - "data source":
886   - messenger to the be_app_messenger of the application which last wrote data
888 reply fields:
889 - "result":
890   - B_OK: success
891   - B_BAD_VALUE: no name / no valid name specified in message
892                  no target specified
893 - "count":
894   - number of times this clipboard has been written to
896 -----------------------------------------------------------------------
899 Disk Device Requests
900 --------------------
902 get next disk device
904 target:         disk device manager
905 message:        B_REG_NEXT_DISK_DEVICE
906                         "cookie":                               B_INT32_TYPE
907 reply:          standard general result
908                         "device":                               B_MESSAGE_TYPE
909                         "cookie":                               B_INT32_TYPE
911 message fields:
912 - "cookie": An iteration cookie. Initially 0.
914 reply fields:
915 - "device": Archived BDiskDevice info.
916 - "cookie": Next value for the iteration cookie.
917 - "result":
918   - B_BAD_VALUE: A request message field is missing or contains an
919     invalid value.
920   - B_ENTRY_NOT_FOUND: Iteration finished.
921   - ...
923 -----------------------------------------------------------------------
925 get disk device
927 target:         disk device manager
928 message:        B_REG_GET_DISK_DEVICE
929                         "device_id":                    B_INT32_TYPE
930                         | "session_id":                 B_INT32_TYPE
931                         | "partition_id":               B_INT32_TYPE
932 reply:          standard general result
933                         "device":                               B_MESSAGE_TYPE
935 message fields:
936 - "device_id": ID of the device to be retrieved.
937 - "session_id": ID of session whose device shall be retrieved.
938 - "partition_id": ID of partition whose device shall be retrieved.
940 reply fields:
941 - "device": Archived BDiskDevice info.
942 - "result":
943   - B_BAD_VALUE: A request message field is missing or contains an
944     invalid value.
945   - B_ENTRY_NOT_FOUND: A device/session/partition with that ID could not
946         be found.
947   - ...
949 -----------------------------------------------------------------------
951 update disk device
953 target:         disk device manager
954 message:        B_REG_UPDATE_DISK_DEVICE
955                         "device_id":                    B_INT32_TYPE
956                         | "session_id":                 B_INT32_TYPE
957                         | "partition_id":               B_INT32_TYPE
958                         "change_counter":               B_INT32_TYPE
959                         "update_policy":                B_INT32_TYPE
960 reply:          standard general result
961                         "up_to_date":                   B_BOOLEAN_TYPE
962                         [ "device":                             B_MESSAGE_TYPE ]
964 message fields:
965 - "device_id": ID of the device to be retrieved.
966 - "session_id": ID of session whose device shall be retrieved.
967 - "partition_id": ID of partition whose device shall be retrieved.
968 - "change_counter": Change counter of the object (or device in case of
969                                         B_REG_DEVICE_UPDATE_DEVICE_CHANGED update policy) in
970                                         question.
971 - "update_policy": (uint32)
972   B_REG_DEVICE_UPDATE_CHECK: Check only, if the object is up to date.
973   B_REG_DEVICE_UPDATE_CHANGED: Update only, if the object has changed.
974   B_REG_DEVICE_UPDATE_DEVICE_CHANGED: Update, if the device has changed, even
975                                                                           if the partition/session has not.
976   The latter two have the same semantics, if the object is a device.
978 reply fields:
979 - "up_to_date": true, if the object (and for
980   B_REG_DEVICE_UPDATE_DEVICE_CHANGED also the device) is already up to date,
981   false otherwise.
982 - "device": Archived BDiskDevice info.
983 - "result":
984   - B_BAD_VALUE: A request message field is missing or contains an
985     invalid value.
986   - B_ENTRY_NOT_FOUND: A device/session/partition with that ID could not
987         be found.
988   - ...
990 -----------------------------------------------------------------------
992 start disk device watching
994 target:         disk device manager
995 message:        B_REG_DEVICE_START_WATCHING
996                         "target":       B_MESSENGER_TYPE
997                         "events":       B_INT32_TYPE
998 reply:          standard general result
999 on error:       - B_NO_REPLY (fatal)
1000                         - standard error
1002 message fields:
1003 - "target": The target the event messages shall be sent to.
1004 - "events": Specifies the events the caller is interested in (uint32).
1005 - "result":
1006   - B_BAD_VALUE: A request message field is missing or contains an
1007     invalid value.
1008   - ...
1010 -----------------------------------------------------------------------
1012 stop disk device watching
1014 target:         disk device manager
1015 message:        B_REG_DEVICE_STOP_WATCHING
1016                         "target":       B_MESSENGER_TYPE
1017 reply:          standard general result
1018 on error:       - B_NO_REPLY (fatal)
1019                         - standard error
1021 message fields:
1022 - "target": The target that shall not longer receive any event messages.
1023 - "result":
1024   - B_BAD_VALUE: A request message field is missing or contains an
1025     invalid value.
1026   - ...
1028 -----------------------------------------------------------------------