| iMatix home page
| << | < | > | >>
SFL Logo SFL
Version 2.11

 

sym_get_boolean

#include "sflsymb.h"
Bool
sym_get_boolean (
    const SYMTAB *table,                /*  Symbol table to process          */
    const char *name,                   /*  Name of symbol to look for       */
    const Bool default_value)           /*  Value to return if not defined   */

Synopsis

Returns value for specified symbol, as TRUE or FALSE. If the symbol is not defined in the table, returns a default value.

Examples

    value = sym_get_boolean (env, "CONNECTS_ENABLED", TRUE);

Source Code - (sflsymb.c)

{
    char
        *value;

    value = sym get value (table, name, NULL);
    return (value? (conv str bool (value) != 0): default_value);
}

| << | < | > | >> iMatix Copyright © 1996-2000 iMatix Corporation