01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */
17: package org.apache.cocoon.webapps.session.acting;
18:
19: import java.util.Map;
20:
21: import org.apache.avalon.framework.parameters.Parameters;
22: import org.apache.avalon.framework.service.ServiceException;
23: import org.apache.avalon.framework.thread.ThreadSafe;
24: import org.apache.cocoon.ProcessingException;
25: import org.apache.cocoon.acting.ServiceableAction;
26: import org.apache.cocoon.environment.Redirector;
27: import org.apache.cocoon.environment.SourceResolver;
28: import org.apache.cocoon.webapps.session.FormManager;
29:
30: /**
31: * This action invokes the form manager to process incomming form values
32: *
33: * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
34: * @deprecated This block is deprecated and will be removed in future versions.
35: * @version CVS $Id: FormManagerAction.java 433543 2006-08-22 06:22:54Z crossley $
36: */
37: public final class FormManagerAction extends ServiceableAction
38: implements ThreadSafe {
39:
40: public Map act(Redirector redirector, SourceResolver resolver,
41: Map objectModel, String source, Parameters par)
42: throws ProcessingException {
43: FormManager formManager = null;
44: try {
45: formManager = (FormManager) this .manager
46: .lookup(FormManager.ROLE);
47: formManager.processInputFields();
48: } catch (ServiceException ce) {
49: throw new ProcessingException(
50: "Error during lookup of formManager component.", ce);
51: } finally {
52: this.manager.release(formManager);
53: }
54:
55: return EMPTY_MAP;
56: }
57:
58: }
|