diff --git a/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundImapIdleAdapterTestApp.java b/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundImapIdleAdapterTestApp.java index 5f4f86f4..e2e5956c 100644 --- a/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundImapIdleAdapterTestApp.java +++ b/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundImapIdleAdapterTestApp.java @@ -1,5 +1,17 @@ -/** - * +/* + * Copyright 2002-2012 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package org.springframework.integration.samples.mail.imapidle; @@ -18,7 +30,7 @@ import org.springframework.integration.core.MessageHandler; public class GmailInboundImapIdleAdapterTestApp { private static Logger logger = Logger.getLogger(GmailInboundImapIdleAdapterTestApp.class); - + public static void main (String[] args) throws Exception { ApplicationContext ac = new ClassPathXmlApplicationContext("/META-INF/spring/integration/gmail-imap-idle-config.xml"); DirectChannel inputChannel = ac.getBean("recieveChannel", DirectChannel.class); diff --git a/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundPop3AdapterTestApp.java b/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundPop3AdapterTestApp.java index cbc6d8bc..3111e1a4 100644 --- a/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundPop3AdapterTestApp.java +++ b/basic/mail/src/main/java/org/springframework/integration/samples/mail/imapidle/GmailInboundPop3AdapterTestApp.java @@ -1,5 +1,17 @@ -/** - * +/* + * Copyright 2002-2012 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package org.springframework.integration.samples.mail.imapidle; @@ -18,10 +30,10 @@ import org.springframework.integration.core.MessageHandler; public class GmailInboundPop3AdapterTestApp { private static Logger logger = Logger.getLogger(GmailInboundPop3AdapterTestApp.class); - + public static void main (String[] args) throws Exception { ApplicationContext ac = new ClassPathXmlApplicationContext("/META-INF/spring/integration/gmail-pop3-config.xml"); - DirectChannel inputChannel = ac.getBean("recieveChannel", DirectChannel.class); + DirectChannel inputChannel = ac.getBean("receiveChannel", DirectChannel.class); inputChannel.subscribe(new MessageHandler() { public void handleMessage(Message message) throws MessagingException { logger.info("Message: " + message); diff --git a/basic/mail/src/main/resources/META-INF/spring/integration/gmail-imap-idle-config.xml b/basic/mail/src/main/resources/META-INF/spring/integration/gmail-imap-idle-config.xml index 211cace3..7bba2e28 100644 --- a/basic/mail/src/main/resources/META-INF/spring/integration/gmail-imap-idle-config.xml +++ b/basic/mail/src/main/resources/META-INF/spring/integration/gmail-imap-idle-config.xml @@ -9,16 +9,16 @@ xmlns:int-mail="http://www.springframework.org/schema/integration/mail" xmlns:util="http://www.springframework.org/schema/util"> - + - + javax.net.ssl.SSLSocketFactory false diff --git a/basic/mail/src/main/resources/META-INF/spring/integration/gmail-pop3-config.xml b/basic/mail/src/main/resources/META-INF/spring/integration/gmail-pop3-config.xml index 003bbfda..154c9cd4 100644 --- a/basic/mail/src/main/resources/META-INF/spring/integration/gmail-pop3-config.xml +++ b/basic/mail/src/main/resources/META-INF/spring/integration/gmail-pop3-config.xml @@ -9,17 +9,17 @@ xmlns:int-mail="http://www.springframework.org/schema/integration/mail" xmlns:util="http://www.springframework.org/schema/util"> - + - - + - + diff --git a/intermediate/multipart-http/README.md b/intermediate/multipart-http/README.md index dc8da1a5..f130c1bf 100644 --- a/intermediate/multipart-http/README.md +++ b/intermediate/multipart-http/README.md @@ -17,13 +17,13 @@ The Server is Spring Integration's HTTP endpoint configuration. To run this sample: -1. Deploy project +1. Deploy project * If you are using STS and project is imported as Eclipse project in your workspace you can just execute **Run on Server** * You can also run **mvn clean install** and generate the WAR file that you can deploy the conventional way 2. run the simple test client program: **org.springframework.integration.samples.multipart.MultipartClient** - + You should see the following output from the server: - - INFO : ...MultipartClient - Successfully recieved multipart request: {company=[[Ljava.lang.String;@147e8bd9], company-logo=[org.springframework.integration.http.UploadedMultipartFile@f5e12]} + + INFO : ...MultipartClient - Successfully received multipart request: {company=[[Ljava.lang.String;@147e8bd9], company-logo=[org.springframework.integration.http.UploadedMultipartFile@f5e12]} INFO : ...MultipartClient - company - SpringSource INFO : org.springframework.integration.samples.multipart.MultipartClient - company-logo - as UploadedMultipartFile: spring09_logo.png diff --git a/intermediate/multipart-http/src/main/java/org/springframework/integration/samples/multipart/MultipartReceiever.java b/intermediate/multipart-http/src/main/java/org/springframework/integration/samples/multipart/MultipartReceiver.java similarity index 79% rename from intermediate/multipart-http/src/main/java/org/springframework/integration/samples/multipart/MultipartReceiever.java rename to intermediate/multipart-http/src/main/java/org/springframework/integration/samples/multipart/MultipartReceiver.java index f058d3cc..0c7528a6 100644 --- a/intermediate/multipart-http/src/main/java/org/springframework/integration/samples/multipart/MultipartReceiever.java +++ b/intermediate/multipart-http/src/main/java/org/springframework/integration/samples/multipart/MultipartReceiver.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2010 the original author or authors. + * Copyright 2002-2012 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -24,12 +24,12 @@ import org.springframework.util.LinkedMultiValueMap; * @author Oleg Zhurakousky * */ -public class MultipartReceiever { - private static Logger logger = Logger.getLogger(MultipartReceiever.class); +public class MultipartReceiver { + private static Logger logger = Logger.getLogger(MultipartReceiver.class); @SuppressWarnings("rawtypes") - public void recieve(LinkedMultiValueMap multipartRequest){ - logger.info("Successfully recieved multipart request: " + multipartRequest); + public void receive(LinkedMultiValueMap multipartRequest){ + logger.info("Successfully received multipart request: " + multipartRequest); for (String elementName : multipartRequest.keySet()) { if (elementName.equals("company")){ LinkedList value = (LinkedList)multipartRequest.get("company"); @@ -38,7 +38,7 @@ public class MultipartReceiever { logger.info(elementName + " - " + companyName); } } else if (elementName.equals("company-logo")){ - logger.info(elementName + " - as UploadedMultipartFile: " + logger.info(elementName + " - as UploadedMultipartFile: " + ((UploadedMultipartFile) multipartRequest.getFirst("company-logo")).getOriginalFilename()); } } diff --git a/intermediate/multipart-http/src/main/webapp/WEB-INF/servlet-config.xml b/intermediate/multipart-http/src/main/webapp/WEB-INF/servlet-config.xml index ffa344a2..f27f8670 100644 --- a/intermediate/multipart-http/src/main/webapp/WEB-INF/servlet-config.xml +++ b/intermediate/multipart-http/src/main/webapp/WEB-INF/servlet-config.xml @@ -18,7 +18,7 @@ - +