org.apache.camel.component.cxf.jaxrs
Class CxfRsEndpoint

java.lang.Object
  extended by org.apache.camel.impl.DefaultEndpoint
      extended by org.apache.camel.component.cxf.jaxrs.CxfRsEndpoint
All Implemented Interfaces:
CamelContextAware, Endpoint, IsSingleton, HeaderFilterStrategyAware
Direct Known Subclasses:
CxfRsSpringEndpoint

public class CxfRsEndpoint
extends DefaultEndpoint
implements HeaderFilterStrategyAware


Constructor Summary
CxfRsEndpoint(String endpointUri, CamelContext camelContext)
           
CxfRsEndpoint(String endpointUri, Component component)
           
 
Method Summary
 Consumer createConsumer(Processor processor)
          Creates a new Event Driven Consumer which consumes messages from the endpoint using the given processor
 org.apache.cxf.jaxrs.client.JAXRSClientFactoryBean createJAXRSClientFactoryBean()
           
 org.apache.cxf.jaxrs.JAXRSServerFactoryBean createJAXRSServerFactoryBean()
           
 Producer createProducer()
          Creates a new producer which is used send messages into the endpoint
 CxfRsBinding getBinding()
           
 HeaderFilterStrategy getHeaderFilterStrategy()
          Gets the header filter strategy used
 Map<String,String> getParameters()
           
 List<Class<?>> getResourceClasses()
           
 boolean isHttpClientAPI()
           
 boolean isLenientProperties()
          Should all properties be known or does the endpoint allow unknown options?

lenient = false means that the endpoint should validate that all given options is known and configured properly.

 boolean isSingleton()
          Wheter this class supports being singleton or not.
 void setBinding(CxfRsBinding binding)
           
 void setHeaderFilterStrategy(HeaderFilterStrategy strategy)
          Sets the header filter strategy to use
 void setHttpClientAPI(boolean clientAPI)
           
 void setParameters(Map<String,String> param)
           
 void setResourceClasses(Class<?>... classes)
           
 void setResourceClasses(List<Class<?>> classes)
           
protected  void setupJAXRSClientFactoryBean(org.apache.cxf.jaxrs.client.JAXRSClientFactoryBean cfb)
           
protected  void setupJAXRSServerFactoryBean(org.apache.cxf.jaxrs.JAXRSServerFactoryBean sfb)
           
 
Methods inherited from class org.apache.camel.impl.DefaultEndpoint
configureProperties, createEndpointUri, createExchange, createExchange, createExchange, createPollingConsumer, createScheduledExecutorService, equals, getCamelContext, getComponent, getEndpointKey, getEndpointUri, getExchangePattern, getExchangeType, getExecutorService, getScheduledExecutorService, hashCode, setCamelContext, setEndpointUri, setEndpointUriIfNotSpecified, setExchangePattern, setExecutorService, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CxfRsEndpoint

public CxfRsEndpoint(String endpointUri,
                     CamelContext camelContext)

CxfRsEndpoint

public CxfRsEndpoint(String endpointUri,
                     Component component)
Method Detail

setParameters

public void setParameters(Map<String,String> param)

getParameters

public Map<String,String> getParameters()

setHttpClientAPI

public void setHttpClientAPI(boolean clientAPI)

isHttpClientAPI

public boolean isHttpClientAPI()

isLenientProperties

public boolean isLenientProperties()
Description copied from interface: Endpoint
Should all properties be known or does the endpoint allow unknown options?

lenient = false means that the endpoint should validate that all given options is known and configured properly. lenient = true means that the endpoint allows additional unknown options to be passed to it but does not throw a ResolveEndpointFailedException when creating the endpoint.

This options is used by a few components for instance the HTTP based that can have dynamic URI options appended that is targeted for an external system.

Most endpoints is configured to be not lenient.

Specified by:
isLenientProperties in interface Endpoint
Overrides:
isLenientProperties in class DefaultEndpoint
Returns:
whether properties is lenient or not

getHeaderFilterStrategy

public HeaderFilterStrategy getHeaderFilterStrategy()
Description copied from interface: HeaderFilterStrategyAware
Gets the header filter strategy used

Specified by:
getHeaderFilterStrategy in interface HeaderFilterStrategyAware
Returns:
the strategy

setHeaderFilterStrategy

public void setHeaderFilterStrategy(HeaderFilterStrategy strategy)
Description copied from interface: HeaderFilterStrategyAware
Sets the header filter strategy to use

Specified by:
setHeaderFilterStrategy in interface HeaderFilterStrategyAware
Parameters:
strategy - the strategy

createConsumer

public Consumer createConsumer(Processor processor)
                        throws Exception
Description copied from interface: Endpoint
Creates a new Event Driven Consumer which consumes messages from the endpoint using the given processor

Specified by:
createConsumer in interface Endpoint
Parameters:
processor - the given processor
Returns:
a newly created consumer
Throws:
Exception - can be thrown

createProducer

public Producer createProducer()
                        throws Exception
Description copied from interface: Endpoint
Creates a new producer which is used send messages into the endpoint

Specified by:
createProducer in interface Endpoint
Returns:
a newly created producer
Throws:
Exception - can be thrown

isSingleton

public boolean isSingleton()
Description copied from interface: IsSingleton
Wheter this class supports being singleton or not.

Specified by:
isSingleton in interface IsSingleton
Returns:
true to be a single shared instance, false to create new instances.

setBinding

public void setBinding(CxfRsBinding binding)

getBinding

public CxfRsBinding getBinding()

setupJAXRSServerFactoryBean

protected void setupJAXRSServerFactoryBean(org.apache.cxf.jaxrs.JAXRSServerFactoryBean sfb)

setupJAXRSClientFactoryBean

protected void setupJAXRSClientFactoryBean(org.apache.cxf.jaxrs.client.JAXRSClientFactoryBean cfb)

createJAXRSServerFactoryBean

public org.apache.cxf.jaxrs.JAXRSServerFactoryBean createJAXRSServerFactoryBean()

createJAXRSClientFactoryBean

public org.apache.cxf.jaxrs.client.JAXRSClientFactoryBean createJAXRSClientFactoryBean()

getResourceClasses

public List<Class<?>> getResourceClasses()

setResourceClasses

public void setResourceClasses(List<Class<?>> classes)

setResourceClasses

public void setResourceClasses(Class<?>... classes)


Copyright © 2007-2010 IONA Open Source Community. All Rights Reserved.