码迷,mamicode.com
首页 >  
搜索关键字:context    ( 11739个结果
Android获取手机位置(LocationManager)
LocationManager lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE); List providers = lm.getProviders(true); /* Loop over the array backwards, and if you get an accurate location, the...
分类:移动开发   时间:2014-12-20 19:42:35    阅读次数:234
Android中Context的总结及其用法
在语句 android中我们经常遇到这样的情况,在创建一个对象的时候往往需要传递一个this参数,比如:语句 MyView mView = new MyView(this),要求传递一个this参数,这个this究竟指的是什么东西呢? 其实这里的this指的就是当前的Activity.this,.....
分类:移动开发   时间:2014-12-20 15:32:34    阅读次数:257
jquery&js $(this) & this
序言:在使用jquery操作js时,经常整不明白this与$(this)。抽空仔细测试了一把,记录下来以供在忘记的时候拉出来参考参考! $(this)生成的是什么 $()生成的是什么呢?实际上$()=jquery(),那么也就是说返回的是一个jquery的对象。 题外话:通常我们为了简便直接使用$(),实际上,该函数省略了一个参数context,即$(selector)=$(se...
分类:Web程序   时间:2014-12-19 20:44:19    阅读次数:166
spring mvc 错误
<context:annotation-config /> ? ?? ?<mvc:annotation-driven />
分类:编程语言   时间:2014-12-19 19:25:51    阅读次数:160
ios各种动画效果
ios各种动画效果最普通动画://开始动画[UIView beginAnimations:nil context:nil];//设定动画持续时间[UIView setAnimationDuration:2];//动画的内容frame.origin.x += 150;[img setFrame:fra...
分类:移动开发   时间:2014-12-19 18:47:24    阅读次数:133
iOS CGContex小记
0 CGContextRef context = UIGraphicsGetCurrentContext(); 设置上下文 1 CGContextMoveToPoint 开始画线  2 CGContextAddLineToPoint 画直线  4 CGContextAddEllipseInRect 画一椭圆  4 CGContextSetLineCap 设置线条终点形状  4 CGCon...
分类:移动开发   时间:2014-12-19 17:32:37    阅读次数:194
用Session实现验证码
新建一个 ashx 一般处理程序 如: YZM.ashx继承接口 IRequiresSessionState //在一般处理程序里面继承HttpContext context 为请求上下文,包含此次请求处理要使用到的信息和对象都在里面,有Response,有Request下面为 YZM.ashx.....
分类:其他好文   时间:2014-12-19 15:44:02    阅读次数:146
ASP.NET获取服务器文件的物理路径
如下:string fullpath = context.Server.MapPath("hello.htm"); //得到hello.htm的全路径string content = System.IO.File.ReadAllText(); //读入文件内容context.Re...
分类:Web程序   时间:2014-12-19 15:39:55    阅读次数:125
ViewPager撤消左右滑动切换功能
ViewPager取消左右滑动切换功能最近做项目要求某种情况下ViewPager不能滑动,那么我们只需要重写这个方法就可以禁止ViewPager滑动IndexViewPager.java:import android.content.Context;import android.support.v4...
分类:其他好文   时间:2014-12-19 14:27:46    阅读次数:125
Tomcat7集群扩展session集中管理,tomcat-redis-session-manager使用
请参考官方文档下载所需的包了:tomcat-redis-session-manager-1.1.jarjedis-2.1.0.jarcommons-pool-1.6.jar将这些jar包都丢到tomcat的lib目录下,然后修改tomcat7的conf/context.xml文件中加入host:re...
分类:其他好文   时间:2014-12-19 13:02:57    阅读次数:195
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!