14887Schin 24887Schin /* : : generated by proto : : */ 34887Schin /*********************************************************************** 44887Schin * * 54887Schin * This software is part of the ast package * 6*12068SRoger.Faulkner@Oracle.COM * Copyright (c) 1985-2010 AT&T Intellectual Property * 74887Schin * and is licensed under the * 84887Schin * Common Public License, Version 1.0 * 98462SApril.Chin@Sun.COM * by AT&T Intellectual Property * 104887Schin * * 114887Schin * A copy of the License is available at * 124887Schin * http://www.opensource.org/licenses/cpl1.0.txt * 134887Schin * (with md5 checksum 059e8cd6165cb4c31e351f2b69388fd9) * 144887Schin * * 154887Schin * Information and Software Systems Research * 164887Schin * AT&T Research * 174887Schin * Florham Park NJ * 184887Schin * * 194887Schin * Glenn Fowler <gsf@research.att.com> * 204887Schin * David Korn <dgk@research.att.com> * 214887Schin * Phong Vo <kpv@research.att.com> * 224887Schin * * 234887Schin ***********************************************************************/ 244887Schin 254887Schin /* 264887Schin * AT&T Research 274887Schin * 284887Schin * sfio discipline interface definitions 294887Schin */ 304887Schin 314887Schin #ifndef _SFDISC_H 324887Schin #if !defined(__PROTO__) 334887Schin #include <prototyped.h> 344887Schin #endif 354887Schin #if !defined(__LINKAGE__) 364887Schin #define __LINKAGE__ /* 2004-08-11 transition */ 374887Schin #endif 384887Schin 394887Schin #define _SFDISC_H 404887Schin 414887Schin #include <ast.h> 424887Schin 434887Schin #define SFDCEVENT(a,b,n) ((((a)-'A'+1)<<11)^(((b)-'A'+1)<<6)^(n)) 444887Schin 454887Schin #if _BLD_ast && defined(__EXPORT__) 464887Schin #undef __MANGLE__ 474887Schin #define __MANGLE__ __LINKAGE__ __EXPORT__ 484887Schin #endif 494887Schin 504887Schin #define SFSK_DISCARD SFDCEVENT('S','K',1) 514887Schin 524887Schin /* 534887Schin * %(...) printf support 544887Schin */ 554887Schin 564887Schin typedef int (*Sf_key_lookup_t) __PROTO__((__V_*, Sffmt_t*, const char*, char**, Sflong_t*)); 574887Schin typedef char* (*Sf_key_convert_t) __PROTO__((__V_*, Sffmt_t*, const char*, char*, Sflong_t)); 584887Schin 594887Schin extern __MANGLE__ int sfkeyprintf __PROTO__((Sfio_t*, __V_*, const char*, Sf_key_lookup_t, Sf_key_convert_t)); 604887Schin #define sfkeyprintf sfkeyprintf_20000308 /* Sffmt_t* callback args */ 614887Schin extern __MANGLE__ int sfkeyprintf __PROTO__((Sfio_t*, __V_*, const char*, Sf_key_lookup_t, Sf_key_convert_t)); 624887Schin 634887Schin /* 644887Schin * pure sfio read and/or write disciplines 654887Schin */ 664887Schin 674887Schin extern __MANGLE__ int sfdcdio __PROTO__((Sfio_t*, size_t)); 684887Schin extern __MANGLE__ int sfdcdos __PROTO__((Sfio_t*)); 694887Schin extern __MANGLE__ int sfdcfilter __PROTO__((Sfio_t*, const char*)); 704887Schin extern __MANGLE__ int sfdcmore __PROTO__((Sfio_t*, const char*, int, int)); 714887Schin extern __MANGLE__ int sfdcprefix __PROTO__((Sfio_t*, const char*)); 724887Schin extern __MANGLE__ int sfdcseekable __PROTO__((Sfio_t*)); 734887Schin extern __MANGLE__ int sfdcslow __PROTO__((Sfio_t*)); 744887Schin extern __MANGLE__ int sfdctee __PROTO__((Sfio_t*, Sfio_t*)); 754887Schin extern __MANGLE__ int sfdcunion __PROTO__((Sfio_t*, Sfio_t**, int)); 764887Schin 774887Schin extern __MANGLE__ Sfio_t* sfdcsubstream __PROTO__((Sfio_t*, Sfio_t*, Sfoff_t, Sfoff_t)); 784887Schin 794887Schin #undef __MANGLE__ 804887Schin #define __MANGLE__ __LINKAGE__ 814887Schin 824887Schin #endif 83