http://json2csharp.com/
 http://jsonclassgenerator.codeplex.com/
 http://jsonutils.com/ JSON生成类文件
 https://github.com/bladefist/JsonUtils ///

http://jsonlint.com/ 检测JSON文件

http://json.codeplex.com/

https://www.mssqltips.com/sqlservertip/3449/making-sql-server-metadata-queries-easier-with-these-new-views/

http://www.sqlteam.com/article/using-metadata

https://github.com/dotnet/docfx  文档转换

http://www.codeproject.com/Articles/192938/jQuery-Templates-View-Engines-and-JSON-Services

http://www.codeproject.com/Articles/266473/JSON-API

http://www.codeproject.com/Articles/630300/JSON-Viewer

http://www.codeproject.com/Articles/78928/Create-JSON-from-C-using-JSON-Library

http://www.codeproject.com/Articles/159450/fastJSON

  public class Rating
{
public int max { get; set; }
public int numRaters { get; set; }
public string average { get; set; }
public int min { get; set; }
} public class Tag
{
public int count { get; set; }
public string name { get; set; }
public string title { get; set; }
} public class Images
{
public string small { get; set; }
public string large { get; set; }
public string medium { get; set; }
} public class Series
{
public string id { get; set; }
public string title { get; set; }
} public class Example
{
public Rating rating { get; set; }
public string subtitle { get; set; }
public IList<string> author { get; set; }
public string pubdate { get; set; }
public IList<Tag> tags { get; set; }
public string origin_title { get; set; }
public string image { get; set; }
public string binding { get; set; }
public IList<string> translator { get; set; }
public string catalog { get; set; }
public string pages { get; set; }
public Images images { get; set; }
public string alt { get; set; }
public string id { get; set; }
public string publisher { get; set; }
public string isbn10 { get; set; }
public string isbn13 { get; set; }
public string title { get; set; }
public string url { get; set; }
public string alt_title { get; set; }
public string author_intro { get; set; }
public string summary { get; set; }
public Series series { get; set; }
public string price { get; set; }
}

  

 WebClient client = new WebClient();
client.Credentials = CredentialCache.DefaultCredentials;
client.Encoding = Encoding.UTF8;
strjson = client.DownloadString(URL);
//MessageBox.Show(strjson);
//string reply = client.UploadString(URL, data); //var jsonlist = JsonConvert.DeserializeObject<List<DoubanBoookInfo>>(strjson);
BookExample book = new BookExample();
book = JsonConvert.DeserializeObject<BookExample>(strjson); // MessageBox.Show(book.title);
this.textBoxprice.Text = book.price;
this.textBoxpubdate.Text = book.pubdate;
this.textBoxtitle.Text = book.title;
this.textBoxImage.Text = book.image;
Images imgurl = book.images;
Encoding encoding = Encoding.GetEncoding("utf-8");
//验证服务器证书回调方法
ServicePointManager.ServerCertificateValidationCallback = new System.Net.Security.RemoteCertificateValidationCallback(CheckValidationResult);
//1
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(book.image);
request.Method = "GET";
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
//String ver = response.ProtocolVersion.ToString();
Stream stream = response.GetResponseStream();
List<byte> list = new List<byte>();
while (true)
{
int data = stream.ReadByte();
if (data == -1)
break;
else
{
byte b = (byte)data;
list.Add(b);
}
}
byte[] photocontent = list.ToArray();
Image photo = BytesToImage(photocontent);
this.pictureBox1.Image = photo; //2
HttpWebRequest objRequest = (HttpWebRequest)WebRequest.Create(imgurl.large);
objRequest.Method = "GET";
HttpWebResponse objResponse = (HttpWebResponse)objRequest.GetResponse();
Stream streambs = objResponse.GetResponseStream();
System.Drawing.Image img = System.Drawing.Image.FromStream(streambs);
this.pictureBox2.Image = img;

  

        /// <summary>
///
/// </summary>
/// <param name="bytes"></param>
/// <returns></returns>
public Image BytesToImage(byte[] bytes)
{
MemoryStream ms = new MemoryStream(bytes);
ms.Position = 0;
Image img = Image.FromStream(ms);
ms.Close();
return img;
} /// <summary>
///
/// </summary>
/// <param name="stream"></param>
/// <returns></returns>
public byte[] StreamToBytes(Stream stream)
{
byte[] bytes = new byte[stream.Length];
stream.Read(bytes, 0, bytes.Length);
// 设置当前流的位置为流的开始
stream.Seek(0, SeekOrigin.Begin);
return bytes;
}
/// <summary>
///
/// </summary>
/// <param name="bytes"></param>
/// <returns></returns>
public Stream BytesToStream(byte[] bytes)
{
Stream stream = new MemoryStream(bytes);
return stream;
} /// <summary>
///
/// </summary>
/// <param name="fileName"></param>
/// <returns></returns>
private byte[] SetImageToByteArray(string fileName)
{
FileStream fs = null;
try
{
fs = new FileStream(fileName, FileMode.Open, System.IO.FileAccess.Read, FileShare.ReadWrite);
Bitmap bt = new Bitmap(fs);
int streamLength = (int)fs.Length;
byte[] image = new byte[streamLength];
fs.Read(image, 0, streamLength); return image;
}
catch (Exception)
{ throw; }
finally
{ fs.Close();
}
} /// <summary>
///
/// </summary>
/// <param name="stream"></param>
/// <param name="fileName"></param>
public void StreamToFile(Stream stream, string fileName)
{
// 把 Stream 转换成 byte[]
byte[] bytes = new byte[stream.Length];
stream.Read(bytes, 0, bytes.Length);
// 设置当前流的位置为流的开始
stream.Seek(0, SeekOrigin.Begin);
// 把 byte[] 写入文件
FileStream fs = new FileStream(fileName, FileMode.Create);
BinaryWriter bw = new BinaryWriter(fs);
bw.Write(bytes);
bw.Close();
fs.Close();
}
/// <summary>
///
/// </summary>
/// <param name="fileName"></param>
/// <returns></returns>
public Stream FileToStream(string fileName)
{
// 打开文件
FileStream fileStream = new FileStream(fileName, FileMode.Open, FileAccess.Read, FileShare.Read);
// 读取文件的 byte[]
byte[] bytes = new byte[fileStream.Length];
fileStream.Read(bytes, 0, bytes.Length);
fileStream.Close();
// 把 byte[] 转换成 Stream
Stream stream = new MemoryStream(bytes);
return stream;
}

  https://github.com/CosmosOS/Cosmos

http://cosmos.codeplex.com/

https://github.com/dotnet/corefx

https://github.com/fsharp

https://github.com/Microsoft/vscode/

https://github.com/adobe/brackets

https://github.com/qihangnet/npoi.css

https://github.com/hprose

https://ltaf.codeplex.com/SourceControl/latest

https://github.com/jmarnold/EmbeddedMail

https://xunit.codeplex.com/

https://github.com/markrendle/Simple.Data

https://github.com/jamietre/CsQuery

https://github.com/Microsoft/vscode/

https://github.com/matteocrippa/awesome-swift

https://github.com/kud1ing/awesome-rust

https://github.com/avelino/awesome-go

https://github.com/sorrycc/awesome-javascript

https://github.com/quozd/awesome-dotnet

https://github.com/Moq/moq4

http://fastreflectionlib.codeplex.com/SourceControl/latest

https://github.com/davidebbo/WebActivator

https://razorgenerator.codeplex.com/

https://github.com/RazorGenerator/RazorGenerator

http://dan.cx/projects/routejs

https://github.com/enyim/EnyimMemcached

https://github.com/tathamoddie/System.IO.Abstractions

https://github.com/NLog/NLog

http://www.quartz-scheduler.net/

http://dotnetopenauth.net/

https://pangusegment.codeplex.com/

http://lucenenet.apache.org/

https://github.com/NancyFx

https://github.com/quartznet/

http://sourceforge.net/projects/quartznet/

https://github.com/DotNetOpenAuth/DotNetOpenAuth

https://github.com/DotNetOpenAuth/DotNetOpenAuth.Samples

https://github.com/NancyFx

https://github.com/MassTransit/MassTransit

http://code.google.com/p/masstransit/

ASP.NET MVC 3 RTM Tools Update

https://www.microsoft.com/zh-cn/download/confirmation.aspx?id=1491

http://orchard.codeplex.com/SourceControl/latest

http://aspnet.codeplex.com/SourceControl/latest

https://github.com/Microsoft/dotnet

https://github.com/dotnet/core

https://github.com/aspnet/EntityFramework

http://www.dotnetfoundation.org/projects

https://www.myget.org/gallery/dotnet-core

csharp: json to csharp的更多相关文章

  1. Excel转Json,Json转CSharp

    一份给策划最好的礼物!就是:Excel2Json2CSharp 策划配置Excel,动不动就要改数值啊,增加字段啊. 程序这边对应的解析类就得改动啊.整一个麻烦了得! 所以我就整理了这个Excel2J ...

  2. Json To CSharp

    This is a tools for generate json reader classes. In some case, when we get a json data, we hope to ...

  3. Newtonsoft.Json.4.5.11使用方法总结---反序列化json字符串

    写在开头: 最近项目需求,需要在C#中处理json字符串,毫不犹豫的下载了Newtonsoft.Json 4.5.11(2012.12.17)http://json.codeplex.com/,然后百 ...

  4. 【.net】“Newtonsoft.Json”已拥有为“Microsoft.CSharp”定义的依赖项。

    #事故现场: “Newtonsoft.Json”已拥有为“Microsoft.CSharp”定义的依赖项. #事故原因: 安装的Newtonsoft.Json版本为11.0.2,版本过高,与Micro ...

  5. CSharp读取json配置文件内容

    步骤 读取配置文件转换成字符串,代码如下 string contents = System.IO.File.ReadAllText("config.json"); 注意:该语句会抛 ...

  6. csharp:Learn how to post JSON string to generic Handler using jQuery in ASP.Net C#.

    /// <summary> ///參考: http://james.newtonking.com/json/help/index.html# /// 塗聚文(Geovin Du) 2014 ...

  7. csharp:.net 3.5 using System.Runtime.Serialization.Json read json

    using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.We ...

  8. csharp: using using System.Web.Script.Serialization read json

    using System; using System.Data; using System.Configuration; using System.Collections; using System. ...

  9. csharp:using Newtonsoft.Json.Net2.0 in .net 2.0 webform

    /// <summary> /// http://www.weather.com.cn/data/sk/101280601.html /// {"weatherinfo" ...

随机推荐

  1. Eclipse shortcuts

    Editor Shortcut Description Alt + / Content assist. A great help for our coding. Ctrl + Shift + F Fo ...

  2. UICollectionView瀑布流的实现原理(转)

    http://ios.jobbole.com/85689/ 和使用 UIScollView 创刊一个瀑布流是一样的方式 7cc829d3gw1f4nq2oc09zj20j00hvq90.jpg 我的 ...

  3. Java程序员转Android开发必读经验分享

    小编最近几日偷偷的发现部分Java程序员想转安卓开发,故此加紧补充知识,为大家搜集资料,积极整理前人的经验,希望可以给正处于困惑中的你,带来些许的帮助. 啰哩啰嗦的说说Java和Android程序的区 ...

  4. Windows Tomcat7.0 安装 Solr

    准备工作 1.下载Tomcat7.0 ,apache-tomcat-7.0.67.exe,安装目录如下:C:\workspace\Tomcat7.0\ 2.下载Solr 5.2,solr-5.2.0. ...

  5. iOS开发 - AVPlayer实现流音频边播边存

    边播边下有三套左右实现思路,本文使用AVPlayer + AVURLAsset实现. 概述 1. AVPlayer简介 AVPlayer存在于AVFoundation中,可以播放视频和音频,可以理解为 ...

  6. thinking in object pool

    1.背景 对象池为了避免频繁创建耗时或耗资源的大对象,事先在对象池中创建好一定数量的大对象,然后尽量复用对象池中的对象,用户用完大对象之后放回对象池. 2.问题 目前纵观主流语言的实现方式无外乎3个步 ...

  7. IOS开发 图形绘制,绘制线条,矩形,和垂直和居中绘制文字

    概述 吐槽下IOS下 的图形绘图,代码冗长,不得不自己重新封装方法.整理形成本文. 绘制线 // 绘制直线 + (void)toDrawLineFromX:(CGFloat)x1 Y:(CGFloat ...

  8. JQuery 表格拖动调整列宽效果

    类似于桌面程序中的表格拖动表头的效果,当鼠标停留在表头边框线上时,鼠标会变成表示左右拖动的形状,接着拖动鼠标,会在表格中出现一条随鼠标移动的竖线,最后放开鼠标,表格列宽会被调整.最近比较空闲,便自己动 ...

  9. Linux 学习碎片

    1.登录远程机器: ssh 远程机器用户名@远程机器IP ssh root@192.168.1.101 2.不同机器之前拷贝文件 #拷贝本机单个文件到远程服务器 scp /home/user1/tb. ...

  10. 我是如何用Go语言搭建自己的博客的

    前言: 话说,已经很久没有在博客园更新博客了,之前写的关于go语言的系列学习文章<让我们一起Go>也由于种种原因一度中断.但是,正如我之前在文章中所写,可以慢慢来,但是对于Go语言的学习却 ...