diff --git a/src/account.cpp b/src/account.cpp index ea1fc8ddf8ba8a01f0245b94c4219b351d3cbfd3..3dd17f06387872ae8dd5d9b38ef064b5ff29d11c 100644 --- a/src/account.cpp +++ b/src/account.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/accountcreator.cpp b/src/accountcreator.cpp index aa590244d182bfb9b486145462a60ee81aef5572..3a062af0fdde7c162517be4a18ac71649cb46fc1 100644 --- a/src/accountcreator.cpp +++ b/src/accountcreator.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify @@ -18,9 +19,7 @@ */ #include "accountcreator.h" #include "sipaccount.h" -#ifdef USE_IAX #include "iaxaccount.h" -#endif AccountCreator::AccountCreator() { @@ -40,9 +39,7 @@ AccountCreator::createAccount(AccountType type, AccountID accountID) break; case IAX_ACCOUNT: -#ifdef USE_IAX return new IAXAccount(accountID); -#endif break; } return 0; diff --git a/src/accountcreator.h b/src/accountcreator.h index 105de35c1a63c8573ea9bc54fc18df34c89bb8c7..c7ff65139c87ed24b7859bb54933b7405dbe2f6e 100644 --- a/src/accountcreator.h +++ b/src/accountcreator.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify @@ -43,7 +44,7 @@ public: static Account* createAccount(AccountType type, AccountID accountID); private: - /** Hidden creator */ + /** Hidden constructor */ AccountCreator(); }; diff --git a/src/audio/audiofile.cpp b/src/audio/audiofile.cpp index 00241e6d3b3d2b6d24676e938b49096080417ad2..952ce8a9e16c5e9a7e3aec2747ab07ea9b7d6f6a 100644 --- a/src/audio/audiofile.cpp +++ b/src/audio/audiofile.cpp @@ -1,5 +1,5 @@ -/** - * Copyright (C) 2005 Savoir-Faire Linux inc. +/* + * Copyright (C) 2005-2007 Savoir-Faire Linux inc. * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * Inspired by tonegenerator of diff --git a/src/audio/audiofile.h b/src/audio/audiofile.h index e2dbb169c80215f31326115dfcd2b8d63d2d66bf..778e50c64d2fcdc04e883bc9b1b5bc4ebb772d15 100644 --- a/src/audio/audiofile.h +++ b/src/audio/audiofile.h @@ -1,5 +1,5 @@ -/** - * Copyright (C) 2005 Savoir-Faire Linux inc. +/* + * Copyright (C) 2005-2007 Savoir-Faire Linux inc. * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * Inspired by tonegenerator of diff --git a/src/audio/audiortp.cpp b/src/audio/audiortp.cpp index 6b7d13aeafcbb8e3a5864433bf55da4fe0f989a0..fe6f0833a0d255cee8befe522f04861f1c0ca64b 100644 --- a/src/audio/audiortp.cpp +++ b/src/audio/audiortp.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2004-2005 Savoir-Faire Linux inc. + * Copyright (C) 2004-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> * diff --git a/src/audio/audiortp.h b/src/audio/audiortp.h index bc5d4b0728dcaa1729db3fc0ab4bff92bd75c2d8..4b018276929b5a2c63d95bcb79027a1ffc3c8580 100644 --- a/src/audio/audiortp.h +++ b/src/audio/audiortp.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2004-2005 Savoir-Faire Linux inc. + * Copyright (C) 2004-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> * diff --git a/src/audio/codecDescriptor.cpp b/src/audio/codecDescriptor.cpp index 0b1032f36505495ad0ca21db24f4a2f8d66ca76b..c04821faebda978eb4787908ac8ee26001067bf8 100644 --- a/src/audio/codecDescriptor.cpp +++ b/src/audio/codecDescriptor.cpp @@ -1,4 +1,4 @@ -/** +/* * Copyright (C) 2004-2005 Savoir-Faire Linux inc. * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> diff --git a/src/audio/codecDescriptor.h b/src/audio/codecDescriptor.h index 95c525566c44acbc52d23534d203d2f3d07479d2..8d0078014be52fcf3a97e9057c7fe9291f44c382 100644 --- a/src/audio/codecDescriptor.h +++ b/src/audio/codecDescriptor.h @@ -1,4 +1,4 @@ -/** +/* * Copyright (C) 2004-2005 Savoir-Faire Linux inc. * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> diff --git a/src/audio/common.h b/src/audio/common.h index 5594a1a00bd626508088b4c2efcbea41dcdae8dd..c574ae15c25c750a062df73ce8110830264ac000 100644 --- a/src/audio/common.h +++ b/src/audio/common.h @@ -1,4 +1,4 @@ -/** +/* * Copyright (C) 2004-2005 Savoir-Faire Linux inc. * Author: * diff --git a/src/audio/dtmfgenerator.cpp b/src/audio/dtmfgenerator.cpp index ec667d44c4c5aeae1203fa607742dba92deb8ee0..3b36bac57a79034b7edfbeb7c7593b5a86071e1a 100644 --- a/src/audio/dtmfgenerator.cpp +++ b/src/audio/dtmfgenerator.cpp @@ -1,4 +1,4 @@ -/** +/* * Copyright (C) 2004-2005 Savoir-Faire Linux inc. * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> diff --git a/src/audio/ringbuffer.h b/src/audio/ringbuffer.h index 1faa54ae9a86ea241b372efc6e5a9601cf348624..281744772570e1d8e996bd105f48202d78929c78 100644 --- a/src/audio/ringbuffer.h +++ b/src/audio/ringbuffer.h @@ -1,4 +1,4 @@ -/** +/* * Copyright (C) 2004-2005 Savoir-Faire Linux inc. * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author : Laurielle Lea <laurielle.lea@savoirfairelinux.com> diff --git a/src/config/config.cpp b/src/config/config.cpp index 8f307be010c89f729c5bd607397a1765200454f4..136e9043ebe01977fa916e6186b21ab68c9d8136 100644 --- a/src/config/config.cpp +++ b/src/config/config.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2005 Savoir-Faire Linux inc. + * Copyright (C) 2005-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/config/config.h b/src/config/config.h index 9171470c081ca23a006dfc20c8b6adcc9a5d715c..b201ac27117182ec0c073d232013930a9cb7185d 100644 --- a/src/config/config.h +++ b/src/config/config.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2005-2006 Savoir-Faire Linux inc. + * Copyright (C) 2005-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify @@ -64,7 +65,27 @@ public: ~ConfigTree(); void createSection(const std::string& section); + + /** + * Return an array of strings, listing the sections of the config file + * + * This will be mainly used to filter which sections are an + * "Account" definition. + * + * @return array Strings of the sections + */ + TokenList getSections(); + void addConfigTreeItem(const std::string& section, const ConfigTreeItem item); + /** + * Verify an item is there. If it's not, add it with the provided + * default value + * + * @param section Section + * @param + */ + void verifyConfigTreeItem(const std::string& section, const std::string& itemName, + const std::string& defaultValue, const std::string& type); bool setConfigTreeItem(const std::string& section, const std::string& itemName, const std::string& value); // throw a ConfigTreeItemException if not found diff --git a/src/dbus/callmanager.cpp b/src/dbus/callmanager.cpp index 9b073950b763f78b7797c792c1335dc21142e352..70bdeabb3b69f26dbdd33bf4fef28d11f1682865 100644 --- a/src/dbus/callmanager.cpp +++ b/src/dbus/callmanager.cpp @@ -1,6 +1,7 @@ /* * Copyright (C) 2007 Savoir-Faire Linux inc. * Author: Pierre-Luc Beaudoin <pierre-luc.beaudoin@savoirfairelinux.com> + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/dbus/configurationmanager.h b/src/dbus/configurationmanager.h index 2a6a41121e529bd492925bb33731d203de97c8ca..53b84ff39c7baaa88822e135927f068c1f4157af 100644 --- a/src/dbus/configurationmanager.h +++ b/src/dbus/configurationmanager.h @@ -1,6 +1,7 @@ /* * Copyright (C) 2007 Savoir-Faire Linux inc. * Author: Pierre-Luc Beaudoin <pierre-luc.beaudoin@savoirfairelinux.com> + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/iaxaccount.cpp b/src/iaxaccount.cpp index 78863ebefccf0d4ee9cc58a7248d7c724dd5c1a7..88c12f5b4ee78a7f50a0cf1514ef34c417f49b79 100644 --- a/src/iaxaccount.cpp +++ b/src/iaxaccount.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/iaxaccount.h b/src/iaxaccount.h index af6090547b3c1887f5f717d5e3a320ef3b12a1c1..663ba07751fcec6150f7ccbca682aafed79eb8aa 100644 --- a/src/iaxaccount.h +++ b/src/iaxaccount.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/iaxcall.cpp b/src/iaxcall.cpp index 3a0e1d457612c2ddc60003ba438246d6bcb1d700..0388d5cb1ff9869afdad7d5de118e9c2ba172901 100644 --- a/src/iaxcall.cpp +++ b/src/iaxcall.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/iaxcall.h b/src/iaxcall.h index 5fb10c3cb966587b9175c4464ed5f0cbebe3c7e9..bc27117ac036fd8515e3f42a7f033c4b0b35aa89 100644 --- a/src/iaxcall.h +++ b/src/iaxcall.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/iaxvoiplink.cpp b/src/iaxvoiplink.cpp index 6232fea44375923044df695d3c6c84df6fc68cf9..164c3afcfdf5ce0c5410a131617d9a96be32b67e 100644 --- a/src/iaxvoiplink.cpp +++ b/src/iaxvoiplink.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/iaxvoiplink.h b/src/iaxvoiplink.h index 9105148aa42698262f7738ddbba6226418715416..7ce9caa956f2caa184774ba278b7e0833eb12648 100644 --- a/src/iaxvoiplink.h +++ b/src/iaxvoiplink.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/main.cpp b/src/main.cpp index 393a466468c72f5e90dd776598f4db6ab3a0dc1d..0247fa23a769c9d1165dca8e9efecaa89a42151b 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2004-2005 Savoir-Faire Linux inc. + * Copyright (C) 2004-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> * diff --git a/src/managerimpl.cpp b/src/managerimpl.cpp index 77050c1e06715d4fdbe503892d34dc901cf3b6f3..af34a57324eda0a6c456fad316ccda8fac71fc50 100644 --- a/src/managerimpl.cpp +++ b/src/managerimpl.cpp @@ -1,18 +1,19 @@ /* - * Copyright (C) 2004-2006 Savoir-Faire Linux inc. + * Copyright (C) 2004-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> - * Author : Laurielle Lea <laurielle.lea@savoirfairelinux.com> - * + * Author: Laurielle Lea <laurielle.lea@savoirfairelinux.com> + * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. diff --git a/src/managerimpl.h b/src/managerimpl.h index a7b6b5062bef5fe25dd8beae648a47ca2af491cc..4af45ccf58faa517977f79a8d0ba1ea38031a5a5 100644 --- a/src/managerimpl.h +++ b/src/managerimpl.h @@ -81,25 +81,29 @@ public: ManagerImpl (void); ~ManagerImpl (void); - // Init a new VoIPLink, audio codec and audio driver /** - * Initialisation of thread (sound) and map + * Initialisation of thread (sound) and map. + * + * Init a new VoIPLink, audio codec and audio driver */ void init (void); /** - * Terminate all thread (sound, link) and clear map + * Terminate all thread (sound, link) and unload AccountMap */ void terminate (void); /** - * Set the graphic user interface : only GuiServer right now - * @param gui A GuiFramework gui implmentation + * Set user interface manaager. + * @param man The DBUS interface implementation */ void setDBusManager (DBusManagerImpl* man) { _dbus = man; } - // Accessor to audiodriver - // it's multi-thread and use mutex internally + /** + * Accessor to audiodriver. + * + * it's multi-thread and use mutex internally + */ AudioLayer* getAudioDriver(void) const { return _audiodriver; } /** @@ -121,21 +125,29 @@ public: void unmute(); bool refuseCall(const CallID& id); - /** Save config on file */ + /** Save config to file */ bool saveConfig (void); + /** - * Initialize action (main thread) + * Send registration information (shake hands) for a specific AccountID + * * @param accountId Account to register * @return true if setRegister is call without failure, else return false */ bool registerVoIPLink(const AccountID& accountId); /** - * Unregister an account + * Send unregistration for a specific account. If the protocol + * doesn't need to send anything, then the state of the account + * will be set to 'Unregistered', and related objects destroyed. + * * @param accountId Account to unregister * @return true if the unregister method is send correctly */ bool unregisterVoIPLink(const AccountID& accountId); + /** + * Undocumented + */ bool sendTextMessage(const AccountID& accountId, const std::string& to, const std::string& message); /* @@ -178,8 +190,15 @@ public: void registrationFailed(const AccountID& accountId); // configuration function requests - /** Start events thread*/ - // TODO: receive account name + + /** + * Start events thread. This function actually only calls the private + * initRegisterVoIPLink(). + * + * This function should definitively be renamed! + * + * @todo Receive account name (???) + */ bool getEvents(); // @@ -283,9 +302,12 @@ public: */ bool behindNat(const std::string& svr, int port); - /** - * Init default values for the different fields - */ + /** + * Init default values for the different fields in the config file. + * Fills the local _config (Conf::ConfigTree) with the default contents. + * + * Called in main.cpp, just before Manager::init(). + */ void initConfigFile (void); /** diff --git a/src/sipaccount.cpp b/src/sipaccount.cpp index 480c21af90be7e2d1406dd8e73f9cd1b5c3cf77c..b56d37546f71c93a41e8d81d41636f2c0f28ab09 100644 --- a/src/sipaccount.cpp +++ b/src/sipaccount.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/sipaccount.h b/src/sipaccount.h index 9a0ccea8b77ff1f8de408cc267f920ddadf4b7c2..0c9e4b511b9edb39f7a9635a1fc32e4d50d76b5d 100644 --- a/src/sipaccount.h +++ b/src/sipaccount.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2006 Savoir-Faire Linux inc. + * Copyright (C) 2006-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * * This program is free software; you can redistribute it and/or modify diff --git a/src/sipcall.cpp b/src/sipcall.cpp index 9a556111174c5f86ed44822e873e121cddb18864..36010b4d73fc60b856d4bdbc26cbf0e3fdf38a97 100644 --- a/src/sipcall.cpp +++ b/src/sipcall.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2004-2006 Savoir-Faire Linux inc. + * Copyright (C) 2004-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author : Laurielle Lea <laurielle.lea@savoirfairelinux.com> * diff --git a/src/sipcall.h b/src/sipcall.h index 521297b060d907abda8ee0e3caf8556606ec1cca..e2c40c1a1c662f7a996d71e195e5a610a8748c86 100644 --- a/src/sipcall.h +++ b/src/sipcall.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2004-2006 Savoir-Faire Linux inc. + * Copyright (C) 2004-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author : Laurielle Lea <laurielle.lea@savoirfairelinux.com> * diff --git a/src/voiplink.cpp b/src/voiplink.cpp index 61a3a4cc7cb4bd30d33c66fd982c6a84ca8ab4ed..e72845b8384bfdd3869ab0471ccdd1878f194bfe 100644 --- a/src/voiplink.cpp +++ b/src/voiplink.cpp @@ -1,5 +1,6 @@ /* - * Copyright (C) 2005-2006 Savoir-Faire Linux inc. + * Copyright (C) 2005-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author : Laurielle Lea <laurielle.lea@savoirfairelinux.com> * diff --git a/src/voiplink.h b/src/voiplink.h index 9f74bdbeb0345b1f942c162ac5c8ca011bcff479..69fc30530af817559109817e7d816ade27bb975a 100644 --- a/src/voiplink.h +++ b/src/voiplink.h @@ -1,5 +1,6 @@ /* - * Copyright (C) 2005-2006 Savoir-Faire Linux inc. + * Copyright (C) 2005-2007 Savoir-Faire Linux inc. + * Author: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> * Author: Yan Morin <yan.morin@savoirfairelinux.com> * Author : Laurielle Lea <laurielle.lea@savoirfairelinux.com> *