Source Code Cross Referenced for DateFormatterConstants.java in  » Development » ivatamasks » com » ivata » mask » web » format » 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.web.format 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Copyright (c) 2001 - 2005 ivata limited.
003:         * All rights reserved.
004:         * -----------------------------------------------------------------------------
005:         * ivata groupware 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: DateFormatterConstants.java,v $
031:         * Revision 1.2  2005/04/09 18:04:18  colinmacleod
032:         * Changed copyright text to GPL v2 explicitly.
033:         *
034:         * Revision 1.1  2005/01/19 12:49:24  colinmacleod
035:         * Moved from ivata groupware.
036:         *
037:         * Revision 1.1  2004/09/30 15:16:04  colinmacleod
038:         * Split off addressbook elements into security subproject.
039:         *
040:         * Revision 1.2  2004/03/21 21:16:19  colinmacleod
041:         * Shortened name to ivata op.
042:         *
043:         * Revision 1.1.1.1  2004/01/27 20:58:00  colinmacleod
044:         * Moved ivata openportal to SourceForge..
045:         *
046:         * Revision 1.2  2003/10/17 12:36:13  jano
047:         * fixing problems with building
048:         * converting intranet -> portal
049:         * Eclipse building
050:         *
051:         * Revision 1.1.1.1  2003/10/13 20:50:15  colin
052:         * Restructured portal into subprojects
053:         *
054:         * Revision 1.6  2003/02/24 19:27:31  colin
055:         * restructured file paths
056:         *
057:         * Revision 1.5  2003/02/20 16:21:19  peter
058:         * added input format for date/time
059:         *
060:         * Revision 1.4  2003/02/20 14:03:14  peter
061:         * 24H time formats removed, fixed DATE_SHORT_YEAR
062:         *
063:         * Revision 1.3  2003/02/04 17:43:52  colin
064:         * copyright notice
065:         *
066:         * Revision 1.2  2002/11/15 15:22:17  jano
067:         * we have new format  date_short_year
068:         *
069:         * Revision 1.1  2002/09/23 11:47:32  colin
070:         * Split date formatter constants off into separate file.
071:         * -----------------------------------------------------------------------------
072:         */
073:        package com.ivata.mask.web.format;
074:
075:        /**
076:         * <p>Contains all of the constants defining date formats used in
077:         * {@link SettingDateFormatter SettingDateFormatter}.</p>
078:         *
079:         * @since   2002-09-18
080:         * @author Colin MacLeod
081:         * <a href='mailto:colin.macleod@ivata.com'>colin.macleod@ivata.com</a>
082:         * @version $Revision: 1.2 $
083:         * @see SettingDateFormatter
084:         */
085:        public class DateFormatterConstants {
086:            /**
087:             * <p>Use this for a long date format. While the actual content of
088:             * this format
089:             * depends on the settings, it should include a representation for day
090:             * and month
091:             * and a text should be used for the month.</p>
092:             *
093:             * <p>The setting for this date type is called "i18nDateLong".</p>
094:             */
095:            public static final int DATE_LONG = 1;
096:            /**
097:             * <p>Use this for a short date format. While the actual content of
098:             * this format
099:             * depends on the settings, it should include a representation for day
100:             * and month
101:             * and numbers are normally used rather than text for the months.</p>
102:             */
103:            public static final int DATE_SHORT = 5;
104:            /**
105:             * <p>This creates a format which depends on how close the date is to
106:             * the
107:             * current date. Typically, this works as follows:<br/>
108:             * <table cellpadding='0' cellspacing='4' border='0'>
109:             *   <tr>
110:             *     <th>how close are the dates?</th>
111:             *     <th>format used</th>
112:             *   </tr>
113:             *   <tr>
114:             *     <td>same day</td>
115:             *     <td>This depends on the time. If the time is before noon then
116:             * the 'date'
117:             * format will be "this morning". After noon but before 6pm, the
118:             * format is "this
119:             * afternoon", and after 6pm the format is "this evening".<br/>These
120:             * texts can
121:             * be
122:             * altered by the settings "i18nDateThisMorning",
123:             * "i18nDateThisAfternoon" and
124:             * "i18nDateThisEvening" respectively.</td>
125:             *   </tr>
126:             *   <tr>
127:             *     <td>previous day</td>
128:             *     <td>This depends on the time. If the time is before noon then
129:             * the 'date'
130:             * format will be "yesterday morning". After noon but before 6pm, the
131:             * format is
132:             * "yesterday afternoon", and after 6pm the format is "last
133:             * night".<br/>These
134:             * texts can be altered by the settings "i18nDateYesterdayMorning",
135:             * "i18nDateYesterdayAfternoon" and "i18nDateYesterdayEvening"
136:             * respectively.</td>
137:             *   </tr>
138:             *   <tr>
139:             *     <td>same week</td>
140:             *     <td>If both dates are in the same week, then the day is used,
141:             * e.g.
142:             * "Tuesday". This can be altered by changing the setting of
143:             * "i18nDateWeekDay".</td>
144:             *   </tr>
145:             *   <tr>
146:             *     <td>previous week</td>
147:             *     <td>Again the day is used but this time with "last", e.g. "last
148:             * Tuesday".
149:             * This can be altered by changing the setting of
150:             * "i18nDateLastWeekDay".</td>
151:             *   </tr>
152:             *   <tr>
153:             *     <td>same year</td>
154:             *     <td>If the years are the same then the format for the setting
155:             * "i18nDateLong"
156:             * is used.</td>
157:             *   </tr>
158:             *   <tr>
159:             *     <td>other</td>
160:             *     <td>For all other dates, the format for the setting
161:             * "i18nDateLongYear" is
162:             * used.</td>
163:             *   </tr>
164:             * </table>
165:             * </p>
166:             */
167:            public static final int DATE_RELATIVE = 4;
168:            /**
169:             * <p>Use this for a long date format which includes the day of the
170:             * week. While
171:             * the actual
172:             * content of this format depends on the settings, it should include a
173:             * representation for day, month and week day and a text should be
174:             * used for the
175:             * month.</p>
176:             *
177:             * <p>The setting for this date type is called "i18nDateLongDay".</p>
178:             */
179:            public static final int DATE_LONG_DAY = 2;
180:            /**
181:             * <p>Use this for a long date format which includes the year. While
182:             * the actual
183:             * content of this format depends on the settings, it should include a
184:             * representation for day, month and year and a text should be used
185:             * for the
186:             * month.</p>
187:             *
188:             * <p>The setting for this date type is called "i18nDateLongYear".</p>
189:             */
190:            public static final int DATE_LONG_YEAR = 3;
191:            /**
192:             * <p>Use this for a short time format. While the actual content of
193:             * this format
194:             * depends on the settings, it should include a representation for
195:             * hour and
196:             * minutes.</p>
197:             */
198:            public static final int TIME_SHORT = 1;
199:            /**
200:             * <p>Use this for a long time format. While the actual content of
201:             * this format
202:             * depends on the settings, it should include a representation for
203:             * hour,
204:             * minutes.
205:             * and seconds.</p>
206:             */
207:            public static final int TIME_LONG = 2;
208:            /**
209:             * <p>This creates a format which depends on how close the date is to
210:             * the current date. Typically, this works as follows:<br/>
211:             * <table cellpadding='0' cellspacing='4' border='0'>
212:             *   <tr>
213:             *     <th>how close are the dates?</th>
214:             *     <th>format used</th>
215:             *   </tr>
216:             *   <tr>
217:             *     <td>same day</td>
218:             *     <td>"Today".<br/>This text can be altered by the setting
219:             * "i18nDateShortToday".</td>
220:             *   </tr>
221:             *   <tr>
222:             *     <td>previous day</td>
223:             *     <td>"Yesterday".<br/>This text can be altered by the setting
224:             * "i18nDateShortYesterday".</td>
225:             *   </tr>
226:             *   <tr>
227:             *     <td>same week</td>
228:             *     <td>If both dates are in the same week, then the day is used,
229:             * e.g.  "Tuesday". This can be altered by changing the setting of
230:             * "i18nDateWeekDay".</td>
231:             *   </tr>
232:             *   <tr>
233:             *     <td>same year</td>
234:             *     <td>If the years are the same then the format for the setting
235:             * "i18nDateShort"
236:             * is used.</td>
237:             *   </tr>
238:             *   <tr>
239:             *     <td>other</td>
240:             *     <td>For all other dates, the format for the setting
241:             * "i18nDateShortYear" is used.</td>
242:             *   </tr>
243:             * </table>
244:             * </p>
245:             */
246:            public static final int DATE_SHORT_RELATIVE = 6;
247:            /**
248:             * <p>Use this for a short date format. While the actual content of
249:             * this format depends on the settings, it should include a
250:             * representation for day and month and year and numbers are normally
251:             * used rather than text for the months.</p>
252:             */
253:            public static final int DATE_SHORT_YEAR = 7;
254:            /**
255:             * <p>Specified input format for time, should be less strict that
256:             * <code>TIME_INPUT_DISPLAY</code>.</p>
257:             */
258:            public static final int TIME_INPUT = 3;
259:            /**
260:             * <p>This format specifies the format of times shown to the user
261:             * after he enters a correct time, should be more specific as
262:             * <code>TIME_INPUT</code>.</p>
263:             */
264:            public static final int TIME_INPUT_DISPLAY = 4;
265:            /**
266:             * <p>Specifies input format for date, should be less strict that
267:             * <code>DATE_INPUT_DISPLAY</code>.</p>
268:             */
269:            public static final int DATE_INPUT = 8;
270:            /**
271:             * <p>This format specifies the format of dates shown to the user
272:             * after he enters a correct date, should be more specific as
273:             * <code>DATE_INPUT</code>.</p>
274:             */
275:            public static final int DATE_INPUT_DISPLAY = 9;
276:
277:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.