pg_event_trigger.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /*-------------------------------------------------------------------------
  2. *
  3. * pg_event_trigger.h
  4. * definition of the "event trigger" system catalog (pg_event_trigger)
  5. *
  6. *
  7. * Portions Copyright (c) 1996-2022, PostgreSQL Global Development Group
  8. * Portions Copyright (c) 1994, Regents of the University of California
  9. *
  10. * src/include/catalog/pg_event_trigger.h
  11. *
  12. * NOTES
  13. * The Catalog.pm module reads this file and derives schema
  14. * information.
  15. *
  16. *-------------------------------------------------------------------------
  17. */
  18. #ifndef PG_EVENT_TRIGGER_H
  19. #define PG_EVENT_TRIGGER_H
  20. #include "catalog/genbki.h"
  21. #include "catalog/pg_event_trigger_d.h"
  22. /* ----------------
  23. * pg_event_trigger definition. cpp turns this into
  24. * typedef struct FormData_pg_event_trigger
  25. * ----------------
  26. */
  27. CATALOG(pg_event_trigger,3466,EventTriggerRelationId)
  28. {
  29. Oid oid; /* oid */
  30. NameData evtname; /* trigger's name */
  31. NameData evtevent; /* trigger's event */
  32. Oid evtowner BKI_LOOKUP(pg_authid); /* trigger's owner */
  33. Oid evtfoid BKI_LOOKUP(pg_proc); /* OID of function to be
  34. * called */
  35. char evtenabled; /* trigger's firing configuration WRT
  36. * session_replication_role */
  37. #ifdef CATALOG_VARLEN
  38. text evttags[1]; /* command TAGs this event trigger targets */
  39. #endif
  40. } FormData_pg_event_trigger;
  41. /* ----------------
  42. * Form_pg_event_trigger corresponds to a pointer to a tuple with
  43. * the format of pg_event_trigger relation.
  44. * ----------------
  45. */
  46. typedef FormData_pg_event_trigger *Form_pg_event_trigger;
  47. DECLARE_TOAST(pg_event_trigger, 4145, 4146);
  48. DECLARE_UNIQUE_INDEX(pg_event_trigger_evtname_index, 3467, EventTriggerNameIndexId, on pg_event_trigger using btree(evtname name_ops));
  49. DECLARE_UNIQUE_INDEX_PKEY(pg_event_trigger_oid_index, 3468, EventTriggerOidIndexId, on pg_event_trigger using btree(oid oid_ops));
  50. #endif /* PG_EVENT_TRIGGER_H */