public void setup()
 {
     getPublicContainerInformation = new GetPublicContainerInformation("http://storageurl", "containername");
 }
Esempio n. 2
0
        private Container getPublicContainerInformation(string containerName)
        {
            var request = new GetPublicContainerInformation(CdnManagementUrl, containerName);
            var response = _requestfactory.Submit(request, AuthToken);

            if (!HasCDN())
            return null;

            return response == null ? null
                       : new Container(containerName)
                             {
                                 CdnUri = response.Headers[Constants.X_CDN_URI],
                                 CdnSslUri = response.Headers[Constants.X_CDN_SSL_URI],
                                 CdnStreamingUri = response.Headers[Constants.X_CDN_STREAMING_URI],
                                 TTL = Convert.ToInt32(response.Headers[Constants.X_CDN_TTL])
                             };
        }