static private ReplaceMachineNameWithThisString ( String url, String newMachineName ) : String | ||
url | String | |
newMachineName | String | |
return | String |
/// <include file='doc\HttpServerChannel.uex' path='docs/doc[@for="HttpServerChannel.AddHookChannelUri"]/*' /> public void AddHookChannelUri(String channelUri) { if (_channelData.ChannelUris != null) { throw new RemotingException( CoreChannel.GetResourceString("Remoting_Http_LimitListenerOfOne")); } else { // replace machine name with explicitly configured // machine name or ip address if necessary if (_forcedMachineName != null) { channelUri = HttpChannelHelper.ReplaceMachineNameWithThisString(channelUri, _forcedMachineName); } else if (_bUseIpAddress) { channelUri = HttpChannelHelper.ReplaceMachineNameWithThisString(channelUri, CoreChannel.GetMachineIp()); } _channelData.ChannelUris = new String[] { channelUri }; _wantsToListen = false; _bHooked = true; } } // AddHookChannelUri
public void AddHookChannelUri(string channelUri) { if (this._channelData.ChannelUris != null) { throw new RemotingException(CoreChannel.GetResourceString("Remoting_Http_LimitListenerOfOne")); } if (this._forcedMachineName != null) { channelUri = HttpChannelHelper.ReplaceMachineNameWithThisString(channelUri, this._forcedMachineName); } else if (this._bUseIpAddress) { channelUri = HttpChannelHelper.ReplaceMachineNameWithThisString(channelUri, CoreChannel.GetMachineIp()); } this._channelData.ChannelUris = new string[] { channelUri }; this._wantsToListen = false; this._bHooked = true; }