view src/client.h @ 54:125d79c9e586 noffle

[svn] * src/client.c, src/configfile.c, src/content.c, src/control.c, src/database.c, src/dynamicstring.c, src/fetch.c, src/fetchlist.c, src/group.c, src/itemlist.c, src/lock.c, src/log.c, src/noffle.c, src/online.c, src/outgoing.c, src/over.c, src/post.c, src/protocol.c, src/pseudo.c, src/request.c, src/server.c, src/util.c: Added portable.h #include. * src/client.h, src/database.h, src/fetch.c, src/group.h, src/lock.c, src/outgoing.c, src/over.c, src/over.h, src/pseudo.c, src/server.c, src/util.c, src/util.h: Added some #ifdefs to correctly include either time.h or sys/time.h or both, depending on which are found. * src/noffle.c: Changed the return-type of the signal-handlers bugReport() and logSignal() to RETSIGTYPE, which is either void or int, depending on the system you compile on (autoconf #defines the RETSIGTYPE).
author uh1763
date Tue, 09 May 2000 23:28:38 +0100
parents 32ba1198c6fa
children 05f50c1761d9
line wrap: on
line source

/*
  client.h

  Noffle acting as client to other NNTP-servers

  $Id: client.h 60 2000-05-09 22:28:38Z uh1763 $
*/

#ifndef CLIENT_H
#define CLIENT_H

#if HAVE_CONFIG_H
#include <config.h>
#endif

#if TIME_WITH_SYS_TIME
#include <sys/time.h>
#include <time.h>
#else
#if HAVE_SYS_TIME_H
#include <sys/time.h>
#else
#include <time.h>
#endif
#endif

#include "common.h"
#include "database.h"
#include "fetchlist.h"

/* Format of server name: <host>[:<port>] */
Bool
Client_connect( const char *serv );

void
Client_disconnect( void );

Bool
Client_getGrps( void );

Bool
Client_getDsc( void );

Bool
Client_getCreationTimes( void );

Bool
Client_getNewgrps( const time_t *lastTime );

/*
  Change to group <name> at server if it is also in current local grouplist.
  Returns TRUE at success.
*/
Bool
Client_changeToGrp( const Str name );

/*
  Get overviews <rmtFirst> - <rmtLast> from server and append it
  to the current content. For articles that are to be fetched due to FULL
  or THREAD mode, store IDs in request database.
*/
Bool
Client_getOver( int rmtFirst, int rmtLast, FetchMode mode );

/*
  Retrieve full article text and store it into database.
*/
void
Client_retrieveArt( const char *msgId );

/*
  Same, but for a list of msgId's (new line after each msgId).
  All ARTICLE commands are sent and then all answers read.
*/
void
Client_retrieveArtList( const char *list );

/*
  Store IDs of first and last article of group selected by
  Client_changeToGroup at remote server. 
*/
void
Client_rmtFirstLast( int *first, int *last );

Bool
Client_postArt( const char *msgId, const char *artTxt, Str errStr );

#endif