private EventSubscriptionResponse GetEventSubscriptionResponse(string subscriptionId, string requestedTimeoutString, int timeoutSeconds) { var response = new EventSubscriptionResponse(string.Empty, "text/plain"); response.Headers["SID"] = subscriptionId; response.Headers["TIMEOUT"] = string.IsNullOrEmpty(requestedTimeoutString) ? ("SECOND-" + timeoutSeconds.ToString(CultureInfo.InvariantCulture)) : requestedTimeoutString; return(response); }
private EventSubscriptionResponse GetEventSubscriptionResponse(string subscriptionId, int timeoutSeconds) { var response = new EventSubscriptionResponse { Content = "\r\n", ContentType = "text/plain" }; response.Headers["SID"] = subscriptionId; response.Headers["TIMEOUT"] = "SECOND-" + timeoutSeconds.ToString(_usCulture); return(response); }
private EventSubscriptionResponse GetEventSubscriptionResponse(string subscriptionId, string requestedTimeoutString, int timeoutSeconds) { var response = new EventSubscriptionResponse { Content = string.Empty, ContentType = "text/plain" }; response.Headers["SID"] = subscriptionId; response.Headers["TIMEOUT"] = string.IsNullOrWhiteSpace(requestedTimeoutString) ? ("SECOND-" + timeoutSeconds.ToString(_usCulture)) : requestedTimeoutString; return(response); }
private object GetSubscriptionResponse(EventSubscriptionResponse response) { return(ResultFactory.GetResult(response.Content, response.ContentType, response.Headers)); }