~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/temporal.h

pandora-build v0.71. Added check for avahi.

Show diffs side-by-side

added added

removed removed

Lines of Context:
68
68
 
69
69
#include "drizzled/calendar.h"
70
70
 
71
 
#include <cassert>
72
71
#include <ostream>
73
72
 
74
73
/* Outside forward declarations */
285
284
 
286
285
 
287
286
  /**
 
287
   * Operator overload for adding/subtracting a TemporalInterval
 
288
   * instance to this temporal.
 
289
   *
 
290
   * @param TemporalInterval instance to add/subtract to/from
 
291
   */
 
292
  Date& operator+=(const TemporalIntervalYear &rhs);
 
293
  Date& operator+=(const TemporalIntervalDayOrLess &rhs);
 
294
  Date& operator+=(const TemporalIntervalDayOrWeek &rhs);
 
295
  Date& operator+=(const TemporalIntervalYearMonth &rhs);
 
296
  Date& operator-=(const TemporalIntervalYear &rhs);
 
297
  Date& operator-=(const TemporalIntervalDayOrLess &rhs);
 
298
  Date& operator-=(const TemporalIntervalDayOrWeek &rhs);
 
299
  Date& operator-=(const TemporalIntervalYearMonth &rhs);
 
300
 
 
301
 
 
302
  /**
288
303
   * Operator overload for when a DateTime instance is
289
304
   * assigned to a Date.  We do a copy of the DateTime's
290
305
   * date-related components.
313
328
   *
314
329
   * @param C-String to fill.
315
330
   * @param Length of to C-String
316
 
   * @returns length of string written (including trailing '\0').
 
331
   * @returns length of string written (not including trailing '\0').
317
332
   *          If output was truncated, returns length that would have
318
333
   *          been outputted.
319
334
   */
333
348
   * successful.
334
349
   *
335
350
   * @param String to convert from
336
 
   * @param Length of supplied string (not including trailing '\0').
 
351
   * @param Length of supplied string
337
352
   */
338
353
  virtual bool from_string(const char *from, size_t from_len);
339
354
 
456
471
public:
457
472
  Time() :Temporal() {}
458
473
  /* Maximum number of seconds in 23:59:59 (24 * 60 * 60) */
459
 
  static const uint32_t MAX_CUMULATIVE_SECONDS= 86400L;
 
474
  const static uint32_t MAX_CUMULATIVE_SECONDS= 86400L;
460
475
 
461
476
  /**
462
477
   * Comparison operator overloads to compare a Time against