01: /**********************************************************************************
02: * $URL: https://source.sakaiproject.org/svn/portal/tags/sakai_2-4-1/portal-portlet-tool/tool/src/java/org/sakaiproject/portal/portlet/PortletRenderContext.java $
03: * $Id: PortletRenderContext.java 19790 2006-12-20 15:48:31Z ian@caret.cam.ac.uk $
04: ***********************************************************************************
05: *
06: * Copyright (c) 2005, 2006 The Sakai Foundation.
07: *
08: * Licensed under the Educational Community License, Version 1.0 (the "License");
09: * you may not use this file except in compliance with the License.
10: * You may obtain a copy of the License at
11: *
12: * http://www.opensource.org/licenses/ecl1.php
13: *
14: * Unless required by applicable law or agreed to in writing, software
15: * distributed under the License is distributed on an "AS IS" BASIS,
16: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17: * See the License for the specific language governing permissions and
18: * limitations under the License.
19: *
20: **********************************************************************************/package org.sakaiproject.portal.portlet;
21:
22: /**
23: * This interface represent the Render Context, it allows the portal implementation to
24: * put values into the render context. There is a utility dump method to dump the context.
25: * Instances of this class should be created per request via an Implimention of the RenderContextEngine
26: * @author ieb
27: *
28: */
29: public interface PortletRenderContext {
30:
31: /**
32: * Set a value agaaisnt a Key, normally a value might be a String, Collection or a Map, but
33: * depending on the render engine technology other objects may be acceptable.
34: * @param string
35: * @param value
36: */
37: void put(String string, Object value);
38:
39: /**
40: * Converr the render context to a string suitable for dumping to a log file or console.
41: * @return
42: */
43: String dump();
44:
45: /**
46: * Return true if the context needs this part of the portal
47: * @param includeOption
48: * @return
49: */
50: boolean uses(String includeOption);
51:
52: }
|