Platon Technologies
not logged in Login Registration
EnglishSlovak
open source software development celebrating 10 years of open source development! Wednesday, October 14, 2026
About Us
Magazine
Open Source
CVS
Services
Index  »  Projects  »  libcfg+  »  Documentation  »  Man  »  cfg_set_context_flag (3)

libcfg+/man/cfg_set_context_flag.3.html

CFG_SET_CONTEXT_FLAG(3)                          libcfg+ 0.6.2                         CFG_SET_CONTEXT_FLAG(3)

NAME
       cfg_set_context_flag, cfg_clear_context_flag, cfg_get_context_flag, cfg_set_context_flags, cfg_get_con‐
       text_flags - libcfg+ context flags manipulation functions

SYNOPSIS
       The following functions can be used to set various context flags:

       #include <cfg+.h>

       void cfg_set_context_flag (const CFG_CONTEXT con, int flag);

       void cfg_clear_context_flag (const CFG_CONTEXT con, int flag);

       int cfg_get_context_flag (const CFG_CONTEXT con, int flag);

       void cfg_set_context_flags (const CFG_CONTEXT con, int flags);

       int cfg_get_context_flags (const CFG_CONTEXT con, int flags);

DESCRIPTION
       You can set a context flag with cfg_set_context_flag().  You  can  clear  a  flag  with  cfg_clear_con‐
       text_flag(). To see whether a flag is set, use cfg_get_context_flag(). It has a macro alias cfg_is_con‐
       text_flag(), which is identical in every way.

       The functions cfg_set_context_flags() and cfg_get_context_flags() can set and retrieve the value of all
       flags in one call.

       A list of all settable context flags is provided in the following table.

       "CONTEXT FLAGS"

       CFG_IGNORE_MULTI
              Ignore  multiple  arguments  for  a  single option. The first argument will be used to store the
              option value. The others are skipped.

              By  default,  multiple  arguments  for  an  option  that  has  not  allowed  them,   cause   the
              CFG_ERROR_MULTI error.

       CFG_IGNORE_UNKNOWN
              Ignore all unknown options.

              The  default  behaviour  is  to  produce  the  CFG_ERROR_UNKNOWN error when an unknown option is
              encountered.

       CFG_SKIP_FIRST
              Setting this flag will cause the first argument on the command line to  be  skipped.  This  flag
              affects only command line contexts.

              The default behaviour is to parse all command line arguments.

       CFG_ADVANCED_LEFTOVERS
              Advanced  leftover  arguments. Setting this flag will drop the requirement of the leftover argu‐
              ments to conform to the POSIX standard.

              The default behaviour is to require the leftover arguments to conform  to  POSIX.  According  to
              POSIX, all option arguments must precede any non-option (leftover) arguments.  Once a non-option
              argument is found, all remaining arguments are also interpreted as non-option.

       CFG_FILE_LINE_POS_USAGE
              Setting this flag will cause the parsing of configuration file to become line- instead of  byte-
              oriented. This will also change the meaning of the values stored in begin_pos and size.

              By default, parsing is byte-oriented.

       You can use the cfg_clear_context_flag() function to restore the value of a flag to its default value.

SEE ALSO
       You  can  get  library  overview,  table  of  contents  and  such additional information info from main
       libcfg+(3) manpage by typing "man libcfg+" on UNIX-based systems. Also use this command to get informa‐
       tion about authors, homepage and license conditions.

libcfg+ 0.6.2                                  17 February 2004                        CFG_SET_CONTEXT_FLAG(3)

Copyright © 2002-2006 Platon Group
Site powered by Metafox CMS
Go to Top · Feedback form · Application form
Report bug on PLATON.SK website · Terms of use · Privacy policy