Source Code Cross Referenced for Field.java in  » Development » ivatamasks » com » ivata » mask » field » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Development » ivatamasks » com.ivata.mask.field 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Copyright (c) 2001 - 2005 ivata limited.
003:         * All rights reserved.
004:         * -----------------------------------------------------------------------------
005:         * ivata masks may be redistributed under the GNU General Public
006:         * License as published by the Free Software Foundation;
007:         * version 2 of the License.
008:         *
009:         * These programs are free software; you can redistribute them and/or
010:         * modify them under the terms of the GNU General Public License
011:         * as published by the Free Software Foundation; version 2 of the License.
012:         *
013:         * These programs are distributed in the hope that they will be useful,
014:         * but WITHOUT ANY WARRANTY; without even the implied warranty of
015:         * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
016:         *
017:         * See the GNU General Public License in the file LICENSE.txt for more
018:         * details.
019:         *
020:         * If you would like a copy of the GNU General Public License write to
021:         *
022:         * Free Software Foundation, Inc.
023:         * 59 Temple Place - Suite 330
024:         * Boston, MA 02111-1307, USA.
025:         *
026:         *
027:         * To arrange commercial support and licensing, contact ivata at
028:         *                  http://www.ivata.com/contact.jsp
029:         * -----------------------------------------------------------------------------
030:         * $Log: Field.java,v $
031:         * Revision 1.9  2005/09/29 12:12:30  colinmacleod
032:         * Added password field type.
033:         *
034:         * Revision 1.8  2005/09/16 13:41:18  colinmacleod
035:         * Created new convertor class to handle timestamps.
036:         *
037:         * Revision 1.7  2005/04/11 12:27:02  colinmacleod
038:         * Added preliminary support for filters.
039:         * Added FieldValueConvertor factor interface
040:         * to split off value convertors for reuse.
041:         *
042:         * Revision 1.6  2005/04/09 18:04:14  colinmacleod
043:         * Changed copyright text to GPL v2 explicitly.
044:         *
045:         * Revision 1.5  2005/03/10 10:19:24  colinmacleod
046:         * Added getLabelKey().
047:         *
048:         * Revision 1.4  2005/01/19 12:35:04  colinmacleod
049:         * Added hidden fields.
050:         *
051:         * Revision 1.3  2005/01/06 22:13:21  colinmacleod
052:         * Moved up a version number.
053:         * Changed copyright notices to 2005.
054:         * Updated the documentation:
055:         *   - started working on multiproject:site docu.
056:         *   - changed the logo.
057:         * Added checkstyle and fixed LOADS of style issues.
058:         * Added separate thirdparty subproject.
059:         * Added struts (in web), util and webgui (in webtheme) from ivata op.
060:         *
061:         * Revision 1.2  2004/12/30 20:14:08  colinmacleod
062:         * Added comment for isMandatory.
063:         *
064:         * Revision 1.1  2004/12/29 20:07:07  colinmacleod
065:         * Renamed subproject masks to mask.
066:         *
067:         * Revision 1.2  2004/11/11 13:31:36  colinmacleod
068:         * Added mask.
069:         *
070:         * Revision 1.1.1.1  2004/05/16 20:40:31  colinmacleod
071:         * Ready for 0.1 release
072:         * -----------------------------------------------------------------------------
073:         */
074:        package com.ivata.mask.field;
075:
076:        import java.util.List;
077:        import java.util.Properties;
078:
079:        import com.ivata.mask.Mask;
080:
081:        /**
082:         * Defines a single field within a mask or group of masks.
083:         *
084:         * @since ivata masks 0.1 (2004-02-26)
085:         * @author Colin MacLeod
086:         * <a href='mailto:colin.macleod@ivata.com'>colin.macleod@ivata.com</a>
087:         */
088:        public interface Field {
089:            /**
090:             * Indicates the fields contents should be formatted as an amount.
091:             */
092:            String TYPE_AMOUNT = "amount";
093:            /**
094:             * Indicates the fields contents should be formatted as a date.
095:             */
096:            String TYPE_DATE = "date";
097:            /**
098:             * Indicates the fields contents should be formatted as a number.
099:             */
100:            String TYPE_NUMBER = "number";
101:            /**
102:             * Indicates the field is an option to be displayed as a password field.
103:             */
104:            String TYPE_PASSWORD = "password";
105:            /**
106:             * Indicates the field is an option to be displayed as a radio button.
107:             */
108:            String TYPE_RADIO = "radio";
109:            /**
110:             * Indicates the field is displayed as a choice combo box.
111:             */
112:            String TYPE_SELECT = "select";
113:            /**
114:             * Indicates the field is displayed as a short text.
115:             */
116:            String TYPE_STRING = "string";
117:            /**
118:             * Indicates the field is displayed as a long text.
119:             */
120:            String TYPE_TEXTAREA = "textarea";
121:            /**
122:             * Indicates the fields contents should be formatted as a long timestamp.
123:             */
124:            String TYPE_TIMESTAMP = "timestamp";
125:
126:            /**
127:             * If this field represents a combo (select) type, returns the choices as a
128:             * <code>Properties</code> instance.
129:             *
130:             * @return <code>Properties</code> instance representing the possible
131:             *         values.
132:             */
133:            Properties getChoiceProperties();
134:
135:            /**
136:             * If this field represents a combo (select) type, returns the choice keys
137:             * as a <code>List</code> of <code>String</code> instances.
138:             *
139:             * @return <code>List</code> of <code>String</code> instances
140:             *         representing the key values of all choice options.
141:             */
142:            List getChoicePropertyKeys();
143:
144:            /**
145:             * Get the default value for this field. If no default has been defined for
146:             * this field, is <code>null</code>.
147:             *
148:             * @return default value for this field, or <code>null</code> if none is
149:             *         defined.
150:             */
151:            String getDefaultValue();
152:
153:            /**
154:             * Get the data object class for this field, if appropriate.
155:             *
156:             * @return data object class if this field links to a data object, otherwise
157:             *         <code>null</code>.
158:             */
159:            Class getDOClass();
160:
161:            /**
162:             * Id of just this field.
163:             *
164:             * @return Id of just this field.
165:             */
166:            String getName();
167:
168:            /**
169:             * <p>
170:             * Get the field which contains this one.
171:             * </p>
172:             *
173:             * @return Field which contains this field, or <code>null</code> if this
174:             *         is a top-level field.
175:             */
176:            Field getParent();
177:
178:            /**
179:             * <p>
180:             * Return the full path to this field, including the names of parent fields
181:             * separated by '.' characters. </p >
182:             *
183:             * @return Full path to this field, to uniquely identify it within the
184:             *         system.
185:             */
186:            String getPath();
187:
188:            /**
189:             * Indicates what sort of data this field should hold.
190:             *
191:             * @return type of the field, from one of the <code>TYPE_</code> values in
192:             *         this interface.
193:             */
194:            String getType();
195:
196:            /**
197:             * <p>
198:             * If this field represents a value object, get the mask associated with
199:             * this value object. <b>Note: </b> this is not the mask the field is in!.
200:             * </p>
201:             *
202:             * @return Mask associated with this value object or <code>null</code> if
203:             *         this field is not a value object.
204:             */
205:            Mask getValueObjectMask();
206:
207:            /**
208:             * Get whether or not this field can be amended. Useful for automatically
209:             * generated fields such as timestamps.
210:             * @return <code>true</code> if the field <u>cannot</u> be manually changed.
211:             */
212:            boolean isDisplayOnly();
213:
214:            /**
215:             * <p>
216:             * Is this field hidden or displayed?
217:             * </p>
218:             *
219:             * @return <code>true</code> if this field is hidden.
220:             */
221:            boolean isHidden();
222:
223:            /**
224:             * <p>
225:             * Is this field required or optional?
226:             * </p>
227:             *
228:             * @return <code>true</code> if this field is required and must have a
229:             *         non- <code>null</code>, non-empty value. Otherwise,
230:             *         <code>false</code> for an optional field.
231:             */
232:            boolean isMandatory();
233:
234:            /**
235:             * If this field represents another value object, but the relationship with
236:             * its container is one-to-one, then it can be included in the parent's
237:             * mask directly.
238:             *
239:             * @return <code>true</code> if this field should be displayed directly
240:             * in the mask of the parent field.
241:             */
242:            boolean isOneToOne();
243:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.