Top Fields Constructors Methods
org.freedesktop.dbus.messages

public Class ExportedObject

extends Object
Class Inheritance
Imports
org.freedesktop.dbus.*, org.freedesktop.dbus.annotations.*, .DBusProperty.Access, .PropertiesEmitsChangedSignal.EmitChangeSignal, org.freedesktop.dbus.connections.AbstractConnection, org.freedesktop.dbus.exceptions.DBusException, .DBusExecutionException, org.freedesktop.dbus.interfaces.DBusInterface, .Introspectable, .Peer, .Properties, org.freedesktop.dbus.propertyref.PropertyRef, org.freedesktop.dbus.utils.DBusNamingUtil, .Util, org.slf4j.LoggerFactory, java.lang.annotation.Annotation, java.lang.ref.Reference, .WeakReference, java.lang.reflect.*, java.text.MessageFormat, java.util.*

Field Summary

Modifier and TypeField and Description
private final Set<Class<?>>
private final String
private final Map<MethodTuple, Method>
private final Reference<DBusInterface>
private final Map<PropertyRef, Method>

Constructor Summary

AccessConstructor and Description
public
ExportedObject(DBusInterface _object, boolean _weakreferences)

Method Summary

Modifier and TypeMethod and Description
private void
createReturnArguments(Method
method which return value is investigated
_meth
,
StringBuilder
StringBuilder to append arguments to
_sb
)

Creates the XML parameters for return types of Container based classes.

protected String

Returns:

xml with annotation definition
generateAnnotationsXml
(AnnotatedElement
input interface/method/signal
_c
)

Generates the introspection data xml for annotations

private String
protected String

Returns:

xml with method definitions
generateMethodsXml
(Class<?>
input interface
_clz
)

Generates the introspection data for the input interface methods

protected String

Returns:

xml with property definitions
generatePropertiesXml
(Class<?>
input interface
_clz
)

Generates the introspection data for the input interface properties.

protected String

Returns:

xml with property definition
generatePropertyXml
(DBusProperty
input property annotation
_property
)

Generates the introspection data for the single property.

protected String

Returns:

xml with property definition
generatePropertyXml
(String
name
_propertyName
,
Class<?>
type class
_propertyTypeClass
,
DBusProperty.Access
type access
_access
,
PropertiesEmitsChangedSignal.EmitChangeSignal _emitChangeSignal)

Generates the introspection data for the single property.

protected String

Returns:

xml with signal definitions
generateSignalsXml
(Class<?>
input interface
_clz
)

Generates the introspection data for the input interface signals

protected Set<Class<?>>

Returns:

set of DBus interfaces implements in the input class
getDBusInterfaces
(Class<?>
input object class
_inputClazz
)

Get all valid DBus interfaces which are implemented in a given class.

public Set<Class<?>>
public String
public Map<MethodTuple, Method>
public Reference<DBusInterface>
public Map<PropertyRef, Method>
public static boolean
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

implementedInterfacesback to summary
private final Set<Class<?>> implementedInterfaces
introspectionDataback to summary
private final String introspectionData
methodsback to summary
private final Map<MethodTuple, Method> methods
objectback to summary
private final Reference<DBusInterface> object
propertyMethodsback to summary
private final Map<PropertyRef, Method> propertyMethods

Constructor Detail

ExportedObjectback to summary
public ExportedObject(DBusInterface _object, boolean _weakreferences) throws DBusException

Method Detail

createReturnArgumentsback to summary
private void createReturnArguments(Method _meth, StringBuilder _sb) throws DBusException

Creates the XML parameters for return types of Container based classes. This method supports both, parameterized and regular return types.

Parameters
_meth:Method

method which return value is investigated

_sb:StringBuilder

StringBuilder to append arguments to

Exceptions
DBusException:
when converting signature fails
generateAnnotationsXmlback to summary
protected String generateAnnotationsXml(AnnotatedElement _c)

Generates the introspection data xml for annotations

Parameters
_c:AnnotatedElement

input interface/method/signal

Returns:String

xml with annotation definition

generateIntrospectionXmlback to summary
private String generateIntrospectionXml(Set<Class<?>> _interfaces) throws DBusException
generateMethodsXmlback to summary
protected String generateMethodsXml(Class<?> _clz) throws DBusException

Generates the introspection data for the input interface methods

Parameters
_clz:Class<?>

input interface

Returns:String

xml with method definitions

Exceptions
DBusException:
if marshalling fails
generatePropertiesXmlback to summary
protected String generatePropertiesXml(Class<?> _clz) throws DBusException

Generates the introspection data for the input interface properties.

Parameters
_clz:Class<?>

input interface

Returns:String

xml with property definitions

Exceptions
DBusException:
in case of unknown data types
generatePropertyXmlback to summary
protected String generatePropertyXml(DBusProperty _property) throws DBusException

Generates the introspection data for the single property.

Parameters
_property:DBusProperty

input property annotation

Returns:String

xml with property definition

Exceptions
DBusException:
in case of unknown data types
generatePropertyXmlback to summary
protected String generatePropertyXml(String _propertyName, Class<?> _propertyTypeClass, DBusProperty.Access _access, PropertiesEmitsChangedSignal.EmitChangeSignal _emitChangeSignal) throws DBusException

Generates the introspection data for the single property.

Parameters
_propertyName:String

name

_propertyTypeClass:Class<?>

type class

_access:DBusProperty.Access

type access

Returns:String

xml with property definition

Exceptions
DBusException:
in case of unknown data types
generateSignalsXmlback to summary
protected String generateSignalsXml(Class<?> _clz) throws DBusException

Generates the introspection data for the input interface signals

Parameters
_clz:Class<?>

input interface

Returns:String

xml with signal definitions

Exceptions
DBusException:
in case of invalid signal name / data types
getDBusInterfacesback to summary
protected Set<Class<?>> getDBusInterfaces(Class<?> _inputClazz)

Get all valid DBus interfaces which are implemented in a given class. The search is performed without recursion taking into account object inheritance. A valid DBus interface must directly extend the DBusInterface.

Parameters
_inputClazz:Class<?>

input object class

Returns:Set<Class<?>>

set of DBus interfaces implements in the input class

getImplementedInterfacesback to summary
public Set<Class<?>> getImplementedInterfaces()
getIntrospectiondataback to summary
public String getIntrospectiondata()
getMethodsback to summary
public Map<MethodTuple, Method> getMethods()
getObjectback to summary
public Reference<DBusInterface> getObject()
getPropertyMethodsback to summary
public Map<PropertyRef, Method> getPropertyMethods()
isExcludedback to summary
public static boolean isExcluded(Method _meth)
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Returns:String

a string representation of the object

Annotations
@Override