org.apache.camel.component.stub
Class StubComponent

java.lang.Object
  extended by org.apache.camel.support.ServiceSupport
      extended by org.apache.camel.impl.DefaultComponent
          extended by org.apache.camel.component.seda.SedaComponent
              extended by org.apache.camel.component.vm.VmComponent
                  extended by org.apache.camel.component.stub.StubComponent
All Implemented Interfaces:
CamelContextAware, Component, Service, ShutdownableService, StatefulService, SuspendableService

public class StubComponent
extends VmComponent

Allows you to easily stub out a middleware transport by prefixing the URI with "stub:" which is handy for testing out routes, or isolating bits of middleware.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.camel.component.seda.SedaComponent
SedaComponent.QueueReference
 
Field Summary
 
Fields inherited from class org.apache.camel.component.vm.VmComponent
QUEUES
 
Fields inherited from class org.apache.camel.component.seda.SedaComponent
defaultConcurrentConsumers, maxConcurrentConsumers, queueSize
 
Fields inherited from class org.apache.camel.support.ServiceSupport
shutdown, shuttingdown, started, starting, stopped, stopping, suspended, suspending
 
Constructor Summary
StubComponent()
           
 
Method Summary
protected  void validateParameters(String uri, Map<String,Object> parameters, String optionPrefix)
          Strategy for validation of parameters, that was not able to be resolved to any endpoint options.
protected  void validateURI(String uri, String path, Map<String,Object> parameters)
          Strategy for validation of the uri when creating the endpoint.
 
Methods inherited from class org.apache.camel.component.vm.VmComponent
doStart, doStop, getQueues
 
Methods inherited from class org.apache.camel.component.seda.SedaComponent
createEndpoint, getConcurrentConsumers, getOrCreateQueue, getQueueKey, getQueueSize, setConcurrentConsumers, setQueueSize
 
Methods inherited from class org.apache.camel.impl.DefaultComponent
afterConfiguration, createConfiguration, createEndpoint, getAndRemoveParameter, getAndRemoveParameter, getCamelContext, ifStartsWithReturnRemainder, preProcessUri, resolveAndRemoveReferenceListParameter, resolveAndRemoveReferenceListParameter, resolveAndRemoveReferenceParameter, resolveAndRemoveReferenceParameter, setCamelContext, setProperties, useIntrospectionOnEndpoint
 
Methods inherited from class org.apache.camel.support.ServiceSupport
doResume, doShutdown, doSuspend, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isSuspended, isSuspending, resume, shutdown, start, stop, suspend
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StubComponent

public StubComponent()
Method Detail

validateURI

protected void validateURI(String uri,
                           String path,
                           Map<String,Object> parameters)
Description copied from class: DefaultComponent
Strategy for validation of the uri when creating the endpoint.

Overrides:
validateURI in class DefaultComponent
Parameters:
uri - the uri - the uri the end user provided untouched
path - the path - part after the scheme
parameters - the parameters, an empty map if no parameters given

validateParameters

protected void validateParameters(String uri,
                                  Map<String,Object> parameters,
                                  String optionPrefix)
Description copied from class: DefaultComponent
Strategy for validation of parameters, that was not able to be resolved to any endpoint options.

Overrides:
validateParameters in class DefaultComponent
Parameters:
uri - the uri - the uri the end user provided untouched
parameters - the parameters, an empty map if no parameters given
optionPrefix - optional prefix to filter the parameters for validation. Use null for validate all.


Apache CAMEL