You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by gd...@apache.org on 2007/03/04 19:17:07 UTC
svn commit: r514453 [18/26] - in
/webservices/axis2/trunk/java/modules/kernel: src/org/apache/axis2/
src/org/apache/axis2/addressing/ src/org/apache/axis2/addressing/wsdl/
src/org/apache/axis2/builder/ src/org/apache/axis2/client/
src/org/apache/axis2/...
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/ThreadContextMigratorUtil.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/ThreadContextMigratorUtil.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/ThreadContextMigratorUtil.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/ThreadContextMigratorUtil.java Sun Mar 4 10:16:54 2007
@@ -27,126 +27,138 @@
/**
* This is a utility class to make it easier/cleaner for user programming
* model-level implementations (e.g. the Axis2 JAX-WS code) to invoke the
- * ThreadContextMigrators.
+ * ThreadContextMigrators.
*/
public class ThreadContextMigratorUtil {
- /**
- * Register a new ThreadContextMigrator.
- *
- * @param configurationContext
- * @param threadContextMigratorListID The name of the property in the
- * ConfigurationContext that contains
- * the list of migrators.
- * @param migrator
- */
- public static void addThreadContextMigrator(ConfigurationContext configurationContext, String threadContextMigratorListID, ThreadContextMigrator migrator) {
- List migratorList = (List)configurationContext.getProperty(threadContextMigratorListID);
+ /**
+ * Register a new ThreadContextMigrator.
+ *
+ * @param configurationContext
+ * @param threadContextMigratorListID The name of the property in the
+ * ConfigurationContext that contains
+ * the list of migrators.
+ * @param migrator
+ */
+ public static void addThreadContextMigrator(ConfigurationContext configurationContext,
+ String threadContextMigratorListID,
+ ThreadContextMigrator migrator) {
+ List migratorList = (List) configurationContext.getProperty(threadContextMigratorListID);
if (migratorList == null) {
- migratorList = new LinkedList();
- configurationContext.setProperty(threadContextMigratorListID, migratorList);
+ migratorList = new LinkedList();
+ configurationContext.setProperty(threadContextMigratorListID, migratorList);
+ }
+
+ migratorList.add(migrator);
}
-
- migratorList.add(migrator);
- }
-
- /**
- * Activate any registered ThreadContextMigrators to move context info
- * to the thread of execution.
+
+ /**
+ * Activate any registered ThreadContextMigrators to move context info
+ * to the thread of execution.
*
- * @param threadContextMigratorListID The name of the property in the
- * ConfigurationContext that contains
- * the list of migrators.
- * @param msgContext
- * @throws AxisFault
- */
- public static void performMigrationToThread(String threadContextMigratorListID, MessageContext msgContext)
+ * @param threadContextMigratorListID The name of the property in the
+ * ConfigurationContext that contains
+ * the list of migrators.
+ * @param msgContext
+ * @throws AxisFault
+ */
+ public static void performMigrationToThread(String threadContextMigratorListID,
+ MessageContext msgContext)
throws AxisFault {
if (msgContext == null) {
- return;
- }
-
- List migratorList = (List)msgContext.getConfigurationContext().getProperty(threadContextMigratorListID);
-
+ return;
+ }
+
+ List migratorList = (List) msgContext.getConfigurationContext()
+ .getProperty(threadContextMigratorListID);
+
if (migratorList != null) {
- ListIterator threadContextMigrators = migratorList.listIterator();
+ ListIterator threadContextMigrators = migratorList.listIterator();
while (threadContextMigrators.hasNext()) {
- ((ThreadContextMigrator)threadContextMigrators.next()).migrateContextToThread(msgContext);
- }
+ ((ThreadContextMigrator) threadContextMigrators.next())
+ .migrateContextToThread(msgContext);
+ }
+ }
}
- }
- /**
- * Activate any registered ThreadContextMigrators to remove information
- * from the thread of execution if necessary.
- *
- * @param threadContextMigratorListID The name of the property in the
- * ConfigurationContext that contains
- * the list of migrators.
- * @param msgContext
- */
- public static void performThreadCleanup(String threadContextMigratorListID, MessageContext msgContext) {
+ /**
+ * Activate any registered ThreadContextMigrators to remove information
+ * from the thread of execution if necessary.
+ *
+ * @param threadContextMigratorListID The name of the property in the
+ * ConfigurationContext that contains
+ * the list of migrators.
+ * @param msgContext
+ */
+ public static void performThreadCleanup(String threadContextMigratorListID,
+ MessageContext msgContext) {
if (msgContext == null) {
- return;
- }
-
- List migratorList = (List)msgContext.getConfigurationContext().getProperty(threadContextMigratorListID);
-
+ return;
+ }
+
+ List migratorList = (List) msgContext.getConfigurationContext()
+ .getProperty(threadContextMigratorListID);
+
if (migratorList != null) {
- ListIterator threadContextMigrators = migratorList.listIterator();
+ ListIterator threadContextMigrators = migratorList.listIterator();
while (threadContextMigrators.hasNext()) {
- ((ThreadContextMigrator)threadContextMigrators.next()).cleanupThread(msgContext);
- }
+ ((ThreadContextMigrator) threadContextMigrators.next()).cleanupThread(msgContext);
+ }
+ }
}
- }
- /**
- * Activate any registered ThreadContextMigrators to move info from the
- * thread of execution into the context.
- *
- * @param threadContextMigratorListID The name of the property in the
- * ConfigurationContext that contains
- * the list of migrators.
- * @param msgContext
- * @throws AxisFault
- */
- public static void performMigrationToContext(String threadContextMigratorListID, MessageContext msgContext)
+ /**
+ * Activate any registered ThreadContextMigrators to move info from the
+ * thread of execution into the context.
+ *
+ * @param threadContextMigratorListID The name of the property in the
+ * ConfigurationContext that contains
+ * the list of migrators.
+ * @param msgContext
+ * @throws AxisFault
+ */
+ public static void performMigrationToContext(String threadContextMigratorListID,
+ MessageContext msgContext)
throws AxisFault {
if (msgContext == null) {
- return;
- }
-
- List migratorList = (List)msgContext.getConfigurationContext().getProperty(threadContextMigratorListID);
+ return;
+ }
+
+ List migratorList = (List) msgContext.getConfigurationContext()
+ .getProperty(threadContextMigratorListID);
if (migratorList != null) {
- ListIterator threadContextMigrators = migratorList.listIterator();
+ ListIterator threadContextMigrators = migratorList.listIterator();
while (threadContextMigrators.hasNext()) {
- ((ThreadContextMigrator)threadContextMigrators.next()).migrateThreadToContext(msgContext);
- }
+ ((ThreadContextMigrator) threadContextMigrators.next())
+ .migrateThreadToContext(msgContext);
+ }
+ }
}
- }
-
- /**
- * Activate any registered ThreadContextMigrators to remove information from
- * the context if necessary.
- *
- * @param threadContextMigratorListID The name of the property in the
- * ConfigurationContext that contains
- * the list of migrators.
- * @param msgContext
- */
- public static void performContextCleanup(String threadContextMigratorListID, MessageContext msgContext) {
+
+ /**
+ * Activate any registered ThreadContextMigrators to remove information from
+ * the context if necessary.
+ *
+ * @param threadContextMigratorListID The name of the property in the
+ * ConfigurationContext that contains
+ * the list of migrators.
+ * @param msgContext
+ */
+ public static void performContextCleanup(String threadContextMigratorListID,
+ MessageContext msgContext) {
if (msgContext == null) {
- return;
- }
-
- List migratorList = (List)msgContext.getConfigurationContext().getProperty(threadContextMigratorListID);
+ return;
+ }
+
+ List migratorList = (List) msgContext.getConfigurationContext()
+ .getProperty(threadContextMigratorListID);
if (migratorList != null) {
- ListIterator threadContextMigrators = migratorList.listIterator();
+ ListIterator threadContextMigrators = migratorList.listIterator();
while (threadContextMigrators.hasNext()) {
- ((ThreadContextMigrator)threadContextMigrators.next()).cleanupContext(msgContext);
- }
- }
+ ((ThreadContextMigrator) threadContextMigrators.next()).cleanupContext(msgContext);
+ }
+ }
}
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/URLProcessor.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/URLProcessor.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/URLProcessor.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/URLProcessor.java Sun Mar 4 10:16:54 2007
@@ -44,7 +44,7 @@
hostname = namespace.substring(namespace.indexOf(":") + 1);
// remove the leading /
- while (hostname.startsWith("/")){
+ while (hostname.startsWith("/")) {
hostname = hostname.substring(1);
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/UUIDGenerator.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/UUIDGenerator.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/UUIDGenerator.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/UUIDGenerator.java Sun Mar 4 10:16:54 2007
@@ -19,5 +19,5 @@
/**
* @deprecated
*/
-public class UUIDGenerator extends org.apache.axiom.om.util.UUIDGenerator{
+public class UUIDGenerator extends org.apache.axiom.om.util.UUIDGenerator {
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/Utils.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/Utils.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/Utils.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/Utils.java Sun Mar 4 10:16:54 2007
@@ -75,17 +75,20 @@
public static AxisService createSimpleService(QName serviceName, String className, QName opName)
throws AxisFault {
return createSimpleService(serviceName, new RawXMLINOutMessageReceiver(), className,
- opName);
+ opName);
}
- public static AxisService createSimpleServiceforClient(QName serviceName, String className, QName opName)
+ public static AxisService createSimpleServiceforClient(QName serviceName, String className,
+ QName opName)
throws AxisFault {
- return createSimpleServiceforClient(serviceName, new RawXMLINOutMessageReceiver(), className,
- opName);
+ return createSimpleServiceforClient(serviceName, new RawXMLINOutMessageReceiver(),
+ className,
+ opName);
}
public static AxisService createSimpleService(QName serviceName,
- MessageReceiver messageReceiver, String className, QName opName)
+ MessageReceiver messageReceiver, String className,
+ QName opName)
throws AxisFault {
AxisService service = new AxisService(serviceName.getLocalPart());
@@ -97,7 +100,8 @@
axisOp.setMessageReceiver(messageReceiver);
axisOp.setStyle(WSDLConstants.STYLE_RPC);
service.addOperation(axisOp);
- service.mapActionToOperation(Constants.AXIS2_NAMESPACE_URI + "/" + opName.getLocalPart(), axisOp);
+ service.mapActionToOperation(Constants.AXIS2_NAMESPACE_URI + "/" + opName.getLocalPart(),
+ axisOp);
return service;
}
@@ -132,19 +136,22 @@
private static ServiceContext fillServiceContextAndServiceGroupContext(AxisService axisService,
ConfigurationContext configurationContext) {
String serviceGroupContextId = UUIDGenerator.getUUID();
- ServiceGroupContext serviceGroupContext = ContextFactory.createServiceGroupContext(configurationContext,
- (AxisServiceGroup) axisService.getParent());
+ ServiceGroupContext serviceGroupContext =
+ ContextFactory.createServiceGroupContext(configurationContext,
+ (AxisServiceGroup) axisService
+ .getParent());
serviceGroupContext.setId(serviceGroupContextId);
configurationContext.registerServiceGroupContextintoSoapSessionTable(serviceGroupContext);
ServiceContext serviceContext = new ServiceContext(axisService, serviceGroupContext);
-
- ClusterManager clusterManager = configurationContext.getAxisConfiguration().getClusterManager();
- if (clusterManager!=null) {
+
+ ClusterManager clusterManager =
+ configurationContext.getAxisConfiguration().getClusterManager();
+ if (clusterManager != null) {
clusterManager.addContext(serviceGroupContext);
clusterManager.addContext(serviceContext);
}
-
+
return serviceContext;
}
@@ -203,7 +210,8 @@
if (axis2xml.exists()) {
axis2xmlString = axis2xml.getName();
}
- return ConfigurationContextFactory.createConfigurationContextFromFileSystem(file.getAbsolutePath(), axis2xmlString);
+ return ConfigurationContextFactory
+ .createConfigurationContextFromFileSystem(file.getAbsolutePath(), axis2xmlString);
}
public static String getParameterValue(Parameter param) {
@@ -282,7 +290,8 @@
return true;
}
- public static void calculateDefaultModuleVersion(HashMap modules, AxisConfiguration axisConfig) {
+ public static void calculateDefaultModuleVersion(HashMap modules,
+ AxisConfiguration axisConfig) {
Iterator allModules = modules.values().iterator();
HashMap defaultModules = new HashMap();
while (allModules.hasNext()) {
@@ -293,7 +302,8 @@
String currentDefaultVerison = (String) defaultModules.get(moduleNameString);
if (currentDefaultVerison != null) {
// if the module version is null then , that will be ignore in this case
- if (moduleVersionString != null && isLatest(moduleVersionString, currentDefaultVerison)) {
+ if (moduleVersionString != null &&
+ isLatest(moduleVersionString, currentDefaultVerison)) {
defaultModules.put(moduleNameString, moduleVersionString);
}
} else {
@@ -386,22 +396,24 @@
* and otherwise does a simple extract.
* <p/>
* MUST NOT be passed a MessageContext which does not contain a SOAPFault
- *
+ *
* @param messageContext
* @return
*/
- public static AxisFault getInboundFaultFromMessageContext(MessageContext messageContext){
+ public static AxisFault getInboundFaultFromMessageContext(MessageContext messageContext) {
// Get the fault if it's already been extracted by a handler
- AxisFault result = (AxisFault)messageContext.getProperty(Constants.INBOUND_FAULT_OVERRIDE);
+ AxisFault result = (AxisFault) messageContext.getProperty(Constants.INBOUND_FAULT_OVERRIDE);
// Else, extract it from the SOAPBody
- if(result == null){
+ if (result == null) {
SOAPEnvelope envelope = messageContext.getEnvelope();
- if(envelope == null || envelope.getBody() ==null || envelope.getBody().getFault()==null){
+ if (envelope == null || envelope.getBody() == null ||
+ envelope.getBody().getFault() == null) {
// Not going to be able to
- throw new IllegalArgumentException("The MessageContext does not have an associated SOAPFault.");
+ throw new IllegalArgumentException(
+ "The MessageContext does not have an associated SOAPFault.");
}
SOAPFault soapFault = envelope.getBody().getFault();
-
+
// The AxisFault returned needs to have the MessageContext set on it so that
// other programming models can potentially handle the fault with an
// alternate deserialization.
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLChar.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLChar.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLChar.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLChar.java Sun Mar 4 10:16:54 2007
@@ -99,7 +99,7 @@
//
int charRange[] = {
- 0x0009, 0x000A, 0x000D, 0x000D, 0x0020, 0xD7FF, 0xE000, 0xFFFD,
+ 0x0009, 0x000A, 0x000D, 0x000D, 0x0020, 0xD7FF, 0xE000, 0xFFFD,
};
//
@@ -107,7 +107,7 @@
//
int spaceChar[] = {
- 0x0020, 0x0009, 0x000D, 0x000A,
+ 0x0020, 0x0009, 0x000D, 0x000A,
};
//
@@ -116,7 +116,7 @@
//
int nameChar[] = {
- 0x002D, 0x002E, // '-' and '.'
+ 0x002D, 0x002E, // '-' and '.'
};
//
@@ -124,7 +124,7 @@
//
int nameStartChar[] = {
- 0x003A, 0x005F, // ':' and '_'
+ 0x003A, 0x005F, // ':' and '_'
};
//
@@ -132,12 +132,12 @@
//
int pubidChar[] = {
- 0x000A, 0x000D, 0x0020, 0x0021, 0x0023, 0x0024, 0x0025, 0x003D,
- 0x005F
+ 0x000A, 0x000D, 0x0020, 0x0021, 0x0023, 0x0024, 0x0025, 0x003D,
+ 0x005F
};
int pubidRange[] = {
- 0x0027, 0x003B, 0x003F, 0x005A, 0x0061, 0x007A
+ 0x0027, 0x003B, 0x003F, 0x005A, 0x0061, 0x007A
};
//
@@ -145,59 +145,59 @@
//
int letterRange[] = {
- // BaseChar
- 0x0041, 0x005A, 0x0061, 0x007A, 0x00C0, 0x00D6, 0x00D8, 0x00F6,
- 0x00F8, 0x0131, 0x0134, 0x013E, 0x0141, 0x0148, 0x014A, 0x017E,
- 0x0180, 0x01C3, 0x01CD, 0x01F0, 0x01F4, 0x01F5, 0x01FA, 0x0217,
- 0x0250, 0x02A8, 0x02BB, 0x02C1, 0x0388, 0x038A, 0x038E, 0x03A1,
- 0x03A3, 0x03CE, 0x03D0, 0x03D6, 0x03E2, 0x03F3, 0x0401, 0x040C,
- 0x040E, 0x044F, 0x0451, 0x045C, 0x045E, 0x0481, 0x0490, 0x04C4,
- 0x04C7, 0x04C8, 0x04CB, 0x04CC, 0x04D0, 0x04EB, 0x04EE, 0x04F5,
- 0x04F8, 0x04F9, 0x0531, 0x0556, 0x0561, 0x0586, 0x05D0, 0x05EA,
- 0x05F0, 0x05F2, 0x0621, 0x063A, 0x0641, 0x064A, 0x0671, 0x06B7,
- 0x06BA, 0x06BE, 0x06C0, 0x06CE, 0x06D0, 0x06D3, 0x06E5, 0x06E6,
- 0x0905, 0x0939, 0x0958, 0x0961, 0x0985, 0x098C, 0x098F, 0x0990,
- 0x0993, 0x09A8, 0x09AA, 0x09B0, 0x09B6, 0x09B9, 0x09DC, 0x09DD,
- 0x09DF, 0x09E1, 0x09F0, 0x09F1, 0x0A05, 0x0A0A, 0x0A0F, 0x0A10,
- 0x0A13, 0x0A28, 0x0A2A, 0x0A30, 0x0A32, 0x0A33, 0x0A35, 0x0A36,
- 0x0A38, 0x0A39, 0x0A59, 0x0A5C, 0x0A72, 0x0A74, 0x0A85, 0x0A8B,
- 0x0A8F, 0x0A91, 0x0A93, 0x0AA8, 0x0AAA, 0x0AB0, 0x0AB2, 0x0AB3,
- 0x0AB5, 0x0AB9, 0x0B05, 0x0B0C, 0x0B0F, 0x0B10, 0x0B13, 0x0B28,
- 0x0B2A, 0x0B30, 0x0B32, 0x0B33, 0x0B36, 0x0B39, 0x0B5C, 0x0B5D,
- 0x0B5F, 0x0B61, 0x0B85, 0x0B8A, 0x0B8E, 0x0B90, 0x0B92, 0x0B95,
- 0x0B99, 0x0B9A, 0x0B9E, 0x0B9F, 0x0BA3, 0x0BA4, 0x0BA8, 0x0BAA,
- 0x0BAE, 0x0BB5, 0x0BB7, 0x0BB9, 0x0C05, 0x0C0C, 0x0C0E, 0x0C10,
- 0x0C12, 0x0C28, 0x0C2A, 0x0C33, 0x0C35, 0x0C39, 0x0C60, 0x0C61,
- 0x0C85, 0x0C8C, 0x0C8E, 0x0C90, 0x0C92, 0x0CA8, 0x0CAA, 0x0CB3,
- 0x0CB5, 0x0CB9, 0x0CE0, 0x0CE1, 0x0D05, 0x0D0C, 0x0D0E, 0x0D10,
- 0x0D12, 0x0D28, 0x0D2A, 0x0D39, 0x0D60, 0x0D61, 0x0E01, 0x0E2E,
- 0x0E32, 0x0E33, 0x0E40, 0x0E45, 0x0E81, 0x0E82, 0x0E87, 0x0E88,
- 0x0E94, 0x0E97, 0x0E99, 0x0E9F, 0x0EA1, 0x0EA3, 0x0EAA, 0x0EAB,
- 0x0EAD, 0x0EAE, 0x0EB2, 0x0EB3, 0x0EC0, 0x0EC4, 0x0F40, 0x0F47,
- 0x0F49, 0x0F69, 0x10A0, 0x10C5, 0x10D0, 0x10F6, 0x1102, 0x1103,
- 0x1105, 0x1107, 0x110B, 0x110C, 0x110E, 0x1112, 0x1154, 0x1155,
- 0x115F, 0x1161, 0x116D, 0x116E, 0x1172, 0x1173, 0x11AE, 0x11AF,
- 0x11B7, 0x11B8, 0x11BC, 0x11C2, 0x1E00, 0x1E9B, 0x1EA0, 0x1EF9,
- 0x1F00, 0x1F15, 0x1F18, 0x1F1D, 0x1F20, 0x1F45, 0x1F48, 0x1F4D,
- 0x1F50, 0x1F57, 0x1F5F, 0x1F7D, 0x1F80, 0x1FB4, 0x1FB6, 0x1FBC,
- 0x1FC2, 0x1FC4, 0x1FC6, 0x1FCC, 0x1FD0, 0x1FD3, 0x1FD6, 0x1FDB,
- 0x1FE0, 0x1FEC, 0x1FF2, 0x1FF4, 0x1FF6, 0x1FFC, 0x212A, 0x212B,
- 0x2180, 0x2182, 0x3041, 0x3094, 0x30A1, 0x30FA, 0x3105, 0x312C,
- 0xAC00, 0xD7A3,
- // Ideographic
- 0x3021, 0x3029, 0x4E00, 0x9FA5,
+ // BaseChar
+ 0x0041, 0x005A, 0x0061, 0x007A, 0x00C0, 0x00D6, 0x00D8, 0x00F6,
+ 0x00F8, 0x0131, 0x0134, 0x013E, 0x0141, 0x0148, 0x014A, 0x017E,
+ 0x0180, 0x01C3, 0x01CD, 0x01F0, 0x01F4, 0x01F5, 0x01FA, 0x0217,
+ 0x0250, 0x02A8, 0x02BB, 0x02C1, 0x0388, 0x038A, 0x038E, 0x03A1,
+ 0x03A3, 0x03CE, 0x03D0, 0x03D6, 0x03E2, 0x03F3, 0x0401, 0x040C,
+ 0x040E, 0x044F, 0x0451, 0x045C, 0x045E, 0x0481, 0x0490, 0x04C4,
+ 0x04C7, 0x04C8, 0x04CB, 0x04CC, 0x04D0, 0x04EB, 0x04EE, 0x04F5,
+ 0x04F8, 0x04F9, 0x0531, 0x0556, 0x0561, 0x0586, 0x05D0, 0x05EA,
+ 0x05F0, 0x05F2, 0x0621, 0x063A, 0x0641, 0x064A, 0x0671, 0x06B7,
+ 0x06BA, 0x06BE, 0x06C0, 0x06CE, 0x06D0, 0x06D3, 0x06E5, 0x06E6,
+ 0x0905, 0x0939, 0x0958, 0x0961, 0x0985, 0x098C, 0x098F, 0x0990,
+ 0x0993, 0x09A8, 0x09AA, 0x09B0, 0x09B6, 0x09B9, 0x09DC, 0x09DD,
+ 0x09DF, 0x09E1, 0x09F0, 0x09F1, 0x0A05, 0x0A0A, 0x0A0F, 0x0A10,
+ 0x0A13, 0x0A28, 0x0A2A, 0x0A30, 0x0A32, 0x0A33, 0x0A35, 0x0A36,
+ 0x0A38, 0x0A39, 0x0A59, 0x0A5C, 0x0A72, 0x0A74, 0x0A85, 0x0A8B,
+ 0x0A8F, 0x0A91, 0x0A93, 0x0AA8, 0x0AAA, 0x0AB0, 0x0AB2, 0x0AB3,
+ 0x0AB5, 0x0AB9, 0x0B05, 0x0B0C, 0x0B0F, 0x0B10, 0x0B13, 0x0B28,
+ 0x0B2A, 0x0B30, 0x0B32, 0x0B33, 0x0B36, 0x0B39, 0x0B5C, 0x0B5D,
+ 0x0B5F, 0x0B61, 0x0B85, 0x0B8A, 0x0B8E, 0x0B90, 0x0B92, 0x0B95,
+ 0x0B99, 0x0B9A, 0x0B9E, 0x0B9F, 0x0BA3, 0x0BA4, 0x0BA8, 0x0BAA,
+ 0x0BAE, 0x0BB5, 0x0BB7, 0x0BB9, 0x0C05, 0x0C0C, 0x0C0E, 0x0C10,
+ 0x0C12, 0x0C28, 0x0C2A, 0x0C33, 0x0C35, 0x0C39, 0x0C60, 0x0C61,
+ 0x0C85, 0x0C8C, 0x0C8E, 0x0C90, 0x0C92, 0x0CA8, 0x0CAA, 0x0CB3,
+ 0x0CB5, 0x0CB9, 0x0CE0, 0x0CE1, 0x0D05, 0x0D0C, 0x0D0E, 0x0D10,
+ 0x0D12, 0x0D28, 0x0D2A, 0x0D39, 0x0D60, 0x0D61, 0x0E01, 0x0E2E,
+ 0x0E32, 0x0E33, 0x0E40, 0x0E45, 0x0E81, 0x0E82, 0x0E87, 0x0E88,
+ 0x0E94, 0x0E97, 0x0E99, 0x0E9F, 0x0EA1, 0x0EA3, 0x0EAA, 0x0EAB,
+ 0x0EAD, 0x0EAE, 0x0EB2, 0x0EB3, 0x0EC0, 0x0EC4, 0x0F40, 0x0F47,
+ 0x0F49, 0x0F69, 0x10A0, 0x10C5, 0x10D0, 0x10F6, 0x1102, 0x1103,
+ 0x1105, 0x1107, 0x110B, 0x110C, 0x110E, 0x1112, 0x1154, 0x1155,
+ 0x115F, 0x1161, 0x116D, 0x116E, 0x1172, 0x1173, 0x11AE, 0x11AF,
+ 0x11B7, 0x11B8, 0x11BC, 0x11C2, 0x1E00, 0x1E9B, 0x1EA0, 0x1EF9,
+ 0x1F00, 0x1F15, 0x1F18, 0x1F1D, 0x1F20, 0x1F45, 0x1F48, 0x1F4D,
+ 0x1F50, 0x1F57, 0x1F5F, 0x1F7D, 0x1F80, 0x1FB4, 0x1FB6, 0x1FBC,
+ 0x1FC2, 0x1FC4, 0x1FC6, 0x1FCC, 0x1FD0, 0x1FD3, 0x1FD6, 0x1FDB,
+ 0x1FE0, 0x1FEC, 0x1FF2, 0x1FF4, 0x1FF6, 0x1FFC, 0x212A, 0x212B,
+ 0x2180, 0x2182, 0x3041, 0x3094, 0x30A1, 0x30FA, 0x3105, 0x312C,
+ 0xAC00, 0xD7A3,
+ // Ideographic
+ 0x3021, 0x3029, 0x4E00, 0x9FA5,
};
int letterChar[] = {
- // BaseChar
- 0x0386, 0x038C, 0x03DA, 0x03DC, 0x03DE, 0x03E0, 0x0559, 0x06D5,
- 0x093D, 0x09B2, 0x0A5E, 0x0A8D, 0x0ABD, 0x0AE0, 0x0B3D, 0x0B9C,
- 0x0CDE, 0x0E30, 0x0E84, 0x0E8A, 0x0E8D, 0x0EA5, 0x0EA7, 0x0EB0,
- 0x0EBD, 0x1100, 0x1109, 0x113C, 0x113E, 0x1140, 0x114C, 0x114E,
- 0x1150, 0x1159, 0x1163, 0x1165, 0x1167, 0x1169, 0x1175, 0x119E,
- 0x11A8, 0x11AB, 0x11BA, 0x11EB, 0x11F0, 0x11F9, 0x1F59, 0x1F5B,
- 0x1F5D, 0x1FBE, 0x2126, 0x212E,
- // Ideographic
- 0x3007,
+ // BaseChar
+ 0x0386, 0x038C, 0x03DA, 0x03DC, 0x03DE, 0x03E0, 0x0559, 0x06D5,
+ 0x093D, 0x09B2, 0x0A5E, 0x0A8D, 0x0ABD, 0x0AE0, 0x0B3D, 0x0B9C,
+ 0x0CDE, 0x0E30, 0x0E84, 0x0E8A, 0x0E8D, 0x0EA5, 0x0EA7, 0x0EB0,
+ 0x0EBD, 0x1100, 0x1109, 0x113C, 0x113E, 0x1140, 0x114C, 0x114E,
+ 0x1150, 0x1159, 0x1163, 0x1165, 0x1167, 0x1169, 0x1175, 0x119E,
+ 0x11A8, 0x11AB, 0x11BA, 0x11EB, 0x11F0, 0x11F9, 0x1F59, 0x1F5B,
+ 0x1F5D, 0x1FBE, 0x2126, 0x212E,
+ // Ideographic
+ 0x3007,
};
//
@@ -205,30 +205,30 @@
//
int combiningCharRange[] = {
- 0x0300, 0x0345, 0x0360, 0x0361, 0x0483, 0x0486, 0x0591, 0x05A1,
- 0x05A3, 0x05B9, 0x05BB, 0x05BD, 0x05C1, 0x05C2, 0x064B, 0x0652,
- 0x06D6, 0x06DC, 0x06DD, 0x06DF, 0x06E0, 0x06E4, 0x06E7, 0x06E8,
- 0x06EA, 0x06ED, 0x0901, 0x0903, 0x093E, 0x094C, 0x0951, 0x0954,
- 0x0962, 0x0963, 0x0981, 0x0983, 0x09C0, 0x09C4, 0x09C7, 0x09C8,
- 0x09CB, 0x09CD, 0x09E2, 0x09E3, 0x0A40, 0x0A42, 0x0A47, 0x0A48,
- 0x0A4B, 0x0A4D, 0x0A70, 0x0A71, 0x0A81, 0x0A83, 0x0ABE, 0x0AC5,
- 0x0AC7, 0x0AC9, 0x0ACB, 0x0ACD, 0x0B01, 0x0B03, 0x0B3E, 0x0B43,
- 0x0B47, 0x0B48, 0x0B4B, 0x0B4D, 0x0B56, 0x0B57, 0x0B82, 0x0B83,
- 0x0BBE, 0x0BC2, 0x0BC6, 0x0BC8, 0x0BCA, 0x0BCD, 0x0C01, 0x0C03,
- 0x0C3E, 0x0C44, 0x0C46, 0x0C48, 0x0C4A, 0x0C4D, 0x0C55, 0x0C56,
- 0x0C82, 0x0C83, 0x0CBE, 0x0CC4, 0x0CC6, 0x0CC8, 0x0CCA, 0x0CCD,
- 0x0CD5, 0x0CD6, 0x0D02, 0x0D03, 0x0D3E, 0x0D43, 0x0D46, 0x0D48,
- 0x0D4A, 0x0D4D, 0x0E34, 0x0E3A, 0x0E47, 0x0E4E, 0x0EB4, 0x0EB9,
- 0x0EBB, 0x0EBC, 0x0EC8, 0x0ECD, 0x0F18, 0x0F19, 0x0F71, 0x0F84,
- 0x0F86, 0x0F8B, 0x0F90, 0x0F95, 0x0F99, 0x0FAD, 0x0FB1, 0x0FB7,
- 0x20D0, 0x20DC, 0x302A, 0x302F,
+ 0x0300, 0x0345, 0x0360, 0x0361, 0x0483, 0x0486, 0x0591, 0x05A1,
+ 0x05A3, 0x05B9, 0x05BB, 0x05BD, 0x05C1, 0x05C2, 0x064B, 0x0652,
+ 0x06D6, 0x06DC, 0x06DD, 0x06DF, 0x06E0, 0x06E4, 0x06E7, 0x06E8,
+ 0x06EA, 0x06ED, 0x0901, 0x0903, 0x093E, 0x094C, 0x0951, 0x0954,
+ 0x0962, 0x0963, 0x0981, 0x0983, 0x09C0, 0x09C4, 0x09C7, 0x09C8,
+ 0x09CB, 0x09CD, 0x09E2, 0x09E3, 0x0A40, 0x0A42, 0x0A47, 0x0A48,
+ 0x0A4B, 0x0A4D, 0x0A70, 0x0A71, 0x0A81, 0x0A83, 0x0ABE, 0x0AC5,
+ 0x0AC7, 0x0AC9, 0x0ACB, 0x0ACD, 0x0B01, 0x0B03, 0x0B3E, 0x0B43,
+ 0x0B47, 0x0B48, 0x0B4B, 0x0B4D, 0x0B56, 0x0B57, 0x0B82, 0x0B83,
+ 0x0BBE, 0x0BC2, 0x0BC6, 0x0BC8, 0x0BCA, 0x0BCD, 0x0C01, 0x0C03,
+ 0x0C3E, 0x0C44, 0x0C46, 0x0C48, 0x0C4A, 0x0C4D, 0x0C55, 0x0C56,
+ 0x0C82, 0x0C83, 0x0CBE, 0x0CC4, 0x0CC6, 0x0CC8, 0x0CCA, 0x0CCD,
+ 0x0CD5, 0x0CD6, 0x0D02, 0x0D03, 0x0D3E, 0x0D43, 0x0D46, 0x0D48,
+ 0x0D4A, 0x0D4D, 0x0E34, 0x0E3A, 0x0E47, 0x0E4E, 0x0EB4, 0x0EB9,
+ 0x0EBB, 0x0EBC, 0x0EC8, 0x0ECD, 0x0F18, 0x0F19, 0x0F71, 0x0F84,
+ 0x0F86, 0x0F8B, 0x0F90, 0x0F95, 0x0F99, 0x0FAD, 0x0FB1, 0x0FB7,
+ 0x20D0, 0x20DC, 0x302A, 0x302F,
};
int combiningCharChar[] = {
- 0x05BF, 0x05C4, 0x0670, 0x093C, 0x094D, 0x09BC, 0x09BE, 0x09BF,
- 0x09D7, 0x0A02, 0x0A3C, 0x0A3E, 0x0A3F, 0x0ABC, 0x0B3C, 0x0BD7,
- 0x0D57, 0x0E31, 0x0EB1, 0x0F35, 0x0F37, 0x0F39, 0x0F3E, 0x0F3F,
- 0x0F97, 0x0FB9, 0x20E1, 0x3099, 0x309A,
+ 0x05BF, 0x05C4, 0x0670, 0x093C, 0x094D, 0x09BC, 0x09BE, 0x09BF,
+ 0x09D7, 0x0A02, 0x0A3C, 0x0A3E, 0x0A3F, 0x0ABC, 0x0B3C, 0x0BD7,
+ 0x0D57, 0x0E31, 0x0EB1, 0x0F35, 0x0F37, 0x0F39, 0x0F3E, 0x0F3F,
+ 0x0F97, 0x0FB9, 0x20E1, 0x3099, 0x309A,
};
//
@@ -236,10 +236,10 @@
//
int digitRange[] = {
- 0x0030, 0x0039, 0x0660, 0x0669, 0x06F0, 0x06F9, 0x0966, 0x096F,
- 0x09E6, 0x09EF, 0x0A66, 0x0A6F, 0x0AE6, 0x0AEF, 0x0B66, 0x0B6F,
- 0x0BE7, 0x0BEF, 0x0C66, 0x0C6F, 0x0CE6, 0x0CEF, 0x0D66, 0x0D6F,
- 0x0E50, 0x0E59, 0x0ED0, 0x0ED9, 0x0F20, 0x0F29,
+ 0x0030, 0x0039, 0x0660, 0x0669, 0x06F0, 0x06F9, 0x0966, 0x096F,
+ 0x09E6, 0x09EF, 0x0A66, 0x0A6F, 0x0AE6, 0x0AEF, 0x0B66, 0x0B6F,
+ 0x0BE7, 0x0BEF, 0x0C66, 0x0C6F, 0x0CE6, 0x0CEF, 0x0D66, 0x0D6F,
+ 0x0E50, 0x0E59, 0x0ED0, 0x0ED9, 0x0F20, 0x0F29,
};
//
@@ -247,11 +247,11 @@
//
int extenderRange[] = {
- 0x3031, 0x3035, 0x309D, 0x309E, 0x30FC, 0x30FE,
+ 0x3031, 0x3035, 0x309D, 0x309E, 0x30FC, 0x30FE,
};
int extenderChar[] = {
- 0x00B7, 0x02D0, 0x02D1, 0x0387, 0x0640, 0x0E46, 0x0EC6, 0x3005,
+ 0x00B7, 0x02D0, 0x02D1, 0x0387, 0x0640, 0x0E46, 0x0EC6, 0x3005,
};
//
@@ -259,7 +259,7 @@
//
int specialChar[] = {
- '<', '&', '\n', '\r', ']',
+ '<', '&', '\n', '\r', ']',
};
//
@@ -275,7 +275,7 @@
// remove special characters
for (int i = 0; i < specialChar.length; i++) {
- CHARS[specialChar[i]] = (byte)(CHARS[specialChar[i]] & ~MASK_CONTENT);
+ CHARS[specialChar[i]] = (byte) (CHARS[specialChar[i]] & ~MASK_CONTENT);
}
// set space characters
@@ -286,17 +286,17 @@
// set name start characters
for (int i = 0; i < nameStartChar.length; i++) {
CHARS[nameStartChar[i]] |= MASK_NAME_START | MASK_NAME |
- MASK_NCNAME_START | MASK_NCNAME;
+ MASK_NCNAME_START | MASK_NCNAME;
}
for (int i = 0; i < letterRange.length; i += 2) {
for (int j = letterRange[i]; j <= letterRange[i + 1]; j++) {
CHARS[j] |= MASK_NAME_START | MASK_NAME |
- MASK_NCNAME_START | MASK_NCNAME;
+ MASK_NCNAME_START | MASK_NCNAME;
}
}
for (int i = 0; i < letterChar.length; i++) {
CHARS[letterChar[i]] |= MASK_NAME_START | MASK_NAME |
- MASK_NCNAME_START | MASK_NCNAME;
+ MASK_NCNAME_START | MASK_NCNAME;
}
// set name characters
@@ -413,7 +413,7 @@
*/
public static boolean isValid(int c) {
return (c < 0x10000 && (CHARS[c] & MASK_VALID) != 0) ||
- (0x10000 <= c && c <= 0x10FFFF);
+ (0x10000 <= c && c <= 0x10FFFF);
} // isValid(int):boolean
/**
@@ -432,7 +432,7 @@
*/
public static boolean isContent(int c) {
return (c < 0x10000 && (CHARS[c] & MASK_CONTENT) != 0) ||
- (0x10000 <= c && c <= 0x10FFFF);
+ (0x10000 <= c && c <= 0x10FFFF);
} // isContent(int):boolean
/**
@@ -463,7 +463,7 @@
*/
public static boolean isXML11Space(int c) {
return (c < 0x10000 && (CHARS[c] & MASK_SPACE) != 0) ||
- c == 0x85 || c == 0x2028;
+ c == 0x85 || c == 0x2028;
} // isXML11Space(int):boolean
/**
@@ -537,13 +537,13 @@
}
char ch = name.charAt(0);
if (!isNameStart(ch)) {
- return false;
+ return false;
}
- for (int i = 1; i < name.length(); i++ ) {
- ch = name.charAt(i);
- if(!isName(ch) ){
- return false;
- }
+ for (int i = 1; i < name.length(); i++) {
+ ch = name.charAt(i);
+ if (!isName(ch)) {
+ return false;
+ }
}
return true;
} // isValidName(String):boolean
@@ -566,13 +566,13 @@
}
char ch = ncName.charAt(0);
if (!isNCNameStart(ch)) {
- return false;
+ return false;
}
- for (int i = 1; i < ncName.length(); i++ ) {
- ch = ncName.charAt(i);
- if(!isNCName(ch) ){
- return false;
- }
+ for (int i = 1; i < ncName.length(); i++) {
+ ch = ncName.charAt(i);
+ if (!isNCName(ch)) {
+ return false;
+ }
}
return true;
} // isValidNCName(String):boolean
@@ -591,19 +591,15 @@
if (nmtoken.length() == 0) {
return false;
}
- for (int i = 0; i < nmtoken.length(); i++ ) {
- char ch = nmtoken.charAt(i);
- if( ! isName( ch ) ){
- return false;
- }
+ for (int i = 0; i < nmtoken.length(); i++) {
+ char ch = nmtoken.charAt(i);
+ if (! isName(ch)) {
+ return false;
+ }
}
return true;
} // isValidName(String):boolean
-
-
-
-
// encodings
/**
@@ -623,8 +619,8 @@
for (int i = 1; i < length; i++) {
c = ianaEncoding.charAt(i);
if ((c < 'A' || c > 'Z') && (c < 'a' || c > 'z') &&
- (c < '0' || c > '9') && c != '.' && c != '_' &&
- c != '-') {
+ (c < '0' || c > '9') && c != '.' && c != '_' &&
+ c != '-') {
return false;
}
}
@@ -650,8 +646,8 @@
for (int i = 1; i < length; i++) {
char c = javaEncoding.charAt(i);
if ((c < 'A' || c > 'Z') && (c < 'a' || c > 'z') &&
- (c < '0' || c > '9') && c != '.' && c != '_' &&
- c != '-') {
+ (c < '0' || c > '9') && c != '.' && c != '_' &&
+ c != '-') {
return false;
}
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLPrettyPrinter.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLPrettyPrinter.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLPrettyPrinter.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLPrettyPrinter.java Sun Mar 4 10:16:54 2007
@@ -24,10 +24,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
/**
- * An XML pretty printer based on jtidy (http://sourceforge.net/projects/jtidy)
- * The Jtidy jar needs to be in classpath for this to work and can be found at
- * http://sourceforge.net/project/showfiles.php?group_id=13153
+ * An XML pretty printer based on jtidy (http://sourceforge.net/projects/jtidy)
+ * The Jtidy jar needs to be in classpath for this to work and can be found at
+ * http://sourceforge.net/project/showfiles.php?group_id=13153
*/
public class XMLPrettyPrinter {
@@ -41,7 +42,7 @@
* @param file
*/
public static void prettify(File file) {
- try{
+ try {
// Create an instance of the Jalopy bean
Class clazz = Loader.loadClass("org.w3c.tidy.Tidy");
Object prettifier = clazz.newInstance();
@@ -51,14 +52,14 @@
"setXmlTags",
new Class[]{boolean.class});
setXmlInFlagMethod.invoke(prettifier,
- new Object[]{Boolean.TRUE});
+ new Object[]{Boolean.TRUE});
//set the output to be xml
Method setXmlOutFlagMethod = clazz.getMethod(
"setXmlOut",
new Class[]{boolean.class});
setXmlOutFlagMethod.invoke(prettifier,
- new Object[]{Boolean.TRUE});
+ new Object[]{Boolean.TRUE});
//create the input stream
InputStream input = new FileInputStream(file);
@@ -87,7 +88,7 @@
//delete the original
file.delete();
- if (!tempFile.renameTo(new File(existingFileName))){
+ if (!tempFile.renameTo(new File(existingFileName))) {
throw new Exception("File renaming failed!" + existingFileName);
}
log.debug("Pretty printed file : " + file);
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLUtils.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLUtils.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLUtils.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XMLUtils.java Sun Mar 4 10:16:54 2007
@@ -51,7 +51,6 @@
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamResult;
-
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
@@ -69,11 +68,11 @@
public class XMLUtils {
public static final String charEncoding = "ISO-8859-1";
private static final String saxParserFactoryProperty =
- "javax.xml.parsers.SAXParserFactory";
+ "javax.xml.parsers.SAXParserFactory";
private static DocumentBuilderFactory dbf = getDOMFactory();
- private static SAXParserFactory saxFactory;
- private static Stack saxParsers = new Stack();
+ private static SAXParserFactory saxFactory;
+ private static Stack saxParsers = new Stack();
private static String empty = "";
private static ByteArrayInputStream bais = new ByteArrayInputStream(empty.getBytes());
@@ -83,7 +82,7 @@
initSAXFactory(null, true, false);
}
- /**
+ /**
* Initializes the SAX parser factory.
*
* @param factoryClassName The (optional) class name of the desired
@@ -93,16 +92,16 @@
* unless this property is already set.
* If <code>null</code>, leaves current setting
* alone.
- * @param namespaceAware true if we want a namespace-aware parser
- * @param validating true if we want a validating parser
+ * @param namespaceAware true if we want a namespace-aware parser
+ * @param validating true if we want a validating parser
*/
public static void initSAXFactory(String factoryClassName,
boolean namespaceAware,
boolean validating) {
if (factoryClassName != null) {
try {
- saxFactory = (SAXParserFactory)Loader.loadClass(factoryClassName).
- newInstance();
+ saxFactory = (SAXParserFactory) Loader.loadClass(factoryClassName).
+ newInstance();
/*
* Set the system property only if it is not already set to
* avoid corrupting environments in which Axis is embedded.
@@ -115,7 +114,7 @@
//log.error(Messages.getMessage("exception00"), e);
saxFactory = null;
}
- } else {
+ } else {
saxFactory = SAXParserFactory.newInstance();
}
saxFactory.setNamespaceAware(namespaceAware);
@@ -131,16 +130,16 @@
dbf = DocumentBuilderFactory.newInstance();
dbf.setNamespaceAware(true);
}
- catch( Exception e ) {
+ catch (Exception e) {
//log.error(Messages.getMessage("exception00"), e );
dbf = null;
}
- return( dbf );
+ return (dbf);
}
-
- private static boolean tryReset= true;
- /**
+ private static boolean tryReset = true;
+
+ /**
* Returns a SAX parser for reuse.
*
* @param parser A SAX parser that is available for reuse
@@ -151,17 +150,17 @@
}
//Free up possible ref. held by past contenthandler.
- try{
- XMLReader xmlReader= parser.getXMLReader();
- if(null != xmlReader){
- synchronized (XMLUtils.class ) {
+ try {
+ XMLReader xmlReader = parser.getXMLReader();
+ if (null != xmlReader) {
+ synchronized (XMLUtils.class) {
saxParsers.push(parser);
}
} else {
- tryReset= false;
+ tryReset = false;
}
} catch (org.xml.sax.SAXException e) {
- tryReset= false;
+ tryReset = false;
}
}
@@ -171,7 +170,7 @@
* @return Returns Document.
* @throws ParserConfigurationException if construction problems occur
*/
- public static Document newDocument()
+ public static Document newDocument()
throws ParserConfigurationException {
synchronized (dbf) {
return dbf.newDocumentBuilder().newDocument();
@@ -183,8 +182,8 @@
*
* @return Returns Document.
* @throws ParserConfigurationException if construction problems occur
- * @throws SAXException if the document has xml sax problems
- * @throws IOException if i/o exceptions occur
+ * @throws SAXException if the document has xml sax problems
+ * @throws IOException if i/o exceptions occur
*/
public static Document newDocument(InputSource inp)
throws ParserConfigurationException, SAXException, IOException {
@@ -193,8 +192,8 @@
db = dbf.newDocumentBuilder();
}
db.setEntityResolver(new DefaultEntityResolver());
- db.setErrorHandler( new ParserErrorHandler() );
- return( db.parse( inp ) );
+ db.setErrorHandler(new ParserErrorHandler());
+ return (db.parse(inp));
}
/**
@@ -202,63 +201,62 @@
*
* @return Returns Document.
* @throws ParserConfigurationException if construction problems occur
- * @throws SAXException if the document has xml sax problems
- * @throws IOException if i/o exceptions occur
+ * @throws SAXException if the document has xml sax problems
+ * @throws IOException if i/o exceptions occur
*/
- public static Document newDocument(InputStream inp)
+ public static Document newDocument(InputStream inp)
throws ParserConfigurationException, SAXException, IOException {
return XMLUtils.newDocument(new InputSource(inp));
- }
+ }
/**
* Gets a new Document read from the indicated uri
*
* @return Returns Document.
* @throws ParserConfigurationException if construction problems occur
- * @throws SAXException if the document has xml sax problems
- * @throws IOException if i/o exceptions occur
+ * @throws SAXException if the document has xml sax problems
+ * @throws IOException if i/o exceptions occur
*/
- public static Document newDocument(String uri)
+ public static Document newDocument(String uri)
throws ParserConfigurationException, SAXException, IOException {
// call the authenticated version as there might be
// username/password info embeded in the uri.
return XMLUtils.newDocument(uri, null, null);
}
-
+
/**
* Creates a new document from the given URI. Uses the username and password
* if the URI requires authentication.
*
- * @param uri the resource to get
+ * @param uri the resource to get
* @param username basic auth username
* @param password basic auth password
* @throws ParserConfigurationException if construction problems occur
- * @throws SAXException if the document has xml sax problems
- * @throws IOException if i/o exceptions occur
- */
+ * @throws SAXException if the document has xml sax problems
+ * @throws IOException if i/o exceptions occur
+ */
public static Document newDocument(String uri, String username, String password)
throws ParserConfigurationException, SAXException, IOException {
- InputSource ins = XMLUtils.getInputSourceFromURI(uri, username, password);
- Document doc = XMLUtils.newDocument(ins);
- // Close the Stream
- if (ins.getByteStream() != null) {
- ins.getByteStream().close();
- } else if (ins.getCharacterStream() != null) {
- ins.getCharacterStream().close();
- }
- return doc;
- }
-
+ InputSource ins = XMLUtils.getInputSourceFromURI(uri, username, password);
+ Document doc = XMLUtils.newDocument(ins);
+ // Close the Stream
+ if (ins.getByteStream() != null) {
+ ins.getByteStream().close();
+ } else if (ins.getCharacterStream() != null) {
+ ins.getCharacterStream().close();
+ }
+ return doc;
+ }
public static String getPrefix(String uri, Node e) {
while (e != null && (e.getNodeType() == Element.ELEMENT_NODE)) {
NamedNodeMap attrs = e.getAttributes();
for (int n = 0; n < attrs.getLength(); n++) {
- Attr a = (Attr)attrs.item(n);
+ Attr a = (Attr) attrs.item(n);
String name;
if ((name = a.getName()).startsWith("xmlns:") &&
- a.getNodeValue().equals(uri)) {
+ a.getNodeValue().equals(uri)) {
return name.substring(6);
}
}
@@ -270,7 +268,7 @@
public static String getNamespace(String prefix, Node e) {
while (e != null && (e.getNodeType() == Node.ELEMENT_NODE)) {
Attr attr =
- ((Element)e).getAttributeNodeNS(Constants.NS_URI_XMLNS, prefix);
+ ((Element) e).getAttributeNodeNS(Constants.NS_URI_XMLNS, prefix);
if (attr != null) {
return attr.getValue();
}
@@ -318,41 +316,41 @@
prefix = "ns" + i;
}
e.setAttributeNS(Constants.NS_URI_XMLNS,
- "xmlns:" + prefix, uri);
+ "xmlns:" + prefix, uri);
}
return prefix + ":" + qname.getLocalPart();
}
- /**
- * Concatinates all the text and cdata node children of this elem and returns
- * the resulting text.
- * (by Matt Duftler)
- *
- * @param parentEl the element whose cdata/text node values are to
- * be combined.
- * @return Returns the concatinated string.
- */
- public static String getChildCharacterData (Element parentEl) {
- if (parentEl == null) {
- return null;
- }
- Node tempNode = parentEl.getFirstChild();
- StringBuffer strBuf = new StringBuffer();
- CharacterData charData;
-
- while (tempNode != null) {
- switch (tempNode.getNodeType()) {
- case Node.TEXT_NODE :
+ /**
+ * Concatinates all the text and cdata node children of this elem and returns
+ * the resulting text.
+ * (by Matt Duftler)
+ *
+ * @param parentEl the element whose cdata/text node values are to
+ * be combined.
+ * @return Returns the concatinated string.
+ */
+ public static String getChildCharacterData(Element parentEl) {
+ if (parentEl == null) {
+ return null;
+ }
+ Node tempNode = parentEl.getFirstChild();
+ StringBuffer strBuf = new StringBuffer();
+ CharacterData charData;
+
+ while (tempNode != null) {
+ switch (tempNode.getNodeType()) {
+ case Node.TEXT_NODE :
case Node.CDATA_SECTION_NODE:
charData = (CharacterData) tempNode;
- strBuf.append(charData.getData());
- break;
- }
- tempNode = tempNode.getNextSibling();
- }
- return strBuf.toString();
- }
-
+ strBuf.append(charData.getData());
+ break;
+ }
+ tempNode = tempNode.getNextSibling();
+ }
+ return strBuf.toString();
+ }
+
public static class ParserErrorHandler implements ErrorHandler {
/**
* Returns a string describing parse exception details
@@ -363,8 +361,8 @@
systemId = "null";
}
return "URI=" + systemId +
- " Line=" + spe.getLineNumber() +
- ": " + spe.getMessage();
+ " Line=" + spe.getLineNumber() +
+ ": " + spe.getMessage();
}
// The following methods are standard SAX ErrorHandler methods.
@@ -372,7 +370,7 @@
public void warning(SAXParseException spe) throws SAXException {
}
-
+
public void error(SAXParseException spe) throws SAXException {
String message = "Error: " + getParseExceptionInfo(spe);
throw new SAXException(message);
@@ -387,7 +385,7 @@
/**
* Utility to get the bytes uri.
- * Does NOT handle authenticated URLs,
+ * Does NOT handle authenticated URLs,
* use getInputSourceFromURI(uri, username, password)
*
* @param uri the resource to get
@@ -406,11 +404,11 @@
* <p/>
* If no username is provided, creates an InputSource from the uri
* and lets the InputSource go fetch the contents.
- *
- * @param uri the resource to get
+ *
+ * @param uri the resource to get
* @param username basic auth username
* @param password basic auth password
- */
+ */
private static InputSource getInputSourceFromURI(String uri,
String username,
String password)
@@ -423,12 +421,12 @@
// let InputSource deal with it
return new InputSource(uri);
}
-
+
// if no authentication, just let InputSource deal with it
if (username == null && wsdlurl.getUserInfo() == null) {
return new InputSource(uri);
}
-
+
// if this is not an HTTP{S} url, let InputSource deal with it
if (!wsdlurl.getProtocol().startsWith("http")) {
return new InputSource(uri);
@@ -457,13 +455,13 @@
} else if (username != null) {
auth = (password == null) ? username : username + ":" + password;
}
-
+
if (auth != null) {
uconn.setRequestProperty("Authorization",
- "Basic " +
- base64encode(auth.getBytes(charEncoding)));
+ "Basic " +
+ base64encode(auth.getBytes(charEncoding)));
}
-
+
uconn.connect();
return new InputSource(uconn.getInputStream());
@@ -476,29 +474,29 @@
public static InputSource getEmptyInputSource() {
return new InputSource(bais);
}
-
+
/**
* Finds a Node with a given QNameb.
- *
+ *
* @param node parent node
* @param name QName of the child we need to find
* @return Returns child node.
- */
- public static Node findNode(Node node, QName name){
- if(name.getNamespaceURI().equals(node.getNamespaceURI()) &&
+ */
+ public static Node findNode(Node node, QName name) {
+ if (name.getNamespaceURI().equals(node.getNamespaceURI()) &&
name.getLocalPart().equals(node.getLocalName())) {
return node;
}
NodeList children = node.getChildNodes();
- for(int i=0;i<children.getLength();i++){
+ for (int i = 0; i < children.getLength(); i++) {
Node ret = findNode(children.item(i), name);
if (ret != null) {
return ret;
- }
+ }
}
return null;
}
-
+
/**
* Converts a given DOM Element to an OMElement.
*
@@ -509,7 +507,7 @@
public static OMElement toOM(Element element) throws Exception {
Source source = new DOMSource(element);
-
+
ByteArrayOutputStream baos = new ByteArrayOutputStream();
Result result = new StreamResult(baos);
@@ -525,7 +523,7 @@
return builder.getDocumentElement();
}
-
+
/**
* Converts a given OMElement to a DOM Element.
@@ -535,13 +533,13 @@
* @throws Exception
*/
public static Element toDOM(OMElement element) throws Exception {
- ByteArrayOutputStream baos = new ByteArrayOutputStream();
- element.serialize(baos);
- ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());
-
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- factory.setNamespaceAware(true);
- return factory.newDocumentBuilder().parse(bais).getDocumentElement();
+ ByteArrayOutputStream baos = new ByteArrayOutputStream();
+ element.serialize(baos);
+ ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());
+
+ DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
+ factory.setNamespaceAware(true);
+ return factory.newDocumentBuilder().parse(bais).getDocumentElement();
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XSLTTemplateProcessor.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XSLTTemplateProcessor.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XSLTTemplateProcessor.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/XSLTTemplateProcessor.java Sun Mar 4 10:16:54 2007
@@ -61,7 +61,7 @@
/**
* Parses an XML stream with an XSL stream
*
- * @param out Stream to write the output
+ * @param out Stream to write the output
* @param doc
* @param transformer
* @throws TransformerFactoryConfigurationError
@@ -79,7 +79,6 @@
}
-
/**
* @param out
* @param document
@@ -131,19 +130,19 @@
throws TransformerFactoryConfigurationError, TransformerException {
Source xsltSource = new StreamSource(xsltStream);
TransformerFactory transformerFactory = TransformerFactory.newInstance();
- if(pretty) {
+ if (pretty) {
try {
transformerFactory.setAttribute("indent-number", new Integer(2));
} catch (Exception e) {
}
}
- if (customResolver!=null){
- transformerFactory.setURIResolver(customResolver);
+ if (customResolver != null) {
+ transformerFactory.setURIResolver(customResolver);
}
-
+
Transformer transformer = transformerFactory
.newTransformer(xsltSource);
- if(pretty) {
+ if (pretty) {
try {
transformer.setOutputProperty("{http://xml.apache.org/xalan}indent-amount", "2");
} catch (Exception e) {
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/DefaultThreadFactory.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/DefaultThreadFactory.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/DefaultThreadFactory.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/DefaultThreadFactory.java Sun Mar 4 10:16:54 2007
@@ -23,7 +23,7 @@
* Creates threads with the given name prefix
*/
public class DefaultThreadFactory implements ThreadFactory {
-
+
final ThreadGroup group;
final AtomicInteger count;
final String namePrefix;
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/ThreadPool.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/ThreadPool.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/ThreadPool.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/threadpool/ThreadPool.java Sun Mar 4 10:16:54 2007
@@ -41,16 +41,16 @@
protected static long SLEEP_INTERVAL = 1000;
private static boolean shutDown;
protected ThreadPoolExecutor executor;
-
+
//integers that define the pool size, with the default values set.
private int corePoolSize = 5;
private int maxPoolSize = Integer.MAX_VALUE;
-
+
public ThreadPool() {
setExecutor(createDefaultExecutor("Axis2 Task", Thread.NORM_PRIORITY, true));
}
-
- public ThreadPool(int corePoolSize,int maxPoolSize) {
+
+ public ThreadPool(int corePoolSize, int maxPoolSize) {
this.corePoolSize = corePoolSize;
this.maxPoolSize = maxPoolSize;
setExecutor(createDefaultExecutor("Axis2 Task", Thread.NORM_PRIORITY, true));
@@ -99,36 +99,52 @@
protected ThreadPoolExecutor createDefaultExecutor(final String name,
final int priority,
final boolean daemon) {
- ThreadPoolExecutor rc = new ThreadPoolExecutor(corePoolSize , maxPoolSize , 10,
- TimeUnit.SECONDS, new SynchronousQueue(),
- new edu.emory.mathcs.backport.java.util.concurrent.ThreadFactory() {
- public Thread newThread(final Runnable runnable) {
- // do the following section as privileged
- // so that it will work even when java2 security
- // has been enabled
- Thread returnThread = null;
- try {
- returnThread = (Thread) AccessController.doPrivileged(
- new PrivilegedExceptionAction() {
- public Object run() {
- Thread newThread = new Thread(runnable, name);
- newThread.setDaemon(daemon);
- newThread.setPriority(priority);
- return newThread;
- }
- }
- );
- }
- catch(PrivilegedActionException e) {
- // note: inner class can't have its own static log variable
- if (log.isDebugEnabled()) {
- log.debug("ThreadPoolExecutor.newThread(): Exception from AccessController ["+e.getClass().getName()+"] for ["+e.getMessage()+"]", e);
- }
- }
- return returnThread;
+ ThreadPoolExecutor rc = new ThreadPoolExecutor(corePoolSize, maxPoolSize, 10,
+ TimeUnit.SECONDS, new SynchronousQueue(),
+ new edu.emory.mathcs.backport.java.util.concurrent.ThreadFactory() {
+ public Thread newThread(
+ final Runnable runnable) {
+ // do the following section as privileged
+ // so that it will work even when java2 security
+ // has been enabled
+ Thread returnThread = null;
+ try {
+ returnThread =
+ (Thread) AccessController
+ .doPrivileged(
+ new PrivilegedExceptionAction() {
+ public Object run() {
+ Thread newThread =
+ new Thread(
+ runnable,
+ name);
+ newThread
+ .setDaemon(
+ daemon);
+ newThread
+ .setPriority(
+ priority);
+ return newThread;
+ }
+ }
+ );
+ }
+ catch (PrivilegedActionException e) {
+ // note: inner class can't have its own static log variable
+ if (log.isDebugEnabled()) {
+ log.debug(
+ "ThreadPoolExecutor.newThread(): Exception from AccessController [" +
+ e.getClass()
+ .getName() +
+ "] for [" +
+ e.getMessage() +
+ "]", e);
+ }
+ }
+ return returnThread;
- }
- });
+ }
+ });
rc.allowCoreThreadTimeOut(true);
return rc;
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPHeaderMessage.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPHeaderMessage.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPHeaderMessage.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPHeaderMessage.java Sun Mar 4 10:16:54 2007
@@ -85,8 +85,8 @@
public void setNamespaceURI(String namespaceURI) {
this.namespaceURI = namespaceURI;
}
-
- public boolean isRequired() {
+
+ public boolean isRequired() {
return required;
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPModuleMessage.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPModuleMessage.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPModuleMessage.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/SOAPModuleMessage.java Sun Mar 4 10:16:54 2007
@@ -1,6 +1,5 @@
package org.apache.axis2.wsdl;
-
/*
* Copyright 2004,2005 The Apache Software Foundation.
*
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLConstants.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLConstants.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLConstants.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLConstants.java Sun Mar 4 10:16:54 2007
@@ -24,7 +24,7 @@
public interface WSDLConstants {
String WSDL_1_1_STYLE = "style";
-
+
String STYLE_RPC = "rpc";
String STYLE_DOC = "document";
String STYLE_MSG = "msg";
@@ -56,7 +56,6 @@
public static final String HTTP_HEADER = "http_header";
-
/**
* Field WSDL_MESSAGE_DIRECTION_OUT
*/
@@ -138,11 +137,10 @@
public static final int MEP_CONSTANT_IN_OUT = 12;
public static final int MEP_CONSTANT_IN_OPTIONAL_OUT = 13;
int MEP_CONSTANT_OUT_OPTIONAL_IN = 17;
- int MEP_CONSTANT_INVALID = -1;
+ int MEP_CONSTANT_INVALID = -1;
int MEP_CONSTANT_ROBUST_OUT_ONLY = 15;
-
public static interface WSDL20_2006Constants {
// http://www.w3.org/TR/2006/CR-wsdl20-adjuncts-20060327/#in-only
@@ -169,7 +167,7 @@
public String NMTOKEN_ELEMENT = "#element";
}
-
+
public static interface WSDL20_2004_Constants {
public String MEP_URI_IN_ONLY = "http://www.w3.org/2004/08/wsdl/in-only";
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLUtil.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLUtil.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLUtil.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/WSDLUtil.java Sun Mar 4 10:16:54 2007
@@ -29,11 +29,11 @@
* @param mep
*/
public static boolean isInputPresentForMEP(String mep) {
- return WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OPTIONAL_OUT.equals(mep)||
- WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_ONLY.equals(mep)||
- WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OUT.equals(mep)||
- WSDLConstants.WSDL20_2006Constants.MEP_URI_OUT_IN.equals(mep)||
- WSDLConstants.WSDL20_2006Constants.MEP_URI_OUT_OPTIONAL_IN.equals(mep)||
+ return WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OPTIONAL_OUT.equals(mep) ||
+ WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_ONLY.equals(mep) ||
+ WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OUT.equals(mep) ||
+ WSDLConstants.WSDL20_2006Constants.MEP_URI_OUT_IN.equals(mep) ||
+ WSDLConstants.WSDL20_2006Constants.MEP_URI_OUT_OPTIONAL_IN.equals(mep) ||
WSDLConstants.WSDL20_2006Constants.MEP_URI_ROBUST_IN_ONLY.equals(mep);
}
@@ -43,7 +43,7 @@
* @param MEP
*/
public static boolean isOutputPresentForMEP(String MEP) {
- return WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OPTIONAL_OUT.equals(MEP) ||
+ return WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OPTIONAL_OUT.equals(MEP) ||
WSDLConstants.WSDL20_2006Constants.MEP_URI_IN_OUT.equals(MEP) ||
WSDLConstants.WSDL20_2006Constants.MEP_URI_OUT_IN.equals(MEP) ||
WSDLConstants.WSDL20_2006Constants.MEP_URI_OUT_ONLY.equals(MEP) ||
@@ -52,7 +52,7 @@
}
/**
- * part names are not unique across messages. Hence
+ * part names are not unique across messages. Hence
* we need some way of making the part name a unique
* one (due to the fact that the type mapper
* is a global list of types).
@@ -69,8 +69,8 @@
*/
public static QName getPartQName(String opName,
String suffix,
- String partName){
- return new QName(opName+suffix,partName);
+ String partName) {
+ return new QName(opName + suffix, partName);
}
}
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/util/WSDL4JImportedWSDLHelper.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/util/WSDL4JImportedWSDLHelper.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/util/WSDL4JImportedWSDLHelper.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/wsdl/util/WSDL4JImportedWSDLHelper.java Sun Mar 4 10:16:54 2007
@@ -58,7 +58,8 @@
Object prefix;
- for (Iterator prefix_iterator = imported_def_namespaces.keySet().iterator(); prefix_iterator.hasNext();) {
+ for (Iterator prefix_iterator = imported_def_namespaces.keySet().iterator();
+ prefix_iterator.hasNext();) {
prefix = prefix_iterator.next();
if (!def_namespaces.containsKey(prefix)) {
Modified: webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/Echo2.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/Echo2.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/Echo2.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/Echo2.java Sun Mar 4 10:16:54 2007
@@ -19,7 +19,7 @@
*/
public class Echo2 {
- public SOAPEnvelope echo(SOAPEnvelope in){
+ public SOAPEnvelope echo(SOAPEnvelope in) {
return in;
}
}
Modified: webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/InavalidModuleImpl.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/InavalidModuleImpl.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/InavalidModuleImpl.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/InavalidModuleImpl.java Sun Mar 4 10:16:54 2007
@@ -41,6 +41,6 @@
public boolean canSupportAssertion(Assertion assertion) {
return true;
}
-
-
+
+
}
Modified: webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/ModuleHandler1.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/ModuleHandler1.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/ModuleHandler1.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/ModuleHandler1.java Sun Mar 4 10:16:54 2007
@@ -37,7 +37,7 @@
public InvocationResponse invoke(MessageContext msgContext) throws AxisFault {
log.info("I am " + message + " Handler Running :)");
- return InvocationResponse.CONTINUE;
+ return InvocationResponse.CONTINUE;
}
public void revoke(MessageContext msgContext) {
Modified: webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/addressing/AddressingHelperTest.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/addressing/AddressingHelperTest.java?view=diff&rev=514453&r1=514452&r2=514453
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/addressing/AddressingHelperTest.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/test/org/apache/axis2/addressing/AddressingHelperTest.java Sun Mar 4 10:16:54 2007
@@ -15,9 +15,8 @@
*/
package org.apache.axis2.addressing;
-import org.apache.axis2.context.MessageContext;
-
import junit.framework.TestCase;
+import org.apache.axis2.context.MessageContext;
public class AddressingHelperTest extends TestCase {
@@ -25,17 +24,19 @@
MessageContext mc = new MessageContext();
assertFalse(AddressingHelper.isReplyRedirected(mc));
}
+
public void testIsReplyRedirectedAnonReplyTo() {
MessageContext mc = new MessageContext();
mc.setReplyTo(new EndpointReference(AddressingConstants.Final.WSA_ANONYMOUS_URL));
assertFalse(AddressingHelper.isReplyRedirected(mc));
}
+
public void testIsReplyRedirectedNonAnonReplyTo() {
MessageContext mc = new MessageContext();
mc.setReplyTo(new EndpointReference("http://ws.apache.org/axis2"));
assertTrue(AddressingHelper.isReplyRedirected(mc));
}
-
+
public void testIsFaultRedirectedNoFaultToOrReplyTo() {
MessageContext mc = new MessageContext();
assertFalse(AddressingHelper.isFaultRedirected(mc));
@@ -46,7 +47,7 @@
mc.setFaultTo(new EndpointReference(AddressingConstants.Final.WSA_ANONYMOUS_URL));
assertFalse(AddressingHelper.isFaultRedirected(mc));
}
-
+
public void testIsFaultRedirectedNonAnonFaultTo() {
MessageContext mc = new MessageContext();
mc.setFaultTo(new EndpointReference("http://ws.apache.org/axis2"));
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org