dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / usr / src / lib / libast / common / include / sfdisc.h
blob9c9c222914f31c63f8442ac2f8be3bcb49d65c0e
1 /***********************************************************************
2 * *
3 * This software is part of the ast package *
4 * Copyright (c) 1985-2010 AT&T Intellectual Property *
5 * and is licensed under the *
6 * Common Public License, Version 1.0 *
7 * by AT&T Intellectual Property *
8 * *
9 * A copy of the License is available at *
10 * http://www.opensource.org/licenses/cpl1.0.txt *
11 * (with md5 checksum 059e8cd6165cb4c31e351f2b69388fd9) *
12 * *
13 * Information and Software Systems Research *
14 * AT&T Research *
15 * Florham Park NJ *
16 * *
17 * Glenn Fowler <gsf@research.att.com> *
18 * David Korn <dgk@research.att.com> *
19 * Phong Vo <kpv@research.att.com> *
20 * *
21 ***********************************************************************/
22 #pragma prototyped
24 * AT&T Research
26 * sfio discipline interface definitions
29 #ifndef _SFDISC_H
30 #define _SFDISC_H
32 #include <ast.h>
34 #define SFDCEVENT(a,b,n) ((((a)-'A'+1)<<11)^(((b)-'A'+1)<<6)^(n))
36 #if _BLD_ast && defined(__EXPORT__)
37 #define extern __EXPORT__
38 #endif
40 #define SFSK_DISCARD SFDCEVENT('S','K',1)
43 * %(...) printf support
46 typedef int (*Sf_key_lookup_t)(void*, Sffmt_t*, const char*, char**, Sflong_t*);
47 typedef char* (*Sf_key_convert_t)(void*, Sffmt_t*, const char*, char*, Sflong_t);
49 extern int sfkeyprintf(Sfio_t*, void*, const char*, Sf_key_lookup_t, Sf_key_convert_t);
50 #define sfkeyprintf sfkeyprintf_20000308 /* Sffmt_t* callback args */
51 extern int sfkeyprintf(Sfio_t*, void*, const char*, Sf_key_lookup_t, Sf_key_convert_t);
54 * pure sfio read and/or write disciplines
57 extern int sfdcdio(Sfio_t*, size_t);
58 extern int sfdcdos(Sfio_t*);
59 extern int sfdcfilter(Sfio_t*, const char*);
60 extern int sfdcmore(Sfio_t*, const char*, int, int);
61 extern int sfdcprefix(Sfio_t*, const char*);
62 extern int sfdcseekable(Sfio_t*);
63 extern int sfdcslow(Sfio_t*);
64 extern int sfdctee(Sfio_t*, Sfio_t*);
65 extern int sfdcunion(Sfio_t*, Sfio_t**, int);
67 extern Sfio_t* sfdcsubstream(Sfio_t*, Sfio_t*, Sfoff_t, Sfoff_t);
69 #undef extern
71 #endif