|
reSIProcate/repro
9694
|
00001 #if defined(HAVE_CONFIG_H) 00002 #include "config.h" 00003 #endif 00004 00005 #include <ostream> 00006 #include "resip/stack/SipMessage.hxx" 00007 #include "repro/Processor.hxx" 00008 00009 using namespace resip; 00010 using namespace repro; 00011 using namespace std; 00012 00013 Processor::Processor(const resip::Data& name, ChainType type) : 00014 mType(type), 00015 mName(name) 00016 { 00017 } 00018 00019 Processor::~Processor() 00020 { 00021 } 00022 00023 void 00024 Processor::pushAddress(const std::vector<short>& address) 00025 { 00026 for(std::vector<short>::const_iterator i=address.begin();i!=address.end();++i) 00027 { 00028 mAddress.push_back(*i); 00029 } 00030 } 00031 00032 void 00033 Processor::pushAddress(const short address) 00034 { 00035 mAddress.push_back(address); 00036 } 00037 00038 void 00039 Processor::setChainType(ChainType type) 00040 { 00041 mType=type; 00042 } 00043 00044 Processor::ChainType 00045 Processor::getChainType() const 00046 { 00047 return mType; 00048 } 00049 00050 void 00051 Processor::setName(const resip::Data& name) 00052 { 00053 mName = name; 00054 } 00055 00056 const resip::Data& 00057 Processor::getName() const 00058 { 00059 return mName; 00060 } 00061 00062 const std::vector<short>& 00063 Processor::getAddress() const 00064 { 00065 return mAddress; 00066 } 00067 00068 EncodeStream & 00069 repro::operator << (EncodeStream &os, const repro::Processor &rp) 00070 { 00071 os << rp.getName(); 00072 return os; 00073 } 00074 00075 00076 /* ==================================================================== 00077 * The Vovida Software License, Version 1.0 00078 * 00079 * Copyright (c) 2000 Vovida Networks, Inc. All rights reserved. 00080 * 00081 * Redistribution and use in source and binary forms, with or without 00082 * modification, are permitted provided that the following conditions 00083 * are met: 00084 * 00085 * 1. Redistributions of source code must retain the above copyright 00086 * notice, this list of conditions and the following disclaimer. 00087 * 00088 * 2. Redistributions in binary form must reproduce the above copyright 00089 * notice, this list of conditions and the following disclaimer in 00090 * the documentation and/or other materials provided with the 00091 * distribution. 00092 * 00093 * 3. The names "VOCAL", "Vovida Open Communication Application Library", 00094 * and "Vovida Open Communication Application Library (VOCAL)" must 00095 * not be used to endorse or promote products derived from this 00096 * software without prior written permission. For written 00097 * permission, please contact vocal@vovida.org. 00098 * 00099 * 4. Products derived from this software may not be called "VOCAL", nor 00100 * may "VOCAL" appear in their name, without prior written 00101 * permission of Vovida Networks, Inc. 00102 * 00103 * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED 00104 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 00105 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND 00106 * NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL VOVIDA 00107 * NETWORKS, INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT DAMAGES 00108 * IN EXCESS OF $1,000, NOR FOR ANY INDIRECT, INCIDENTAL, SPECIAL, 00109 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 00110 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 00111 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 00112 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00113 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE 00114 * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH 00115 * DAMAGE. 00116 * 00117 * ==================================================================== 00118 * 00119 * This software consists of voluntary contributions made by Vovida 00120 * Networks, Inc. and many individuals on behalf of Vovida Networks, 00121 * Inc. For more information on Vovida Networks, Inc., please see 00122 * <http://www.vovida.org/>. 00123 * 00124 */
1.7.5.1