~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/field/date.cc

  • Committer: Monty Taylor
  • Date: 2010-02-04 08:14:46 UTC
  • mfrom: (1277.2.1 build) (1280.2.1 build)
  • mto: This revision was merged to the branch mainline in revision 1283.
  • Revision ID: mordred@inaugust.com-20100204081446-ldh9m486va30uap6
Put everything in drizzled into drizzled namespace.
Put internal stuff into drizzled::internal namespace.
Removed some cruft.
Now every symbol that is shipped in a header is in the drizzled namespace
and everything in the server that's not shipped is labeled internal. woot. 
Removed a lot of the extra extern "C" stuff that was in there. Less ugliness for
internal callbacks now for Sun Studio.

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
#include <sstream>
32
32
#include <string>
33
33
 
 
34
namespace drizzled
 
35
{
 
36
 
34
37
 
35
38
/****************************************************************************
36
39
** Drizzle date type stored in 3 bytes
97
100
   * and matches on datetime format strings can occur.
98
101
   */
99
102
  ASSERT_COLUMN_MARKED_FOR_WRITE;
100
 
  drizzled::DateTime temporal;
 
103
  DateTime temporal;
101
104
  if (! temporal.from_string(from, (size_t) len))
102
105
  {
103
106
    my_error(ER_INVALID_DATETIME_VALUE, MYF(ME_FATALERROR), from);
133
136
   * if unable to create a valid DateTime.  
134
137
   */
135
138
  ASSERT_COLUMN_MARKED_FOR_WRITE;
136
 
  drizzled::DateTime temporal;
 
139
  DateTime temporal;
137
140
  if (! temporal.from_int64_t(from))
138
141
  {
139
142
    /* Convert the integer to a string using stringstream */
275
278
{
276
279
  res.set_ascii(STRING_WITH_LEN("date"));
277
280
}
 
281
 
 
282
} /* namespace drizzled */