View Javadoc
1   /*
2    * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
3    * The software in this package is published under the terms of the CPAL v1.0
4    * license, a copy of which has been included with this distribution in the
5    * LICENSE.txt file.
6    */
7   package org.mule.api.component;
8   
9   import org.mule.api.MuleEvent;
10  import org.mule.api.construct.FlowConstructAware;
11  import org.mule.api.processor.MessageProcessor;
12  import org.mule.management.stats.ComponentStatistics;
13  
14  /**
15   * A <code>Component</code> component processes a {@link MuleEvent} by invoking the
16   * component instance that has been configured, optionally returning a result.
17   * <p/>
18   * Implementations of <code>Component</code> can use different types of component
19   * implementation, implement component instance pooling or implement
20   * <em>bindings</em> which allow for service composition.
21   */
22  public interface Component extends MessageProcessor, FlowConstructAware
23  {
24  
25      /**
26       * Component statistics are used to gather component statistics such as
27       * sync/async invocation counts and total and average execution time.
28       */
29      ComponentStatistics getStatistics();
30  
31  }