fmgrtab.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*-------------------------------------------------------------------------
  2. *
  3. * fmgrtab.h
  4. * The function manager's table of internal functions.
  5. *
  6. * Portions Copyright (c) 1996-2016, PostgreSQL Global Development Group
  7. * Portions Copyright (c) 1994, Regents of the University of California
  8. *
  9. * src/include/utils/fmgrtab.h
  10. *
  11. *-------------------------------------------------------------------------
  12. */
  13. #ifndef FMGRTAB_H
  14. #define FMGRTAB_H
  15. #include "fmgr.h"
  16. /*
  17. * This table stores info about all the built-in functions (ie, functions
  18. * that are compiled into the Postgres executable). The table entries are
  19. * required to appear in Oid order, so that binary search can be used.
  20. */
  21. typedef struct
  22. {
  23. Oid foid; /* OID of the function */
  24. const char *funcName; /* C name of the function */
  25. short nargs; /* 0..FUNC_MAX_ARGS, or -1 if variable count */
  26. bool strict; /* T if function is "strict" */
  27. bool retset; /* T if function returns a set */
  28. PGFunction func; /* pointer to compiled function */
  29. } FmgrBuiltin;
  30. extern const FmgrBuiltin fmgr_builtins[];
  31. extern const int fmgr_nbuiltins; /* number of entries in table */
  32. #endif /* FMGRTAB_H */