~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/field.cc

  • Committer: Jay Pipes
  • Date: 2009-06-11 05:12:48 UTC
  • mto: This revision was merged to the branch mainline in revision 1061.
  • Revision ID: jpipes@serialcoder-20090611051248-9nhakgtbg95ey6st
More documentation cleanup for Field class

Show diffs side-by-side

added added

removed removed

Lines of Context:
430
430
  STRING_RESULT,
431
431
};
432
432
 
433
 
 
434
 
/*
435
 
  Test if the given string contains important data:
436
 
  not spaces for character string,
437
 
  or any data for binary string.
438
 
 
439
 
  SYNOPSIS
440
 
    test_if_important_data()
441
 
    cs          Character set
442
 
    str         String to test
443
 
    strend      String end
444
 
 
445
 
  RETURN
446
 
    false - If string does not have important data
447
 
    true  - If string has some important data
448
 
*/
449
 
 
450
 
bool
451
 
test_if_important_data(const CHARSET_INFO * const cs, const char *str,
452
 
                       const char *strend)
 
433
bool test_if_important_data(const CHARSET_INFO * const cs, 
 
434
                            const char *str,
 
435
                            const char *strend)
453
436
{
454
437
  if (cs != &my_charset_bin)
455
438
    str+= cs->cset->scan(cs, str, strend, MY_SEQ_SPACES);
456
439
  return (str < strend);
457
440
}
458
441
 
459
 
 
460
442
Item_result Field::result_merge_type(enum_field_types field_type)
461
443
{
462
444
  assert(field_type <= DRIZZLE_TYPE_MAX);
642
624
  return null_ptr != 0;
643
625
}
644
626
 
645
 
/*****************************************************************************
646
 
  Static help functions
647
 
*****************************************************************************/
648
 
 
649
627
bool Field::type_can_have_key_part(enum enum_field_types type)
650
628
{
651
629
  switch (type) {
996
974
  return 1;
997
975
}
998
976
 
999
 
/**
1000
 
  @return
1001
 
  returns 1 if the fields are equally defined
1002
 
*/
1003
977
bool Field_enum::eq_def(Field *field)
1004
978
{
1005
979
  if (!Field::eq_def(field))