01: /*******************************************************************************
02: * Licensed to the Apache Software Foundation (ASF) under one
03: * or more contributor license agreements. See the NOTICE file
04: * distributed with this work for additional information
05: * regarding copyright ownership. The ASF licenses this file
06: * to you under the Apache License, Version 2.0 (the
07: * "License"); you may not use this file except in compliance
08: * with the License. You may obtain a copy of the License at
09: *
10: * http://www.apache.org/licenses/LICENSE-2.0
11: *
12: * Unless required by applicable law or agreed to in writing,
13: * software distributed under the License is distributed on an
14: * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15: * KIND, either express or implied. See the License for the
16: * specific language governing permissions and limitations
17: * under the License.
18: *******************************************************************************/package org.ofbiz.widget;
19:
20: import java.io.IOException;
21: import java.io.Writer;
22: import java.util.List;
23: import java.util.Locale;
24: import java.util.Map;
25:
26: import org.ofbiz.base.util.GeneralException;
27: import org.ofbiz.entity.GenericDelegator;
28: import org.ofbiz.entity.GenericEntityException;
29: import org.ofbiz.entity.GenericValue;
30: import org.ofbiz.service.LocalDispatcher;
31:
32: /**
33: * ContentWorkerInterface
34: */
35: public interface ContentWorkerInterface {
36:
37: // helper methods
38: public GenericValue getCurrentContentExt(
39: GenericDelegator delegator, List trail,
40: GenericValue userLogin, Map ctx, Boolean nullThruDatesOnly,
41: String contentAssocPredicateId) throws GeneralException;
42:
43: public GenericValue getWebSitePublishPointExt(
44: GenericDelegator delegator, String contentId,
45: boolean ignoreCache) throws GenericEntityException;
46:
47: public String getMimeTypeIdExt(GenericDelegator delegator,
48: GenericValue view, Map ctx);
49:
50: // new rendering methods
51: public void renderContentAsTextExt(LocalDispatcher dispatcher,
52: GenericDelegator delegator, String contentId, Writer out,
53: Map templateContext, Locale locale, String mimeTypeId,
54: boolean cache) throws GeneralException, IOException;
55:
56: public String renderContentAsTextExt(LocalDispatcher dispatcher,
57: GenericDelegator delegator, String contentId,
58: Map templateContext, Locale locale, String mimeTypeId,
59: boolean cache) throws GeneralException, IOException;
60:
61: public void renderSubContentAsTextExt(LocalDispatcher dispatcher,
62: GenericDelegator delegator, String contentId, Writer out,
63: String mapKey, Map templateContext, Locale locale,
64: String mimeTypeId, boolean cache) throws GeneralException,
65: IOException;
66:
67: public String renderSubContentAsTextExt(LocalDispatcher dispatcher,
68: GenericDelegator delegator, String contentId,
69: String mapKey, Map templateContext, Locale locale,
70: String mimeTypeId, boolean cache) throws GeneralException,
71: IOException;
72: }
|