]> Some of my projects - anidbudpclient.git/commitdiff
- New (broken) hashing infrastructure
authorAPTX <mail@example.com>
Fri, 21 Aug 2009 11:12:51 +0000 (13:12 +0200)
committerAPTX <mail@example.com>
Fri, 21 Aug 2009 11:24:21 +0000 (13:24 +0200)
anidbudpclient.pro
anidbudpclient_global.h

index 1aabbb393c0ac8b0a3f77c353d3b7c9a2ff74435..b9deb3a78f30a09ae4181f9d801cfec811d4bfc2 100644 (file)
@@ -1,7 +1,8 @@
 # -------------------------------------------------
 # Project created by QtCreator 2009-03-22T14:53:52
 # -------------------------------------------------
-QT += network script
+QT += network \
+    script
 QT -= gui
 TEMPLATE = lib
 TARGET = anidbudpclient
@@ -15,16 +16,18 @@ static {
 }
 INCLUDEPATH += $$PWD
 DEPENDPATH += $$PWD
-
 DEFINES += ANIDBUDPCLIENT_LIBRARY
 SOURCES += client.cpp \
     abstractcommand.cpp \
     authcommand.cpp \
     rawcommand.cpp \
-       mylistaddcommand.cpp \
+    mylistaddcommand.cpp \
     logoutcommand.cpp \
     uptimecommand.cpp \
-    mylistcommand.cpp
+    mylistcommand.cpp \
+    hash.cpp \
+    hashproducer.cpp \
+    hashconsumer.cpp
 HEADERS += client.h \
     anidbudpclient_global.h \
     abstractcommand.h \
@@ -33,13 +36,16 @@ HEADERS += client.h \
     mylistaddcommand.h \
     logoutcommand.h \
     uptimecommand.h \
-    mylistcommand.h
-
+    mylistcommand.h \
+    hash.h \
+    hashproducer.h \
+    hashconsumer.h \
+       circularbuffer.h
 CONV_HEADERS += include/AniDBUdpClient/Client \
-       include/AniDBUdpClient/AbstractCommand \
-       include/AniDBUdpClient/RawCommand \
-       include/AniDBUdpClient/MyListCommand \
-       include/AniDBUdpClient/MyListAddCommand \
-       include/AniDBUdpClient/UptimeCommand
-
+    include/AniDBUdpClient/AbstractCommand \
+    include/AniDBUdpClient/RawCommand \
+    include/AniDBUdpClient/MyListCommand \
+    include/AniDBUdpClient/MyListAddCommand \
+       include/AniDBUdpClient/UptimeCommand \
+       include/AniDBUdpClient/Hash
 include(../../lib/qtstatemachine/src/qtstatemachine.pri)
index 2f5a1a48953a5aa3cee0d5c0e23d8869bb7b7773..e4052954a38341ceadf4e0575652606e2279bb3c 100644 (file)
@@ -40,6 +40,7 @@ namespace AniDBUdpClient
        {
                CLIENT_DESTROYED                        = -1,
                UNKNOWN_REPLY                           = 0,
+
                // POSITIVE 2XX
                LOGIN_ACCEPTED                          = 200, //a
                LOGIN_ACCEPTED_NEW_VER          = 201, //a
@@ -193,6 +194,10 @@ namespace AniDBUdpClient
        };
 
        Q_ENUMS(Error IdlePolicy ReplyCode State FileState);
+
+       namespace HashPrivate {
+               static const qint64 ED2K_PART_SIZE = 9728000;
+       }
 }
 
 #endif // ANIDBUDPCLIENT_GLOBAL_H