package obus

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module OBus_nameSource

D-Bus names

For specific restrictions on D-Bus names, see

General restrictions include:

  • names must not be empty
  • names must contains only ascii characters

Bus names

example: "org.freedesktop.DBus", ":1.1"

Sourceval validate_bus : OBus_string.validator
Sourceval is_unique : bus -> bool

Tell wether a bus name is a unique connection name or not.

Sourcetype interface = OBus_string.t

Interface names

example: "org.freedesktop.DBus.Introspectable"

Sourceval validate_interface : OBus_string.validator
Sourcetype member = OBus_string.t

Methods/signals/properties names

example: "StartServiceByName"

Sourceval validate_member : OBus_string.validator
Sourcetype error = OBus_string.t

Error names

example: "org.freedesktop.Error.UnknownMethod"

Sourceval validate_error : OBus_string.validator
D-Bus name translation
Sourceval split : string -> string list

Split a name into longest blocks matched by the regular expression "A-Z*^A-Z.*":

split "SetCPUFreqGovernor" = ["Set"; "CPUFreq"; "Governor"], split "org.freedesktop.DBus" = ["org"; "freedesktop"; "DBus"]

Sourceval ocaml_lid : string -> string

Translate a D-Bus name into an ocaml-style lower-identifier:

caml_lid "SetCPUFreqGovernor" = "set_cpufreq_governor"

Sourceval ocaml_uid : string -> string

Translate a D-Bus name into an ocaml-style upper-identifier:

caml_uid "org.freedesktop.DBus" = "Org_freedesktop_dbus"

Sourceval haskell_lid : string -> string

Translate a D-Bus name into an haskell-style lower-identifier:

haskell_lid "SetCPUFreqGovernor" = "setCPUFreqGovernor"

Sourceval haskell_uid : string -> string

Translate a D-Bus name into an haskell-style upper-identifier:

haskell_uid "org.freedesktop.DBus" = "OrgFreedesktopDBus"

OCaml

Innovation. Community. Security.