ExtDateTime.h File Reference

Go to the source code of this file.

Functions

FENNEL_BEGIN_NAMESPACE void ExtDateTimeRegister (ExtendedInstructionTable *eit)
 Registers extended instructions relating to date, time, and timestamp values.


Function Documentation

FENNEL_BEGIN_NAMESPACE void ExtDateTimeRegister ( ExtendedInstructionTable eit  ) 

Registers extended instructions relating to date, time, and timestamp values.

Definition at line 259 of file ExtDateTime.cpp.

References ExtendedInstructionTable::add(), CastDateTimeToInt64(), CastDateToStrA(), CastStrAToDate(), CastStrAToTime(), CastStrAToTimestamp(), CastTimestampToStrA(), CastTimeToStrA(), CurrentTime(), CurrentTimestamp(), LocalTime(), LocalTimestamp(), STANDARD_TYPE_CHAR, STANDARD_TYPE_INT_32, STANDARD_TYPE_INT_64, and STANDARD_TYPE_VARCHAR.

Referenced by CalcInit::instance().

00260 {
00261     assert(eit != NULL);
00262 
00263     vector<StandardTypeDescriptorOrdinal> params_V_I64;
00264     params_V_I64.push_back(STANDARD_TYPE_VARCHAR);
00265     params_V_I64.push_back(STANDARD_TYPE_INT_64);
00266 
00267     vector<StandardTypeDescriptorOrdinal> params_C_I64;
00268     params_C_I64.push_back(STANDARD_TYPE_CHAR);
00269     params_C_I64.push_back(STANDARD_TYPE_INT_64);
00270 
00271     vector<StandardTypeDescriptorOrdinal> params_I64_V;
00272     params_I64_V.push_back(STANDARD_TYPE_INT_64);
00273     params_I64_V.push_back(STANDARD_TYPE_VARCHAR);
00274 
00275     vector<StandardTypeDescriptorOrdinal> params_I64_C;
00276     params_I64_C.push_back(STANDARD_TYPE_INT_64);
00277     params_I64_C.push_back(STANDARD_TYPE_CHAR);
00278 
00279     vector<StandardTypeDescriptorOrdinal> params_I64_C_I32;
00280     params_I64_C_I32.push_back(STANDARD_TYPE_INT_64);
00281     params_I64_C_I32.push_back(STANDARD_TYPE_CHAR);
00282     params_I64_C_I32.push_back(STANDARD_TYPE_INT_32);
00283 
00284     vector<StandardTypeDescriptorOrdinal> params_I64_I64;
00285     params_I64_I64.push_back(STANDARD_TYPE_INT_64);
00286     params_I64_I64.push_back(STANDARD_TYPE_INT_64);
00287 
00288     vector<StandardTypeDescriptorOrdinal> params_I64;
00289     params_I64.push_back(STANDARD_TYPE_INT_64);
00290 
00291     vector<StandardTypeDescriptorOrdinal> params_I64_I32;
00292     params_I64_I32.push_back(STANDARD_TYPE_INT_64);
00293     params_I64_I32.push_back(STANDARD_TYPE_INT_32);
00294 
00295     // date -> str
00296     eit->add(
00297         "CastDateToStrA", params_V_I64,
00298         (ExtendedInstruction2<char*, int64_t>*) NULL,
00299         &CastDateToStrA);
00300 
00301     eit->add(
00302         "CastDateToStrA", params_C_I64,
00303         (ExtendedInstruction2<char*, int64_t>*) NULL,
00304         &CastDateToStrA);
00305 
00306     eit->add(
00307         "CastTimeToStrA", params_V_I64,
00308         (ExtendedInstruction2<char*, int64_t>*) NULL,
00309         &CastTimeToStrA);
00310 
00311     eit->add(
00312         "CastTimeToStrA", params_C_I64,
00313         (ExtendedInstruction2<char*, int64_t>*) NULL,
00314         &CastTimeToStrA);
00315 
00316     eit->add(
00317         "CastTimestampToStrA", params_V_I64,
00318         (ExtendedInstruction2<char*, int64_t>*) NULL,
00319         &CastTimestampToStrA);
00320 
00321     eit->add(
00322         "CastTimestampToStrA", params_C_I64,
00323         (ExtendedInstruction2<char*, int64_t>*) NULL,
00324         &CastTimestampToStrA);
00325 
00326     // str -> date
00327     eit->add(
00328         "CastStrAToDate", params_I64_V,
00329         (ExtendedInstruction2<int64_t, char*>*) NULL,
00330         &CastStrAToDate);
00331 
00332     eit->add(
00333         "CastStrAToDate", params_I64_C,
00334         (ExtendedInstruction2<int64_t, char*>*) NULL,
00335         &CastStrAToDate);
00336 
00337     eit->add(
00338         "CastStrAToTime", params_I64_V,
00339         (ExtendedInstruction2<int64_t, char*>*) NULL,
00340         &CastStrAToTime);
00341 
00342     eit->add(
00343         "CastStrAToTime", params_I64_C,
00344         (ExtendedInstruction2<int64_t, char*>*) NULL,
00345         &CastStrAToTime);
00346 
00347     eit->add(
00348         "CastStrAToTimestamp", params_I64_V,
00349         (ExtendedInstruction2<int64_t, char*>*) NULL,
00350         &CastStrAToTimestamp);
00351 
00352     eit->add(
00353         "CastStrAToTimestamp", params_I64_C,
00354         (ExtendedInstruction2<int64_t, char*>*) NULL,
00355         &CastStrAToTimestamp);
00356 
00357     // others
00358     eit->add(
00359         "CastDateTimeToInt64", params_I64_I64,
00360         (ExtendedInstruction2<int64_t, int64_t>*) NULL,
00361         &CastDateTimeToInt64);
00362 
00363     eit->add(
00364         "LocalTime2", params_I64_C,
00365         (ExtendedInstruction2<int64_t, char *>*) NULL,
00366         &LocalTime);
00367 
00368     eit->add(
00369         "LocalTimestamp2", params_I64_C,
00370         (ExtendedInstruction2<int64_t, char *>*) NULL,
00371         &LocalTimestamp);
00372 
00373     eit->add(
00374         "LocalTime3", params_I64_C_I32,
00375         (ExtendedInstruction3<int64_t, char *, int32_t>*) NULL,
00376         &LocalTime);
00377 
00378     eit->add(
00379         "LocalTimestamp3", params_I64_C_I32,
00380         (ExtendedInstruction3<int64_t, char *, int32_t>*) NULL,
00381         &LocalTimestamp);
00382 
00383     eit->add(
00384         "CurrentTime1", params_I64,
00385         (ExtendedInstruction1<int64_t>*) NULL,
00386         &CurrentTime);
00387 
00388     eit->add(
00389         "CurrentTimestamp1", params_I64,
00390         (ExtendedInstruction1<int64_t>*) NULL,
00391         &CurrentTimestamp);
00392 
00393     eit->add(
00394         "CurrentTime2", params_I64_I32,
00395         (ExtendedInstruction2<int64_t, int32_t>*) NULL,
00396         &CurrentTime);
00397 
00398     eit->add(
00399         "CurrentTimestamp2", params_I64_I32,
00400         (ExtendedInstruction2<int64_t, int32_t>*) NULL,
00401         &CurrentTimestamp);
00402 
00403 }


Generated on Mon Jun 22 04:00:21 2009 for Fennel by  doxygen 1.5.1