Renable threading build for Solaris 2.5, per report from Andrew Chernow
[PostgreSQL.git] / contrib / isn / isn.h
blobae92896e0ec2216c6e1d0c43f1c5a7c14a1f7f74
1 /*-------------------------------------------------------------------------
3 * isn.h
4 * PostgreSQL type definitions for ISNs (ISBN, ISMN, ISSN, EAN13, UPC)
6 * Copyright (c) 2004-2006, Germán Méndez Bravo (Kronuz)
7 * Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
9 * IDENTIFICATION
10 * $PostgreSQL$
12 *-------------------------------------------------------------------------
15 #ifndef ISN_H
16 #define ISN_H
18 #include "fmgr.h"
20 #undef ISN_DEBUG
21 #define ISN_WEAK_MODE
24 * uint64 is the internal storage format for ISNs.
26 typedef uint64 ean13;
28 #define EAN13_FORMAT UINT64_FORMAT
30 #define PG_GETARG_EAN13(n) PG_GETARG_INT64(n)
31 #define PG_RETURN_EAN13(x) PG_RETURN_INT64(x)
33 extern Datum isn_out(PG_FUNCTION_ARGS);
34 extern Datum ean13_out(PG_FUNCTION_ARGS);
35 extern Datum ean13_in(PG_FUNCTION_ARGS);
36 extern Datum isbn_in(PG_FUNCTION_ARGS);
37 extern Datum ismn_in(PG_FUNCTION_ARGS);
38 extern Datum issn_in(PG_FUNCTION_ARGS);
39 extern Datum upc_in(PG_FUNCTION_ARGS);
41 extern Datum isbn_cast_from_ean13(PG_FUNCTION_ARGS);
42 extern Datum ismn_cast_from_ean13(PG_FUNCTION_ARGS);
43 extern Datum issn_cast_from_ean13(PG_FUNCTION_ARGS);
44 extern Datum upc_cast_from_ean13(PG_FUNCTION_ARGS);
46 extern Datum is_valid(PG_FUNCTION_ARGS);
47 extern Datum make_valid(PG_FUNCTION_ARGS);
49 extern Datum accept_weak_input(PG_FUNCTION_ARGS);
50 extern Datum weak_input_status(PG_FUNCTION_ARGS);
52 extern void initialize(void);
54 #endif /* ISN_H */