| 475 | /************************************************************************/ |
| 476 | |
| 477 | int DBFIsValueNULL( const char* pszValue, char type ) |
| 478 | |
| 479 | { |
| 480 | switch(type) |
| 481 | { |
| 482 | case 'N': |
| 483 | case 'F': |
| 484 | /* NULL numeric fields have value "****************" */ |
| 485 | return pszValue[0] == '*'; |
| 486 | |
| 487 | case 'D': |
| 488 | /* NULL date fields have value "00000000" */ |
| 489 | return strncmp(pszValue,"00000000",8) == 0; |
| 490 | |
| 491 | case 'L': |
| 492 | /* NULL boolean fields have value "?" */ |
| 493 | return pszValue[0] == '?'; |
| 494 | |
| 495 | default: |
| 496 | /* empty string fields are considered NULL */ |
| 497 | return strlen(pszValue) == 0; |
| 498 | } |
| 499 | } |
| 500 | |
| 501 | /************************************************************************/ |
| 502 | /* msDBFReadAttribute() */ |
no outgoing calls
no test coverage detected