java.lang.Object
org.freedesktop.dbus.connections.BusAddress
Defines an address to connect to DBus.
The address will define which transport to use.
-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungaddParameter(String _parameter, String _value) Add a parameter to the address.Returns the transport type in uppercase.getGuid()Creates a listening BusAddress if this instance is not already listening.getParameterValue(String _parameter) Returns a the value of the given parameter.getParameterValue(String _parameter, String _default) Returns a the value of the given parameter.getType()Returns the transport type as found in the address.booleanhasParameter(String _parameter) Checks if the given parameter is present.booleanChecks if thisBusAddressis for the given bus type.
The given type will be compared case-insensitive.booleanTrue if this is a listening address.booleanisServer()True if this address represents a listening server address.static BusAddressCreates a newBusAddressfrom String.static BusAddressof(BusAddress _address) Creates a copy of the givenBusAddress.removeParameter(String _parameter) Remove parameter with given name.final StringtoString()
-
Konstruktordetails
-
BusAddress
-
-
Methodendetails
-
of
Creates a copy of the givenBusAddress. If given address is null, an emptyBusAddressobject is created.- Parameter:
_address- address to copy- Gibt zurück:
- BusAddress
- Seit:
- 4.2.0 - 2022-07-18
-
of
Creates a newBusAddressfrom String.- Parameter:
_address- address String, never null or empty- Gibt zurück:
- BusAddress
- Seit:
- 4.2.0 - 2022-07-18
-
getType
Returns the transport type as found in the address.- Gibt zurück:
- type
-
getBusType
Returns the transport type in uppercase.- Gibt zurück:
- type
-
isBusType
Checks if thisBusAddressis for the given bus type.
The given type will be compared case-insensitive.
e.g.isBusType("unix");- Parameter:
_type- to compare- Gibt zurück:
- true if same type (case-insensitive), false if null or not same type
- Seit:
- 4.2.0 - 2022-07-20
-
isListeningSocket
public boolean isListeningSocket()True if this is a listening address.- Gibt zurück:
- true if listening
-
getGuid
-
toString
-
isServer
public boolean isServer()True if this address represents a listening server address.- Gibt zurück:
- true if server
-
addParameter
Add a parameter to the address. Adding multiple parameters with same name is not possible and will overwrite previous values.- Parameter:
_parameter- parameter name_value- value- Gibt zurück:
- this
- Seit:
- 4.2.0 - 2022-07-18
-
removeParameter
Remove parameter with given name. If parameter does not exists, nothing will happen.- Parameter:
_parameter- parameter to remove- Gibt zurück:
- this
- Seit:
- 4.2.0 - 2022-07-18
-
hasParameter
Checks if the given parameter is present.- Parameter:
_parameter- parameter to check- Gibt zurück:
- true if parameter exists, false otherwise
- Seit:
- 4.2.2 - 2023-01-11
-
getParameterValue
Returns a the value of the given parameter.When no value present,
nullis returned.- Parameter:
_parameter- parameter to get value for- Gibt zurück:
- String or
null - Seit:
- 4.2.0 - 2022-07-19
-
getParameterValue
Returns a the value of the given parameter.When no value present, the given default is returned.
- Parameter:
_parameter- parameter to get value for_default- default to return if parameter not set- Gibt zurück:
- String or default
- Seit:
- 4.2.2 - 2023-01-11
-
getListenerAddress
Creates a listening BusAddress if this instance is not already listening.- Gibt zurück:
- new BusAddress or this
- Seit:
- 4.2.0 - 2022-07-18
-