摘要:
Java容器类类库的用途是“保存对象”,并将其划分为两个不同的概念: (1)Collection。一个独立元素的序列,这些元素都服从一条或多条规则。List必须按照插入的顺序保存元素,而Set不能有重复元素。Queue按照排队规则来确定对象产生的顺序。 (2)Map。一组成对的“键值对”对象,允许你
阅读全文
posted @ 2019-09-18 17:45
深南大道
阅读(3324)
推荐(2)
摘要:
package com.test3; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map.Entry; public class demo3 { public static void main(String[] args) { HashMap<String
阅读全文
posted @ 2019-09-18 13:56
深南大道
阅读(182)
推荐(0)
摘要:
package com.test2; public class demo2 { public static void main(String[] args) { /** * 一维数组使用 */ //数组最大的缺陷:长度固定 //int data[] = {10, 20, 30}; /*开辟了一个长度为...
阅读全文
posted @ 2019-09-18 12:05
深南大道
阅读(547)
推荐(0)
摘要:
package com.inter; /** * 继承和接口的关系,单继承,多接口 * java不支持多继承,但可通过接口实现多重继承 */ public class test2 { public static void main(String[] args) { LitterMonkey litterMonkey = new LitterMonkey(); ...
阅读全文
posted @ 2019-09-17 19:11
深南大道
阅读(867)
推荐(0)
摘要:
package com.test1; /** * 接口的使用 */ public class test1 { public static void main(String[] args) { //创建Compute Compute compute = new Compute(); //创建Camera Camera camera = new Camera(); //创建Phone Phone ph
阅读全文
posted @ 2019-09-17 17:50
深南大道
阅读(879)
推荐(0)
摘要:
抽象类: 抽象类就是不能使用new方法进行实例化的类(不能被实例化,可以有多个抽象方法),即没有具体实例对象的类,抽象类有点类似于“模板”的作用,目的是根据其格式来创建和修改新的类,对象不能由抽象类直接创建,只可以通过抽象类派生出新的子类,再由其子类来创建对象,当一个类被声明为抽象类时,要在这个类前
阅读全文
posted @ 2019-09-17 17:07
深南大道
阅读(3391)
推荐(0)
摘要:
package com.qushida.util; import java.beans.BeanInfo; import java.beans.Introspector; import java.beans.PropertyDescriptor; import java.sql.Connection; import java.sql.PreparedStatement; import jav...
阅读全文
posted @ 2019-09-17 16:41
深南大道
阅读(1496)
推荐(0)
摘要:
using System; using System.Reflection; namespace ConsoleApp2 { class Program { static void Main(string[] args) { //反射获取 命名空间+类名 string className = "Co...
阅读全文
posted @ 2018-02-26 18:17
深南大道
阅读(13666)
推荐(0)
摘要:
using System; using Microsoft.Win32; using System.Diagnostics; using System.IO; namespace MSCL { /// /// 压缩解压类 /// public class ZipHelper { /// /// 利用 WinRAR 进...
阅读全文
posted @ 2017-10-16 15:53
深南大道
阅读(6627)
推荐(0)
摘要:
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Configuration; using System.Data.SqlClient; using System.Data; using S...
阅读全文
posted @ 2017-10-16 14:09
深南大道
阅读(20752)
推荐(0)
摘要:
using System; using System.Linq; using System.Xml.Linq; namespace Sample2 { class Program { static void Main(string[] args) { #region 写文件一(生成节点性质的) XD...
阅读全文
posted @ 2017-10-16 14:05
深南大道
阅读(9273)
推荐(0)
摘要:
//引用using Newtonsoft.Json; using Newtonsoft.Json.Linq; public ActionResult JsonSample() { ResponseResult obj = new ResponseResult(); try { JObject jo
阅读全文
posted @ 2017-10-16 10:12
深南大道
阅读(1437)
推荐(0)
摘要:
JSON对象与字符串之间的相互转换
阅读全文
posted @ 2017-10-16 09:37
深南大道
阅读(1545)
推荐(0)
摘要:
正则表达式可以: •测试字符串的某个模式。例如,可以对一个输入字符串进行测试,看在该字符串是否存在一个电话号码模式或一个信用卡号码模式。这称为数据有效性验证 •替换文本。可以在文档中使用一个正则表达式来标识特定文字,然后可以全部将其删除,或者替换为别的文字 •根据模式匹配从字符串中提取一个子字符串。可以用来在文本或输入字段中查找特定文字 正则表达式语法 一个正则表达式就是由普通字符(...
阅读全文
posted @ 2017-10-16 09:36
深南大道
阅读(941)
推荐(0)
摘要:
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading; using System.Threading.Tasks; namespace Sample3 { class Program { static...
阅读全文
posted @ 2017-10-16 09:34
深南大道
阅读(13573)
推荐(1)
摘要:
uploadify3.2上传文件 using System; using System.Collections.Generic; using Sys...
阅读全文
posted @ 2017-10-14 20:28
深南大道
阅读(3146)
推荐(0)
摘要:
/// /// 反射得到实体类的字段名称和值 /// var dict = GetProperties(model); /// /// 实体类 /// 实例化 /// public static Dictionary GetProperties(T t) { var ret = new Dictionary(); if (t == null) { return null; ...
阅读全文
posted @ 2017-10-14 20:26
深南大道
阅读(8664)
推荐(0)
摘要:
/*查找XML*/ var filePath = Server.MapPath("~/xml/sample.xml"); XDocument doc = XDocument.Load(filePath); var text1 = doc.Descendants("用户") //定位到节点 .Where(p => p.Element("性别").Value.Co...
阅读全文
posted @ 2017-10-14 20:24
深南大道
阅读(5593)
推荐(0)
摘要:
--1、默认情况下,SQL Server中的CLR是关闭的,所以我们需要执行如下命令打开CLR: exec sp_configure 'clr enabled',1 reconfigure GO -- DROP FUNCTION dbo.fnScoketSend --删除Function -- drop assembly SqlDependency ...
阅读全文
posted @ 2017-10-14 20:22
深南大道
阅读(1641)
推荐(0)
posted @ 2017-10-14 20:20
深南大道
阅读(310)
推荐(0)
posted @ 2017-10-14 20:19
深南大道
阅读(2387)
推荐(0)
摘要:
MSCL超强工具类库 是基于C#开发的超强工具类集合,涵盖了日常B/S或C/S开发的诸多方面,包含上百个常用封装类(数据库操作类全面支持Mysql、Access、Oracle、Sqlserver、Sqlite等数据库,常用字符串处理类,内存容器类,Session/Cookie/Cache类,Conf
阅读全文
posted @ 2017-10-14 20:12
深南大道
阅读(2093)
推荐(0)
摘要:
ALTER PROCEDURE sp_refallview AS --刷新所有视图 DECLARE @ViewName VARCHAR(MAX); DECLARE @i INT; SET @i = 0; DECLARE #_cursor CURSOR FOR SELECT name FROM sysobjects WHERE type = 'V'; OPE...
阅读全文
posted @ 2017-10-14 13:47
深南大道
阅读(2992)
推荐(0)
摘要:
在Sql Server 数据库还原出现 3154错误 解决方法1:不要在数据库名字上点右键选择还原,而要是在根目录“数据库”三个字上点右键选择还原,然后再选择数据库,问题便可以解决,如果不行参照方法2 解决方法2:写sql语句处理: RESTORE DATABASE [databaseName] F
阅读全文
posted @ 2017-10-14 13:46
深南大道
阅读(1926)
推荐(0)
摘要:
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Configuration; using System.Data.SqlClient; using System.Data; using S...
阅读全文
posted @ 2017-10-14 13:45
深南大道
阅读(1682)
推荐(1)
摘要:
using System; using System.Collections.Generic; using System.Text; using System.Configuration; using System.Xml; using System.Web; namespace MSCL { /// /// 配置文件帮助类 /// public class...
阅读全文
posted @ 2017-10-14 11:39
深南大道
阅读(2114)
推荐(0)
posted @ 2017-10-14 11:34
深南大道
阅读(2923)
推荐(0)
摘要:
@{ Layout = null; } 示例 public ActionResult Sample() { List list = new List() { new SampleData{ id=1000, name="张三", sex="男"}, new Sam...
阅读全文
posted @ 2017-10-14 11:32
深南大道
阅读(1833)
推荐(0)
摘要:
using Quartz; using Quartz.Impl; using System; using System.Collections.Generic; using System.Linq; using System.Reflection; using System.Text; using System.Threading; using System.Threading.Tasks; ...
阅读全文
posted @ 2017-10-14 11:31
深南大道
阅读(1978)
推荐(0)
摘要:
//App_Start-RouteConfig.cs public class RouteConfig { public static void RegisterRoutes(RouteCollection routes) { routes.IgnoreRoute("{resource}.axd/{*pathInfo...
阅读全文
posted @ 2017-10-14 11:29
深南大道
阅读(964)
推荐(0)