📄 profile.cxx
字号:
mOutboundProxy = NameAddr(tmpUri); mHasOutboundProxy = true;}const NameAddr&Profile::getOutboundProxy() const{ // Fall through seting (if required) if(!mHasOutboundProxy && mBaseProfile.get()) { return mBaseProfile->getOutboundProxy(); } assert(mHasOutboundProxy); return mOutboundProxy;}boolProfile::hasOutboundProxy() const{ // Fall through seting (if required) if(!mHasOutboundProxy && mBaseProfile.get()) { return mBaseProfile->hasOutboundProxy(); } return mHasOutboundProxy;}voidProfile::unsetOutboundProxy(){ if(mBaseProfile.get()) { mHasOutboundProxy = false; } else // No Base profile - so return to default setting { mHasOutboundProxy = false; }}void Profile::setRportEnabled(bool enabled){ mRportEnabled = enabled; mHasRportEnabled = true;}bool Profile::getRportEnabled() const{ // Fall through seting (if required) if(!mHasRportEnabled && mBaseProfile.get()) { return mBaseProfile->getRportEnabled(); } return mRportEnabled;}voidProfile::unsetRportEnabled(){ if(mBaseProfile.get()) { mHasRportEnabled = false; } else // No Base profile - so return to default setting { mHasRportEnabled = true; mRportEnabled = true; }}void Profile::setUserAgent( const Data& userAgent ){ mUserAgent = userAgent; mHasUserAgent = true; }const Data& Profile::getUserAgent() const{ // Fall through seting (if required) if(!mHasUserAgent && mBaseProfile.get()) { return mBaseProfile->getUserAgent(); } assert(mHasUserAgent); return mUserAgent;} bool Profile::hasUserAgent() const{ // Fall through seting (if required) if(!mHasUserAgent && mBaseProfile.get()) { return mBaseProfile->hasUserAgent(); } return mHasUserAgent;}voidProfile::unsetUserAgent(){ if(mBaseProfile.get()) { mHasUserAgent = false; } else // No Base profile - so return to default setting { mHasUserAgent = false; }}void Profile::setProxyRequires( const Tokens& proxyRequires ){ mProxyRequires = proxyRequires; mHasProxyRequires = true; }const Tokens& Profile::getProxyRequires() const{ // Fall through seting (if required) if(!mHasProxyRequires && mBaseProfile.get()) { return mBaseProfile->getProxyRequires(); } assert(mHasProxyRequires); return mProxyRequires;} bool Profile::hasProxyRequires() const{ // Fall through seting (if required) if(!mHasProxyRequires && mBaseProfile.get()) { return mBaseProfile->hasProxyRequires(); } return mHasProxyRequires;}voidProfile::unsetProxyRequires(){ if(mBaseProfile.get()) { mHasProxyRequires = false; } else // No Base profile - so return to default setting { mHasProxyRequires = false; }}void Profile::setKeepAliveTimeForDatagram(int keepAliveTime){ mKeepAliveTimeForDatagram = keepAliveTime; mHasKeepAliveTimeForDatagram = true;}int Profile::getKeepAliveTimeForDatagram() const{ // Fall through seting (if required) if(!mHasKeepAliveTimeForDatagram && mBaseProfile.get()) { return mBaseProfile->getKeepAliveTimeForDatagram(); } return mKeepAliveTimeForDatagram;}voidProfile::unsetKeepAliveTimeForDatagram(){ if(mBaseProfile.get()) { mHasKeepAliveTimeForDatagram = false; } else // No Base profile - so return to default setting { mHasKeepAliveTimeForDatagram = true; mKeepAliveTimeForDatagram = 30; // 30 seconds. }}void Profile::setKeepAliveTimeForStream(int keepAliveTime){ mKeepAliveTimeForStream = keepAliveTime; mHasKeepAliveTimeForStream = true;}int Profile::getKeepAliveTimeForStream() const{ // Fall through seting (if required) if(!mHasKeepAliveTimeForStream && mBaseProfile.get()) { return mBaseProfile->getKeepAliveTimeForStream(); } return mKeepAliveTimeForStream;}voidProfile::unsetKeepAliveTimeForStream(){ if(mBaseProfile.get()) { mHasKeepAliveTimeForStream = false; } else // No Base profile - so return to default setting { mHasKeepAliveTimeForStream = true; mKeepAliveTimeForStream = 180; // 3 minutes. }}void Profile::setFixedTransportPort(int fixedTransportPort){ mFixedTransportPort = fixedTransportPort; mHasFixedTransportPort = true;}int Profile::getFixedTransportPort() const{ // Fall through seting (if required) if(!mHasFixedTransportPort && mBaseProfile.get()) { return mBaseProfile->getFixedTransportPort(); } return mFixedTransportPort;}voidProfile::unsetFixedTransportPort(){ if(mBaseProfile.get()) { mHasFixedTransportPort = false; } else // No Base profile - so return to default setting { mHasFixedTransportPort = true; mFixedTransportPort = 0; }}void Profile::setFixedTransportInterface(const Data& fixedTransportInterface){ mFixedTransportInterface = fixedTransportInterface; mHasFixedTransportInterface = true;}const Data&Profile::getFixedTransportInterface() const{ // Fall through seting (if required) if(!mHasFixedTransportInterface && mBaseProfile.get()) { return mBaseProfile->getFixedTransportInterface(); } return mFixedTransportInterface;}voidProfile::unsetFixedTransportInterface(){ if(mBaseProfile.get()) { mHasFixedTransportInterface = false; } else // No Base profile - so return to default setting { mHasFixedTransportInterface = true; mFixedTransportInterface = Data::Empty; }}void Profile::setRinstanceEnabled(bool enabled){ mRinstanceEnabled = enabled; mHasRinstanceEnabled = true;}bool Profile::getRinstanceEnabled() const{ // Fall through seting (if required) if(!mHasRinstanceEnabled && mBaseProfile.get()) { return mBaseProfile->getRinstanceEnabled(); } return mRinstanceEnabled;}voidProfile::unsetRinstanceEnabled(){ if(mBaseProfile.get()) { mHasRinstanceEnabled = false; } else { mHasRinstanceEnabled = true; mRinstanceEnabled = true; }} ////If set then dum will add this MessageDecorator to all outbound messages //virtual void setOutboundDecorator(SharedPtr<MessageDecorator> outboundDecorator); //virtual SharedPtr<MessageDecorator> getOutboundDecorator(); //virtual void unsetOutboundDecorator();void Profile::setOutboundDecorator(SharedPtr<MessageDecorator> outboundDecorator){ mOutboundDecorator = outboundDecorator; mHasOutboundDecorator = true;}SharedPtr<MessageDecorator> Profile::getOutboundDecorator(){ // Fall through seting (if required) if(!mHasOutboundDecorator && mBaseProfile.get()) { return mBaseProfile->getOutboundDecorator(); } return mOutboundDecorator;}voidProfile::unsetOutboundDecorator(){ if (mHasOutboundDecorator) { mOutboundDecorator.reset(); } mHasOutboundDecorator = false;}void Profile::setMethodsParamEnabled(bool enabled){ mMethodsParamEnabled = enabled; mHasMethodsParamEnabled = true;}bool Profile::getMethodsParamEnabled() const{ // Fall through seting (if required) if(!mHasMethodsParamEnabled && mBaseProfile.get()) { return mBaseProfile->getMethodsParamEnabled(); } return mMethodsParamEnabled;}voidProfile::unsetMethodsParamEnabled(){ if(mBaseProfile.get()) { mHasMethodsParamEnabled = false; } else { mHasMethodsParamEnabled = true; mMethodsParamEnabled = false; }} void Profile::setExpressOutboundAsRouteSetEnabled(bool enabled){ mExpressOutboundAsRouteSetEnabled = enabled; mHasExpressOutboundAsRouteSetEnabled = true;}bool Profile::getExpressOutboundAsRouteSetEnabled() const{ // Fall through seting (if required) if(!mHasExpressOutboundAsRouteSetEnabled && mBaseProfile.get()) { return mBaseProfile->getExpressOutboundAsRouteSetEnabled(); } return mExpressOutboundAsRouteSetEnabled;}voidProfile::unsetExpressOutboundAsRouteSetEnabled(){ if(mBaseProfile.get()) { mHasExpressOutboundAsRouteSetEnabled = false; } else { mHasExpressOutboundAsRouteSetEnabled = true; mExpressOutboundAsRouteSetEnabled = false; }} /* ==================================================================== * The Vovida Software License, Version 1.0 * * Copyright (c) 2000 Vovida Networks, Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The names "VOCAL", "Vovida Open Communication Application Library", * and "Vovida Open Communication Application Library (VOCAL)" must * not be used to endorse or promote products derived from this * software without prior written permission. For written * permission, please contact vocal@vovida.org. * * 4. Products derived from this software may not be called "VOCAL", nor * may "VOCAL" appear in their name, without prior written * permission of Vovida Networks, Inc. * * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND * NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL VOVIDA * NETWORKS, INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT DAMAGES * IN EXCESS OF $1,000, NOR FOR ANY INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * DAMAGE. * * ==================================================================== * * This software consists of voluntary contributions made by Vovida * Networks, Inc. and many individuals on behalf of Vovida Networks, * Inc. For more information on Vovida Networks, Inc., please see * <http://www.vovida.org/>. * */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -