Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
AG_CORE(3)	       FreeBSD Library Functions Manual		    AG_CORE(3)

NAME
     AG_Core --	agar core library initialization

SYNOPSIS
     #include <agar/core.h>

DESCRIPTION
     The Agar AG_Core library implements the base Agar object system along
     with portable interfaces to operating system services (e.g., filesystems,
     network, threads).	 Even though the Agar-GUI library is built on top of
     it, AG_Core is an independent, general utility library containing no GUI-
     related code.

     For a complete listing of available subsystems and	interfaces, see	the
     "AGAR-CORE" section of the	AG_Intro(3) manual page, or the	SEE ALSO sec-
     tion below.

INITIALIZATION
     int AG_InitCore(const char	*progname, Uint	flags)

     void AG_AtExitFunc(void (*fn)(void))

     void AG_Quit(void)

     void AG_Destroy(void)

     The AG_InitCore() function	initializes the	AG_Core	library.  The optional
     progname argument sets an application name	(this name may be used by
     ag_gui and	AG_Core	to set various platform-dependent defaults).  progname
     may be set	to NULL.

     Available flags options include:

     AG_VERBOSE		 Allow errors/warnings on the standard error output.

     AG_CREATE_DATADIR	 Create	a data directory for the application.  The ex-
			 act location of the directory is platform-dependent
			 (and may depend on progname).	On Unix-like plat-
			 forms,	the default would be ~/._progname_.

     AG_SOFT_TIMERS	 Disable use of	hardware timers.  Indicate that	the
			 application will be updating the software-based tim-
			 ing wheel using AG_ProcessTimeouts(3).

     The AG_AtExitFunc() registers a function that will	be invoked automati-
     cally by AG_Destroy().

     AG_Quit() terminates the application by releasing resources allocated by
     AG_Core and invoking exit(2).

     The AG_Destroy() function releases	all resources allocated	by the AG_Core
     library.

AGAR VERSION INFORMATION
     void AG_GetVersion(AG_AgarVersion *ver)

     bool AG_VERSION_ATLEAST(int major,	int minor, int patchlevel)

     The AG_GetVersion() function fills	an AG_AgarVersion structure with ver-
     sion information:

     typedef struct ag_agar_version {
	     int major;
	     int minor;
	     int patch;
	     const char	*release;
     } AG_AgarVersion;

     Agar does not need	to have	been previously	initialized for
     AG_GetVersion() to	work.

     The AG_VERSION_ATLEAST() macro evaluates to true if the current Agar ver-
     sion is equal to, or exceeds the given version number.

SEE ALSO
     AG_Config(3), AG_DataSource(3), AG_Db(3), AG_DSO(3), AG_Error(3),
     AG_Event(3), AG_EventLoop(3), AG_Execute(3), AG_File(3), AG_Intro(3),
     AG_Limits(3), AG_Net(3), AG_Object(3), AG_String(3), AG_TextElement(3),
     AG_Threads(3), AG_Time(3),	AG_Timer(3), AG_User(3), AG_Variable(3),
     AG_Version(3)

HISTORY
     The AG_InitCore() function	first appeared in Agar 1.0.

FreeBSD	13.0		       NOVEMBER	26, 2001		  FreeBSD 13.0

NAME | SYNOPSIS | DESCRIPTION | INITIALIZATION | AGAR VERSION INFORMATION | SEE ALSO | HISTORY

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=AG_Core&sektion=3&manpath=FreeBSD+12.2-RELEASE+and+Ports>

home | help