/***********************************************************************1* *2* This software is part of the ast package *3* Copyright (c) 1998-2011 AT&T Intellectual Property *4* and is licensed under the *5* Eclipse Public License, Version 1.0 *6* by AT&T Intellectual Property *7* *8* A copy of the License is available at *9* http://www.eclipse.org/org/documents/epl-v10.html *10* (with md5 checksum b35adb5213ca9657e911e9befb180842) *11* *12* Information and Software Systems Research *13* AT&T Research *14* Florham Park NJ *15* *16* Glenn Fowler <[email protected]> *17* *18***********************************************************************/19#pragma prototyped20/*21* uu encode/decode interface definitions22*23* AT&T Research24*/2526#ifndef _UU_H27#define _UU_H2829#include <ast.h>3031#define UU_VERSION 19980611L3233#define UU_HEADER (1<<0) /* header/trailer encoded too */34#define UU_TEXT (1<<1) /* process text file */35#define UU_LOCAL (1<<2) /* embedded paths in . */3637struct Uu_s; typedef struct Uu_s Uu_t;38struct Uudisc_s; typedef struct Uudisc_s Uudisc_t;39struct Uumeth_s; typedef struct Uumeth_s Uumeth_t;4041typedef int (*Uu_f)(Uu_t*);4243struct Uumeth_s44{45const char* name;46const char* alias;47const char* id;48Uu_f headerf;49Uu_f encodef;50Uu_f decodef;51void* data;52};5354struct Uudisc_s55{56unsigned long version;57unsigned long flags;58Error_f errorf;59};6061struct Uu_s62{63const char* id;64Uumeth_t meth;65Uudisc_t* disc;66char* path;6768#ifdef _UU_PRIVATE_69_UU_PRIVATE_70#endif7172};7374#if _BLD_uu && defined(__EXPORT__)75#define extern __EXPORT__76#endif7778extern Uu_t* uuopen(Uudisc_t*, Uumeth_t*);79extern int uuclose(Uu_t*);8081extern ssize_t uuencode(Uu_t*, Sfio_t*, Sfio_t*, size_t, const char*);82extern ssize_t uudecode(Uu_t*, Sfio_t*, Sfio_t*, size_t, const char*);8384extern int uumain(char**, int);8586extern int uulist(Sfio_t*);87extern Uumeth_t* uumeth(const char*);8889#undef extern9091#endif929394