コード例 #1
0
 public void WriteToContextAndFlush(IContextResponse response)
 {
     response.Clear();
     response.ContentType = ContentType;
     using (XmlWriter writer = response.CreateXmlWriter())
         Capabilities.WriteTo(writer);
     response.End();
 }
コード例 #2
0
 public void WriteToContextAndFlush(IContextResponse response)
 {
     response.Clear();
     response.ContentType = ContentType;
     using (XmlWriter writer = response.CreateXmlWriter())
         Capabilities.WriteTo(writer);
     response.End();
 }
コード例 #3
0
 public void WriteToContextAndFlush(IContextResponse response)
 {
     response.Clear();
     if (Charset != null)
     {
         //"windows-1252";
         response.Charset = Charset;
     }
     response.BufferOutput = _bufferOutput;
     response.Write(Response);
     response.End();
 }
コード例 #4
0
 public void WriteToContextAndFlush(IContextResponse response)
 {
     response.Clear();
     if (Charset != null)
     {
         //"windows-1252";
         response.Charset = Charset;
     }
     response.BufferOutput = _bufferOutput;
     response.Write(Response);
     response.End();
 }
コード例 #5
0
 public virtual void WriteToContextAndFlush(IContextResponse response)
 {
     response.Clear();
     response.ContentType = "text/xml";
     response.Write("<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n");
     response.Write(
         "<ServiceExceptionReport version=\"1.3.0\" xmlns=\"http://www.opengis.net/ogc\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:schemaLocation=\"http://www.opengis.net/ogc http://schemas.opengis.net/wms/1.3.0/exceptions_1_3_0.xsd\">\n");
     response.Write("<ServiceException");
     if (ExceptionCode != WmsExceptionCode.NotApplicable)
         response.Write(" code=\"" + ExceptionCode + "\"");
     response.Write(">" + Message + "</ServiceException>\n");
     response.Write("</ServiceExceptionReport>");
     response.End();
 }
コード例 #6
0
ファイル: GetMapResponse.cs プロジェクト: cugkgq/Project
 public void WriteToContextAndFlush(IContextResponse response)
 {
     //Png can't stream directy. Going through a memorystream instead
     byte[] buffer;
     using (MemoryStream ms = new MemoryStream())
     {
         Image.Save(ms, CodecInfo, null);
         Image.Dispose();
         buffer = ms.ToArray();
     }
     response.Clear();
     response.ContentType = CodecInfo.MimeType;
     response.Write(buffer);
     response.End();
 }
コード例 #7
0
ファイル: GetMapResponse.cs プロジェクト: geobabbler/SharpMap
 public void WriteToContextAndFlush(IContextResponse response)
 {
     //Png can't stream directy. Going through a memorystream instead
     byte[] buffer;
     using (MemoryStream ms = new MemoryStream())
     {
         Image.Save(ms, CodecInfo, null);
         Image.Dispose();
         buffer = ms.ToArray();
     }
     response.Clear();
     response.ContentType = CodecInfo.MimeType;
     response.Write(buffer);
     response.End();
 }
コード例 #8
0
 public virtual void WriteToContextAndFlush(IContextResponse response)
 {
     response.Clear();
     response.ContentType = "text/xml";
     response.Write("<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n");
     response.Write(
         "<ServiceExceptionReport version=\"1.3.0\" xmlns=\"http://www.opengis.net/ogc\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:schemaLocation=\"http://www.opengis.net/ogc http://schemas.opengis.net/wms/1.3.0/exceptions_1_3_0.xsd\">\n");
     response.Write("<ServiceException");
     if (ExceptionCode != WmsExceptionCode.NotApplicable)
     {
         response.Write(" code=\"" + ExceptionCode + "\"");
     }
     response.Write(">" + Message + "</ServiceException>\n");
     response.Write("</ServiceExceptionReport>");
     response.End();
 }