12 2011 档案

摘要:public static class XmlHelper { private static byte[] XmlSerializeInternal(object o, Encoding encoding) { if( o == null ) throw new ArgumentNullException("o"); if( encoding == null ) throw new ArgumentNullException("encoding"); XmlSerializer ser = new XmlSerializer(o.GetType()); 阅读全文
posted @ 2011-12-31 09:06 darjuan 阅读(204) 评论(0) 推荐(0)
摘要:public class RestClient { private HttpWebRequest CreateHttpRequest(string url, string method) { HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url); this.SetProxy(request); request.Headers.Set("Cache-Control", "No-Cache"); requ... 阅读全文
posted @ 2011-12-23 16:07 darjuan 阅读(302) 评论(0) 推荐(0)