Class CommonAdapter


  • public class CommonAdapter
    extends AspectAdapter
    An adapter for an empty aspect.

    This adapter handles special messages (without namespace in XML). Also it handles tag messages in all aspects by distributing them via processGlobalTagChange method of handlers.

    Method getAspect() returns an empty string.

    • Constructor Detail

      • CommonAdapter

        public CommonAdapter()
    • Method Detail

      • getAspect

        public java.lang.String getAspect()
        Description copied from class: AspectAdapter
        Gets the name of the aspect that is being handled.
        Specified by:
        getAspect in class AspectAdapter
      • processingStarted

        public void processingStarted​(java.lang.String providerDesc)
        Description copied from class: AspectAdapter
        Notification from provider: begin trace handling. By agreement, this method is overridden only in the class which CommonAdapter distributes the corresponding message between the handlers and provider notifies only this method.
        Overrides:
        processingStarted in class AspectAdapter
      • processingFinished

        public void processingFinished​(java.lang.String providerDesc,
                                       boolean normally)
        Description copied from class: AspectAdapter
        Notification from provider: end trace handling. By agreement, this method is overridden only in the class which CommonAdapter, distributes the corresponding message between the handlers and provider notifies only this method.
        Overrides:
        processingFinished in class AspectAdapter
      • processTagMessage

        protected void processTagMessage​(TagMessage msg)
        Description copied from class: AspectAdapter
        Notification about tags change from provider. This message is being send to the CommonAdapter and to the corresponding aspect adapter.
        Overrides:
        processTagMessage in class AspectAdapter
      • processMessage

        protected void processMessage​(TraceMessage msg)
                               throws java.lang.IllegalArgumentException
        Description copied from class: AspectAdapter
        Handles one message from provider. Realized by concrete aspect dependent adapters. Usual method behaviour - converts raw message from provider into aspect dependent message and distributes it to handlers. Class messages TagMessage come in adapter via method call AspectAdapter.processTagMessage(TagMessage).
        Overrides:
        processMessage in class AspectAdapter
        Throws:
        java.lang.IllegalArgumentException - Incorrect message struct or incorrect message data
      • getListeners

        protected java.util.List<CommonListener> getListeners()
        Description copied from class: AspectAdapter
        Gets list of handlers for the internal use. Subclasses must override this method with an appropriate type of return value.
        Overrides:
        getListeners in class AspectAdapter