You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by co...@apache.org on 2017/02/14 09:49:29 UTC
[24/51] [partial] cxf git commit: Remove all trailing whitespaces
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/client/Client.java b/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/client/Client.java
index 5915ffe..d98f033 100644
--- a/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/client/Client.java
+++ b/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/client/Client.java
@@ -58,15 +58,15 @@ public final class Client {
} else {
wsdlURL = new URL(args[0]);
}
-
+
HeaderService hs = new HeaderService(wsdlURL, SERVICE_NAME);
HeaderTester proxy = hs.getSoapPort();
invokeInHeader(proxy);
- invokeOutHeader(proxy);
- invokeInOutHeader(proxy);
+ invokeOutHeader(proxy);
+ invokeInOutHeader(proxy);
}
-
+
private static void invokeInHeader(HeaderTester proxy) {
// invoke inHeader operation
System.out.println("Invoking inHeader operation");
@@ -80,7 +80,7 @@ public final class Client {
System.out.println("\t\tResult: " + response.getResponseType());
}
- private static void invokeOutHeader(HeaderTester proxy) {
+ private static void invokeOutHeader(HeaderTester proxy) {
// invoke outHeaderoperation
System.out.println("Invoking outHeader operation");
OutHeader me = new OutHeader();
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/server/HeaderTesterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/server/HeaderTesterImpl.java b/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/server/HeaderTesterImpl.java
index 42a602e..f350d8d 100644
--- a/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/server/HeaderTesterImpl.java
+++ b/distribution/src/main/release/samples/soap_header/src/main/java/demo/soap_header/server/HeaderTesterImpl.java
@@ -32,8 +32,8 @@ import org.apache.headers.OutHeaderResponse;
import org.apache.headers.SOAPHeaderData;
-@javax.jws.WebService(serviceName = "HeaderService",
- portName = "SoapPort",
+@javax.jws.WebService(serviceName = "HeaderService",
+ portName = "SoapPort",
endpointInterface = "org.apache.headers.HeaderTester",
targetNamespace = "http://apache.org/headers")
@@ -52,7 +52,7 @@ public class HeaderTesterImpl implements HeaderTester {
return ihr;
}
- public void outHeader(OutHeader me,
+ public void outHeader(OutHeader me,
Holder<OutHeaderResponse> theResponse,
Holder<SOAPHeaderData> headerInfo) {
System.out.println("outHeader invoked");
@@ -87,5 +87,5 @@ public class HeaderTesterImpl implements HeaderTester {
iohr.setResponseType("Hello " + me.getRequestType());
return iohr;
- }
+ }
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/Client.java b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/Client.java
index 94e2788..fee0536 100644
--- a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/Client.java
+++ b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/Client.java
@@ -42,12 +42,12 @@ public final class Client {
}
public static void main(String args[]) throws Exception {
-
+
if (args.length < 2) {
System.out.println("please specify wsdl and configuration file");
System.exit(1);
}
-
+
URL wsdlURL;
File wsdlFile = new File(args[0]);
if (wsdlFile.exists()) {
@@ -55,7 +55,7 @@ public final class Client {
} else {
wsdlURL = new URL(args[0]);
}
-
+
SpringBusFactory bf = new SpringBusFactory();
URL busURL;
File busFile = new File(args[1]);
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/ClientCallbackHandler.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/ClientCallbackHandler.java b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/ClientCallbackHandler.java
index 3dcbfc4..8b9746f 100644
--- a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/ClientCallbackHandler.java
+++ b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/client/ClientCallbackHandler.java
@@ -31,7 +31,7 @@ public class ClientCallbackHandler implements CallbackHandler {
for (int i = 0; i < callbacks.length; i++) {
if (callbacks[i] instanceof WSPasswordCallback) {
WSPasswordCallback pc = (WSPasswordCallback) callbacks[i];
- if (pc.getUsage() == WSPasswordCallback.DECRYPT
+ if (pc.getUsage() == WSPasswordCallback.DECRYPT
|| pc.getUsage() == WSPasswordCallback.SIGNATURE) {
if ("myclientkey".equals(pc.getIdentifier())) {
pc.setPassword("ckpass");
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/server/GreeterImpl.java b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/server/GreeterImpl.java
index f483954..a47dea4 100644
--- a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/server/GreeterImpl.java
@@ -22,15 +22,15 @@ package demo.wssec.server;
import java.util.logging.Logger;
import org.apache.hello_world_soap_http.Greeter;
-@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
- targetNamespace = "http://apache.org/hello_world_soap_http",
+@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
+ targetNamespace = "http://apache.org/hello_world_soap_http",
wsdlLocation = "file:./wsdl/hello_world.wsdl")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.objectweb.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/sts/STSCallbackHandler.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/sts/STSCallbackHandler.java b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/sts/STSCallbackHandler.java
index 59cda5f..8af89de 100644
--- a/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/sts/STSCallbackHandler.java
+++ b/distribution/src/main/release/samples/sts/src/main/java/demo/wssec/sts/STSCallbackHandler.java
@@ -31,7 +31,7 @@ public class STSCallbackHandler implements CallbackHandler {
for (int i = 0; i < callbacks.length; i++) {
if (callbacks[i] instanceof WSPasswordCallback) {
WSPasswordCallback pc = (WSPasswordCallback) callbacks[i];
- if (pc.getUsage() == WSPasswordCallback.DECRYPT
+ if (pc.getUsage() == WSPasswordCallback.DECRYPT
|| pc.getUsage() == WSPasswordCallback.SIGNATURE) {
if ("mystskey".equals(pc.getIdentifier())) {
pc.setPassword("stskpass");
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/client/Client.java b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/client/Client.java
index 57cf5fb..5616433 100644
--- a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/client/Client.java
+++ b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/client/Client.java
@@ -51,7 +51,7 @@ public final class Client implements Runnable {
this.username = name;
this.service = service;
}
-
+
@Override
public void run() {
long start = System.currentTimeMillis();
@@ -79,15 +79,15 @@ public final class Client implements Runnable {
}
long end = System.currentTimeMillis();
double rate = x * 1000 / (end - start);
- System.out.println(username + " finished " + x + " invocations: " + rate + " req/sec "
+ System.out.println(username + " finished " + x + " invocations: " + rate + " req/sec "
+ (exceeded ? "(exceeded max)" : ""));
try {
- //sleep for a few seconds before the client is closed so things can be seen in JMX
+ //sleep for a few seconds before the client is closed so things can be seen in JMX
Thread.sleep(10000);
} catch (InterruptedException e) {
//ignore
- }
-
+ }
+
} catch (Exception e1) {
e1.printStackTrace();
}
@@ -95,7 +95,7 @@ public final class Client implements Runnable {
public void stop() {
doStop = true;
}
-
+
public static void main(String args[]) throws Exception {
if (args.length == 0) {
args = new String[] {SOAPService.WSDL_LOCATION.toExternalForm()};
@@ -108,7 +108,7 @@ public final class Client implements Runnable {
} else {
wsdlURL = new URL(args[0]);
}
-
+
Map<String, Object> properties = new HashMap<>();
properties.put("bus.jmx.usePlatformMBeanServer", Boolean.TRUE);
properties.put("bus.jmx.enabled", Boolean.TRUE);
@@ -116,7 +116,7 @@ public final class Client implements Runnable {
Bus b = new CXFBusFactory().createBus(null, properties);
MetricRegistry registry = new MetricRegistry();
CodahaleMetricsProvider.setupJMXReporter(b, registry);
- b.setExtension(registry, MetricRegistry.class);
+ b.setExtension(registry, MetricRegistry.class);
SOAPService ss = new SOAPService(wsdlURL, SERVICE_NAME);
List<Client> c = new ArrayList<>();
@@ -136,7 +136,7 @@ public final class Client implements Runnable {
client = new Client("Jonas", ss);
new Thread(client).start();
c.add(client);
-
+
System.out.println("Sleeping on main thread for 60 seconds");
Thread.sleep(60000);
for (Client c2 : c) {
@@ -148,6 +148,6 @@ public final class Client implements Runnable {
//System.exit(0);
}
-
+
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Customer.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Customer.java b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Customer.java
index d2e978d..149b4e3 100644
--- a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Customer.java
+++ b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Customer.java
@@ -26,16 +26,16 @@ import org.apache.cxf.metrics.codahale.CodahaleMetricsContext;
import org.apache.cxf.throttling.ThrottleResponse;
/**
- *
+ *
*/
public abstract class Customer {
protected final String name;
protected volatile CodahaleMetricsContext metrics;
-
+
public Customer(String n) {
name = n;
}
-
+
MetricsContext getMetricsContext(MetricRegistry registry) {
if (metrics == null) {
metrics = new CodahaleMetricsContext("demo.server:customer=" + name + ",type=Customer,", registry);
@@ -44,8 +44,8 @@ public abstract class Customer {
}
public abstract void throttle(ThrottleResponse r);
-
-
+
+
public static class PremiumCustomer extends Customer {
public PremiumCustomer(String n) {
super(n);
@@ -73,12 +73,12 @@ public abstract class Customer {
super(n);
}
public void throttle(ThrottleResponse m) {
- //Regular customers are unthrottled until they hit 25req/sec, then start delaying by 0.25 seconds
+ //Regular customers are unthrottled until they hit 25req/sec, then start delaying by 0.25 seconds
//(drops to max of 4req/sec until below the 25req/sec rate)
if (metrics.getTotals().getOneMinuteRate() > 25) {
m.setDelay(250);
}
- //They also get throttled more if they are over 10req/sec over a 5 minute period
+ //They also get throttled more if they are over 10req/sec over a 5 minute period
//(drops to max of 2req/sec until below the 10req/sec rate)
if (metrics.getTotals().getFiveMinuteRate() > 10) {
m.setDelay(500);
@@ -98,7 +98,7 @@ public abstract class Customer {
if (metrics.getTotals().getOneMinuteRate() > 5) {
delay += 1000;
}
- //They also get throttled after 5 minutes of more than
+ //They also get throttled after 5 minutes of more than
if (metrics.getTotals().getFiveMinuteRate() > 1) {
delay += 1000;
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/CustomerMetricsInterceptor.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/CustomerMetricsInterceptor.java b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/CustomerMetricsInterceptor.java
index 5d05678..45e564d 100644
--- a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/CustomerMetricsInterceptor.java
+++ b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/CustomerMetricsInterceptor.java
@@ -34,7 +34,7 @@ import org.apache.cxf.phase.AbstractPhaseInterceptor;
import org.apache.cxf.phase.Phase;
/**
- *
+ *
*/
public class CustomerMetricsInterceptor extends AbstractPhaseInterceptor<Message> {
MetricRegistry registry;
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/GreeterImpl.java b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/GreeterImpl.java
index e8664ab..a1a2eb2 100644
--- a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/GreeterImpl.java
@@ -20,11 +20,11 @@
package demo.throttling.server;
-@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
- targetNamespace = "http://apache.org/hello_world_soap_http",
+@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
+ targetNamespace = "http://apache.org/hello_world_soap_http",
wsdlLocation = "file:./src/main/config/hello_world.wsdl",
endpointInterface = "org.apache.hello_world_soap_http.Greeter")
-
+
public class GreeterImpl {
public String greetMe(String me) {
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Server.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Server.java b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Server.java
index aa722cf..337c7aa 100644
--- a/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Server.java
+++ b/distribution/src/main/release/samples/throttling/src/main/java/demo/throttling/server/Server.java
@@ -40,7 +40,7 @@ import org.apache.cxf.throttling.ThrottlingManager;
public class Server {
Map<String, Customer> customers = new HashMap<>();
-
+
protected Server() throws Exception {
System.out.println("Starting Server");
@@ -49,15 +49,15 @@ public class Server {
customers.put("Vince", new Customer.RegularCustomer("Vince"));
customers.put("Malcolm", new Customer.CheapCustomer("Malcolm"));
customers.put("Jonas", new Customer.TrialCustomer("Jonas"));
-
+
Map<String, Object> properties = new HashMap<>();
properties.put("bus.jmx.usePlatformMBeanServer", Boolean.TRUE);
properties.put("bus.jmx.enabled", Boolean.TRUE);
Bus b = new CXFBusFactory().createBus(null, properties);
MetricRegistry registry = new MetricRegistry();
CodahaleMetricsProvider.setupJMXReporter(b, registry);
- b.setExtension(registry, MetricRegistry.class);
-
+ b.setExtension(registry, MetricRegistry.class);
+
ThrottlingManager manager = new ThrottlingManager() {
@Override
public ThrottleResponse getThrottleResponse(String phase, Message m) {
@@ -78,10 +78,10 @@ public class Server {
};
b.getInInterceptors().add(new CustomerMetricsInterceptor(registry, customers));
-
+
Object implementor = new GreeterImpl();
String address = "http://localhost:9001/SoapContext/SoapPort";
- Endpoint.publish(address, implementor,
+ Endpoint.publish(address, implementor,
new MetricsFeature(),
new ThrottlingFeature(manager));
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_addressing/src/main/java/demo/ws_addressing/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_addressing/src/main/java/demo/ws_addressing/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_addressing/src/main/java/demo/ws_addressing/server/GreeterImpl.java
index b36ac76..86f1df0 100644
--- a/distribution/src/main/release/samples/ws_addressing/src/main/java/demo/ws_addressing/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_addressing/src/main/java/demo/ws_addressing/server/GreeterImpl.java
@@ -29,15 +29,15 @@ import org.apache.hello_world_soap_http.types.FaultDetail;
@WebService(name = "SoapPort",
portName = "SoapPort",
- serviceName = "SOAPService",
- targetNamespace = "http://apache.org/hello_world_soap_http",
+ serviceName = "SOAPService",
+ targetNamespace = "http://apache.org/hello_world_soap_http",
wsdlLocation = "file:./src/main/resources/hello_world_addr.wsdl")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.apache.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
@@ -47,7 +47,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Message received: " + me + "\n");
return "Hello " + me;
}
-
+
/* (non-Javadoc)
* @see org.apache.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
*/
@@ -65,7 +65,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Executing operation sayHi\n");
return "Bonjour";
}
-
+
public void pingMe() throws PingMeFault {
FaultDetail faultDetail = new FaultDetail();
faultDetail.setMajor((short)2);
@@ -75,5 +75,5 @@ public class GreeterImpl implements Greeter {
throw new PingMeFault("PingMeFault raised by server", faultDetail);
}
-
+
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Client.java b/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Client.java
index c827190..444931f 100644
--- a/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Client.java
+++ b/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Client.java
@@ -37,16 +37,16 @@ public final class Client {
//Use WS-Discovery to find references to services that implement the Greeter portType
WSDiscoveryClient client = new WSDiscoveryClient();
- List<EndpointReference> references
+ List<EndpointReference> references
= client.probe(new QName("http://cxf.apache.org/hello_world/discovery", "Greeter"));
client.close();
-
+
GreeterService service = new GreeterService();
//loop through all of them and have them greet me.
for (EndpointReference ref : references) {
Greeter g = service.getPort(ref, Greeter.class);
System.out.println(g.greetMe("World"));
- }
+ }
}
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/GreeterImpl.java b/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/GreeterImpl.java
index 0d63a67..daa71eb 100644
--- a/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/GreeterImpl.java
@@ -26,7 +26,7 @@ import org.apache.cxf.hello_world.discovery.Greeter;
import org.apache.cxf.hello_world.discovery.PingMeFault;
/**
- *
+ *
*/
@WebService(endpointInterface = "org.apache.cxf.hello_world.discovery.Greeter",
wsdlLocation = "classpath:/org/apache/cxf/hello_world/discovery/hello_world.wsdl",
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Main.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Main.java b/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Main.java
index 187496c..e58c4ce 100644
--- a/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Main.java
+++ b/distribution/src/main/release/samples/ws_discovery/src/main/java/org/apache/cxf/samples/discovery/Main.java
@@ -32,7 +32,7 @@ public final class Main {
public static void main(String[] args) throws Exception {
//find a randomish port to use. The clients will
- //use WS-Discovery to find these services so
+ //use WS-Discovery to find these services so
//it really doesn't matter what port we publish them
//on (or what URL or anything like that)
ServerSocket sock = new ServerSocket();
@@ -40,7 +40,7 @@ public final class Main {
sock.bind(s);
int port = sock.getLocalPort();
sock.close();
-
+
String address = "http://localhost:" + port + "/Greeter";
System.out.println("Publishing on " + address);
Endpoint.publish(address, new GreeterImpl(port));
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_notification/src/main/java/demo/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_notification/src/main/java/demo/client/Client.java b/distribution/src/main/release/samples/ws_notification/src/main/java/demo/client/Client.java
index 3d3adaa..ebd895c 100644
--- a/distribution/src/main/release/samples/ws_notification/src/main/java/demo/client/Client.java
+++ b/distribution/src/main/release/samples/ws_notification/src/main/java/demo/client/Client.java
@@ -30,7 +30,7 @@ import org.apache.cxf.wsn.client.Subscription;
import org.oasis_open.docs.wsn.b_2.NotificationMessageHolderType;
/**
- *
+ *
*/
public final class Client {
private Client() {
@@ -45,7 +45,7 @@ public final class Client {
if (args.length > 0) {
wsnPort = args[0];
}
-
+
// Start a consumer that will listen for notification messages
// We'll just print the text content out for now.
Consumer consumer = new Consumer(new Consumer.Callback() {
@@ -57,22 +57,22 @@ public final class Client {
}
}
}, "http://localhost:9001/MyConsumer");
-
-
+
+
// Create a subscription for a Topic on the broker
- NotificationBroker notificationBroker
+ NotificationBroker notificationBroker
= new NotificationBroker("http://localhost:" + wsnPort + "/wsn/NotificationBroker");
Subscription subscription = notificationBroker.subscribe(consumer, "MyTopic");
// Send a notification on the Topic
- notificationBroker.notify("MyTopic",
+ notificationBroker.notify("MyTopic",
new JAXBElement<String>(new QName("urn:test:org", "foo"),
String.class, "Hello World!"));
-
+
// Just sleep for a bit to make sure the notification gets delivered
Thread.sleep(5000);
-
+
// Cleanup and exit
subscription.unsubscribe();
consumer.stop();
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_policy/src/main/java/demo/ws_policy/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_policy/src/main/java/demo/ws_policy/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_policy/src/main/java/demo/ws_policy/server/GreeterImpl.java
index 4e7e0b7..a172c45 100644
--- a/distribution/src/main/release/samples/ws_policy/src/main/java/demo/ws_policy/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_policy/src/main/java/demo/ws_policy/server/GreeterImpl.java
@@ -29,14 +29,14 @@ import org.apache.hello_world_soap_http.types.FaultDetail;
@WebService(name = "Greeter",
- serviceName = "SOAPService",
+ serviceName = "SOAPService",
targetNamespace = "http://apache.org/hello_world_soap_http")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.apache.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
@@ -46,7 +46,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Message received: " + me + "\n");
return "Hello " + me;
}
-
+
/* (non-Javadoc)
* @see org.apache.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
*/
@@ -64,7 +64,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Executing operation sayHi\n");
return "Bonjour";
}
-
+
public void pingMe() throws PingMeFault {
FaultDetail faultDetail = new FaultDetail();
faultDetail.setMajor((short)2);
@@ -74,5 +74,5 @@ public class GreeterImpl implements Greeter {
throw new PingMeFault("PingMeFault raised by server", faultDetail);
}
-
+
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/client/Client.java b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/client/Client.java
index 1faecf2..2dc64da 100644
--- a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/client/Client.java
+++ b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/client/Client.java
@@ -40,7 +40,7 @@ public final class Client {
public static void main(String args[]) throws Exception {
try {
-
+
SpringBusFactory bf = new SpringBusFactory();
URL busFile = Client.class.getResource("/client.xml");
Bus bus = bf.createBus(busFile.toString());
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/common/MessageLossSimulator.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/common/MessageLossSimulator.java b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/common/MessageLossSimulator.java
index 693c918..148ad38 100644
--- a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/common/MessageLossSimulator.java
+++ b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/common/MessageLossSimulator.java
@@ -38,19 +38,19 @@ import org.apache.cxf.ws.addressing.AddressingProperties;
import org.apache.cxf.ws.rm.RMContextUtils;
/**
- *
+ *
*/
public class MessageLossSimulator extends AbstractPhaseInterceptor<Message> {
private static final Logger LOG = Logger.getLogger(MessageLossSimulator.class.getName());
- private int appMessageCount;
-
+ private int appMessageCount;
+
public MessageLossSimulator() {
super(Phase.PREPARE_SEND);
addBefore(MessageSenderInterceptor.class.getName());
}
-
+
public void handleMessage(Message message) throws Fault {
AddressingProperties maps =
RMContextUtils.retrieveMAPs(message, false, true);
@@ -60,7 +60,7 @@ public class MessageLossSimulator extends AbstractPhaseInterceptor<Message> {
if (maps != null && null != maps.getAction()) {
action = maps.getAction().getValue();
}
- if (RMContextUtils.isRMProtocolMessage(action)) {
+ if (RMContextUtils.isRMProtocolMessage(action)) {
return;
}
appMessageCount++;
@@ -68,8 +68,8 @@ public class MessageLossSimulator extends AbstractPhaseInterceptor<Message> {
if (0 != (appMessageCount % 2)) {
return;
}
-
-
+
+
// discard even-numbered message
InterceptorChain chain = message.getInterceptorChain();
ListIterator<Interceptor<? extends Message>> it = chain.getIterator();
@@ -81,8 +81,8 @@ public class MessageLossSimulator extends AbstractPhaseInterceptor<Message> {
break;
}
}
-
- message.setContent(OutputStream.class, new WrappedOutputStream(message));
+
+ message.setContent(OutputStream.class, new WrappedOutputStream(message));
message.getInterceptorChain().add(new AbstractPhaseInterceptor<Message>(Phase.PREPARE_SEND_ENDING) {
@@ -93,10 +93,10 @@ public class MessageLossSimulator extends AbstractPhaseInterceptor<Message> {
throw new Fault(e);
}
}
-
- });
+
+ });
}
-
+
private class WrappedOutputStream extends AbstractWrappedOutputStream {
private Message outMessage;
@@ -114,20 +114,20 @@ public class MessageLossSimulator extends AbstractPhaseInterceptor<Message> {
}
wrappedStream = new DummyOutputStream();
}
- }
+ }
+
+
-
-
private class DummyOutputStream extends OutputStream {
@Override
public void write(int b) throws IOException {
// TODO Auto-generated method stub
-
+
}
-
+
}
-
-
-
+
+
+
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/GreeterImpl.java
index cc7ca6f..e682999 100644
--- a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/GreeterImpl.java
@@ -27,12 +27,12 @@ import org.apache.cxf.hello_world_soap_http.Greeter;
endpointInterface = "org.apache.cxf.hello_world_soap_http.Greeter",
wsdlLocation = "file:./src/main/resources/hello_world_rm.wsdl",
targetNamespace = "http://cxf.apache.org/hello_world_soap_http")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.apache.cxf.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
@@ -42,7 +42,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Message received: " + me + "\n");
return "Hello " + me;
}
-
+
/* (non-Javadoc)
* @see org.apache.cxf.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/Server.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/Server.java b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/Server.java
index cfff8e8..f54ef73 100644
--- a/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/Server.java
+++ b/distribution/src/main/release/samples/ws_rm/src/main/java/demo/ws_rm/server/Server.java
@@ -42,7 +42,7 @@ public class Server {
SpringBusFactory bf = new SpringBusFactory();
URL busFile = Server.class.getResource("/server.xml");
Bus bus = bf.createBus(busFile.toString());
-
+
BusFactory.setDefaultBus(bus);
new Server();
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/Client.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/Client.java
index 11af5b46c..7fdf2db 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/Client.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/Client.java
@@ -40,7 +40,7 @@ import org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor;
*/
public final class Client {
- private static final String WSSE_NS
+ private static final String WSSE_NS
= "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd";
private static final String WSU_NS
= "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
@@ -80,7 +80,7 @@ public final class Client {
+ "{Element}{http://schemas.xmlsoap.org/soap/envelope/}Body;"
+ "{}{http://www.w3.org/2005/08/addressing}ReplyTo;");
- outProps.put("encryptionKeyTransportAlgorithm",
+ outProps.put("encryptionKeyTransportAlgorithm",
"http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p");
outProps.put("signatureAlgorithm", "http://www.w3.org/2000/09/xmldsig#rsa-sha1");
@@ -97,7 +97,7 @@ public final class Client {
inProps.put("signaturePropFile", "etc/Client_Encrypt.properties");
inProps.put("signatureKeyIdentifier", "DirectReference");
- inProps.put("encryptionKeyTransportAlgorithm",
+ inProps.put("encryptionKeyTransportAlgorithm",
"http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p");
inProps.put("signatureAlgorithm", "http://www.w3.org/2000/09/xmldsig#rsa-sha1");
@@ -115,7 +115,7 @@ public final class Client {
client.getInInterceptors().add(new WSS4JInInterceptor(inProps));
client.getOutInterceptors().add(new WSS4JOutInterceptor(outProps));
client.getInInterceptors().add(coverageChecker);
-
+
String[] names = new String[] {"Anne", "Bill", "Chris", "Sachin Tendulkar"};
// make a sequence of 4 invocations
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/StaxClient.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/StaxClient.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/StaxClient.java
index d64aa0d..8b00152 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/StaxClient.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/StaxClient.java
@@ -58,12 +58,12 @@ public final class StaxClient {
Bus bus = bf.createBus(busFile.toString());
BusFactory.setDefaultBus(bus);
- Properties encCryptoProperties =
+ Properties encCryptoProperties =
CryptoFactory.getProperties("etc/Client_Encrypt.properties",
StaxClient.class.getClassLoader());
- Properties sigCryptoProperties =
+ Properties sigCryptoProperties =
CryptoFactory.getProperties("etc/Client_Sign.properties", StaxClient.class.getClassLoader());
-
+
WSSSecurityProperties properties = new WSSSecurityProperties();
properties.addAction(WSSConstants.USERNAMETOKEN);
properties.addAction(WSSConstants.TIMESTAMP);
@@ -74,7 +74,7 @@ public final class StaxClient {
properties.setTokenUser("abcd");
properties.setSignatureUser("clientx509v1");
properties.setEncryptionUser("serverx509v1");
-
+
properties.setEncryptionCryptoProperties(encCryptoProperties);
properties.setEncryptionKeyIdentifier(
WSSecurityTokenConstants.KeyIdentifier_IssuerSerial
@@ -89,7 +89,7 @@ public final class StaxClient {
properties.addEncryptionPart(
new SecurePart(new QName(WSSConstants.NS_SOAP11, "Body"), SecurePart.Modifier.Content)
);
-
+
properties.setSignatureCryptoProperties(sigCryptoProperties);
properties.setSignatureKeyIdentifier(
WSSecurityTokenConstants.KEYIDENTIFIER_SECURITY_TOKEN_DIRECT_REFERENCE
@@ -106,10 +106,10 @@ public final class StaxClient {
SecurePart.Modifier.Element)
);
properties.setCallbackHandler(new UTPasswordCallback());
-
+
WSS4JStaxOutInterceptor ohandler = new WSS4JStaxOutInterceptor(properties);
bus.getOutInterceptors().add(ohandler);
-
+
WSSSecurityProperties inProperties = new WSSSecurityProperties();
inProperties.addAction(WSSConstants.USERNAMETOKEN);
inProperties.addAction(WSSConstants.TIMESTAMP);
@@ -119,7 +119,7 @@ public final class StaxClient {
inProperties.setCallbackHandler(new UTPasswordCallback());
inProperties.setDecryptionCryptoProperties(sigCryptoProperties);
inProperties.setSignatureVerificationCryptoProperties(encCryptoProperties);
-
+
WSS4JStaxInInterceptor inhandler = new WSS4JStaxInInterceptor(inProperties);
bus.getInInterceptors().add(inhandler);
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/UTPasswordCallback.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/UTPasswordCallback.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/UTPasswordCallback.java
index a202a2a..608981e 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/UTPasswordCallback.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/client/UTPasswordCallback.java
@@ -32,10 +32,10 @@ import org.apache.wss4j.common.ext.WSPasswordCallback;
*/
public class UTPasswordCallback implements CallbackHandler {
-
- private Map<String, String> passwords =
+
+ private Map<String, String> passwords =
new HashMap<String, String>();
-
+
public UTPasswordCallback() {
passwords.put("Alice", "ecilA");
passwords.put("abcd", "dcba");
@@ -44,7 +44,7 @@ public class UTPasswordCallback implements CallbackHandler {
}
/**
- * Here, we attempt to get the password from the private
+ * Here, we attempt to get the password from the private
* alias/passwords map.
*/
public void handle(Callback[] callbacks) throws IOException, UnsupportedCallbackException {
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/GreeterImpl.java
index 8df7dac..35cc9cc 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/GreeterImpl.java
@@ -27,12 +27,12 @@ import org.apache.cxf.hello_world_soap_http.Greeter;
endpointInterface = "org.apache.cxf.hello_world_soap_http.Greeter",
wsdlLocation = "file:./wsdl/hello_world_wssec.wsdl",
targetNamespace = "http://cxf.apache.org/hello_world_soap_http")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.apache.cxf.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
@@ -42,7 +42,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Message received: " + me + "\n");
return "Hello " + me;
}
-
+
/* (non-Javadoc)
* @see org.apache.cxf.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/Server.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/Server.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/Server.java
index faeac00..ae3d7f1 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/Server.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/Server.java
@@ -37,7 +37,7 @@ import org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor;
* A DOM-based server
*/
public class Server {
- private static final String WSSE_NS
+ private static final String WSSE_NS
= "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd";
private static final String WSU_NS
= "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
@@ -48,7 +48,7 @@ public class Server {
Object implementor = new GreeterImpl();
String address = "http://localhost:9000/SoapContext/GreeterPort";
EndpointImpl endpoint = (EndpointImpl)Endpoint.publish(address, implementor);
-
+
Map<String, Object> outProps = new HashMap<String, Object>();
outProps.put("action", "UsernameToken Timestamp Signature Encrypt");
@@ -69,7 +69,7 @@ public class Server {
outProps.put("signatureParts", "{Element}{" + WSU_NS + "}Timestamp;"
+ "{Element}{http://schemas.xmlsoap.org/soap/envelope/}Body");
- outProps.put("encryptionKeyTransportAlgorithm",
+ outProps.put("encryptionKeyTransportAlgorithm",
"http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p");
outProps.put("signatureAlgorithm", "http://www.w3.org/2000/09/xmldsig#rsa-sha1");
@@ -86,7 +86,7 @@ public class Server {
inProps.put("signaturePropFile", "etc/Server_SignVerf.properties");
inProps.put("signatureKeyIdentifier", "DirectReference");
- inProps.put("encryptionKeyTransportAlgorithm",
+ inProps.put("encryptionKeyTransportAlgorithm",
"http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p");
inProps.put("signatureAlgorithm", "http://www.w3.org/2000/09/xmldsig#rsa-sha1");
@@ -108,7 +108,7 @@ public class Server {
URL busFile = Server.class.getResource("wssec.xml");
Bus bus = bf.createBus(busFile.toString());
-
+
BusFactory.setDefaultBus(bus);
new Server();
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/StaxServer.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/StaxServer.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/StaxServer.java
index 0d10e4a..d0d8111 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/StaxServer.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/StaxServer.java
@@ -56,11 +56,11 @@ public class StaxServer {
URL busFile = Server.class.getResource("wssec.xml");
Bus bus = bf.createBus(busFile.toString());
- Properties decCryptoProperties =
+ Properties decCryptoProperties =
CryptoFactory.getProperties("etc/Server_Decrypt.properties", StaxServer.class.getClassLoader());
- Properties sigVerCryptoProperties =
+ Properties sigVerCryptoProperties =
CryptoFactory.getProperties("etc/Server_SignVerf.properties", StaxServer.class.getClassLoader());
-
+
WSSSecurityProperties properties = new WSSSecurityProperties();
properties.addAction(WSSConstants.USERNAMETOKEN);
properties.addAction(WSSConstants.TIMESTAMP);
@@ -71,7 +71,7 @@ public class StaxServer {
properties.setTokenUser("Alice");
properties.setSignatureUser("serverx509v1");
properties.setEncryptionUser("clientx509v1");
-
+
properties.setEncryptionCryptoProperties(sigVerCryptoProperties);
properties.setEncryptionKeyIdentifier(
WSSecurityTokenConstants.KeyIdentifier_IssuerSerial
@@ -85,7 +85,7 @@ public class StaxServer {
properties.addEncryptionPart(
new SecurePart(new QName(WSSConstants.NS_SOAP11, "Body"), SecurePart.Modifier.Content)
);
-
+
properties.setSignatureCryptoProperties(decCryptoProperties);
properties.setSignatureKeyIdentifier(
WSSecurityTokenConstants.KEYIDENTIFIER_SECURITY_TOKEN_DIRECT_REFERENCE
@@ -98,10 +98,10 @@ public class StaxServer {
new SecurePart(new QName(WSSConstants.NS_SOAP11, "Body"), SecurePart.Modifier.Content)
);
properties.setCallbackHandler(new UTPasswordCallback());
-
+
WSS4JStaxOutInterceptor ohandler = new WSS4JStaxOutInterceptor(properties);
bus.getOutInterceptors().add(ohandler);
-
+
WSSSecurityProperties inProperties = new WSSSecurityProperties();
inProperties.addAction(WSSConstants.USERNAMETOKEN);
inProperties.addAction(WSSConstants.TIMESTAMP);
@@ -111,7 +111,7 @@ public class StaxServer {
inProperties.setCallbackHandler(new UTPasswordCallback());
inProperties.setDecryptionCryptoProperties(decCryptoProperties);
inProperties.setSignatureVerificationCryptoProperties(sigVerCryptoProperties);
-
+
WSS4JStaxInInterceptor inhandler = new WSS4JStaxInInterceptor(inProperties);
bus.getInInterceptors().add(inhandler);
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/UTPasswordCallback.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/UTPasswordCallback.java b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/UTPasswordCallback.java
index b5455b6..8eb0453 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/UTPasswordCallback.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc/src/main/java/demo/wssec/server/UTPasswordCallback.java
@@ -32,10 +32,10 @@ import org.apache.wss4j.common.ext.WSPasswordCallback;
*/
public class UTPasswordCallback implements CallbackHandler {
-
- private Map<String, String> passwords =
+
+ private Map<String, String> passwords =
new HashMap<String, String>();
-
+
public UTPasswordCallback() {
passwords.put("Alice", "ecilA");
passwords.put("abcd", "dcba");
@@ -44,7 +44,7 @@ public class UTPasswordCallback implements CallbackHandler {
}
/**
- * Here, we attempt to get the password from the private
+ * Here, we attempt to get the password from the private
* alias/passwords map.
*/
public void handle(Callback[] callbacks) throws IOException, UnsupportedCallbackException {
@@ -58,7 +58,7 @@ public class UTPasswordCallback implements CallbackHandler {
}
}
}
-
+
/**
* Add an alias/password pair to the callback mechanism.
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/client/Client.java b/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/client/Client.java
index 86c4fad..bf3464e 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/client/Client.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/client/Client.java
@@ -63,7 +63,7 @@ public final class Client {
} else {
busURL = new URL(args[1]);
}
-
+
Bus bus = bf.createBus(busFile.toString());
BusFactory.setDefaultBus(bus);
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/server/GreeterImpl.java
index 2ae6cd0..92098bb 100644
--- a/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_security/sign_enc_policy/src/main/java/demo/wssec/server/GreeterImpl.java
@@ -22,13 +22,13 @@ package demo.wssec.server;
import java.util.logging.Logger;
import org.apache.hello_world_soap_http.Greeter;
-@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
+@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
targetNamespace = "http://apache.org/hello_world_soap_http")
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.objectweb.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/client/StaxClient.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/client/StaxClient.java b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/client/StaxClient.java
index 8be503e..c2fcb61 100644
--- a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/client/StaxClient.java
+++ b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/client/StaxClient.java
@@ -59,14 +59,14 @@ public final class StaxClient {
properties.setUsernameTokenPasswordType(WSSConstants.UsernameTokenPasswordType.PASSWORD_DIGEST);
properties.setTokenUser("abcd");
properties.setCallbackHandler(new UTPasswordCallback());
-
+
WSSSecurityProperties inProperties = new WSSSecurityProperties();
inProperties.addAction(WSSConstants.USERNAMETOKEN);
inProperties.addAction(WSSConstants.TIMESTAMP);
inProperties.setUsernameTokenPasswordType(WSSConstants.UsernameTokenPasswordType.PASSWORD_TEXT);
inProperties.setCallbackHandler(new UTPasswordCallback());
-
+
GreeterService service = new GreeterService();
Greeter port = service.getGreeterPort();
org.apache.cxf.endpoint.Client client = ClientProxy.getClient(port);
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/GreeterImpl.java
index 1ec7114..1ceeca5 100644
--- a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/GreeterImpl.java
@@ -27,12 +27,12 @@ import org.apache.cxf.hello_world_soap_http.Greeter;
endpointInterface = "org.apache.cxf.hello_world_soap_http.Greeter",
wsdlLocation = "file:./src/main/resources/hello_world_wssec.wsdl",
targetNamespace = "http://cxf.apache.org/hello_world_soap_http")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.apache.cxf.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
@@ -42,7 +42,7 @@ public class GreeterImpl implements Greeter {
System.out.println("Message received: " + me + "\n");
return "Hello " + me;
}
-
+
/* (non-Javadoc)
* @see org.apache.cxf.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/Server.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/Server.java b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/Server.java
index 1f5ca05..472d4e3 100644
--- a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/Server.java
+++ b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/Server.java
@@ -43,7 +43,7 @@ public class Server {
Object implementor = new GreeterImpl();
String address = "http://localhost:9000/SoapContext/GreeterPort";
EndpointImpl impl = (EndpointImpl)Endpoint.publish(address, implementor);
-
+
Map<String, Object> outProps = new HashMap<String, Object>();
outProps.put("action", "UsernameToken Timestamp");
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/StaxServer.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/StaxServer.java b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/StaxServer.java
index 5324dbc..61b2d0f 100644
--- a/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/StaxServer.java
+++ b/distribution/src/main/release/samples/ws_security/ut/src/main/java/demo/wssec/server/StaxServer.java
@@ -43,16 +43,16 @@ public class StaxServer {
Object implementor = new GreeterImpl();
String address = "http://localhost:9000/SoapContext/GreeterPort";
EndpointImpl impl = (EndpointImpl)Endpoint.publish(address, implementor);
-
+
WSSSecurityProperties properties = new WSSSecurityProperties();
properties.addAction(WSSConstants.USERNAMETOKEN);
properties.addAction(WSSConstants.TIMESTAMP);
properties.setUsernameTokenPasswordType(WSSConstants.UsernameTokenPasswordType.PASSWORD_TEXT);
properties.setTokenUser("Alice");
-
+
properties.setCallbackHandler(new UTPasswordCallback());
-
+
impl.getOutInterceptors().add(new WSS4JStaxOutInterceptor(properties));
WSSSecurityProperties inProperties = new WSSSecurityProperties();
@@ -60,7 +60,7 @@ public class StaxServer {
inProperties.addAction(WSSConstants.TIMESTAMP);
inProperties.setUsernameTokenPasswordType(WSSConstants.UsernameTokenPasswordType.PASSWORD_DIGEST);
inProperties.setCallbackHandler(new UTPasswordCallback());
-
+
impl.getInInterceptors().add(new WSS4JStaxInInterceptor(inProperties));
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/client/Client.java b/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/client/Client.java
index 86c4fad..bf3464e 100644
--- a/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/client/Client.java
+++ b/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/client/Client.java
@@ -63,7 +63,7 @@ public final class Client {
} else {
busURL = new URL(args[1]);
}
-
+
Bus bus = bf.createBus(busFile.toString());
BusFactory.setDefaultBus(bus);
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/server/GreeterImpl.java b/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/server/GreeterImpl.java
index 2ae6cd0..92098bb 100644
--- a/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/ws_security/ut_policy/src/main/java/demo/wssec/server/GreeterImpl.java
@@ -22,13 +22,13 @@ package demo.wssec.server;
import java.util.logging.Logger;
import org.apache.hello_world_soap_http.Greeter;
-@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
+@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
targetNamespace = "http://apache.org/hello_world_soap_http")
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.objectweb.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceClient.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceClient.java b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceClient.java
index ef9989f..bb84550 100644
--- a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceClient.java
+++ b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceClient.java
@@ -27,7 +27,7 @@ import com.example.customerservice.CustomerServiceService;
public class CustomerServiceClient {
protected CustomerServiceClient() {
}
-
+
public static void main(String args[]) throws Exception {
CustomerServiceService customerServiceService;
if (args.length != 0 && args[0].length() != 0) {
@@ -46,11 +46,11 @@ public class CustomerServiceClient {
}
CustomerService customerService = customerServiceService.getCustomerServicePort();
-
+
// Initialize the test class and call the tests
CustomerServiceTester client = new CustomerServiceTester();
client.setCustomerService(customerService);
client.testCustomerService();
- System.exit(0);
+ System.exit(0);
}
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceSpringClient.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceSpringClient.java b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceSpringClient.java
index 159ad56..8ce3bf6 100644
--- a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceSpringClient.java
+++ b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceSpringClient.java
@@ -29,10 +29,10 @@ public final class CustomerServiceSpringClient {
public static void main(String args[]) throws Exception {
// Initialize the spring context and fetch our test client
- ClassPathXmlApplicationContext context
+ ClassPathXmlApplicationContext context
= new ClassPathXmlApplicationContext(new String[] {"classpath:client-applicationContext.xml"});
CustomerServiceTester client = (CustomerServiceTester)context.getBean("tester");
-
+
client.testCustomerService();
System.exit(0);
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceTester.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceTester.java b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceTester.java
index 6245c39..a0c6d30 100644
--- a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceTester.java
+++ b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/client/CustomerServiceTester.java
@@ -28,10 +28,10 @@ import com.example.customerservice.CustomerService;
import com.example.customerservice.NoSuchCustomerException;
public final class CustomerServiceTester {
-
- // The CustomerService proxy will be injected either by spring or by a direct call to the setter
+
+ // The CustomerService proxy will be injected either by spring or by a direct call to the setter
CustomerService customerService;
-
+
public CustomerService getCustomerService() {
return customerService;
}
@@ -42,7 +42,7 @@ public final class CustomerServiceTester {
public void testCustomerService() throws NoSuchCustomerException {
List<Customer> customers = null;
-
+
// First we test the positive case where customers are found and we retreive
// a list of customers
System.out.println("Sending request for customers named Smith");
@@ -50,7 +50,7 @@ public final class CustomerServiceTester {
System.out.println("Response received");
Assert.assertEquals(2, customers.size());
Assert.assertEquals("Smith", customers.get(0).getName());
-
+
// Then we test for an unknown Customer name and expect the NoSuchCustomerException
try {
customers = customerService.getCustomersByName("None");
@@ -61,14 +61,14 @@ public final class CustomerServiceTester {
Assert.assertEquals("None", e.getFaultInfo().getCustomerName());
System.out.println("NoSuchCustomer exception was received as expected");
}
-
- // The implementation of updateCustomer is set to sleep for some seconds.
+
+ // The implementation of updateCustomer is set to sleep for some seconds.
// Still this method should return instantly as the method is declared
// as a one way method in the WSDL
Customer customer = new Customer();
customer.setName("Smith");
customerService.updateCustomer(customer);
-
+
System.out.println("All calls were successful");
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceImpl.java b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceImpl.java
index f2e91c0..eac3ea7 100644
--- a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceImpl.java
+++ b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceImpl.java
@@ -34,9 +34,9 @@ import com.example.customerservice.NoSuchCustomer;
import com.example.customerservice.NoSuchCustomerException;
public class CustomerServiceImpl implements CustomerService {
-
+
/**
- * The WebServiceContext can be used to retrieve special attributes like the
+ * The WebServiceContext can be used to retrieve special attributes like the
* user principal. Normally it is not needed
*/
@Resource
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceSpringServer.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceSpringServer.java b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceSpringServer.java
index 11c62b3..70d52db 100644
--- a/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceSpringServer.java
+++ b/distribution/src/main/release/samples/wsdl_first/src/main/java/com/example/customerservice/server/CustomerServiceSpringServer.java
@@ -21,7 +21,7 @@ package com.example.customerservice.server;
import org.springframework.context.support.ClassPathXmlApplicationContext;
public class CustomerServiceSpringServer {
-
+
protected CustomerServiceSpringServer() {
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/demo/hw/client/ComplexClient.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/demo/hw/client/ComplexClient.java b/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/demo/hw/client/ComplexClient.java
index bc58797..8e1b57a 100644
--- a/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/demo/hw/client/ComplexClient.java
+++ b/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/demo/hw/client/ComplexClient.java
@@ -37,14 +37,14 @@ import org.apache.cxf.service.model.MessagePartInfo;
import org.apache.cxf.service.model.ServiceInfo;
/**
- *
+ *
*/
public final class ComplexClient {
-
- private static final QName SERVICE_NAME
- = new QName("http://Company.com/Application",
+
+ private static final QName SERVICE_NAME
+ = new QName("http://Company.com/Application",
"Company_ESB_Application_Biztalk_AgentDetails_4405_AgentDetails_Prt");
-
+
private ComplexClient() {
}
@@ -52,9 +52,9 @@ public final class ComplexClient {
* @param args
*/
public static void main(String[] args) throws Exception {
- if (args.length == 0) {
+ if (args.length == 0) {
System.out.println("please specify wsdl");
- System.exit(1);
+ System.exit(1);
}
URL wsdlURL;
@@ -64,15 +64,15 @@ public final class ComplexClient {
} else {
wsdlURL = new URL(args[0]);
}
-
+
System.out.println(wsdlURL);
-
+
JaxWsDynamicClientFactory factory = JaxWsDynamicClientFactory.newInstance();
Client client = factory.createClient(wsdlURL.toExternalForm(), SERVICE_NAME);
ClientImpl clientImpl = (ClientImpl) client;
Endpoint endpoint = clientImpl.getEndpoint();
ServiceInfo serviceInfo = endpoint.getService().getServiceInfos().get(0);
- QName bindingName = new QName("http://Company.com/Application",
+ QName bindingName = new QName("http://Company.com/Application",
"Company_ESB_Application_Biztalk_AgentDetails_4405_AgentDetails_PrtSoap");
BindingInfo binding = serviceInfo.getBinding(bindingName);
//{
@@ -106,7 +106,7 @@ public final class ComplexClient {
PropertyDescriptor agentNameDescriptor = new PropertyDescriptor("agentName", wsResponseClass);
String agentName = (String)agentNameDescriptor.getReadMethod().invoke(wsResponse);
System.out.println("Agent name: " + agentName);
-
+
}
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/org/apache/cxf/demo/complex/ComplexImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/org/apache/cxf/demo/complex/ComplexImpl.java b/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/org/apache/cxf/demo/complex/ComplexImpl.java
index b497961..ebb7e25 100644
--- a/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/org/apache/cxf/demo/complex/ComplexImpl.java
+++ b/distribution/src/main/release/samples/wsdl_first_dynamic_client/src/main/java/org/apache/cxf/demo/complex/ComplexImpl.java
@@ -35,7 +35,7 @@ import agentwsresponse.agent.legacysystemservices.schemas.hitum.esb.company.Agen
portName = "Company_ESB_Application_Biztalk_AgentDetails_4405_AgentDetails_PrtSoap",
targetNamespace = "http://Company.com/Application",
wsdlLocation = "/wsdl/complex.wsdl",
- endpointInterface =
+ endpointInterface =
"com.company.application.CompanyESBApplicationBiztalkAgentDetails4405AgentDetailsPrtSoap")
public class ComplexImpl implements CompanyESBApplicationBiztalkAgentDetails4405AgentDetailsPrtSoap {
@@ -44,11 +44,11 @@ public class ComplexImpl implements CompanyESBApplicationBiztalkAgentDetails4405
public GetAgentDetailsResponse getAgentDetails(GetAgentDetails parameters) {
GetAgentDetailsResponse r = new GetAgentDetailsResponse();
AgentWSResponse awr = new AgentWSResponse();
-
+
int number = parameters.getPart().getAgentNumber();
awr.setAgenceNumber(number);
awr.setAgentName("Orange");
-
+
r.setAgentWSResponse(awr);
return r;
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/client/ClientNonSpring.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/client/ClientNonSpring.java b/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/client/ClientNonSpring.java
index f8e9a6c..f2ea332 100644
--- a/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/client/ClientNonSpring.java
+++ b/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/client/ClientNonSpring.java
@@ -70,7 +70,7 @@ public final class ClientNonSpring {
System.out.println(wsdlURL);
SOAPService ss = new SOAPService(wsdlURL, SERVICE_NAME);
- Greeter port = ss.getPort(PORT_NAME, Greeter.class);
+ Greeter port = ss.getPort(PORT_NAME, Greeter.class);
if ("secure".equals(args[1])) {
setupTLS(port);
} else if ("insecure".equals(args[1])) {
@@ -79,7 +79,7 @@ public final class ClientNonSpring {
System.out.println("arg1 needs to be either secure or insecure");
System.exit(1);
}
-
+
System.out.println("Invoking greetMe...");
try {
String resp = port.greetMe(System.getProperty("user.name"));
@@ -93,37 +93,37 @@ public final class ClientNonSpring {
System.exit(0);
}
-
- private static void setupTLS(Greeter port)
+
+ private static void setupTLS(Greeter port)
throws FileNotFoundException, IOException, GeneralSecurityException {
String keyStoreLoc = "src/main/config/clientKeystore.jks";
HTTPConduit httpConduit = (HTTPConduit) ClientProxy.getClient(port).getConduit();
-
+
TLSClientParameters tlsCP = new TLSClientParameters();
String keyPassword = "ckpass";
KeyStore keyStore = KeyStore.getInstance("JKS");
keyStore.load(new FileInputStream(keyStoreLoc), "cspass".toCharArray());
KeyManager[] myKeyManagers = getKeyManagers(keyStore, keyPassword);
tlsCP.setKeyManagers(myKeyManagers);
-
-
+
+
KeyStore trustStore = KeyStore.getInstance("JKS");
trustStore.load(new FileInputStream(keyStoreLoc), "cspass".toCharArray());
TrustManager[] myTrustStoreKeyManagers = getTrustManagers(trustStore);
tlsCP.setTrustManagers(myTrustStoreKeyManagers);
-
+
httpConduit.setTlsClientParameters(tlsCP);
}
- private static TrustManager[] getTrustManagers(KeyStore trustStore)
+ private static TrustManager[] getTrustManagers(KeyStore trustStore)
throws NoSuchAlgorithmException, KeyStoreException {
String alg = KeyManagerFactory.getDefaultAlgorithm();
TrustManagerFactory fac = TrustManagerFactory.getInstance(alg);
fac.init(trustStore);
return fac.getTrustManagers();
}
-
- private static KeyManager[] getKeyManagers(KeyStore keyStore, String keyPassword)
+
+ private static KeyManager[] getKeyManagers(KeyStore keyStore, String keyPassword)
throws GeneralSecurityException, IOException {
String alg = KeyManagerFactory.getDefaultAlgorithm();
char[] keyPass = keyPassword != null
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/server/GreeterImpl.java b/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/server/GreeterImpl.java
index 5cdf6b5..04dc529 100644
--- a/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/wsdl_first_https/src/main/java/demo/hw_https/server/GreeterImpl.java
@@ -22,15 +22,15 @@ package demo.hw_https.server;
import java.util.logging.Logger;
import org.apache.hello_world_soap_http.Greeter;
-@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
- targetNamespace = "http://apache.org/hello_world_soap_http",
+@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService",
+ targetNamespace = "http://apache.org/hello_world_soap_http",
wsdlLocation = "file:./src/main/config/hello_world.wsdl")
-
+
public class GreeterImpl implements Greeter {
- private static final Logger LOG =
+ private static final Logger LOG =
Logger.getLogger(GreeterImpl.class.getPackage().getName());
-
+
/* (non-Javadoc)
* @see org.objectweb.hello_world_soap_http.Greeter#greetMe(java.lang.String)
*/
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/client/Client.java b/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/client/Client.java
index 5607a04..c0bdeda 100644
--- a/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/client/Client.java
+++ b/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/client/Client.java
@@ -34,7 +34,7 @@ public final class Client {
private static final QName SERVICE_NAME = new QName("http://apache.org/hello_world_xml_http/bare",
"XMLService");
- private static final QName PORT_NAME =
+ private static final QName PORT_NAME =
new QName("http://apache.org/hello_world_xml_http/bare", "XMLPort");
private Client() {
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/server/GreeterImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/server/GreeterImpl.java b/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/server/GreeterImpl.java
index 35af3d1..c1d0f79 100644
--- a/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/server/GreeterImpl.java
+++ b/distribution/src/main/release/samples/wsdl_first_pure_xml/src/main/java/demo/hw/server/GreeterImpl.java
@@ -22,7 +22,7 @@ package demo.hw.server;
import org.apache.hello_world_xml_http.bare.Greeter;
import org.apache.hello_world_xml_http.bare.types.MyComplexStructType;
-@javax.jws.WebService(serviceName = "XMLService",
+@javax.jws.WebService(serviceName = "XMLService",
portName = "XMLPort",
endpointInterface = "org.apache.hello_world_xml_http.bare.Greeter",
targetNamespace = "http://apache.org/hello_world_xml_http/bare")
@@ -34,7 +34,7 @@ public class GreeterImpl implements Greeter {
public String greetMe(String me) {
// TODO Auto-generated method stub
System.out.println("received calling greetMe!");
- return "Hello " + me;
+ return "Hello " + me;
}
public String sayHi() {
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/client/Client.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/client/Client.java b/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/client/Client.java
index 310da2c..94da22d 100644
--- a/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/client/Client.java
+++ b/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/client/Client.java
@@ -28,19 +28,19 @@ import org.apache.hello_world_rpclit.types.MyComplexStruct;
public final class Client {
- private static final QName SERVICE_NAME =
+ private static final QName SERVICE_NAME =
new QName("http://apache.org/hello_world_rpclit", "SOAPServiceRPCLit");
- private static final QName PORT_NAME =
+ private static final QName PORT_NAME =
new QName("http://apache.org/hello_world_rpclit", "SoapPortRPCLit");
private Client() {
- }
+ }
public static void main(String[] args) throws Exception {
- if (args.length == 0) {
+ if (args.length == 0) {
System.out.println("please specify wsdl");
- System.exit(1);
+ System.exit(1);
}
URL wsdlURL;
@@ -50,24 +50,24 @@ public final class Client {
} else {
wsdlURL = new URL(args[0]);
}
-
+
SOAPServiceRPCLit service = new SOAPServiceRPCLit(wsdlURL, SERVICE_NAME);
GreeterRPCLit greeter = (GreeterRPCLit)service.getPort(PORT_NAME, GreeterRPCLit.class);
System.out.println("Invoking sayHi...");
System.out.println("server responded with: " + greeter.sayHi());
- System.out.println();
+ System.out.println();
System.out.println("Invoking greetMe...");
System.out.println("server responded with: " + greeter.greetMe(System.getProperty("user.name")));
System.out.println();
-
+
MyComplexStruct argument = new MyComplexStruct();
MyComplexStruct retVal = null;
- String str1 = "this is element 1";
- String str2 = "this is element 2";
- int int1 = 42;
+ String str1 = "this is element 1";
+ String str2 = "this is element 2";
+ int int1 = 42;
argument.setElem1(str1);
argument.setElem2(str2);
@@ -83,6 +83,6 @@ public final class Client {
System.out.println();
- System.exit(0);
+ System.exit(0);
}
}
http://git-wip-us.apache.org/repos/asf/cxf/blob/8cea7c87/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/server/GreeterRPCLitImpl.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/server/GreeterRPCLitImpl.java b/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/server/GreeterRPCLitImpl.java
index 254753a..024cb9c 100644
--- a/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/server/GreeterRPCLitImpl.java
+++ b/distribution/src/main/release/samples/wsdl_first_rpclit/src/main/java/demo/hwRPCLit/server/GreeterRPCLitImpl.java
@@ -22,8 +22,8 @@ import java.util.logging.Logger;
import org.apache.hello_world_rpclit.GreeterRPCLit;
import org.apache.hello_world_rpclit.types.MyComplexStruct;
-@javax.jws.WebService(portName = "SoapPortRPCLit", serviceName = "SOAPServiceRPCLit",
- targetNamespace = "http://apache.org/hello_world_rpclit",
+@javax.jws.WebService(portName = "SoapPortRPCLit", serviceName = "SOAPServiceRPCLit",
+ targetNamespace = "http://apache.org/hello_world_rpclit",
endpointInterface = "org.apache.hello_world_rpclit.GreeterRPCLit")
public class GreeterRPCLitImpl implements GreeterRPCLit {