001 // Copyright 2007, 2008 The Apache Software Foundation
002 //
003 // Licensed under the Apache License, Version 2.0 (the "License");
004 // you may not use this file except in compliance with the License.
005 // You may obtain a copy of the License at
006 //
007 // http://www.apache.org/licenses/LICENSE-2.0
008 //
009 // Unless required by applicable law or agreed to in writing, software
010 // distributed under the License is distributed on an "AS IS" BASIS,
011 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
012 // See the License for the specific language governing permissions and
013 // limitations under the License.
014
015 package org.apache.tapestry5.beaneditor;
016
017 /**
018 * Defines the names of data types used to select an editor (or display) block for a property.
019 *
020 * @see DataType
021 * @since 5.3
022 */
023 public class DataTypeConstants
024 {
025 /**
026 * Used for {@link String} properties.
027 */
028 public static final String TEXT = "text";
029
030 /**
031 * Used for properties of {@link Number} type.
032 */
033 public static final String NUMBER = "number";
034
035 /**
036 * Used for {@link Enum}s.
037 */
038 public static final String ENUM = "enum";
039
040 /**
041 * Used for boolean properties.
042 */
043 public static final String BOOLEAN = "boolean";
044
045 /**
046 * Used to render a JavaScript calendar for a {@link java.util.Date} property.
047 */
048 public static final String DATE = "date";
049
050 /**
051 * Used to render a JavaScript calendar for a {@link java.util.Calendar} property.
052 */
053 public static final String CALENDAR = "calendar";
054
055 /**
056 * Used to render a password field for a {@link String} property.
057 */
058 public static final String PASSWORD = "password";
059
060 /**
061 * Used to render a textarea field for a {@link String} property.
062 */
063 public static final String LONG_TEXT = "longtext";
064
065 }