Package org.apache.axis2.transport.base
Class BaseUtils
java.lang.Object
org.apache.axis2.transport.base.BaseUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetEPRProperties(String url) Extract the properties from an endpoint reference.static org.apache.axis2.kernel.MessageFormattergetMessageFormatter(org.apache.axis2.context.MessageContext msgContext) Get the MessageFormatter for the given message.static org.apache.axiom.om.OMOutputFormatgetOMOutputFormat(org.apache.axis2.context.MessageContext msgContext) Get the OMOutput format for the given messagestatic QNamegetQNameFromString(Object obj) Return a QName from the String passed in of the form {ns}elementprotected static voidprotected static voidhandleException(String s, Exception e) static booleanUtility method to check if a string is null or emptystatic booleanisUsingTransport(org.apache.axis2.description.AxisService service, String transportName) static PropertiesloadProperties(String filePath) Loads the properties from a given property file pathstatic voidmarkServiceAsFaulty(String serviceName, String msg, org.apache.axis2.engine.AxisConfiguration axisCfg) Marks the given service as faulty with the given comment
-
Constructor Details
-
BaseUtils
public BaseUtils()
-
-
Method Details
-
getQNameFromString
Return a QName from the String passed in of the form {ns}element- Parameters:
obj- a QName or a String containing a QName in {ns}element form- Returns:
- a corresponding QName object
-
markServiceAsFaulty
public static void markServiceAsFaulty(String serviceName, String msg, org.apache.axis2.engine.AxisConfiguration axisCfg) Marks the given service as faulty with the given comment- Parameters:
serviceName- service namemsg- comment for being faultyaxisCfg- configuration context
-
getOMOutputFormat
public static org.apache.axiom.om.OMOutputFormat getOMOutputFormat(org.apache.axis2.context.MessageContext msgContext) Get the OMOutput format for the given message- Parameters:
msgContext- the axis message context- Returns:
- the OMOutput format to be used
-
getMessageFormatter
public static org.apache.axis2.kernel.MessageFormatter getMessageFormatter(org.apache.axis2.context.MessageContext msgContext) Get the MessageFormatter for the given message.- Parameters:
msgContext- the axis message context- Returns:
- the MessageFormatter to be used
-
handleException
-
handleException
-
isBlank
Utility method to check if a string is null or empty- Parameters:
str- the string to check- Returns:
- true if the string is null or empty
-
isUsingTransport
public static boolean isUsingTransport(org.apache.axis2.description.AxisService service, String transportName) -
getEPRProperties
Extract the properties from an endpoint reference.- Parameters:
url- an endpoint reference- Returns:
- the extracted properties
-
loadProperties
Loads the properties from a given property file path- Parameters:
filePath- Path of the property file- Returns:
- Properties loaded from given file
-