org.ow2.petals.binding.soap.util
Class SUPropertiesHelper

java.lang.Object
  extended by org.ow2.petals.binding.soap.util.SUPropertiesHelper

public class SUPropertiesHelper
extends java.lang.Object

Helper for Service Unit properties values

Author:
chamerling - eBM Websourcing

Constructor Summary
protected SUPropertiesHelper()
          Creates a new instance if SUPropertiesHelper
 
Method Summary
protected static boolean checkPresent(java.lang.String parameterName, org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Check if the given parameter is present
static java.lang.String getAddress(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the address parameter value
protected static boolean getBoolean(java.lang.String parameterName, org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the boolean value of the parameter
protected static boolean getBoolean(java.lang.String parameterName, org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions, boolean defaultValue)
           
protected static long getLong(java.lang.String parameterName, org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the parameter value as long or return -1L if not found
static java.lang.String getMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the mode.
static java.lang.String getServiceName(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the service name.
protected static java.lang.String getString(java.lang.String parameterName, org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the parameter value or return null if not found
protected static java.lang.String getString(java.lang.String parameterName, java.lang.String defaultValue, org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
           
static java.lang.String getTopicName(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Retrieve the topic name
static java.lang.String getWSAFaultTo(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
           
static java.lang.String getWSAFrom(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
           
static java.lang.String getWSAReplyTo(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
           
static java.lang.String getWSATo(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
           
static boolean isHttpTransportEnable(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the flag enabling the HTTP transport layer.
static boolean isJmsTransportEnable(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the flag enabling the JMS transport layer.
static boolean isPolicyEnabled(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          The policy is enabled if the policy path has been defined
static boolean isRESTMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          The mode is REST ?
static boolean isServiceMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Returns true if the mode is service compatible : SOAP, REST or JSON
static boolean isSOAPMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          The mode is SOAP ?
static boolean isTopicMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          The mode is TOPIC ?
static boolean isWSAEnabled(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Use the WSA fields from the exchange
static java.util.List<java.lang.String> retrieveHeaderList(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
           
static boolean retrieveInjectHeader(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          We inject the headers by default
static boolean retrieveRemoveRootElement(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Retrieve the remove root element extension value
static java.lang.String retrieveRESTAddNSPrefixOnRequest(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the prefix to be used
static java.lang.String retrieveRESTAddNSURIOnRequest(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get the URI which has to be added to the message payload
static java.util.List<java.lang.String> retrieveRESTRemovePrefixOnResponse(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Get all the prefix which has to be removed on REST response.
static long retrieveTimeout(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
          Retrieve the timeout extensions value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SUPropertiesHelper

protected SUPropertiesHelper()
Creates a new instance if SUPropertiesHelper

Method Detail

retrieveTimeout

public static final long retrieveTimeout(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Retrieve the timeout extensions value.

Parameters:
extensions -
Returns:

retrieveRemoveRootElement

public static final boolean retrieveRemoveRootElement(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Retrieve the remove root element extension value

Parameters:
extensions -
Returns:

retrieveRESTAddNSURIOnRequest

public static java.lang.String retrieveRESTAddNSURIOnRequest(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the URI which has to be added to the message payload

Parameters:
props -
Returns:

retrieveRESTAddNSPrefixOnRequest

public static java.lang.String retrieveRESTAddNSPrefixOnRequest(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the prefix to be used

Parameters:
props -
Returns:

retrieveRESTRemovePrefixOnResponse

public static java.util.List<java.lang.String> retrieveRESTRemovePrefixOnResponse(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get all the prefix which has to be removed on REST response.

Parameters:
props -
Returns:
a list of prefixes to remove or null if the option has not been set

retrieveHeaderList

public static java.util.List<java.lang.String> retrieveHeaderList(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Parameters:
extensions -
Returns:

retrieveInjectHeader

public static boolean retrieveInjectHeader(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
We inject the headers by default

Parameters:
extensions -
Returns:

getMode

public static java.lang.String getMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the mode. SOAP is default when not found.

Parameters:
extensions -
Returns:

getServiceName

public static java.lang.String getServiceName(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the service name. This name will be used to create the web service

Parameters:
extensions -
Returns:

getTopicName

public static java.lang.String getTopicName(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Retrieve the topic name

Parameters:
extensions -
Returns:

isPolicyEnabled

public static boolean isPolicyEnabled(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
The policy is enabled if the policy path has been defined

Parameters:
extensions -
Returns:

getWSATo

public static java.lang.String getWSATo(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Returns:

getAddress

public static java.lang.String getAddress(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the address parameter value

Parameters:
extensions -
Returns:

getWSAFrom

public static java.lang.String getWSAFrom(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Parameters:
extensions -
Returns:

getWSAReplyTo

public static java.lang.String getWSAReplyTo(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Parameters:
extensions -
Returns:

getWSAFaultTo

public static java.lang.String getWSAFaultTo(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Parameters:
extensions -
Returns:

isWSAEnabled

public static boolean isWSAEnabled(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Use the WSA fields from the exchange

Parameters:
extensions -
Returns:

checkPresent

protected static final boolean checkPresent(java.lang.String parameterName,
                                            org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Check if the given parameter is present

Parameters:
parameterName -
extensions -
Returns:

isSOAPMode

public static final boolean isSOAPMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
The mode is SOAP ?

Parameters:
extensions -
Returns:

isRESTMode

public static final boolean isRESTMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
The mode is REST ?

Parameters:
extensions -
Returns:

isServiceMode

public static final boolean isServiceMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Returns true if the mode is service compatible : SOAP, REST or JSON

Parameters:
extensions -
Returns:

isTopicMode

public static final boolean isTopicMode(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
The mode is TOPIC ?

Parameters:
extensions -
Returns:

isHttpTransportEnable

public static boolean isHttpTransportEnable(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the flag enabling the HTTP transport layer.

Parameters:
extensions -
Returns:

isJmsTransportEnable

public static boolean isJmsTransportEnable(org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the flag enabling the JMS transport layer.

Parameters:
extensions -
Returns:

getBoolean

protected static final boolean getBoolean(java.lang.String parameterName,
                                          org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the boolean value of the parameter

Parameters:
parameterName -
extensions -
Returns:
the boolean value of the parameter according to the Boolean.parseBoolean method, true if the parameter has not been found.

getBoolean

protected static final boolean getBoolean(java.lang.String parameterName,
                                          org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions,
                                          boolean defaultValue)

getString

protected static final java.lang.String getString(java.lang.String parameterName,
                                                  org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the parameter value or return null if not found

Parameters:
parameterName -
extensions -
Returns:

getString

protected static final java.lang.String getString(java.lang.String parameterName,
                                                  java.lang.String defaultValue,
                                                  org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Parameters:
parameterName -
defaultValue -
extensions -
Returns:

getLong

protected static final long getLong(java.lang.String parameterName,
                                    org.ow2.petals.component.framework.api.configuration.ConfigurationExtensions extensions)
Get the parameter value as long or return -1L if not found

Parameters:
parameterName -
extensions -
Returns:


Copyright © 2005-2010 OW2 Consortium. All Rights Reserved.