01: /*
02: * Copyright 2001-2006 C:1 Financial Services GmbH
03: *
04: * This software is free software; you can redistribute it and/or
05: * modify it under the terms of the GNU Lesser General Public
06: * License Version 2.1, as published by the Free Software Foundation.
07: *
08: * This software is distributed in the hope that it will be useful,
09: * but WITHOUT ANY WARRANTY; without even the implied warranty of
10: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11: * Lesser General Public License for more details.
12: *
13: * You should have received a copy of the GNU Lesser General Public
14: * License along with this library; if not, write to the Free Software
15: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA
16: */
17:
18: package de.finix.contelligent.core;
19:
20: import java.util.Map;
21: import java.util.Set;
22:
23: import de.finix.contelligent.CallData;
24: import de.finix.contelligent.Component;
25: import de.finix.contelligent.ComponentContext;
26: import de.finix.contelligent.search.Metainfo;
27:
28: public class ComponentPlaceholder implements Component {
29:
30: private ComponentContext context;
31:
32: private Map properties;
33:
34: public ComponentPlaceholder(Map properties) {
35: this .properties = properties;
36: }
37:
38: public Map getProperties() {
39: return properties;
40: }
41:
42: public void setComponentContext(ComponentContext ctx) {
43: this .context = ctx;
44: }
45:
46: public ComponentContext getComponentContext() {
47: return context;
48: }
49:
50: public boolean isDynamic() {
51: return false;
52: }
53:
54: /**
55: * Gets called by the Contelligent system after a component was loaded and
56: * all properties were set. If any exception is thrown by this method the
57: * system assumes that this instance was not properly initialized and the
58: * instance gets removed. <BR>
59: * <B>Important:</B> Any component extending another component has to call
60: * <code>super.postCreate()</code> when implementing this method.
61: */
62: public void postCreate() throws Exception {
63: }
64:
65: /**
66: * Returns the MetaData-Information: A XML-Document with doctype
67: * metainfo.dtd.
68: */
69: public void putSearchMetainfo(Metainfo metainfo, CallData callData) {
70: }
71:
72: public Set getRelations() {
73: return null;
74: }
75:
76: /**
77: * Answer true if the content of this component may be changed
78: *
79: * @return
80: */
81: public boolean mayChangeContent() {
82: return false;
83: }
84: }
|