|
|||||||||||||||||||
30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover | |||||||||||||||||||
Source file | Conditionals | Statements | Methods | TOTAL | |||||||||||||||
MaskEdit.java | - | - | - | - |
|
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.contrib.form;
|
|
16 |
|
|
17 |
import org.apache.tapestry.BaseComponent;
|
|
18 |
|
|
19 |
/**
|
|
20 |
* Provides a mask edit HTML <input type="text"> form element.
|
|
21 |
* <p>
|
|
22 |
* Mask edit field validates the text the user enters against a mask that encodes the valid forms
|
|
23 |
* the text can take. The mask can also format text that is displayed to the user.
|
|
24 |
* <p>
|
|
25 |
* <table border="1" cellpadding="2">
|
|
26 |
* <tr>
|
|
27 |
* <th>Mask character</th>
|
|
28 |
* <th>Meaning in mask</th>
|
|
29 |
* </tr>
|
|
30 |
* <tr>
|
|
31 |
* <td> l</td>
|
|
32 |
* <td> Mixed case letter character [a..z, A..Z]</td>
|
|
33 |
* </tr>
|
|
34 |
* <tr>
|
|
35 |
* <td> L</td>
|
|
36 |
* <td> Upper case letter character [A..Z]</td>
|
|
37 |
* </tr>
|
|
38 |
* <tr>
|
|
39 |
* <td> a</td>
|
|
40 |
* <td> Mixed case alpha numeric character [a..z, A..Z, 0..1]</td>
|
|
41 |
* </tr>
|
|
42 |
* <tr>
|
|
43 |
* <td> A</td>
|
|
44 |
* <td> Upper case alpha numeric character [A..Z, 0..9]</td>
|
|
45 |
* </tr>
|
|
46 |
* <tr>
|
|
47 |
* <td> #</td>
|
|
48 |
* <td> Numeric character [0..9]</td>
|
|
49 |
* </tr>
|
|
50 |
* <tr>
|
|
51 |
* <td> _</td>
|
|
52 |
* <td> Reserved character for display, do not use.</td>
|
|
53 |
* </tr>
|
|
54 |
* <tr>
|
|
55 |
* <td> others</td>
|
|
56 |
* <td> Non editable character for display.</td>
|
|
57 |
* </tr>
|
|
58 |
* </table>
|
|
59 |
* <p>
|
|
60 |
* This component requires JavaScript to be enabled in the client browser.
|
|
61 |
* <p>[ <a href="../../../../../ComponentReference/MaskEdit.html">Component Reference </a>]
|
|
62 |
*
|
|
63 |
* @author Malcolm Edgar
|
|
64 |
* @since 2.3
|
|
65 |
*/
|
|
66 |
|
|
67 |
public abstract class MaskEdit extends BaseComponent |
|
68 |
{ |
|
69 |
public abstract String getMask();
|
|
70 |
|
|
71 |
public abstract void setMask(String mask); |
|
72 |
|
|
73 |
public abstract String getValue();
|
|
74 |
|
|
75 |
public abstract void setValue(String value); |
|
76 |
|
|
77 |
public abstract boolean isDisabled(); |
|
78 |
|
|
79 |
public abstract void setDisabled(boolean disabled); |
|
80 |
} |
|