Debian Codegraph @

include/cddb/cddbremote.h

raw symbols SCIP
1 /* fre:ac - free audio converter
2 * Copyright (C) 2001-2025 Robert Kausch <[email protected]>
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License as
6 * published by the Free Software Foundation, either version 2 of
7 * the License, or (at your option) any later version.
8 *
9 * THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
10 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
11 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. */
12
13 #ifndef H_FREAC_CDDB_REMOTE
14 #define H_FREAC_CDDB_REMOTE
15
16 #include <cddb/cddb.h>
17 #include <boca/common/protocol.h>
18
19 using namespace smooth::IO;
20
21 namespace freac
22 {
23 class CDDBRemote : public CDDB
24 {
25 private:
26 Bool connected;
27
28 Buffer<UnsignedByte> httpResultBuffer;
29
30 Array<CDDBInfo> readEntries;
31
32 Driver *socket;
33 InStream *in;
34 OutStream *out;
35
36 String SendCommand(const String &);
37 public:
38 CDDBRemote();
39 virtual ~CDDBRemote();
40
41 Bool ConnectToServer();
42 Int Query(const String &);
43 Bool Read(const String &, UnsignedInt32, CDDBInfo &);
44 Bool Submit(const CDDBInfo &);
45 Bool CloseConnection();
46 };
47 };
48
49 #endif