项目中发现别人写好的操作系统相关的工具类: 我总结的类似相关博客:http://www.cnblogs.com/DreamDrive/p/4289860.html import java.net.InetAddress; import java.net.UnknownHostException; import java.util.List; /** * OS Utility Class This is used to obtain the os related var programmatica
// 将时间戳转换成日期格式: function timestampToTime(timestamp) { var date = new Date(timestamp);//时间戳为10位需*1000,时间戳为13位的话不需乘1000 var Y = date.getFullYear() + '年'; var M = (date.getMonth()+1 < 10 ? '0'+(date.getMonth()+1) : date.getMonth()+1) + '月'; var D = (dat
function toQueryString(obj) { var ret = []; for (var key in obj) { key = encodeURIComponent(key); var values = obj[key]; if (values && values.constructor == Array) { //数组 var queryValues = []; for (var i = 0, len = values.length, value; i < len