Class ExportedObject


  • public class ExportedObject
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.lang.String generateAnnotationsXml​(java.lang.reflect.AnnotatedElement _c)
      Generates the introspection data xml for annotations
      private java.lang.String generateIntrospectionXml​(java.util.Set<java.lang.Class<?>> _interfaces)  
      protected java.lang.String generateMethodsXml​(java.lang.Class<?> _clz)
      Generates the introspection data for the input interface methods
      protected java.lang.String generatePropertiesXml​(java.lang.Class<?> _clz)
      Generates the introspection data for the input interface properties.
      protected java.lang.String generatePropertyXml​(DBusProperty _property)
      Generates the introspection data for the single property.
      protected java.lang.String generateSignalsXml​(java.lang.Class<?> _clz)
      Generates the introspection data for the input interface signals
      protected java.util.Set<java.lang.Class<?>> getDBusInterfaces​(java.lang.Class<?> _inputClazz)
      Get all valid DBus interfaces which are implemented in a given class.
      java.lang.String getIntrospectiondata()  
      java.util.Map<MethodTuple,​java.lang.reflect.Method> getMethods()  
      java.lang.ref.Reference<DBusInterface> getObject()  
      static boolean isExcluded​(java.lang.reflect.Method _meth)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • methods

        private final java.util.Map<MethodTuple,​java.lang.reflect.Method> methods
      • introspectionData

        private final java.lang.String introspectionData
      • object

        private final java.lang.ref.Reference<DBusInterface> object
    • Method Detail

      • generateAnnotationsXml

        protected java.lang.String generateAnnotationsXml​(java.lang.reflect.AnnotatedElement _c)
        Generates the introspection data xml for annotations
        Parameters:
        _c - input interface/method/signal
        Returns:
        xml with annotation definition
      • generatePropertyXml

        protected java.lang.String generatePropertyXml​(DBusProperty _property)
                                                throws DBusException
        Generates the introspection data for the single property.
        Parameters:
        _property - input property annotation
        Returns:
        xml with property definition
        Throws:
        DBusException - in case of unknown data types
      • generatePropertiesXml

        protected java.lang.String generatePropertiesXml​(java.lang.Class<?> _clz)
                                                  throws DBusException
        Generates the introspection data for the input interface properties.
        Parameters:
        _clz - input interface
        Returns:
        xml with property definitions
        Throws:
        DBusException - in case of unknown data types
      • generateMethodsXml

        protected java.lang.String generateMethodsXml​(java.lang.Class<?> _clz)
                                               throws DBusException
        Generates the introspection data for the input interface methods
        Parameters:
        _clz - input interface
        Returns:
        xml with method definitions
        Throws:
        DBusException - if marshalling fails
      • generateSignalsXml

        protected java.lang.String generateSignalsXml​(java.lang.Class<?> _clz)
                                               throws DBusException
        Generates the introspection data for the input interface signals
        Parameters:
        _clz - input interface
        Returns:
        xml with signal definitions
        Throws:
        DBusException - in case of invalid signal name / data types
      • getDBusInterfaces

        protected java.util.Set<java.lang.Class<?>> getDBusInterfaces​(java.lang.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 - input object class
        Returns:
        set of DBus interfaces implements in the input class
      • generateIntrospectionXml

        private java.lang.String generateIntrospectionXml​(java.util.Set<java.lang.Class<?>> _interfaces)
                                                   throws DBusException
        Throws:
        DBusException
      • getMethods

        public java.util.Map<MethodTuple,​java.lang.reflect.Method> getMethods()
      • getObject

        public java.lang.ref.Reference<DBusInterface> getObject()
      • getIntrospectiondata

        public java.lang.String getIntrospectiondata()
      • isExcluded

        public static boolean isExcluded​(java.lang.reflect.Method _meth)