Package org.eclipse.swt.internal
Class GDBus
java.lang.Object
org.eclipse.swt.internal.GDBus
General purpose DBus interface for SWT to interact with the operating system and vice versa.
(See also WebkitGDBus for the webkit specific gdbus interface).
This implementation uses GDBus (Gnome DBus) to implement the DBus interface.
It can be reached via:
gdbus call --session --dest org.eclipse.swt --object-path /org/eclipse/swt --method org.eclipse.swt.YOUR_METHOD YOUR_ARGS
where YOUR_ARGS can be something like "MyString" or "['/tmp/myFile', '/tmp/myFile2']" etc..
For hygiene purposes, GVariant/GDBus native types/values should *never* leave this class. Convert on the way in/out.
Technical notes:
- Concurrent gdbus names can co-exist. (i.e, multiple session names in single proc).
Meaning if you don't like org.eclipse.swt, you can add more session names.
- This implementation is only a small subset of GDBus.
E.g not all types are translated and not functionality implemented. Add them as you need them.
- At time of writing (v 1.4), only handles incoming gdbus calls. But could be easily extended to
handle outgoing gdbus calls.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
init
(GDBus.GDBusMethod[] methods) Instantiate GDBus for use by SWT.
-
Constructor Details
-
GDBus
public GDBus()
-
-
Method Details
-
init
Instantiate GDBus for use by SWT. Note, a new SWT instance that runs this "Steals" org.eclipse.swt session bus, but upon termination it returns the session back to the previous owner.- Parameters:
methods
- GDBus methods that we should handle.
-