Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
IBindingSpecification |
|
| 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 org.apache.hivemind.Locatable; | |
18 | import org.apache.hivemind.LocationHolder; | |
19 | ||
20 | /** | |
21 | * Stores a binding specification, which identifies the static value or OGNL | |
22 | * expression for the binding. The name of the binding (which matches a bindable | |
23 | * property of the contined component) is implicitly known. | |
24 | * | |
25 | * @author glongman@intelligentworks.com | |
26 | */ | |
27 | public interface IBindingSpecification extends LocationHolder, Locatable | |
28 | { | |
29 | ||
30 | /** | |
31 | * Returns the type of binding specification; this is generally | |
32 | * {@link org.apache.tapestry.spec.BindingType#PREFIXED}. | |
33 | */ | |
34 | ||
35 | BindingType getType(); | |
36 | ||
37 | /** | |
38 | * For a prefixed binding specification (the typical type), the value is a | |
39 | * binding reference; a string used to contruct the actual binding, and | |
40 | * consists of a prefix (such as "ognl:" or "message:") and a locator. The | |
41 | * prefix selects a {@link org.apache.tapestry.binding.BindingFactory}, and | |
42 | * the locator is passed to the factory, which uses it to construct the | |
43 | * {@link org.apache.tapestry.IBinding}instance. | |
44 | */ | |
45 | ||
46 | String getValue(); | |
47 | ||
48 | void setType(BindingType type); | |
49 | ||
50 | void setValue(String value); | |
51 | } |