Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
IContainedComponent |
|
| 1.0;1 |
1 | // Copyright 2004, 2005 The Apache Software Foundation | |
2 | // | |
3 | // Licensed under the Apache License, Version 2.0 (the "License"); | |
4 | // you may not use this file except in compliance with the License. | |
5 | // You may obtain a copy of the License at | |
6 | // | |
7 | // http://www.apache.org/licenses/LICENSE-2.0 | |
8 | // | |
9 | // Unless required by applicable law or agreed to in writing, software | |
10 | // distributed under the License is distributed on an "AS IS" BASIS, | |
11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
12 | // See the License for the specific language governing permissions and | |
13 | // limitations under the License. | |
14 | ||
15 | package org.apache.tapestry.spec; | |
16 | ||
17 | import java.util.Collection; | |
18 | ||
19 | import org.apache.hivemind.Locatable; | |
20 | import org.apache.hivemind.LocationHolder; | |
21 | import org.apache.tapestry.util.IPropertyHolder; | |
22 | ||
23 | /** | |
24 | * Defines a contained component. This includes the information needed to get | |
25 | * the contained component's specification, as well as any bindings for the | |
26 | * component. | |
27 | * | |
28 | * @author glongman@intelligentworks.com | |
29 | */ | |
30 | public interface IContainedComponent extends IPropertyHolder, LocationHolder, | |
31 | Locatable, PropertyInjectable | |
32 | { | |
33 | ||
34 | /** | |
35 | * Returns the named binding, or null if the binding does not exist. | |
36 | */ | |
37 | IBindingSpecification getBinding(String name); | |
38 | ||
39 | /** | |
40 | * Returns an umodifiable <code>Collection</code> of Strings, each the | |
41 | * name of one binding for the component. | |
42 | */ | |
43 | Collection getBindingNames(); | |
44 | ||
45 | String getType(); | |
46 | ||
47 | void setBinding(String name, IBindingSpecification spec); | |
48 | ||
49 | void setType(String value); | |
50 | ||
51 | /** | |
52 | * Sets the String Id of the component being copied from. For use by IDE | |
53 | * tools like Spindle. | |
54 | * | |
55 | * @since 1.0.9 | |
56 | */ | |
57 | void setCopyOf(String id); | |
58 | ||
59 | /** | |
60 | * Returns the id of the component being copied from. For use by IDE tools | |
61 | * like Spindle. | |
62 | * | |
63 | * @since 1.0.9 | |
64 | */ | |
65 | String getCopyOf(); | |
66 | ||
67 | /** | |
68 | * Returns whether the contained component will inherit the informal | |
69 | * parameters of its parent. | |
70 | * | |
71 | * @since 3.0 | |
72 | */ | |
73 | boolean getInheritInformalParameters(); | |
74 | ||
75 | /** | |
76 | * Sets whether the contained component will inherit the informal parameters | |
77 | * of its parent. | |
78 | * | |
79 | * @since 3.0 | |
80 | */ | |
81 | void setInheritInformalParameters(boolean value); | |
82 | ||
83 | /** | |
84 | * Returns the name of the property to be created for this component, or | |
85 | * null if no property should be created. | |
86 | * | |
87 | * @since 4.0 | |
88 | */ | |
89 | String getPropertyName(); | |
90 | ||
91 | /** | |
92 | * @since 4.0 | |
93 | */ | |
94 | ||
95 | void setPropertyName(String propertyName); | |
96 | } |