1 /*
2 * Copyright 2000-2001,2004 The Apache Software Foundation.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16 /*
17 * ViewProcessor.java
18 *
19 * Created on January 27, 2003, 5:18 PM
20 */
21 package org.apache.jetspeed.portal.portlets.viewprocessor;
22
23 import org.apache.jetspeed.portal.Portlet;
24 import org.apache.jetspeed.portal.PortletException;
25 import org.apache.jetspeed.portal.portlets.*;
26
27 /***
28 * Interface that defines a ViewProcessor. This is what the
29 * GenericMVCPortlet uses via the ViewProcessorFactory to
30 * do the template processing portion of the MVC design pattern.
31 *
32 * @author tkuebler
33 * @version 1.0
34 * @stereotype plug-in point
35 */
36 public interface ViewProcessor
37 {
38
39 /***
40 * Process the template passed in the context
41 * (context.get("template")). Invoked by the GenericMVCPortlet
42 * after action handling to process the template type
43 * in question.
44 */
45 void init(Portlet portlet)
46 throws PortletException;
47
48 Object processView(GenericMVCContext context);
49 }