Qore Programming Language Reference Manual  1.0.8
Pseudo_QC_Date.dox.h
1 
3 namespace Qore {
5 /***/
6 class <date> : public <value> {
7 
8 public:
10 
17 bool absolute();
18 
19 public:
21 
31 *string currentZoneName();
32 
33 public:
35 
49 int dayNumber();
50 
51 public:
53 
69 int dayOfWeek();
70 
71 public:
73 
87 int days();
88 
89 public:
91 
119 
120 public:
122 
152 
153 public:
155 
184 int durationSeconds();
185 
186 public:
188 
211 float durationSecondsFloat();
212 
213 public:
215 
231 string format(string format);
232 
233 public:
235 
247 int getEpochSeconds();
248 
249 public:
251 
264 
265 public:
267 
277 int getUtcOffset();
278 
279 public:
281 
295 int hours();
296 
297 public:
299 
313 hash<DateTimeInfo> info();
314 
315 public:
317 
328 bool intp();
329 
330 public:
332 
342 bool isDst();
343 
344 public:
346 
362 int isoDayOfWeek();
363 
364 public:
366 
384 hash<IsoWeekInfo> isoWeekHash();
385 
386 public:
388 
404 string isoWeekString();
405 
406 public:
408 
424 int microseconds();
425 
426 public:
428 
442 date midnight();
443 
444 public:
446 
462 int milliseconds();
463 
464 public:
466 
480 int minutes();
481 
482 public:
484 
498 int months();
499 
500 public:
502 
509 bool relative();
510 
511 public:
513 
529 int seconds();
530 
531 public:
533 
544 bool strp();
545 
546 public:
548 
559 int typeCode();
560 
561 public:
563 
577 bool val();
578 
579 public:
581 
593 int years();
594 
595 public:
597 
607 *TimeZone zone();
608 };
609 }
date date(date dt)
Returns the date passed.
string format(string format)
Returns a formatted string for the date value.
int durationMilliseconds()
Returns an integer value representing the the number of milliseconds of time duration in the date val...
bool relative()
Returns True if the date is a relative date/time value.
*TimeZone zone()
Returns a Qore::TimeZone object for the time zone of the date/time value; returns NOTHING for relativ...
*string currentZoneName()
Returns the name of the current time zone for the current absolute date/time value (ex: "CEST" for Ce...
bool strp()
Returns True because boolean values can be converted to strings.
Methods in this pseudo-class are available to be executed on any value type (even NOTHING); this is t...
Definition: Pseudo_QC_All.dox.h:6
int getUtcOffset()
Returns the time zone offset for the current time in seconds east of UTC or -1 for relative date/time...
int hours()
Returns an integer corresponding to the literal hour value in the date (does not calculate a duration...
string isoWeekString()
Returns a string representing the ISO-8601 calendar week information for the absolute date (ex: 2006-...
int microseconds()
Returns an integer corresponding to the literal microsecond value in the date (does not calculate a d...
int dayNumber()
Returns an integer representing the ordinal day number in the year (corresponding to the ISO-8601 day...
bool intp()
Returns True because date values can be converted to integers.
bool isDst()
Returns True if the current date/time value is currently in daylight savings time.
The TimeZone class provides access to time zone functionality.
Definition: QC_TimeZone.dox.h:11
int milliseconds()
Returns an integer corresponding to the literal millisecond value in the date (does not calculate a d...
int dayOfWeek()
Returns an integer representing the day of the week for the absolute date value (0=Sunday, 6=Saturday)
Methods in this pseudo-class can be executed on date/time value types.
Definition: Pseudo_QC_Date.dox.h:6
date midnight()
Returns midnight on the given date (strips the time component on the new value)
int months()
Returns an integer corresponding to the literal month value in the date (does not calculate a duratio...
hash< DateTimeInfo > info()
Returns a DateTimeInfo hash for the date (can be either a relative or absolute date) ...
bool val()
Returns False if the date value is all zeros, True if not.
hash< IsoWeekInfo > isoWeekHash()
Returns an IsoWeekInfo hash representing the ISO-8601 calendar week information for the absolute date...
bool absolute()
Returns True if the date is an absolute date/time value.
int getEpochSeconds()
Returns the number of seconds since the start of the epoch (1970-01-01Z) for the current date for abs...
int minutes()
Returns an integer corresponding to the literal minute value in the date (does not calculate a durati...
int isoDayOfWeek()
Returns an integer representing the ISO-8601 day of the week for the absolute date value (1=Monday...
int durationSeconds()
Returns an integer value representing the the number of seconds of time duration in the date value (c...
main Qore-language namespace
Definition: Pseudo_QC_All.dox.h:3
int years()
Returns an integer corresponding to the literal year value in the date (does not calculate a duration...
int typeCode()
Returns Qore::NT_DATE.
int getEpochSecondsLocalTime()
Returns the number of seconds since the start of the epoch (1970-01-01) for the current date in the l...
int seconds()
Returns an integer corresponding to the literal second value in the date (does not calculate a durati...
float durationSecondsFloat()
Returns a floating-point value representing the the number of seconds of duration in the value of the...
int durationMicroseconds()
Returns an integer value representing the the number of microseconds of time duration in the date val...
int days()
Returns an integer corresponding to the literal day value in the date (does not calculate a duration)...