Emeric Vigier | 2f62582 | 2012-08-06 11:09:52 -0400 | [diff] [blame] | 1 | // Copyright (C) 2000-2005 Open Source Telecom Corporation. |
| 2 | // Copyright (C) 2006-2008 David Sugar, Tycho Softworks. |
| 3 | // |
| 4 | // This program is free software; you can redistribute it and/or modify |
| 5 | // it under the terms of the GNU General Public License as published by |
| 6 | // the Free Software Foundation; either version 2 of the License, or |
| 7 | // (at your option) any later version. |
| 8 | // |
| 9 | // This program is distributed in the hope that it will be useful, |
| 10 | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 | // GNU General Public License for more details. |
| 13 | // |
| 14 | // You should have received a copy of the GNU General Public License |
| 15 | // along with this program; if not, write to the Free Software |
| 16 | // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
| 17 | |
| 18 | #include "server.h" |
| 19 | |
| 20 | #ifdef CCXX_NAMESPACES |
| 21 | namespace ost { |
| 22 | #endif |
| 23 | |
| 24 | KeyThreads::KeyThreads() : |
| 25 | Keydata("/phone/threads") |
| 26 | { |
| 27 | static Keydata::Define defkeys[] = { |
| 28 | {"audio", "0"}, |
| 29 | {"priority", "0"}, |
| 30 | {"rtp", "0"}, |
| 31 | {"gui", "0"}, |
| 32 | {"policy", "other"}, |
| 33 | {"stack", "8"}, |
| 34 | {NULL, NULL}}; |
| 35 | |
| 36 | load("~phone/threads"); |
| 37 | load(defkeys); |
| 38 | |
| 39 | const char *cp = getLast("pri"); |
| 40 | |
| 41 | if(cp) |
| 42 | setValue("priority", cp); |
| 43 | } |
| 44 | |
| 45 | KeyRTP::KeyRTP() : |
| 46 | Keydata("/phone/rtp") |
| 47 | { |
| 48 | static Keydata::Define defkeys[] = { |
| 49 | {"interface", "*"}, |
| 50 | {"multicast", "*"}, |
| 51 | {"port", "3128"}, |
| 52 | {NULL, NULL}}; |
| 53 | |
| 54 | load("~phone/rtp"); |
| 55 | load(defkeys); |
| 56 | } |
| 57 | |
| 58 | KeyAudio::KeyAudio() : |
| 59 | Keydata("/phone/audio") |
| 60 | { |
| 61 | static Keydata::Define defkeys[] = { |
| 62 | {"interface", "oss"}, |
| 63 | {"device", "/dev/audio"}, |
| 64 | {"mike", "80"}, |
| 65 | {"speaker", "80"}, |
| 66 | {NULL, NULL}}; |
| 67 | |
| 68 | load("~phone/audio"); |
| 69 | load(defkeys); |
| 70 | } |
| 71 | |
| 72 | KeyThreads keythreads; |
| 73 | KeyAudio keyaudio; |
| 74 | KeyRTP keyrtp; |
| 75 | |
| 76 | #ifdef CCXX_NAMESPACES |
| 77 | } |
| 78 | #endif |