home *** CD-ROM | disk | FTP | other *** search
/ vsiftp.vmssoftware.com / VSIPUBLIC@vsiftp.vmssoftware.com.tar / FREEWARE / FREEWARE40.ZIP / pine / c-client / news.h < prev    next >
C/C++ Source or Header  |  1994-01-09  |  4KB  |  135 lines

  1. /*
  2.  * Program:    Netnews mail routines
  3.  *
  4.  * Author:    Mark Crispin
  5.  *        Networks and Distributed Computing
  6.  *        Computing & Communications
  7.  *        University of Washington
  8.  *        Administration Building, AG-44
  9.  *        Seattle, WA  98195
  10.  *        Internet: MRC@CAC.Washington.EDU
  11.  *
  12.  * Date:    4 September 1991
  13.  * Last Edited:    19 November 1992
  14.  *
  15.  * Copyright 1992 by the University of Washington
  16.  *
  17.  *  Permission to use, copy, modify, and distribute this software and its
  18.  * documentation for any purpose and without fee is hereby granted, provided
  19.  * that the above copyright notice appears in all copies and that both the
  20.  * above copyright notice and this permission notice appear in supporting
  21.  * documentation, and that the name of the University of Washington not be
  22.  * used in advertising or publicity pertaining to distribution of the software
  23.  * without specific, written prior permission.  This software is made
  24.  * available "as is", and
  25.  * THE UNIVERSITY OF WASHINGTON DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED,
  26.  * WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT LIMITATION ALL IMPLIED
  27.  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, AND IN
  28.  * NO EVENT SHALL THE UNIVERSITY OF WASHINGTON BE LIABLE FOR ANY SPECIAL,
  29.  * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
  30.  * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, TORT
  31.  * (INCLUDING NEGLIGENCE) OR STRICT LIABILITY, ARISING OUT OF OR IN CONNECTION
  32.  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  33.  *
  34.  */
  35.  
  36. /* Command bits from news_getflags() */
  37.  
  38. #define fSEEN 1
  39. #define fDELETED 2
  40. #define fFLAGGED 4
  41. #define fANSWERED 8
  42.  
  43.  
  44. /* NEWS I/O stream local data */
  45.  
  46. typedef struct news_local {
  47.   unsigned int dirty : 1;    /* disk copy of .newsrc needs updating */
  48.   char *dir;            /* spool directory name */
  49.   char *name;            /* local mailbox name */
  50.   char *buf;            /* temporary buffer */
  51.   unsigned long buflen;        /* current size of temporary buffer */
  52.   unsigned long *number;    /* news message numbers */
  53.   char **header;        /* message headers */
  54.   char **body;            /* message bodies */
  55.   char *seen;            /* local seen status */
  56. } NEWSLOCAL;
  57.  
  58.  
  59. /* Convenient access to local data */
  60.  
  61. #define LOCAL ((NEWSLOCAL *) stream->local)
  62.  
  63. /* Function prototypes */
  64.  
  65. DRIVER *news_valid  ();
  66. void *news_parameters  ();
  67. void news_find  ();
  68. void news_find_bboards  ();
  69. void news_find_all  ();
  70. void news_find_all_bboards  ();
  71. long news_subscribe  ();
  72. long news_unsubscribe  ();
  73. long news_subscribe_bboard  ();
  74. long news_unsubscribe_bboard  ();
  75. long news_create  ();
  76. long news_delete  ();
  77. long news_rename  ();
  78. MAILSTREAM *news_open  ();
  79. int news_select  ();
  80. int news_numsort  ();
  81. void news_close  ();
  82. void news_fetchfast  ();
  83. void news_fetchflags  ();
  84. ENVELOPE *news_fetchstructure  ();
  85. char *news_fetchheader  ();
  86. char *news_fetchtext  ();
  87. char *news_fetchbody  ();
  88. void news_setflag  ();
  89. void news_clearflag  ();
  90. void news_search  ();
  91. long news_ping  ();
  92. void news_check  ();
  93. void news_expunge  ();
  94. long news_copy  ();
  95. long news_move  ();
  96. long news_append  ();
  97. void news_gc  ();
  98. char *news_read  ();
  99. short news_getflags  ();
  100. char news_search_all  ();
  101. char news_search_answered  ();
  102. char news_search_deleted  ();
  103. char news_search_flagged  ();
  104. char news_search_keyword  ();
  105. char news_search_new  ();
  106. char news_search_old  ();
  107. char news_search_recent  ();
  108. char news_search_seen  ();
  109. char news_search_unanswered  ();
  110. char news_search_undeleted  ();
  111. char news_search_unflagged  ();
  112. char news_search_unkeyword  ();
  113. char news_search_unseen  ();
  114. char news_search_before  ();
  115. char news_search_on  ();
  116. char news_search_since  ();
  117. unsigned long news_msgdate  ();
  118. char news_search_body  ();
  119. char news_search_subject  ();
  120. char news_search_text  ();
  121. char news_search_bcc  ();
  122. char news_search_cc  ();
  123. char news_search_from  ();
  124. char news_search_to  ();
  125. typedef char (*search_t)  ();
  126. search_t news_search_date  ();
  127. search_t news_search_flag  ();
  128. search_t news_search_string  ();
  129.  
  130. /* This is embarassing */
  131.  
  132. extern char *bezerk_file  ();
  133. extern int bezerk_lock  ();
  134. extern void bezerk_unlock  ();
  135.