Author: sergeyb
Date: Fri Nov 8 14:06:35 2013
New Revision: 1540037
URL: http://svn.apache.org/r1540037
Log:
[CXF-5308, CXF-5309] Adding simple interceptors expecting the singleton service
object being injected directly into them from Spring/etc
Added:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java
(with props)
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java
(with props)
Added:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java
URL:
http://svn.apache.org/viewvc/cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java?rev=1540037&view=auto
==============================================================================
---
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java
(added)
+++
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java
Fri Nov 8 14:06:35 2013
@@ -0,0 +1,40 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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.apache.cxf.validation;
+
+import org.apache.cxf.message.Message;
+
+
+public class SimpleValidationInInterceptor extends
AbstractValidationInInterceptor {
+ private Object serviceObject;
+ public SimpleValidationInInterceptor() {
+ }
+ public SimpleValidationInInterceptor(String phase) {
+ super(phase);
+ }
+
+ @Override
+ protected Object getResourceInstance(Message message) {
+ return serviceObject;
+ }
+
+ public void setServiceObject(Object object) {
+ this.serviceObject = object;
+ }
+}
Propchange:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationInInterceptor.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java
URL:
http://svn.apache.org/viewvc/cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java?rev=1540037&view=auto
==============================================================================
---
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java
(added)
+++
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java
Fri Nov 8 14:06:35 2013
@@ -0,0 +1,40 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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.apache.cxf.validation;
+
+import org.apache.cxf.message.Message;
+
+
+public class SimpleValidationOutInterceptor extends
AbstractValidationOutInterceptor {
+ private Object serviceObject;
+ public SimpleValidationOutInterceptor() {
+ }
+ public SimpleValidationOutInterceptor(String phase) {
+ super(phase);
+ }
+
+ @Override
+ protected Object getResourceInstance(Message message) {
+ return serviceObject;
+ }
+
+ public void setServiceObject(Object object) {
+ this.serviceObject = object;
+ }
+}
Propchange:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
cxf/trunk/core/src/main/java/org/apache/cxf/validation/SimpleValidationOutInterceptor.java
------------------------------------------------------------------------------
svn:keywords = Rev Date