ValidateConnectionState method
Implementation
/* private */
void ValidateConnectionState(bool isConnectedExpected, String errorMessage) {
if ((isConnectedExpected && !this.IsOpen) ||
(!isConnectedExpected && this.IsOpen)) {
throw new ServiceLocalException(errorMessage);
}
}