Changeset 41:680c6a482e9d in SMSSender


Ignore:
Timestamp:
Jan 14, 2010 3:11:37 PM (12 years ago)
Author:
Sämy Zehnder <saemy.zehnder@…>
Branch:
3.0
Convert:
svn:3639001d-8e34-449c-bb86-3782b86c4877/branches/3.0@40
Message:
 
Location:
lib
Files:
45 added
3 deleted
43 edited

Legend:

Unmodified
Added
Removed
  • lib/libgateway/Makefile

    r37 r41  
    11#############################################################################
    22# Makefile for building: libgateway.a
    3 # Generated by qmake (2.01a) (Qt 4.5.2) on: Sat Nov 21 17:21:14 2009
     3# Generated by qmake (2.01a) (Qt 4.5.2) on: Tue Jan 12 16:59:06 2010
    44# Project:  gateway.pro
    55# Template: lib
     
    7575                /usr/share/qt4/mkspecs/features/debug_and_release.prf \
    7676                /usr/share/qt4/mkspecs/features/default_post.prf \
     77                /usr/share/qt4/mkspecs/features/unix/thread.prf \
    7778                /usr/share/qt4/mkspecs/features/staticlib.prf \
    7879                /usr/share/qt4/mkspecs/features/static.prf \
    7980                /usr/share/qt4/mkspecs/features/warn_on.prf \
    8081                /usr/share/qt4/mkspecs/features/qt.prf \
    81                 /usr/share/qt4/mkspecs/features/unix/thread.prf \
    8282                /usr/share/qt4/mkspecs/features/moc.prf \
    8383                /usr/share/qt4/mkspecs/features/resources.prf \
     
    101101/usr/share/qt4/mkspecs/features/debug_and_release.prf:
    102102/usr/share/qt4/mkspecs/features/default_post.prf:
     103/usr/share/qt4/mkspecs/features/unix/thread.prf:
    103104/usr/share/qt4/mkspecs/features/staticlib.prf:
    104105/usr/share/qt4/mkspecs/features/static.prf:
    105106/usr/share/qt4/mkspecs/features/warn_on.prf:
    106107/usr/share/qt4/mkspecs/features/qt.prf:
    107 /usr/share/qt4/mkspecs/features/unix/thread.prf:
    108108/usr/share/qt4/mkspecs/features/moc.prf:
    109109/usr/share/qt4/mkspecs/features/resources.prf:
  • lib/libgateway/Makefile.Debug

    r37 r41  
    11#############################################################################
    22# Makefile for building: libgateway.a
    3 # Generated by qmake (2.01a) (Qt 4.5.2) on: Sat Nov 21 17:21:14 2009
     3# Generated by qmake (2.01a) (Qt 4.5.2) on: Tue Jan 12 16:59:06 2010
    44# Project:  gateway.pro
    55# Template: lib
     
    1111CXX           = g++
    1212DEFINES       = -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED
    13 CFLAGS        = -pipe -g -fPIC -Wall -W -D_REENTRANT $(DEFINES)
    14 CXXFLAGS      = -pipe -g -fPIC -Wall -W -D_REENTRANT $(DEFINES)
    15 INCPATH       = -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4 -Iapp -I../libinterfaces/src/business -I../libinterfaces/src -I../../src/persistence -I../../src/exceptions -I../../src/utils -Idebug
     13CFLAGS        = -pipe -g -D_REENTRANT -fPIC -Wall -W $(DEFINES)
     14CXXFLAGS      = -pipe -g -D_REENTRANT -fPIC -Wall -W $(DEFINES)
     15INCPATH       = -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4 -Iapp -I../libinterfaces/src/exceptions -I../libinterfaces/src/business -I../libinterfaces/src -I../libutils/src -Idebug
    1616AR            = ar cqs
    1717RANLIB        =
     
    3939####### Files
    4040
    41 SOURCES       = src/business/AbstractAccount.cpp \
     41SOURCES       = src/business/validation/BCLoginAccountValidator.cpp \
     42                src/business/AbstractAccount.cpp \
    4243                src/business/AbstractLoginAccount.cpp \
    4344                src/business/AbstractGateway.cpp \
     
    4546                src/business/HttpHelper.cpp \
    4647                src/business/HttpCookieManager.cpp \
     48                src/business/validation/BCValidationResult.cpp \
     49                src/business/validation/BCStdAccountValidator.cpp \
     50                src/business/validation/BCLoginAccountValidator.cpp \
    4751                src/persistence/AbstractAccountStorageOfficer.cpp \
    48                 src/persistence/AbstractLoginAccountStorageOfficer.cpp debug/moc_HttpHelper.cpp \
    49                 debug/moc_HttpCookieManager.cpp
    50 OBJECTS       = debug/AbstractAccount.o \
     52                src/persistence/AbstractLoginAccountStorageOfficer.cpp \
     53                src/persistence/AbstractSQLiteStorageOfficer.cpp debug/moc_BCLoginAccountValidator.cpp \
     54                debug/moc_AbstractAccount.cpp \
     55                debug/moc_AbstractLoginAccount.cpp \
     56                debug/moc_AbstractGateway.cpp \
     57                debug/moc_AbstractLoginGateway.cpp \
     58                debug/moc_HttpHelper.cpp \
     59                debug/moc_HttpCookieManager.cpp \
     60                debug/moc_BCStdAccountValidator.cpp \
     61                debug/moc_BCValidationResult.cpp \
     62                debug/moc_AbstractAccountStorageOfficer.cpp \
     63                debug/moc_AbstractLoginAccountStorageOfficer.cpp \
     64                debug/moc_AbstractSQLiteStorageOfficer.cpp
     65OBJECTS       = debug/BCLoginAccountValidator.o \
     66                debug/AbstractAccount.o \
    5167                debug/AbstractLoginAccount.o \
    5268                debug/AbstractGateway.o \
     
    5470                debug/HttpHelper.o \
    5571                debug/HttpCookieManager.o \
     72                debug/BCValidationResult.o \
     73                debug/BCStdAccountValidator.o \
     74                debug/BCLoginAccountValidator.o \
    5675                debug/AbstractAccountStorageOfficer.o \
    5776                debug/AbstractLoginAccountStorageOfficer.o \
     77                debug/AbstractSQLiteStorageOfficer.o \
     78                debug/moc_BCLoginAccountValidator.o \
     79                debug/moc_AbstractAccount.o \
     80                debug/moc_AbstractLoginAccount.o \
     81                debug/moc_AbstractGateway.o \
     82                debug/moc_AbstractLoginGateway.o \
    5883                debug/moc_HttpHelper.o \
    59                 debug/moc_HttpCookieManager.o
     84                debug/moc_HttpCookieManager.o \
     85                debug/moc_BCStdAccountValidator.o \
     86                debug/moc_BCValidationResult.o \
     87                debug/moc_AbstractAccountStorageOfficer.o \
     88                debug/moc_AbstractLoginAccountStorageOfficer.o \
     89                debug/moc_AbstractSQLiteStorageOfficer.o
    6090DIST          = /usr/share/qt4/mkspecs/common/g++.conf \
    6191                /usr/share/qt4/mkspecs/common/unix.conf \
     
    70100                /usr/share/qt4/mkspecs/features/default_post.prf \
    71101                /usr/share/qt4/mkspecs/features/build_pass.prf \
     102                /usr/share/qt4/mkspecs/features/unix/thread.prf \
    72103                /usr/share/qt4/mkspecs/features/staticlib.prf \
    73104                /usr/share/qt4/mkspecs/features/static.prf \
    74105                /usr/share/qt4/mkspecs/features/warn_on.prf \
    75106                /usr/share/qt4/mkspecs/features/qt.prf \
    76                 /usr/share/qt4/mkspecs/features/unix/thread.prf \
    77107                /usr/share/qt4/mkspecs/features/moc.prf \
    78108                /usr/share/qt4/mkspecs/features/resources.prf \
     
    125155dist:
    126156        @$(CHK_DIR_EXISTS) debug/gateway2.0.0 || $(MKDIR) debug/gateway2.0.0
    127         $(COPY_FILE) --parents $(SOURCES) $(DIST) debug/gateway2.0.0/ && $(COPY_FILE) --parents src/exceptions/ELoginAccountExceptions.h src/business/AbstractAccount.h src/business/AbstractLoginAccount.h src/business/AbstractGateway.h src/business/AbstractLoginGateway.h src/business/HttpHelper.h src/business/HttpCookieManager.h src/persistence/AbstractAccountStorageOfficer.h src/persistence/AbstractLoginAccountStorageOfficer.h debug/gateway2.0.0/ && $(COPY_FILE) --parents src/business/AbstractAccount.cpp src/business/AbstractLoginAccount.cpp src/business/AbstractGateway.cpp src/business/AbstractLoginGateway.cpp src/business/HttpHelper.cpp src/business/HttpCookieManager.cpp src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractLoginAccountStorageOfficer.cpp debug/gateway2.0.0/ && (cd `dirname debug/gateway2.0.0` && $(TAR) gateway2.0.0.tar gateway2.0.0 && $(COMPRESS) gateway2.0.0.tar) && $(MOVE) `dirname debug/gateway2.0.0`/gateway2.0.0.tar.gz . && $(DEL_FILE) -r debug/gateway2.0.0
     157        $(COPY_FILE) --parents $(SOURCES) $(DIST) debug/gateway2.0.0/ && $(COPY_FILE) --parents src/business/validation/BCLoginAccountValidator.h src/business/AbstractAccount.h src/business/AbstractLoginAccount.h src/business/AbstractGateway.h src/business/AbstractLoginGateway.h src/business/HttpHelper.h src/business/HttpCookieManager.h src/business/exceptions/ELoginAccountLoginException.h src/business/exceptions/LoginAccountExceptions.h src/business/validation/BCStdAccountValidator.h src/business/validation/BCLoginAccountValidator.h src/business/validation/BCValidationResult.h src/exceptions/LoginAccountExceptions.h src/persistence/AbstractAccountStorageOfficer.h src/persistence/AbstractLoginAccountStorageOfficer.h src/persistence/AbstractSQLiteStorageOfficer.h debug/gateway2.0.0/ && $(COPY_FILE) --parents src/business/validation/BCLoginAccountValidator.cpp src/business/AbstractAccount.cpp src/business/AbstractLoginAccount.cpp src/business/AbstractGateway.cpp src/business/AbstractLoginGateway.cpp src/business/HttpHelper.cpp src/business/HttpCookieManager.cpp src/business/validation/BCValidationResult.cpp src/business/validation/BCStdAccountValidator.cpp src/business/validation/BCLoginAccountValidator.cpp src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractLoginAccountStorageOfficer.cpp src/persistence/AbstractSQLiteStorageOfficer.cpp debug/gateway2.0.0/ && (cd `dirname debug/gateway2.0.0` && $(TAR) gateway2.0.0.tar gateway2.0.0 && $(COMPRESS) gateway2.0.0.tar) && $(MOVE) `dirname debug/gateway2.0.0`/gateway2.0.0.tar.gz . && $(DEL_FILE) -r debug/gateway2.0.0
    128158
    129159
     
    144174mocables: compiler_moc_header_make_all compiler_moc_source_make_all
    145175
    146 compiler_moc_header_make_all: debug/moc_HttpHelper.cpp debug/moc_HttpCookieManager.cpp
     176compiler_moc_header_make_all: debug/moc_BCLoginAccountValidator.cpp debug/moc_AbstractAccount.cpp debug/moc_AbstractLoginAccount.cpp debug/moc_AbstractGateway.cpp debug/moc_AbstractLoginGateway.cpp debug/moc_HttpHelper.cpp debug/moc_HttpCookieManager.cpp debug/moc_BCStdAccountValidator.cpp debug/moc_BCLoginAccountValidator.cpp debug/moc_BCValidationResult.cpp debug/moc_AbstractAccountStorageOfficer.cpp debug/moc_AbstractLoginAccountStorageOfficer.cpp debug/moc_AbstractSQLiteStorageOfficer.cpp
    147177compiler_moc_header_clean:
    148         -$(DEL_FILE) debug/moc_HttpHelper.cpp debug/moc_HttpCookieManager.cpp
     178        -$(DEL_FILE) debug/moc_BCLoginAccountValidator.cpp debug/moc_AbstractAccount.cpp debug/moc_AbstractLoginAccount.cpp debug/moc_AbstractGateway.cpp debug/moc_AbstractLoginGateway.cpp debug/moc_HttpHelper.cpp debug/moc_HttpCookieManager.cpp debug/moc_BCStdAccountValidator.cpp debug/moc_BCLoginAccountValidator.cpp debug/moc_BCValidationResult.cpp debug/moc_AbstractAccountStorageOfficer.cpp debug/moc_AbstractLoginAccountStorageOfficer.cpp debug/moc_AbstractSQLiteStorageOfficer.cpp
     179debug/moc_BCLoginAccountValidator.cpp: src/business/validation/BCStdAccountValidator.h \
     180                src/business/validation/BCLoginAccountValidator.h
     181        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCLoginAccountValidator.h -o debug/moc_BCLoginAccountValidator.cpp
     182
     183debug/moc_AbstractAccount.cpp: src/business/AbstractAccount.h
     184        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractAccount.h -o debug/moc_AbstractAccount.cpp
     185
     186debug/moc_AbstractLoginAccount.cpp: src/business/AbstractAccount.h \
     187                src/business/AbstractLoginAccount.h
     188        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractLoginAccount.h -o debug/moc_AbstractLoginAccount.cpp
     189
     190debug/moc_AbstractGateway.cpp: src/business/AbstractGateway.h
     191        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractGateway.h -o debug/moc_AbstractGateway.cpp
     192
     193debug/moc_AbstractLoginGateway.cpp: src/business/AbstractGateway.h \
     194                src/business/AbstractLoginGateway.h
     195        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractLoginGateway.h -o debug/moc_AbstractLoginGateway.cpp
     196
    149197debug/moc_HttpHelper.cpp: src/business/HttpCookieManager.h \
    150198                src/business/HttpHelper.h
     
    153201debug/moc_HttpCookieManager.cpp: src/business/HttpCookieManager.h
    154202        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/HttpCookieManager.h -o debug/moc_HttpCookieManager.cpp
     203
     204debug/moc_BCStdAccountValidator.cpp: src/business/validation/BCStdAccountValidator.h
     205        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCStdAccountValidator.h -o debug/moc_BCStdAccountValidator.cpp
     206
     207debug/moc_BCLoginAccountValidator.cpp: src/business/validation/BCStdAccountValidator.h \
     208                src/business/validation/BCLoginAccountValidator.h
     209        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCLoginAccountValidator.h -o debug/moc_BCLoginAccountValidator.cpp
     210
     211debug/moc_BCValidationResult.cpp: src/business/validation/BCValidationResult.h
     212        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCValidationResult.h -o debug/moc_BCValidationResult.cpp
     213
     214debug/moc_AbstractAccountStorageOfficer.cpp: src/persistence/AbstractSQLiteStorageOfficer.h \
     215                src/persistence/AbstractAccountStorageOfficer.h
     216        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/persistence/AbstractAccountStorageOfficer.h -o debug/moc_AbstractAccountStorageOfficer.cpp
     217
     218debug/moc_AbstractLoginAccountStorageOfficer.cpp: src/persistence/AbstractAccountStorageOfficer.h \
     219                src/persistence/AbstractSQLiteStorageOfficer.h \
     220                src/persistence/AbstractLoginAccountStorageOfficer.h
     221        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/persistence/AbstractLoginAccountStorageOfficer.h -o debug/moc_AbstractLoginAccountStorageOfficer.cpp
     222
     223debug/moc_AbstractSQLiteStorageOfficer.cpp: src/persistence/AbstractSQLiteStorageOfficer.h
     224        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/persistence/AbstractSQLiteStorageOfficer.h -o debug/moc_AbstractSQLiteStorageOfficer.cpp
    155225
    156226compiler_rcc_make_all:
     
    173243####### Compile
    174244
     245debug/BCLoginAccountValidator.o: src/business/validation/BCLoginAccountValidator.cpp src/business/validation/BCLoginAccountValidator.h \
     246                src/business/validation/BCStdAccountValidator.h \
     247                src/business/AbstractLoginAccount.h \
     248                src/business/AbstractAccount.h
     249        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/BCLoginAccountValidator.o src/business/validation/BCLoginAccountValidator.cpp
     250
    175251debug/AbstractAccount.o: src/business/AbstractAccount.cpp src/business/AbstractAccount.h
    176252        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/AbstractAccount.o src/business/AbstractAccount.cpp
     
    194270        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/HttpCookieManager.o src/business/HttpCookieManager.cpp
    195271
    196 debug/AbstractAccountStorageOfficer.o: src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractAccountStorageOfficer.h
     272debug/BCValidationResult.o: src/business/validation/BCValidationResult.cpp src/business/validation/BCValidationResult.h
     273        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/BCValidationResult.o src/business/validation/BCValidationResult.cpp
     274
     275debug/BCStdAccountValidator.o: src/business/validation/BCStdAccountValidator.cpp src/business/validation/BCStdAccountValidator.h \
     276                src/business/validation/BCValidationResult.h
     277        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/BCStdAccountValidator.o src/business/validation/BCStdAccountValidator.cpp
     278
     279debug/BCLoginAccountValidator.o: src/business/validation/BCLoginAccountValidator.cpp src/business/validation/BCLoginAccountValidator.h \
     280                src/business/validation/BCStdAccountValidator.h \
     281                src/business/AbstractLoginAccount.h \
     282                src/business/AbstractAccount.h
     283        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/BCLoginAccountValidator.o src/business/validation/BCLoginAccountValidator.cpp
     284
     285debug/AbstractAccountStorageOfficer.o: src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractAccountStorageOfficer.h \
     286                src/persistence/AbstractSQLiteStorageOfficer.h
    197287        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/AbstractAccountStorageOfficer.o src/persistence/AbstractAccountStorageOfficer.cpp
    198288
    199289debug/AbstractLoginAccountStorageOfficer.o: src/persistence/AbstractLoginAccountStorageOfficer.cpp src/persistence/AbstractLoginAccountStorageOfficer.h \
    200                 src/persistence/AbstractAccountStorageOfficer.h
     290                src/persistence/AbstractAccountStorageOfficer.h \
     291                src/persistence/AbstractSQLiteStorageOfficer.h
    201292        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/AbstractLoginAccountStorageOfficer.o src/persistence/AbstractLoginAccountStorageOfficer.cpp
     293
     294debug/AbstractSQLiteStorageOfficer.o: src/persistence/AbstractSQLiteStorageOfficer.cpp src/persistence/AbstractSQLiteStorageOfficer.h
     295        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/AbstractSQLiteStorageOfficer.o src/persistence/AbstractSQLiteStorageOfficer.cpp
     296
     297debug/moc_BCLoginAccountValidator.o: debug/moc_BCLoginAccountValidator.cpp
     298        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_BCLoginAccountValidator.o debug/moc_BCLoginAccountValidator.cpp
     299
     300debug/moc_AbstractAccount.o: debug/moc_AbstractAccount.cpp
     301        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractAccount.o debug/moc_AbstractAccount.cpp
     302
     303debug/moc_AbstractLoginAccount.o: debug/moc_AbstractLoginAccount.cpp
     304        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractLoginAccount.o debug/moc_AbstractLoginAccount.cpp
     305
     306debug/moc_AbstractGateway.o: debug/moc_AbstractGateway.cpp
     307        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractGateway.o debug/moc_AbstractGateway.cpp
     308
     309debug/moc_AbstractLoginGateway.o: debug/moc_AbstractLoginGateway.cpp
     310        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractLoginGateway.o debug/moc_AbstractLoginGateway.cpp
    202311
    203312debug/moc_HttpHelper.o: debug/moc_HttpHelper.cpp
     
    207316        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_HttpCookieManager.o debug/moc_HttpCookieManager.cpp
    208317
     318debug/moc_BCStdAccountValidator.o: debug/moc_BCStdAccountValidator.cpp
     319        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_BCStdAccountValidator.o debug/moc_BCStdAccountValidator.cpp
     320
     321debug/moc_BCValidationResult.o: debug/moc_BCValidationResult.cpp
     322        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_BCValidationResult.o debug/moc_BCValidationResult.cpp
     323
     324debug/moc_AbstractAccountStorageOfficer.o: debug/moc_AbstractAccountStorageOfficer.cpp
     325        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractAccountStorageOfficer.o debug/moc_AbstractAccountStorageOfficer.cpp
     326
     327debug/moc_AbstractLoginAccountStorageOfficer.o: debug/moc_AbstractLoginAccountStorageOfficer.cpp
     328        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractLoginAccountStorageOfficer.o debug/moc_AbstractLoginAccountStorageOfficer.cpp
     329
     330debug/moc_AbstractSQLiteStorageOfficer.o: debug/moc_AbstractSQLiteStorageOfficer.cpp
     331        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o debug/moc_AbstractSQLiteStorageOfficer.o debug/moc_AbstractSQLiteStorageOfficer.cpp
     332
    209333####### Install
    210334
  • lib/libgateway/Makefile.Release

    r37 r41  
    11#############################################################################
    22# Makefile for building: libgateway.a
    3 # Generated by qmake (2.01a) (Qt 4.5.2) on: Sat Nov 21 17:21:14 2009
     3# Generated by qmake (2.01a) (Qt 4.5.2) on: Tue Jan 12 16:59:06 2010
    44# Project:  gateway.pro
    55# Template: lib
     
    1111CXX           = g++
    1212DEFINES       = -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED
    13 CFLAGS        = -pipe -O2 -fPIC -Wall -W -D_REENTRANT $(DEFINES)
    14 CXXFLAGS      = -pipe -O2 -fPIC -Wall -W -D_REENTRANT $(DEFINES)
    15 INCPATH       = -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4 -Iapp -I../libinterfaces/src/business -I../libinterfaces/src -I../../src/persistence -I../../src/exceptions -I../../src/utils -Irelease
     13CFLAGS        = -pipe -O2 -D_REENTRANT -fPIC -Wall -W $(DEFINES)
     14CXXFLAGS      = -pipe -O2 -D_REENTRANT -fPIC -Wall -W $(DEFINES)
     15INCPATH       = -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4 -Iapp -I../libinterfaces/src/exceptions -I../libinterfaces/src/business -I../libinterfaces/src -I../libutils/src -Irelease
    1616AR            = ar cqs
    1717RANLIB        =
     
    3939####### Files
    4040
    41 SOURCES       = src/business/AbstractAccount.cpp \
     41SOURCES       = src/business/validation/BCLoginAccountValidator.cpp \
     42                src/business/AbstractAccount.cpp \
    4243                src/business/AbstractLoginAccount.cpp \
    4344                src/business/AbstractGateway.cpp \
     
    4546                src/business/HttpHelper.cpp \
    4647                src/business/HttpCookieManager.cpp \
     48                src/business/validation/BCValidationResult.cpp \
     49                src/business/validation/BCStdAccountValidator.cpp \
     50                src/business/validation/BCLoginAccountValidator.cpp \
    4751                src/persistence/AbstractAccountStorageOfficer.cpp \
    48                 src/persistence/AbstractLoginAccountStorageOfficer.cpp release/moc_HttpHelper.cpp \
    49                 release/moc_HttpCookieManager.cpp
    50 OBJECTS       = release/AbstractAccount.o \
     52                src/persistence/AbstractLoginAccountStorageOfficer.cpp \
     53                src/persistence/AbstractSQLiteStorageOfficer.cpp release/moc_BCLoginAccountValidator.cpp \
     54                release/moc_AbstractAccount.cpp \
     55                release/moc_AbstractLoginAccount.cpp \
     56                release/moc_AbstractGateway.cpp \
     57                release/moc_AbstractLoginGateway.cpp \
     58                release/moc_HttpHelper.cpp \
     59                release/moc_HttpCookieManager.cpp \
     60                release/moc_BCStdAccountValidator.cpp \
     61                release/moc_BCValidationResult.cpp \
     62                release/moc_AbstractAccountStorageOfficer.cpp \
     63                release/moc_AbstractLoginAccountStorageOfficer.cpp \
     64                release/moc_AbstractSQLiteStorageOfficer.cpp
     65OBJECTS       = release/BCLoginAccountValidator.o \
     66                release/AbstractAccount.o \
    5167                release/AbstractLoginAccount.o \
    5268                release/AbstractGateway.o \
     
    5470                release/HttpHelper.o \
    5571                release/HttpCookieManager.o \
     72                release/BCValidationResult.o \
     73                release/BCStdAccountValidator.o \
     74                release/BCLoginAccountValidator.o \
    5675                release/AbstractAccountStorageOfficer.o \
    5776                release/AbstractLoginAccountStorageOfficer.o \
     77                release/AbstractSQLiteStorageOfficer.o \
     78                release/moc_BCLoginAccountValidator.o \
     79                release/moc_AbstractAccount.o \
     80                release/moc_AbstractLoginAccount.o \
     81                release/moc_AbstractGateway.o \
     82                release/moc_AbstractLoginGateway.o \
    5883                release/moc_HttpHelper.o \
    59                 release/moc_HttpCookieManager.o
     84                release/moc_HttpCookieManager.o \
     85                release/moc_BCStdAccountValidator.o \
     86                release/moc_BCValidationResult.o \
     87                release/moc_AbstractAccountStorageOfficer.o \
     88                release/moc_AbstractLoginAccountStorageOfficer.o \
     89                release/moc_AbstractSQLiteStorageOfficer.o
    6090DIST          = /usr/share/qt4/mkspecs/common/g++.conf \
    6191                /usr/share/qt4/mkspecs/common/unix.conf \
     
    70100                /usr/share/qt4/mkspecs/features/default_post.prf \
    71101                /usr/share/qt4/mkspecs/features/build_pass.prf \
     102                /usr/share/qt4/mkspecs/features/unix/thread.prf \
    72103                /usr/share/qt4/mkspecs/features/staticlib.prf \
    73104                /usr/share/qt4/mkspecs/features/static.prf \
    74105                /usr/share/qt4/mkspecs/features/warn_on.prf \
    75106                /usr/share/qt4/mkspecs/features/qt.prf \
    76                 /usr/share/qt4/mkspecs/features/unix/thread.prf \
    77107                /usr/share/qt4/mkspecs/features/moc.prf \
    78108                /usr/share/qt4/mkspecs/features/resources.prf \
     
    125155dist:
    126156        @$(CHK_DIR_EXISTS) release/gateway2.0.0 || $(MKDIR) release/gateway2.0.0
    127         $(COPY_FILE) --parents $(SOURCES) $(DIST) release/gateway2.0.0/ && $(COPY_FILE) --parents src/exceptions/ELoginAccountExceptions.h src/business/AbstractAccount.h src/business/AbstractLoginAccount.h src/business/AbstractGateway.h src/business/AbstractLoginGateway.h src/business/HttpHelper.h src/business/HttpCookieManager.h src/persistence/AbstractAccountStorageOfficer.h src/persistence/AbstractLoginAccountStorageOfficer.h release/gateway2.0.0/ && $(COPY_FILE) --parents src/business/AbstractAccount.cpp src/business/AbstractLoginAccount.cpp src/business/AbstractGateway.cpp src/business/AbstractLoginGateway.cpp src/business/HttpHelper.cpp src/business/HttpCookieManager.cpp src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractLoginAccountStorageOfficer.cpp release/gateway2.0.0/ && (cd `dirname release/gateway2.0.0` && $(TAR) gateway2.0.0.tar gateway2.0.0 && $(COMPRESS) gateway2.0.0.tar) && $(MOVE) `dirname release/gateway2.0.0`/gateway2.0.0.tar.gz . && $(DEL_FILE) -r release/gateway2.0.0
     157        $(COPY_FILE) --parents $(SOURCES) $(DIST) release/gateway2.0.0/ && $(COPY_FILE) --parents src/business/validation/BCLoginAccountValidator.h src/business/AbstractAccount.h src/business/AbstractLoginAccount.h src/business/AbstractGateway.h src/business/AbstractLoginGateway.h src/business/HttpHelper.h src/business/HttpCookieManager.h src/business/exceptions/ELoginAccountLoginException.h src/business/exceptions/LoginAccountExceptions.h src/business/validation/BCStdAccountValidator.h src/business/validation/BCLoginAccountValidator.h src/business/validation/BCValidationResult.h src/exceptions/LoginAccountExceptions.h src/persistence/AbstractAccountStorageOfficer.h src/persistence/AbstractLoginAccountStorageOfficer.h src/persistence/AbstractSQLiteStorageOfficer.h release/gateway2.0.0/ && $(COPY_FILE) --parents src/business/validation/BCLoginAccountValidator.cpp src/business/AbstractAccount.cpp src/business/AbstractLoginAccount.cpp src/business/AbstractGateway.cpp src/business/AbstractLoginGateway.cpp src/business/HttpHelper.cpp src/business/HttpCookieManager.cpp src/business/validation/BCValidationResult.cpp src/business/validation/BCStdAccountValidator.cpp src/business/validation/BCLoginAccountValidator.cpp src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractLoginAccountStorageOfficer.cpp src/persistence/AbstractSQLiteStorageOfficer.cpp release/gateway2.0.0/ && (cd `dirname release/gateway2.0.0` && $(TAR) gateway2.0.0.tar gateway2.0.0 && $(COMPRESS) gateway2.0.0.tar) && $(MOVE) `dirname release/gateway2.0.0`/gateway2.0.0.tar.gz . && $(DEL_FILE) -r release/gateway2.0.0
    128158
    129159
     
    144174mocables: compiler_moc_header_make_all compiler_moc_source_make_all
    145175
    146 compiler_moc_header_make_all: release/moc_HttpHelper.cpp release/moc_HttpCookieManager.cpp
     176compiler_moc_header_make_all: release/moc_BCLoginAccountValidator.cpp release/moc_AbstractAccount.cpp release/moc_AbstractLoginAccount.cpp release/moc_AbstractGateway.cpp release/moc_AbstractLoginGateway.cpp release/moc_HttpHelper.cpp release/moc_HttpCookieManager.cpp release/moc_BCStdAccountValidator.cpp release/moc_BCLoginAccountValidator.cpp release/moc_BCValidationResult.cpp release/moc_AbstractAccountStorageOfficer.cpp release/moc_AbstractLoginAccountStorageOfficer.cpp release/moc_AbstractSQLiteStorageOfficer.cpp
    147177compiler_moc_header_clean:
    148         -$(DEL_FILE) release/moc_HttpHelper.cpp release/moc_HttpCookieManager.cpp
     178        -$(DEL_FILE) release/moc_BCLoginAccountValidator.cpp release/moc_AbstractAccount.cpp release/moc_AbstractLoginAccount.cpp release/moc_AbstractGateway.cpp release/moc_AbstractLoginGateway.cpp release/moc_HttpHelper.cpp release/moc_HttpCookieManager.cpp release/moc_BCStdAccountValidator.cpp release/moc_BCLoginAccountValidator.cpp release/moc_BCValidationResult.cpp release/moc_AbstractAccountStorageOfficer.cpp release/moc_AbstractLoginAccountStorageOfficer.cpp release/moc_AbstractSQLiteStorageOfficer.cpp
     179release/moc_BCLoginAccountValidator.cpp: src/business/validation/BCStdAccountValidator.h \
     180                src/business/validation/BCLoginAccountValidator.h
     181        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCLoginAccountValidator.h -o release/moc_BCLoginAccountValidator.cpp
     182
     183release/moc_AbstractAccount.cpp: src/business/AbstractAccount.h
     184        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractAccount.h -o release/moc_AbstractAccount.cpp
     185
     186release/moc_AbstractLoginAccount.cpp: src/business/AbstractAccount.h \
     187                src/business/AbstractLoginAccount.h
     188        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractLoginAccount.h -o release/moc_AbstractLoginAccount.cpp
     189
     190release/moc_AbstractGateway.cpp: src/business/AbstractGateway.h
     191        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractGateway.h -o release/moc_AbstractGateway.cpp
     192
     193release/moc_AbstractLoginGateway.cpp: src/business/AbstractGateway.h \
     194                src/business/AbstractLoginGateway.h
     195        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/AbstractLoginGateway.h -o release/moc_AbstractLoginGateway.cpp
     196
    149197release/moc_HttpHelper.cpp: src/business/HttpCookieManager.h \
    150198                src/business/HttpHelper.h
     
    153201release/moc_HttpCookieManager.cpp: src/business/HttpCookieManager.h
    154202        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/HttpCookieManager.h -o release/moc_HttpCookieManager.cpp
     203
     204release/moc_BCStdAccountValidator.cpp: src/business/validation/BCStdAccountValidator.h
     205        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCStdAccountValidator.h -o release/moc_BCStdAccountValidator.cpp
     206
     207release/moc_BCLoginAccountValidator.cpp: src/business/validation/BCStdAccountValidator.h \
     208                src/business/validation/BCLoginAccountValidator.h
     209        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCLoginAccountValidator.h -o release/moc_BCLoginAccountValidator.cpp
     210
     211release/moc_BCValidationResult.cpp: src/business/validation/BCValidationResult.h
     212        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/business/validation/BCValidationResult.h -o release/moc_BCValidationResult.cpp
     213
     214release/moc_AbstractAccountStorageOfficer.cpp: src/persistence/AbstractSQLiteStorageOfficer.h \
     215                src/persistence/AbstractAccountStorageOfficer.h
     216        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/persistence/AbstractAccountStorageOfficer.h -o release/moc_AbstractAccountStorageOfficer.cpp
     217
     218release/moc_AbstractLoginAccountStorageOfficer.cpp: src/persistence/AbstractAccountStorageOfficer.h \
     219                src/persistence/AbstractSQLiteStorageOfficer.h \
     220                src/persistence/AbstractLoginAccountStorageOfficer.h
     221        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/persistence/AbstractLoginAccountStorageOfficer.h -o release/moc_AbstractLoginAccountStorageOfficer.cpp
     222
     223release/moc_AbstractSQLiteStorageOfficer.cpp: src/persistence/AbstractSQLiteStorageOfficer.h
     224        /usr/bin/moc-qt4 $(DEFINES) $(INCPATH) src/persistence/AbstractSQLiteStorageOfficer.h -o release/moc_AbstractSQLiteStorageOfficer.cpp
    155225
    156226compiler_rcc_make_all:
     
    173243####### Compile
    174244
     245release/BCLoginAccountValidator.o: src/business/validation/BCLoginAccountValidator.cpp src/business/validation/BCLoginAccountValidator.h \
     246                src/business/validation/BCStdAccountValidator.h \
     247                src/business/AbstractLoginAccount.h \
     248                src/business/AbstractAccount.h
     249        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/BCLoginAccountValidator.o src/business/validation/BCLoginAccountValidator.cpp
     250
    175251release/AbstractAccount.o: src/business/AbstractAccount.cpp src/business/AbstractAccount.h
    176252        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/AbstractAccount.o src/business/AbstractAccount.cpp
     
    194270        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/HttpCookieManager.o src/business/HttpCookieManager.cpp
    195271
    196 release/AbstractAccountStorageOfficer.o: src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractAccountStorageOfficer.h
     272release/BCValidationResult.o: src/business/validation/BCValidationResult.cpp src/business/validation/BCValidationResult.h
     273        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/BCValidationResult.o src/business/validation/BCValidationResult.cpp
     274
     275release/BCStdAccountValidator.o: src/business/validation/BCStdAccountValidator.cpp src/business/validation/BCStdAccountValidator.h \
     276                src/business/validation/BCValidationResult.h
     277        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/BCStdAccountValidator.o src/business/validation/BCStdAccountValidator.cpp
     278
     279release/BCLoginAccountValidator.o: src/business/validation/BCLoginAccountValidator.cpp src/business/validation/BCLoginAccountValidator.h \
     280                src/business/validation/BCStdAccountValidator.h \
     281                src/business/AbstractLoginAccount.h \
     282                src/business/AbstractAccount.h
     283        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/BCLoginAccountValidator.o src/business/validation/BCLoginAccountValidator.cpp
     284
     285release/AbstractAccountStorageOfficer.o: src/persistence/AbstractAccountStorageOfficer.cpp src/persistence/AbstractAccountStorageOfficer.h \
     286                src/persistence/AbstractSQLiteStorageOfficer.h
    197287        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/AbstractAccountStorageOfficer.o src/persistence/AbstractAccountStorageOfficer.cpp
    198288
    199289release/AbstractLoginAccountStorageOfficer.o: src/persistence/AbstractLoginAccountStorageOfficer.cpp src/persistence/AbstractLoginAccountStorageOfficer.h \
    200                 src/persistence/AbstractAccountStorageOfficer.h
     290                src/persistence/AbstractAccountStorageOfficer.h \
     291                src/persistence/AbstractSQLiteStorageOfficer.h
    201292        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/AbstractLoginAccountStorageOfficer.o src/persistence/AbstractLoginAccountStorageOfficer.cpp
     293
     294release/AbstractSQLiteStorageOfficer.o: src/persistence/AbstractSQLiteStorageOfficer.cpp src/persistence/AbstractSQLiteStorageOfficer.h
     295        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/AbstractSQLiteStorageOfficer.o src/persistence/AbstractSQLiteStorageOfficer.cpp
     296
     297release/moc_BCLoginAccountValidator.o: release/moc_BCLoginAccountValidator.cpp
     298        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_BCLoginAccountValidator.o release/moc_BCLoginAccountValidator.cpp
     299
     300release/moc_AbstractAccount.o: release/moc_AbstractAccount.cpp
     301        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractAccount.o release/moc_AbstractAccount.cpp
     302
     303release/moc_AbstractLoginAccount.o: release/moc_AbstractLoginAccount.cpp
     304        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractLoginAccount.o release/moc_AbstractLoginAccount.cpp
     305
     306release/moc_AbstractGateway.o: release/moc_AbstractGateway.cpp
     307        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractGateway.o release/moc_AbstractGateway.cpp
     308
     309release/moc_AbstractLoginGateway.o: release/moc_AbstractLoginGateway.cpp
     310        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractLoginGateway.o release/moc_AbstractLoginGateway.cpp
    202311
    203312release/moc_HttpHelper.o: release/moc_HttpHelper.cpp
     
    207316        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_HttpCookieManager.o release/moc_HttpCookieManager.cpp
    208317
     318release/moc_BCStdAccountValidator.o: release/moc_BCStdAccountValidator.cpp
     319        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_BCStdAccountValidator.o release/moc_BCStdAccountValidator.cpp
     320
     321release/moc_BCValidationResult.o: release/moc_BCValidationResult.cpp
     322        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_BCValidationResult.o release/moc_BCValidationResult.cpp
     323
     324release/moc_AbstractAccountStorageOfficer.o: release/moc_AbstractAccountStorageOfficer.cpp
     325        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractAccountStorageOfficer.o release/moc_AbstractAccountStorageOfficer.cpp
     326
     327release/moc_AbstractLoginAccountStorageOfficer.o: release/moc_AbstractLoginAccountStorageOfficer.cpp
     328        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractLoginAccountStorageOfficer.o release/moc_AbstractLoginAccountStorageOfficer.cpp
     329
     330release/moc_AbstractSQLiteStorageOfficer.o: release/moc_AbstractSQLiteStorageOfficer.cpp
     331        $(CXX) -c $(CXXFLAGS) $(INCPATH) -o release/moc_AbstractSQLiteStorageOfficer.o release/moc_AbstractSQLiteStorageOfficer.cpp
     332
    209333####### Install
    210334
  • lib/libgateway/gateway.pro

    r33 r41  
    22TEMPLATE = lib
    33CONFIG += staticlib \
    4     precompile_header
     4    thread \
     5    debug_and_release
    56DESTDIR = ../
    67TARGET = gateway
    7 
    8 QT        += core \
     8QT += core \
     9    gui \
    910    network
    1011LIBS += -L../
    11 LIBS += -linterfaces
    12 
     12LIBS += -linterfaces \
     13    -lutils
    1314INCLUDEPATH += app \
     15    ../libinterfaces/src/exceptions/ \
    1416    ../libinterfaces/src/business/ \
    1517    ../libinterfaces/src/ \
    16     ../../src/persistence/ \
    17     ../../src/exceptions/ \
    18     ../../src/utils/
    19 HEADERS   += src/exceptions/ELoginAccountExceptions.h \
     18    ../libutils/src/
     19HEADERS += src/business/validation/BCLoginAccountValidator.h \
    2020    src/business/AbstractAccount.h \
    2121    src/business/AbstractLoginAccount.h \
     
    2424    src/business/HttpHelper.h \
    2525    src/business/HttpCookieManager.h \
     26    src/business/exceptions/ELoginAccountLoginException.h \
     27    src/business/exceptions/LoginAccountExceptions.h \
     28    src/business/validation/BCStdAccountValidator.h \
     29    src/business/validation/BCLoginAccountValidator.h \
     30    src/business/validation/BCValidationResult.h \
     31    src/exceptions/LoginAccountExceptions.h \
    2632    src/persistence/AbstractAccountStorageOfficer.h \
    27     src/persistence/AbstractLoginAccountStorageOfficer.h
    28 SOURCES   += src/business/AbstractAccount.cpp \
     33    src/persistence/AbstractLoginAccountStorageOfficer.h \
     34    src/persistence/AbstractSQLiteStorageOfficer.h
     35SOURCES += src/business/validation/BCLoginAccountValidator.cpp \
     36    src/business/AbstractAccount.cpp \
    2937    src/business/AbstractLoginAccount.cpp \
    3038    src/business/AbstractGateway.cpp \
     
    3240    src/business/HttpHelper.cpp \
    3341    src/business/HttpCookieManager.cpp \
     42    src/business/validation/BCValidationResult.cpp \
     43    src/business/validation/BCStdAccountValidator.cpp \
     44    src/business/validation/BCLoginAccountValidator.cpp \
    3445    src/persistence/AbstractAccountStorageOfficer.cpp \
    35     src/persistence/AbstractLoginAccountStorageOfficer.cpp
    36 FORMS     +=
    37 RESOURCES +=
     46    src/persistence/AbstractLoginAccountStorageOfficer.cpp \
     47    src/persistence/AbstractSQLiteStorageOfficer.cpp
     48FORMS +=
     49RESOURCES +=
  • lib/libgateway/src/business/AbstractAccount.cpp

    r30 r41  
    11
    22#include "AbstractAccount.h"
    3 
    43
    54int AbstractAccount::id() const {
    65    return id_;
    76}
    8 void AbstractAccount::setId(const int& id) {
     7void AbstractAccount::setId(int id) {
    98    id_ = id;
    109}
     
    1413}
    1514void AbstractAccount::setName(const QString& name) {
    16     name_ = name;
     15    name_ = name.trimmed();
    1716}
    1817
    1918
    20 void AbstractAccount::setStatus(const QString& status, const int& progress /* = -1 */, const ProgressMethod& progressMethod /* = SetProgress*/) {
     19void AbstractAccount::setStatus(const QString& status, int progress /* = -1 */, const ProgressMethod& progressMethod /* = SetProgress*/) {
    2120    if (progress > -1) {
    2221        setProgress(progress, progressMethod);
     
    2524    // TODO (inform observer about status change & progress...)
    2625}
    27 void AbstractAccount::setProgress(const int& progress, const ProgressMethod& progressMethod /* = SetProgress */) {
     26void AbstractAccount::setProgress(int progress, const ProgressMethod& progressMethod /* = SetProgress */) {
    2827    switch (progressMethod) {
    2928        case IncProgress:
     
    3938}
    4039
     40bool AbstractAccount::isEnabled() const {
     41    return enabled_;
     42}
     43void AbstractAccount::setEnabled(bool enabled) {
     44    enabled_ = enabled;
     45    if (!enabled) {
     46        unInitialize();
     47    }
     48}
     49
     50
    4151int AbstractAccount::freeSMSCount() const {
    4252    return freeSMSCount_;
    4353}
    44 void AbstractAccount::setFreeSMSCount(const int freeSMSCount) {
     54void AbstractAccount::setFreeSMSCount(int freeSMSCount) {
    4555    freeSMSCount_ = freeSMSCount;
    4656}
    4757
     58IValidator* AbstractAccount::getValidator() const {
     59    return validator_;
     60}
     61ISQLiteStorageOfficer* AbstractAccount::getStorageOfficer() const {
     62    return storageOfficer_;
     63}
     64
     65
    4866
    4967void AbstractAccount::initialize(){
    50     if (initializing_ || initialized_) {
     68    if (initializing_ || initialized_ || !isEnabled()) {
    5169        return;
    5270    }
  • lib/libgateway/src/business/AbstractAccount.h

    r30 r41  
    1010
    1111#include <iaccount.h>
     12#include <persistence/isqlitestorageofficer.h>
    1213
    13 class AbstractAccount: virtual public IAccount {
     14class AbstractAccount: public QObject, virtual public IAccount {
     15    Q_OBJECT
     16    Q_INTERFACES(IAccount)
     17
    1418public:
    15     AbstractAccount()
    16       : freeSMSCount_(-1)
     19    AbstractAccount(ISQLiteStorageOfficer* storageOfficer, IValidator* validator)
     20        : freeSMSCount_(-1)
    1721
    18       , initializing_(false)
    19       , initialized_(false)
    20       , stoppingInitialization_(false)
     22        , enabled_(true)
    2123
    22       , cancelSMSSending_(false)
    23     { };
     24        , initializing_(false)
     25        , initialized_(false)
     26        , stoppingInitialization_(false)
    2427
     28        , cancelSMSSending_(false)
     29        , storageOfficer_(storageOfficer)
     30        , validator_(validator)
     31    {};
    2532
    2633    /* IAccount */
    27     virtual int       id() const;
    28     virtual void      setId(const int& id);
     34    virtual int         id() const;
     35    virtual void        setId(int id);
    2936
    30     virtual QString   name() const;
    31     virtual void      setName(const QString& name);
     37    virtual QString     name() const;
     38    virtual void        setName(const QString& name);
    3239
    33     virtual int       freeSMSCount() const;
     40    virtual bool        isEnabled() const;
     41    virtual void        setEnabled(bool enabled);
    3442
    35     virtual void      initialize();
    36     virtual bool      isInitializing();
    37     virtual bool      isInitialized();
    38     virtual void      stopInitializing();
    39     virtual void      unInitialize();
     43    virtual int         freeSMSCount() const;
    4044
    41     virtual bool      isSendingCanceled();
    42     virtual void      cancelSMSSending();
     45    virtual void        initialize();
     46    virtual bool        isInitializing();
     47    virtual bool        isInitialized();
     48    virtual void        stopInitializing();
     49    virtual void        unInitialize();
     50
     51    virtual bool        isSendingCanceled();
     52    virtual void        cancelSMSSending();
     53
     54    /* IValidatable */
     55    virtual IValidator*            getValidator() const;
     56
     57    /* IStorable */
     58    virtual ISQLiteStorageOfficer* getStorageOfficer() const;
    4359
    4460protected:
    45     virtual void      setStatus(const QString& status, const int& progress = -1, const ProgressMethod& progressMethod = SetProgress);
    46     virtual void      setProgress(const int& progress, const ProgressMethod& progressMethod = SetProgress);
    47     virtual void      setFreeSMSCount(const int freeSMSCount);
     61    virtual void        setStatus(const QString& status, int progress = -1, const ProgressMethod& progressMethod = SetProgress);
     62    virtual void        setProgress(int progress, const ProgressMethod& progressMethod = SetProgress);
     63    virtual void        setFreeSMSCount(const int freeSMSCount);
    4864
    49     virtual void      doInitialize() =0;
     65    virtual void        doInitialize() =0;
    5066
    5167    /* IAccount */
    52     virtual void      uncancelSendingSMS();
     68    virtual void        uncancelSendingSMS();
    5369
    5470private:
    5571    int     id_;
    5672    QString name_;
     73
     74    bool    enabled_;
    5775
    5876    int     progress_;
     
    6482
    6583    bool    cancelSMSSending_;
     84
     85    ISQLiteStorageOfficer* storageOfficer_;
     86    IValidator*            validator_;
    6687};
    6788
  • lib/libgateway/src/business/AbstractGateway.cpp

    r36 r41  
    11#include "AbstractGateway.h"
    2 
    32
    43IAccount* AbstractGateway::createAccountInstance() const {
    54    return createAccountInstance(defaultStorage());
    6 }
    7 IAccount* AbstractGateway::createAccountInstance(IStorage* storage) const {
    8     return createAccountInstance(static_cast<ISQLiteStorage*>(storage));
    95}
    106
  • lib/libgateway/src/business/AbstractGateway.h

    r36 r41  
    1010
    1111#include <igateway.h>
    12 #include <persistence/isqlitestorage.h>
    1312
    14 class AbstractGateway: virtual public IGateway {
     13class AbstractGateway: public QObject, virtual public IGateway {
     14    Q_OBJECT
     15    Q_INTERFACES(IGateway)
     16
    1517public:
    16     virtual IAccount*      createAccountInstance() const;
    17     virtual IAccount*      createAccountInstance(IStorage* storage) const;
    18     virtual IAccount*      createAccountInstance(ISQLiteStorage* storage) const =0;
     18    AbstractGateway()
     19        : defaultStorage_(NULL)
     20    {};
    1921
    20     virtual IStorage*      defaultStorage() const;
    21     virtual void           setDefaultStorage(IStorage* storage);
     22    virtual IAccount* createAccountInstance() const;
     23    virtual IAccount* createAccountInstance(IStorage* storage) const =0;
     24
     25    virtual IStorage* defaultStorage() const;
     26    virtual void      setDefaultStorage(IStorage* storage);
    2227
    2328private:
  • lib/libgateway/src/business/AbstractLoginAccount.cpp

    r28 r41  
    77
    88void AbstractLoginAccount::setUsername(const QString& username){
    9     username_ = username;
     9    username_ = username.trimmed();
    1010}
    1111
     
    2020
    2121
    22 void AbstractLoginAccount::setLoggedIn(const bool& loggedIn) {
     22void AbstractLoginAccount::setLoggedIn(bool loggedIn) {
    2323    loggedIn_ = loggedIn;
    2424}
     
    4545}
    4646
    47 void AbstractLoginAccount::logout(const bool& FORCE /* = false */) {
     47void AbstractLoginAccount::logout(bool FORCE /* = false */) {
    4848    if ((!gateway()->stayLoggedIn() || FORCE) && isLoggedIn()) {
    4949        try {
  • lib/libgateway/src/business/AbstractLoginAccount.h

    r28 r41  
    1212#include "AbstractAccount.h"
    1313
    14 class AbstractLoginAccount: public ILoginAccount, public AbstractAccount {
     14class AbstractLoginAccount: public AbstractAccount, public ILoginAccount {
     15    Q_OBJECT
     16    Q_INTERFACES(ILoginAccount)
     17
    1518public:
    16     AbstractLoginAccount()
    17       : username_("")
     19    AbstractLoginAccount(ISQLiteStorageOfficer* storageOfficer, IValidator* validator)
     20      : AbstractAccount(storageOfficer, validator)
     21
     22      , username_("")
    1823      , password_("")
    1924
     
    3136    virtual bool      isLoggedIn();
    3237    virtual void      login();
    33     virtual void      logout(const bool& FORCE = false);
     38    virtual void      logout(bool FORCE = false);
    3439
    3540protected:
    3641    /* ILoginAccount */
    37     virtual void      setLoggedIn(const bool& loggedIn);
     42    virtual void      setLoggedIn(bool loggedIn);
    3843
    3944    virtual void      doLogin() =0;
  • lib/libgateway/src/business/AbstractLoginGateway.h

    r28 r41  
    1212#include "AbstractGateway.h"
    1313
    14 class AbstractLoginGateway: public ILoginGateway, public AbstractGateway {
     14class AbstractLoginGateway: public AbstractGateway, public ILoginGateway {
     15    Q_OBJECT
     16    Q_INTERFACES(ILoginGateway)
     17
    1518public:
    1619    virtual bool stayLoggedIn() const;
  • lib/libgateway/src/business/HttpCookieManager.cpp

    r36 r41  
    1818    }
    1919
    20     QRegExp rx(domain, Qt::CaseInsensitive, QRegExp::Wildcard);
     20    QRegExp rx(domain_, Qt::CaseInsensitive, QRegExp::Wildcard);
    2121    if (!rx.exactMatch(url.host())) {
    2222        return false;
  • lib/libgateway/src/business/HttpCookieManager.h

    r30 r41  
    99#define HTTPCOOKIEMANAGER_H_
    1010
     11#include <QObject>
    1112#include <QDateTime>
    1213#include <QHttp>
     
    1415#include <QUrl>
    1516
    16 class HttpCookie {
     17class HttpCookie: public QObject {
     18    Q_OBJECT
     19
    1720public:
    1821    HttpCookie()
  • lib/libgateway/src/business/HttpHelper.cpp

    r36 r41  
    143143}*/
    144144
    145 void HttpHelper::waitForRequest(const bool& createIfNotExisting /* = true */) {
     145void HttpHelper::waitForRequest(bool createIfNotExisting /* = true */) {
    146146    if (!requestLoop_.isRunning() && !createIfNotExisting){
    147147        return;
  • lib/libgateway/src/business/HttpHelper.h

    r30 r41  
    4848    virtual int                doRequest(const QString& destination);
    4949    //virtual bool               isRequestFinished() const;
    50     virtual void               waitForRequest(const bool& createIfNotExisting = true);
     50    virtual void               waitForRequest(bool createIfNotExisting = true);
    5151    virtual QString            getRequestResult() const;
    5252
  • lib/libgateway/src/persistence/AbstractAccountStorageOfficer.cpp

    r33 r41  
    2222
    2323void AbstractAccountStorageOfficer::readFromStorage(){
    24 //    AbstractSQLiteStorageOfficer::readFromStorage();
    25 
    2624    try{
    2725        tntdb::Row row = storage()->connection().selectRow(s("SELECT name "
     
    2927                                                               "WHERE (accountId = '" + to_string(account()->id()) + "'); "));
    3028        account()->setName(QString::fromUtf8(row.getString("name").c_str()));
     29        account()->setEnabled(storage()->readBool(getNamespace(), "enabled", true));
    3130    }catch(const tntdb::NotFound& e){
    3231        // No such contact
     
    3635
    3736void AbstractAccountStorageOfficer::writeToStorage() const {
    38 //    AbstractSQLiteStorageOfficer::writeToStorage();
    39 
    4037    tntdb::Result res = storage()->connection().select(s("SELECT accountId "
    4138                                                           "FROM t_accounts "
     
    6158                                          "WHERE (accountId = '" + to_string(account()->id()) + "'); "));
    6259    }
     60    storage()->writeBool(getNamespace(), "enabled", account()->isEnabled());
    6361}
    6462
  • lib/libgateway/src/persistence/AbstractAccountStorageOfficer.h

    r33 r41  
    99#define ABSTRACTACCOUNTSTORAGEOFFICER_H_
    1010
    11 #include <persistence/AbstractSQLiteStorageOfficer.h>
     11#include <QString>
     12
    1213#include <iaccount.h>
    1314
    14 #include <QString>
     15#include "AbstractSQLiteStorageOfficer.h"
    1516
    1617class AbstractAccountStorageOfficer: public AbstractSQLiteStorageOfficer {
     18    Q_OBJECT
     19
    1720public:
    1821    AbstractAccountStorageOfficer(IAccount* account, ISQLiteStorage* storage);
  • lib/libgateway/src/persistence/AbstractLoginAccountStorageOfficer.cpp

    r28 r41  
    1818
    1919ILoginAccount* AbstractLoginAccountStorageOfficer::account() const {
    20     return dynamic_cast<ILoginAccount*>(AbstractAccountStorageOfficer::account()); // has to be a dynamic_cast, since IAccount is included virtually
     20    return reinterpret_cast<ILoginAccount*>(AbstractAccountStorageOfficer::account()); // has to be a reinterpret_cast, since IAccount is included virtually
    2121}
  • lib/libgateway/src/persistence/AbstractLoginAccountStorageOfficer.h

    r28 r41  
    99#define ABSTRACTLOGINACCOUNTSTORAGEOFFICER_H_
    1010
     11#include <iloginaccount.h>
     12#include <persistence/isqlitestorage.h>
     13
    1114#include "AbstractAccountStorageOfficer.h"
    12 #include <iloginaccount.h>
    1315
    1416class AbstractLoginAccountStorageOfficer: public AbstractAccountStorageOfficer {
     17    Q_OBJECT
     18
    1519public:
    16     AbstractLoginAccountStorageOfficer(ILoginAccount* account, ISQLiteStorage* storage)
    17         : AbstractAccountStorageOfficer(account, storage)
    18         , ENCRYPTION_PWD("sdo2o0034_k!Qdoc0DiwnfDaLdY<ymWWpovDmwpovDö__dmkosadDLDd.:easdfDSs")
     20    AbstractLoginAccountStorageOfficer(ILoginAccount* account, ISQLiteStorage* storage, const QString& encryptionPassword)
     21        : AbstractAccountStorageOfficer(reinterpret_cast<IAccount*>(account), storage)
     22        , ENCRYPTION_PWD(encryptionPassword)
    1923    {};
    2024
  • lib/libinterfaces/interfaces.pro

    r36 r41  
    22TEMPLATE = lib
    33CONFIG += staticlib \
    4     precompile_header
     4    thread \
     5    debug_and_release
    56DESTDIR = ../
    67TARGET = interfaces
    78QT += core \
    89    network
    9 INCLUDEPATH += app \
    10     src/interfaces/business/ \
    11     src/interfaces/ \
    12     ../../src/exceptions/ \
    13     ../../src/utils/
     10INCLUDEPATH += app
    1411HEADERS += src/business/iaccount.h \
    1512    src/business/ibinary.h \
     
    2623    src/business/istorable.h \
    2724    src/business/istreamable.h \
     25    src/business/ivalidatable.h \
     26    src/business/ivalidator.h \
     27    src/business/ivalidationresult.h \
     28    src/business/exceptions/EException.h \
     29    src/business/exceptions/EHttpReadException.h \
     30    src/business/exceptions/ELibraryLoadException.h \
     31    src/business/exceptions/EParseException.h \
     32    src/business/exceptions/HttpExceptions.h \
     33    src/business/exceptions/LibraryExceptions.h \
     34    src/business/exceptions/StdExceptions.h \
     35    src/exceptions/HttpExceptions.h \
     36    src/exceptions/LibraryExceptions.h \
     37    src/exceptions/StdExceptions.h \
     38    src/exceptions/StorageExceptions.h \
    2839    src/persistence/iaccountmanager.h \
    2940    src/persistence/icontactmanager.h \
     
    3142    src/persistence/isettings.h \
    3243    src/persistence/isqlitestorage.h \
     44    src/persistence/isqlitestorageofficer.h \
    3345    src/persistence/istorage.h \
    3446    src/persistence/istorageofficer.h \
    35     src/persistence/AbstractSQLiteStorageOfficer.h \
     47    src/persistence/exceptions/EStorageReadException.h \
     48    src/persistence/exceptions/EStorageWriteException.h \
     49    src/persistence/exceptions/StorageExceptions.h \
    3650    src/ui/iaccountsettingswidget.h
    3751SOURCES += src/business/iaccount.cpp \
    3852    src/business/iloginaccount.cpp \
    39     src/business/inumber.cpp \
    40     src/persistence/AbstractSQLiteStorageOfficer.cpp
     53    src/business/inumber.cpp
    4154FORMS +=
    4255RESOURCES +=
  • lib/libinterfaces/src/business/iaccount.h

    r36 r41  
    99#define IACCOUNT_H_
    1010
     11#include <QObject>
     12#include <QString>
     13#include <QList>
     14
    1115#include "istorable.h"
     16#include "ivalidatable.h"
    1217
    1318class IContact;
    1419class IGateway;
    15 
    16 #include <QString>
    17 #include <QSet>
    1820
    1921namespace Account {
     
    2931}
    3032
    31 class IAccount: public IStorable {
     33class IAccount: public IStorable, public IValidatable {
     34    Q_INTERFACES(IStorable IValidatable)
     35
    3236public:
    3337    virtual IGateway* gateway() const =0;
     
    3640
    3741    virtual int       id() const =0;
    38     virtual void      setId(const int& id) =0;
     42    virtual void      setId(int id) =0;
    3943
    4044    virtual QString   name() const =0;
     
    4246
    4347    virtual int       freeSMSCount() const =0;
     48
     49    virtual bool      isEnabled() const =0;
     50    virtual void      setEnabled(bool enabled) =0;
    4451
    4552    virtual void      initialize() =0;
     
    4956    virtual void      unInitialize() =0;
    5057
    51     virtual void      sendSMS(const QString& message, const QSet<IContact*>& recipients) =0;
     58    virtual void      sendSMS(const QString& message, const QList<IContact*>& recipients) =0;
    5259    virtual bool      isSendingCanceled() =0;
    5360    virtual void      cancelSMSSending() =0;
     61
     62    virtual IAccount* getClonedInstance() const =0;
    5463
    5564protected:
     
    5968    };
    6069
    61     virtual void      setStatus(const QString& status, const int& progress = -1, const ProgressMethod& progressMethod = SetProgress) =0;
    62     virtual void      setProgress(const int& progress, const ProgressMethod& progressMethod = SetProgress) =0;
     70    virtual void      setStatus(const QString& status, int progress = -1, const ProgressMethod& progressMethod = SetProgress) =0;
     71    virtual void      setProgress(int progress, const ProgressMethod& progressMethod = SetProgress) =0;
    6372
    6473    virtual void      uncancelSendingSMS() =0;
     
    6877#include "igateway.h"
    6978
     79Q_DECLARE_INTERFACE(IAccount,
     80                     "ch.gorrion.smssender.IAccount/1.0")
    7081
    7182
  • lib/libinterfaces/src/business/ibinary.h

    r29 r41  
    1111#include "iinterface.h"
    1212
     13#include <QObject>
    1314#include <cstddef>
    1415
    1516class IBinary: public IInterface{
     17    Q_INTERFACES(IInterface)
     18
    1619public:
    1720    virtual char*       data() const =0;
     
    2124};
    2225
     26Q_DECLARE_INTERFACE(IBinary,
     27                     "ch.gorrion.smssender.IBinary/1.0")
     28
     29
    2330#endif /* IBINARY_H_ */
  • lib/libinterfaces/src/business/icontact.h

    r29 r41  
    99#define ICONTACT_H_
    1010
     11#include <QObject>
    1112#include <QString>
    1213#include <QStringList>
    1314
    1415#include "iinterface.h"
    15 #include "ibinary.h"
    16 #include "inumber.h"
    1716
    18 class IContact: public IInterface{
     17class IBinary;
     18class INumber;
     19
     20class IContact: public IInterface {
     21    Q_INTERFACES(IStorable IValidatable)
     22
    1923public:
    2024    virtual int         id() const =0;
     
    2428    virtual IBinary*    image() const =0;
    2529
    26     virtual void setID(const int& id)=0;
     30    virtual void setID(int id)=0;
    2731    virtual void setName(const QString& name)=0;
    2832    virtual void setNumber(const INumber& number)=0;
     
    3236};
    3337
     38#include "ibinary.h"
     39#include "inumber.h"
     40
     41Q_DECLARE_INTERFACE(IContact,
     42                     "ch.gorrion.smssender.IContact/1.0")
     43
    3444
    3545#endif /* ICONTACT_H_ */
  • lib/libinterfaces/src/business/igateway.h

    r36 r41  
    99#define IGATEWAY_H_
    1010
    11 /*#ifndef IACCOUNT_H_  // prevent circular reference...
    12     #define IACCOUNT_H_TEMP_
    13     #define IACCOUNT_H_
    14 
    15     class IAccount;
    16 #endif*/
    17 
     11#include <QObject>
    1812#include <QString>
    1913#include <QList>
     
    2519class IContact;
    2620class IAccountSettingsWidget;
    27 class IStorage;
     21
     22#include "../persistence/istorage.h"
    2823
    2924class IGateway: public IInterface {
     25    Q_INTERFACES(IInterface)
     26
    3027public:
    3128    virtual QString        name() const =0;
     
    4643#include "icontact.h"
    4744#include "../ui/iaccountsettingswidget.h"
    48 #include "../persistence/istorage.h"
    4945
    50 /*#ifdef IACCOUNT_H_TEMP_
    51     #undef IACCOUNT_H_
    52     #undef IACCOUNT_H_TEMP_
    53 #endif*/
     46Q_DECLARE_INTERFACE(IGateway,
     47                     "ch.gorrion.smssender.IGateway/1.0")
     48
    5449
    5550#endif /* IGATEWAY_H_ */
  • lib/libinterfaces/src/business/igroup.h

    r29 r41  
    99#define IGROUP_H_
    1010
     11#include <QObject>
    1112#include <QString>
    12 #include <QSet>
     13#include <QList>
    1314
    1415#include "iinterface.h"
     16
     17class IBinary;
     18class IContact;
     19
     20class IGroup: public IInterface {
     21    Q_INTERFACES(IStorable IValidatable)
     22
     23public:
     24    virtual int              id() const =0;
     25    virtual QString          name() const =0;
     26    virtual IBinary*         image() const =0;
     27    virtual QList<IContact*> contacts() const =0;
     28
     29    virtual void setID(int id)=0;
     30    virtual void setName(const QString& name)=0;
     31    virtual void setImage(const IBinary& image)=0;
     32//    virtual void setContacts(const QSet<int>& contactIds)=0;
     33    virtual void setContacts(const QList<IContact*>& contacts)=0;
     34
     35//    virtual void addContact(int contactId)=0;
     36    virtual void addContact(IContact* contact)=0;
     37    virtual void removeContact(int contactId)=0;
     38    virtual void removeContact(IContact* contact)=0;
     39};
     40
    1541#include "ibinary.h"
    1642#include "icontact.h"
    1743
    18 class IGroup: public IInterface {
    19 public:
    20     virtual int             id() const =0;
    21     virtual QString         name() const =0;
    22     virtual IBinary*        image() const =0;
    23     virtual QSet<IContact*> contacts() const =0;
    24 
    25     virtual void setID(const int& id)=0;
    26     virtual void setName(const QString& name)=0;
    27     virtual void setImage(const IBinary& image)=0;
    28     virtual void setContacts(const QSet<int>& contactIds)=0;
    29     virtual void setContacts(const QSet<IContact*>& contacts)=0;
    30 
    31     virtual void addContact(const int& contactId)=0;
    32     virtual void addContact(const IContact& contact)=0;
    33     virtual void removeContact(const int& contactId)=0;
    34     virtual void removeContact(const IContact& contact)=0;
    35 };
    36 
     44Q_DECLARE_INTERFACE(IGroup,
     45                     "ch.gorrion.smssender.IGroup/1.0")
    3746
    3847#endif /* IGROUP_H_ */
  • lib/libinterfaces/src/business/iinterface.h

    r29 r41  
    99#define IINTERFACE_H_
    1010
     11#include <QObject>
     12
    1113class IInterface {
    1214public:
     
    1416};
    1517
     18Q_DECLARE_INTERFACE(IInterface, "ch.gorrion.smssender.IInterface/1.0")
     19
    1620#endif /* IINTERFACE_H_ */
  • lib/libinterfaces/src/business/ilibrary.h

    r29 r41  
    99#define ILIBRARY_H_
    1010
     11#include <QObject>
     12#include <QLocale>
     13#include <QTranslator>
     14
    1115#include "iinterface.h"
    1216#include "igateway.h"
    1317
    14 // The actual major version of the library. Increase this, if something in IAccount or IGateway has changed.
     18// The actual major version of the library. Increase this, if something in the interfaces has changed.
    1519const int LIBRARY_VERSION = 2;
    1620
    1721
    1822class ILibrary: public IInterface {
     23    Q_INTERFACES(IInterface)
     24
    1925public:
    20     int               version() const { return LIBRARY_VERSION; } // To prevent loading of too old/new libraries
     26    int                  version() const { return LIBRARY_VERSION; } // To prevent loading of too old/new libraries
    2127
    22     virtual IGateway* getGateway() const =0;
     28    virtual QTranslator* getTranslator(const QLocale& locale) =0;
     29    virtual IGateway*    getGateway() const =0;
    2330};
     31
     32Q_DECLARE_INTERFACE(ILibrary,
     33                     "ch.gorrion.smssender.ILibrary/1.0")
    2434
    2535
  • lib/libinterfaces/src/business/ilibraryloader.h

    r29 r41  
    99#define ILIBRARYLOADER_H_
    1010
     11#include <QDir>
     12#include <QList>
     13#include <QString>
     14
    1115#include "iinterface.h"
    1216#include "igateway.h"
     17#include "ilibrary.h"
    1318
    1419class ILibraryLoader: public IInterface {
    15     virtual IGateway* getGatewayFromLibrary(const QString& libraryName) =0;
     20    Q_INTERFACES(IInterface)
     21
     22public:
     23    virtual bool      isLibrary(const QString& filename) =0;
     24    virtual ILibrary* loadLibrary(const QString& filename) =0;
     25
     26    virtual void loadLibraries(const QDir& libraryPath) =0;
     27
     28    virtual QList<ILibrary*> libraries() const =0;
     29    virtual QList<IGateway*> gateways() const =0;
    1630};
    1731
    18 
     32Q_DECLARE_INTERFACE(ILibraryLoader,
     33                     "ch.gorrion.smssender.ILibraryLoader/1.0")
    1934
    2035#endif /* ILIBRARYLOADER_H_ */
  • lib/libinterfaces/src/business/iloginaccount.h

    r30 r41  
    1111#include "iaccount.h"
    1212#include "ilogingateway.h"
     13
     14#include <QObject>
    1315#include <QString>
    1416
     
    2224
    2325class ILoginAccount: virtual public IAccount {
     26    Q_INTERFACES(IAccount)
     27
    2428public:
    2529    virtual ILoginGateway* gateway() const =0;
     
    3337    virtual bool      isLoggedIn() =0;
    3438    virtual void      login() =0;
    35     virtual void      logout(const bool& FORCE = false) =0;
     39    virtual void      logout(bool FORCE = false) =0;
    3640
    3741protected:
    38     virtual void      setLoggedIn(const bool& loggedIn) =0;
     42    virtual void      setLoggedIn(bool loggedIn) =0;
    3943};
    4044
     45Q_DECLARE_INTERFACE(ILoginAccount,
     46                     "ch.gorrion.smssender.ILoginAccount/1.0")
     47
    4148#endif /* ILOGINACOUNT_H_ */
  • lib/libinterfaces/src/business/ilogingateway.h

    r29 r41  
    99#define ILOGINGATEWAY_H_
    1010
     11#include <QObject>
     12
    1113#include "igateway.h"
    1214
    1315class ILoginGateway: virtual public IGateway {
     16    Q_INTERFACES(IGateway)
     17
    1418public:
    1519    virtual bool stayLoggedIn() const =0;
    1620};
    1721
     22Q_DECLARE_INTERFACE(ILoginGateway,
     23                     "ch.gorrion.smssender.ILoginGateway/1.0")
     24
    1825#endif /* ILOGINGATEWAY_H_ */
  • lib/libinterfaces/src/business/inumber.h

    r30 r41  
    1111#include "istreamable.h"
    1212
     13#include <QObject>
    1314#include <QString>
    1415
    1516class INumber: public IStreamable{
     17    Q_INTERFACES(IStreamable)
     18
    1619public:
    1720    static const QString IsoFormat;
     
    2427    virtual void    setNumber(const QString& numberStr) =0;
    2528
     29    virtual void    clear() =0;
     30    virtual bool    isEmpty() const =0;
     31    virtual bool    isValid() const =0;
     32    virtual QString error() const =0;
     33
    2634    virtual QString toString(const QString& format = INumber::IsoFormat) const =0;
    2735};
    2836
     37Q_DECLARE_INTERFACE(INumber,
     38                     "ch.gorrion.smssender.INumber/1.0")
     39
    2940#endif /* INUMBER_H_ */
  • lib/libinterfaces/src/business/ishortcut.h

    r29 r41  
    99#define ISHORTCUT_H_
    1010
     11#include <QObject>
     12
    1113#include "istreamable.h"
    1214
     
    1618
    1719class IShortcut: public IStreamable{
     20    Q_INTERFACES(IStreamable)
    1821
    1922public:
     
    2124        virtual char  chr() const =0;
    2225
    23         virtual void setAccessKeys(const short& keyCodes)=0;
    24         virtual void setChar(const char& chr)=0;
     26        virtual void setAccessKeys(short keyCodes)=0;
     27        virtual void setChar(char chr)=0;
    2528};
    2629
     30Q_DECLARE_INTERFACE(IShortcut,
     31                     "ch.gorrion.smssender.IShortcut/1.0")
     32
    2733#endif /* ISHORTCUT_H_ */
  • lib/libinterfaces/src/business/istorable.h

    r29 r41  
    99#define ISTORABLE_H_
    1010
     11#include <QObject>
     12
    1113#include "iinterface.h"
    1214#include "../persistence/istorageofficer.h"
    1315
    14 class IStorable: public IInterface {
     16class IStorable: public virtual IInterface {
     17    Q_INTERFACES(IInterface)
     18
    1519public:
    1620    virtual IStorageOfficer* getStorageOfficer() const =0;
    1721};
    1822
     23Q_DECLARE_INTERFACE(IStorable,
     24                     "ch.gorrion.smssender.IStorable/1.0")
     25
    1926#endif /* ISTORABLE_H_ */
  • lib/libinterfaces/src/business/istreamable.h

    r29 r41  
    99#define ISTREAMABLE_H_
    1010
    11 #include "iinterface.h"
     11#include <QObject>
    1212
    1313#include <iostream>
    1414
     15#include "iinterface.h"
     16
    1517class IStreamable: public IInterface {
     18    Q_INTERFACES(IInterface)
     19
    1620public:
    1721    virtual void readFromStream(std::istream& stream)=0;
     
    2125    friend std::ostream& operator<<(std::ostream&, const IStreamable&);
    2226};
     27
     28Q_DECLARE_INTERFACE(IStreamable,
     29                     "ch.gorrion.smssender.IStreamable/1.0")
    2330
    2431inline std::istream& operator>>(std::istream& in, IStreamable& storable){
  • lib/libinterfaces/src/persistence/iaccountmanager.h

    r33 r41  
    99#define IACCOUNTMANAGER_H_
    1010
     11#include <QObject>
    1112#include <QSet>
    1213
     
    1516
    1617class IAccountManager: public IInterface{
     18    Q_INTERFACES(IInterface)
    1719
    1820public:
    19     virtual IAccount*       getAccount(const int& accountId)=0;
     21    virtual IAccount*       getAccount(int accountId)=0;
    2022    virtual QSet<IAccount*> getAccountList()=0;
    2123
     
    2426};
    2527
     28Q_DECLARE_INTERFACE(IAccountManager,
     29                     "ch.gorrion.smssender.IAccountManager/1.0")
     30
    2631#endif /* IACCOUNTMANAGER_H_ */
  • lib/libinterfaces/src/persistence/icontactmanager.h

    r36 r41  
    99#define ICONTACTMANAGER_H_
    1010
     11#include <QObject>
    1112#include <QMap>
    1213
     
    1516
    1617class IContactManager: public IInterface{
     18    Q_INTERFACES(IInterface)
    1719
    1820public:
    19     virtual IContact*            getContact(const int& contactId)=0;
     21    virtual IContact*            getContact(int contactId)=0;
    2022    virtual QMap<int, IContact*> getContactList()=0;
    2123
    2224    virtual void saveContact(IContact* contact)=0;
    2325    virtual void removeContact(IContact* contact)=0;
    24     virtual void removeContact(const int& contactId)=0;
     26    virtual void removeContact(int contactId)=0;
    2527};
    2628
     29Q_DECLARE_INTERFACE(IContactManager,
     30                     "ch.gorrion.smssender.IContactManager/1.0")
     31
    2732#endif /* ICONTACTMANAGER_H_ */
  • lib/libinterfaces/src/persistence/igroupmanager.h

    r36 r41  
    99#define IGROUPMANAGER_H_
    1010
     11#include <QObject>
    1112#include <QMap>
    1213
     
    1516
    1617class IGroupManager: public IInterface{
     18    Q_INTERFACES(IInterface)
    1719
    1820public:
    19     virtual IGroup*            getGroup(const int& groupId)=0;
     21    virtual IGroup*            getGroup(int groupId)=0;
    2022    virtual QMap<int, IGroup*> getGroupList()=0;
    2123
    2224    virtual void saveGroup(IGroup* group)=0;
    2325    virtual void removeGroup(IGroup* group)=0;
    24     virtual void removeGroup(const int& groupId)=0;
     26    virtual void removeGroup(int groupId)=0;
    2527};
    2628
     29Q_DECLARE_INTERFACE(IGroupManager,
     30                     "ch.gorrion.smssender.IGroupManager/1.0")
     31
    2732#endif /* IGROUPMANAGER_H_ */
  • lib/libinterfaces/src/persistence/isettings.h

    r37 r41  
    99#define ISETTINGS_H_
    1010
     11#include <QObject>
    1112#include <QLocale>
    1213#include <QMap>
     
    1718
    1819class ISettings: public IInterface{
     20    Q_INTERFACES(IInterface)
    1921
    2022public:
     
    4446        virtual void setLocale(const QLocale& locale)=0;
    4547
    46         virtual void setCheckForUpdates(const bool& checkForUpdates)=0;
    47         virtual void setAddSuffix(const bool& addSuffix)=0;
     48        virtual void setCheckForUpdates(bool checkForUpdates)=0;
     49        virtual void setAddSuffix(bool addSuffix)=0;
    4850        virtual void setSMSSuffix(const QString& smsSuffix)=0;
    4951        virtual void setActiveAccountId(const QString& accountId)=0;
    50         virtual void setShowSentConfirmation(const bool& showSentConfirmation)=0;
     52        virtual void setShowSentConfirmation(bool showSentConfirmation)=0;
    5153
    52         virtual void setProxyEnabled(const bool& enabled)=0;
     54        virtual void setProxyEnabled(bool enabled)=0;
    5355        virtual void setProxyHost(const QString& host)=0;
    54         virtual void setProxyPort(const int& port)=0;
    55     virtual void setProxyAuthEnabled(const bool& enabled)=0;
     56        virtual void setProxyPort(int port)=0;
     57    virtual void setProxyAuthEnabled(bool enabled)=0;
    5658        virtual void setProxyUsername(const QString& username)=0;
    5759        virtual void setProxyPassword(const QString& password)=0;
     
    6365};
    6466
     67Q_DECLARE_INTERFACE(ISettings,
     68                     "ch.gorrion.smssender.ISettings/1.0")
     69
    6570#endif /* ISETTINGS_H_ */
  • lib/libinterfaces/src/persistence/isqlitestorage.h

    r29 r41  
    99#define ISQLITESTORAGE_H_
    1010
     11#include <QObject>
     12
    1113#include "istorage.h"
    1214
    1315#include <tntdb/connection.h>
    1416
    15 class ISQLiteStorage: public IStorage{
     17class ISQLiteStorage: public IStorage {
     18    Q_INTERFACES(IStorage)
     19
    1620public:
    1721    virtual tntdb::Connection connection() =0;
    1822};
    1923
     24Q_DECLARE_INTERFACE(ISQLiteStorage,
     25                     "ch.gorrion.smssender.ISQLiteStorage/1.0")
     26
    2027#endif /* ISQLITESTORAGE_H_ */
  • lib/libinterfaces/src/persistence/istorage.h

    r36 r41  
    99#define ISTORAGE_H_
    1010
     11#include <QObject>
    1112#include <QMap>
    1213#include <QString>
     
    2122
    2223class IStorage: public IInterface{
     24    Q_INTERFACES(IInterface)
     25
    2326public:
    2427    virtual IBinary*   readBlob(const QString& _namespace, const QString& key, const char* defaultValue = 0) =0;
    25     virtual bool       readBool(const QString& _namespace, const QString& key, const bool& defaultValue = false) =0;
    26     virtual int        readInt(const QString& _namespace, const QString& key, const int& defaultValue = 0) =0;
     28    virtual bool       readBool(const QString& _namespace, const QString& key, bool defaultValue = false) =0;
     29    virtual int        readInt(const QString& _namespace, const QString& key, int defaultValue = 0) =0;
    2730    virtual QString    readString(const QString& _namespace, const QString& key, const QString& defaultValue = "") =0;
    2831    virtual QString    readEncryptedString(const QString& _namespace, const QString& key, const QString& password, const QString& defaultValue = "") =0;
    29     virtual IContact*  readContact(const int& contactId) =0;
    30     virtual IGroup*    readGroup(const int& groupId) =0;
     32    virtual IContact*  readContact(int contactId) =0;
     33    virtual IGroup*    readGroup(int groupId) =0;
    3134    virtual IShortcut* readShortcut(const QString& key) =0;
    3235
    33     virtual QMap<QString, IAccount*> readAccountList() =0;
    3436    virtual QMap<int, IContact*>     readContactList() =0;
    3537    virtual QMap<int, IGroup*>       readGroupList() =0;
    3638
    37     virtual void writeBlob(const QString& _namespace, const QString& key, const char* value, const int& size) =0;
     39    virtual void writeBlob(const QString& _namespace, const QString& key, const char* value, int size) =0;
    3840    virtual void writeBlob(const QString& _namespace, const QString& key, const IBinary& binary) =0;
    39     virtual void writeBool(const QString& _namespace, const QString& key, const bool& value) =0;
    40     virtual void writeInt(const QString& _namespace, const QString& key, const int& value) =0;
     41    virtual void writeBool(const QString& _namespace, const QString& key, bool value) =0;
     42    virtual void writeInt(const QString& _namespace, const QString& key, int value) =0;
    4143    virtual void writeString(const QString& _namespace, const QString& key, const QString& value) =0;
    4244    virtual void writeEncryptedString(const QString& _namespace, const QString& key, const QString& password, const QString& value) =0;
     
    4951    virtual void removeValues(const QString& _namespace) =0;
    5052
    51     virtual void removeContact(const int& contactId) =0;
    52     virtual void removeGroup(const int& groupId) =0;
     53    virtual void removeContact(int contactId) =0;
     54    virtual void removeGroup(int groupId) =0;
    5355};
    5456
     57Q_DECLARE_INTERFACE(IStorage,
     58                     "ch.gorrion.smssender.IStorage/1.0")
     59
    5560#endif /* ISTORAGE_H_ */
  • lib/libinterfaces/src/persistence/istorageofficer.h

    r33 r41  
    99#define ISTOREOFFICER_H_
    1010
     11#include <QObject>
     12
    1113#include "../business/iinterface.h"
    1214#include "istorage.h"
    1315
    1416class IStorageOfficer: public IInterface {
     17    Q_INTERFACES(IInterface)
     18
    1519public:
    1620    virtual void readFromStorage() =0;
    1721    virtual void writeToStorage() const =0;
    1822    virtual void removeFromStorage() =0;
     23
     24    virtual IStorage* storage() const =0;
    1925};
    2026
     27Q_DECLARE_INTERFACE(IStorageOfficer,
     28                     "ch.gorrion.smssender.IStorageOfficer/1.0")
     29
    2130#endif /* ISTOREOFFICER_H_ */
  • lib/libinterfaces/src/ui/iaccountsettingswidget.h

    r36 r41  
    99#define IACCOUNTSETTINGSWIDGET_H_
    1010
     11#include <QObject>
    1112#include <QWidget>
    1213
    1314#include "../business/iaccount.h"
    1415
    15 class IAccountSettingsWidget: public IInterface, public QWidget {
     16class IAccountSettingsWidget: public QWidget, public IInterface {
     17    Q_OBJECT
     18    Q_INTERFACES(IInterface)
     19
    1620public:
    1721    IAccountSettingsWidget(QWidget* parent = 0)
     
    2529};
    2630
     31Q_DECLARE_INTERFACE(IAccountSettingsWidget,
     32                     "ch.gorrion.smssender.IAccountSettingsWidget/1.0")
     33
    2734#endif /* IACCOUNTSETTINGSWIDGET_H_ */
  • lib/resource.qrc

    r23 r41  
    11<RCC>
    2   <qresource prefix="ico" >
     2  <qresource prefix="ico">
     3    <file>sms_new.png</file>
    34    <file>blank.png</file>
    45    <file>navigate_right.png</file>
Note: See TracChangeset for help on using the changeset viewer.