From 3b5421b4c75f5c85b48cbb61bf22642ff52a6352 Mon Sep 17 00:00:00 2001 From: Arch Librarian Date: Mon, 20 Sep 2004 16:51:06 +0000 Subject: Start on acquire stuff Author: jgg Date: 1998-10-20 02:39:12 GMT Start on acquire stuff --- apt-pkg/acquire-worker.h | 36 ++++++++++++++++++++++++++++++------ 1 file changed, 30 insertions(+), 6 deletions(-) (limited to 'apt-pkg/acquire-worker.h') diff --git a/apt-pkg/acquire-worker.h b/apt-pkg/acquire-worker.h index f01c935ae..28072373f 100644 --- a/apt-pkg/acquire-worker.h +++ b/apt-pkg/acquire-worker.h @@ -1,10 +1,12 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: acquire-worker.h,v 1.1 1998/10/15 06:59:59 jgg Exp $ +// $Id: acquire-worker.h,v 1.2 1998/10/20 02:39:14 jgg Exp $ /* ###################################################################### Acquire Worker - Worker process manager + Each worker class is associated with exaclty one subprocess. + ##################################################################### */ /*}}}*/ #ifndef PKGLIB_ACQUIRE_WORKER_H @@ -20,18 +22,40 @@ class pkgAcquire::Worker { protected: + friend Queue; + + Worker *Next; + // The access association Queue *OwnerQ; - MethodConfig *Config; - Worker *Next; + MethodConfig *Config; + string Access; + + // This is the subprocess IPC setup + pid_t Process; + int InFd; + int OutFd; - friend Queue; + // Various internal things + bool Debug; + vector MessageQueue; + + // Private constructor helper + void Construct(); + + // Message handling things + bool ReadMessages(); + bool RunMessages(); + + // The message handlers + bool Capabilities(string Message); public: - bool Create(); + // Load the method and do the startup + bool Start(); - Worker(Queue *OwnerQ); + Worker(Queue *OwnerQ,string Access); Worker(MethodConfig *Config); ~Worker(); }; -- cgit v1.2.3