自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(58)
  • 收藏
  • 关注

原创 shiro session listener

[code="java"]package com.xyz.service.shiro;import org.apache.shiro.session.Session;import org.apache.shiro.session.SessionListener;import lombok.extern.slf4j.Slf4j;@Slf4jpublic class S...

2016-08-17 17:54:45 361

原创 Https - TLSv1.2

大于8k左右的数据请求(PUT/POST)无法与server通信[b]Chrome: Error (net::ERR_SSL_PROTOCOL_ERROR): SSL protocol error.[/b]public class ShortBufferException extends GeneralSecurityExceptionThis exception is thr...

2016-05-25 15:39:49 844

原创 grep and sed

[code="java"]grep -n x.log sed -n '1000,2000p' x.log > target.log[/code]

2014-09-24 18:14:07 108

原创 What do the arrow icons in Subclipse mean?

[url]http://stackoverflow.com/questions/3917925/what-do-the-arrow-icons-in-subclipse-mean[/url]

2013-02-07 09:43:08 101

原创 Java call R - windows

[quote]install.packages("rJava")[/quote](1/3) 新增 R_HOME [code="java"]D:\opt\R\R-2.15.2[/code](2/3) CLASSPATH 加入:[code="java"];%R_HOME%\library\rJava\jri\JRI.jar[/code](3/3) Path 加入:[...

2012-12-10 10:29:33 100

原创 flash camera

flash拍照改进版 - 参照的原版地址不详。camera.zip - flash sourceflashcamera.zip - web-app source

2012-06-19 10:24:52 173

原创 UNIX / Linux Convert DOS Newlines CR-LF to Unix/Linux Format

patch remove Bomb(^M) [code="java"] $ cat ~/bin/rmBom #! /bin/sh¬¬#echo "uconv --remove-signature the $1 files"¬¬### uconv not availble¬# find . -name "*.$1" \¬# -exec uconv ...

2011-09-22 18:48:37 101

原创 Objective-C NSDateFormater

[code="objective-c"]NSDateFormatter *dateFormat = [[NSDateFormatter alloc] init]; [dateFormat setDateFormat:@"yyyy-MM-dd HH:mm Z"]; NSDate *selected = [datePicker date]; NSString *messa...

2011-08-26 10:50:19 97

原创 M:The road of learn TCP/IP

1.Richard Stevens,TCP/IP Illustrated, Vol.1 / Vol.2 / Vol.3《TCP/IP详解(第一卷)协议》《TCP/IP详解 卷2:实现》《TCP/IP详解卷3:TCP事务协议、HTTP、NNTP和UNIX域协议》《TCP/IP详解卷1:协议(英文版)》《TCP/IP详解卷2:实现(英文版》《TCP/IP详解卷3:TCP事务协议...

2011-08-15 11:42:49 137

原创 Thu Rules of Cocoa Memory Management

When you create an object using [b]new, alloc, or copy[/b], the object has a retain count of 1. You are responsible for sending the object a release or autorelease message whenyou're done with it...

2011-08-11 09:05:14 104

原创 oracle help manual

[code="java"]cd ORACLE_HOEM/sqlplus/admin/helpsqlplus system/pwdsystem@ORCL> @helpdrop.sqlsystem@ORCL> @helpbld.sqlsystem@ORCL> @helpus.sqlfirst input: path name()second input: helpus.sql...

2011-01-24 13:41:28 90

让MyEclipse7.1更精简

去除MyEclipse 的一些相关的jsf的支持jar包查找MyEclipse加载的jar包:[code="shell"]$ pmap `pidof java` | grep jsf6abfc000 368K r-xs- Genuitec/Common/plugins/org.jboss.tools.jsf.ui_2.0.1.zmyeclipse71020090305...

2010-04-30 14:47:56 122

在Linux平台下使用JNI

[color=green]参考:http://www.ibm.com/developerworks/cn/java/l-linux-jni/[/color][color=green]但参考中的版本过于古老,不利于初学者参照。[/color]环境: gentoo, jdk-1.6, gcc version 4.3.4 (Gentoo 4.3.4 p1.0, pie-10.1.5)...

2010-04-07 14:49:51 128

原创 'for' and 'sed' command

sed -e '/^sshd/!d' hosts.deny | cut -d' ' -f2-e '/^sshd/!d' 删除非‘sshd’开头的行-d' ' 空格分隔 -f2 分隔后所得数组的第二个值[quote]$ cat hosts.denysshd: 117.21.249.75sshd: 58.252.146.187sshd: 217.111.0.6sshd...

2009-09-10 23:11:41 81

原创 如何应对不确定

原文链接:[url=http://www.goal-setting-college.com/success/how-to-live-with-uncertainty/]How to Live With Uncertainty [/url]原文作者:Ellesse Chow翻 译:Paula审 校:Ellesse Chow如果你下周开始新工作,要结婚,或者移居异国,你是不是感到心...

2009-08-19 13:16:49 173

原创 正确理解你自己的聪明才智

原文地址:[url=http://www.pickthebrain.com/blog/learn-to-understand-your-own-intelligence/]Learn to Understand Your Own Intelligence[/url]翻译:"正确理解你自己的聪明才智" - Angelived三年前我听了一个关于“认知”的讲座,从此之后,我改变了对“聪明”...

2009-08-19 12:57:37 494

Thinkpad 死于 Lenovo ?

发点牢骚,实在是不吐不快。T60 各方面还好T400 键盘的质量差到了极点,手感太差了。首先弹性不足,整体的硬度不够(稍用力安个别键会致使键盘局部下陷),有时个别键还会卡死(比如空格)防水性如何无法测试机器的整体有点脆弱(防滚架的保护好像没了),T60单手拿左下角或右下角很轻松,T400每当我单手拿时,特别是右下角,给我的感觉是随时有可能会断掉!现在都不敢单手拿!...

2009-08-16 00:49:44 136

原创 灭九族

[code="java"]父族四(代),母族三(代),妻族二(代),为九族父族四:指自己一族。出嫁的姑母及其儿子、出嫁的姐妹及外甥、出嫁的女儿及外孙。母族三:是指外祖父一家、外祖母的娘家、姨母及其儿子。妻族二:是指岳父的一家、岳母的娘家。[/code][quote]关于九族说法不一: 一种认为是从本人算起向上五代,向下五代,共是九代为九族;[/quote]PS:8.4有...

2009-08-06 00:01:18 142

原创 install memcached

[quote]http://www.iteye.com/topic/193900[/quote]Gentoo:[code="java"]# emerge -av net-misc/memcached dev-libs/libevent-1.4.11 net-misc/memcached-1.3.3-r2配置文件: # emacs -nw /etc/con...

2009-07-29 14:41:19 86

原创 Linux系统命令行性能检测工具

http://www.chineselinuxuniversity.net/courses/using/introductions/25591.shtml

2009-07-27 23:36:39 111

原创 Disable “WARNING: Parameters: Invalid chunk ignored.” messages in Tomcat log

http://www.itonguard.com/20080605/disable-warning-parameters-invalid-chunk-ignored-messages-in-tomcat-log/[quote]To disable this message you need to modify logging properties file.If you have ...

2009-07-23 16:11:29 87

原创 HOWTO_CVS_Server

http://gentoo-wiki.com/HOWTO_CVS_Server丢失了,做个备份[edit] Introduction If you've ever had some sort of programming project where you didn'twant to turn your code into a disorganize...

2009-07-21 10:42:45 120

原创 笑笑,放松一下

来源: mop.com宿管科突来宿舍检查有无违章电器。可怜我那两个哥们吓得魂不附体,一人赶忙收起电炉子躲进蚊帐,另一人端着炉子上煮的热牛奶也钻进了进来…… 检查的推门进来,拉灯一看没人,正欲离开,突然,蚊帐里的一兄弟被牛奶杯烫了一下,一下子碰翻了杯子,并发出骇人的惨叫声……宿管科老师吓了一跳,拉开蚊帐细瞧:两个男生衣冠不整地抱在一起,床单上白乎乎的一大片……======...

2009-07-16 15:06:09 111

原创 取消Linux下的鼠标中键粘贴功能

http://yujian5.spaces.live.com/blog/cns!6CDC9EF6CBD6E27C!777.entry[quote]Section "InputDevice" [...] Option "EmulateWheel" "true" Option "EmulateWheelButton" "2" Option "EmulateW.

2009-07-15 09:55:25 1784

原创 Enable gzip with Apache Tomcat proxy connector

[code="java"]vim /etc/apache2/vhosts.d/00_default_vhost.conf Servername localhost DocumentRoot "/home/mg/opt/tomcat/webapps/cityunion" ProxyRequests Off...

2009-07-10 10:57:31 98

神仙啊!快被你折腾死了

200行一个方法,到处充斥着全局变量真是个神仙啊![code="java"]public String payCart() { identity = getPubStrB();//证件号码 SessionUtil sessionUtil = new SessionUtil(); CookieUtil cookieUtil = new CookieUtil();...

2009-04-28 10:48:10 117

原创 gentoo "gcc-config: active gcc profile is invalid"

[quote]gcc-config error: Could not run/locate "i686-pc-linux-gnu-gcc$ gcc-config -l$ gcc-config -cgcc-config: active gcc profile is invalid[/quote][quote]Then we manually checked around. F...

2009-04-10 10:14:39 117

eclipse3.2.1 + junit4

环境:gentoo, eclipse-3.2.1在eclipse中执行TestCase(使用junit-3.8.1.jar)时,出现如下错误:[quote]Cannot find 'org.junit.Test' on project build path. JUnit 4 tests can only be run if JUnit 4 is on the build path.[/qu...

2008-11-24 18:56:05 100

Gentoo中,使用Django 连接 Oracle

[quote]Django supports Oracle Database Server versions 9i and higher. Oracle version 10g or later is required to use Django's regex and iregex query operators. You will also need the cx_Oracle driver,...

2008-11-11 19:00:02 131

linux 环境下连接Oracle

今天Windows开始黑屏了(欢迎大家脱离MS)。在linux上装了oracle,作为程序员当然要试试连接了,google、baidu了很多,没发现一个完整的介绍(也许是我没发现)。所以自己摸索了:[b]OS:gentooOracle: 10.2.0.1gJDBC: mysql-connector-java-3.1.11-bin.jar[/b]1. Starting...

2008-10-21 02:17:06 378

gentoo revdep-rebuild 'not owned ... broken'

[quote]mg # revdep-rebuild * Assigning files to packages * !!! /home/oracle/product/10.2.0.1/bin/emagtm0 not owned by any package is broken !!! * /home/oracle/product/10.2.0.1/bin/emagtm0 -...

2008-10-18 18:26:58 104

常用搜索技巧-Google

[b]双引号可以用‘-’代替[/b],比如搜索["like this"]与搜索[like-this]是一个效果[b]在单词前加~符号可以搜索同义词[/b],比如你想搜索[house],同时也想找[home],你就可以搜索[~house][b]如果你想把搜索结果限制在大学的网站之中,可以使用[site:.edu]关键词[/b],比如[c-tutorial site:.edu],这样可...

2008-10-18 15:39:22 93

原创 感受痛苦...

[quote]和很多求职者一样,从起初的信心百倍,到怀疑、急躁、愤懑、失望、绝望,一直到麻木,期间的心理历程,不堪回首,但又无可奈何。下面是我的一些求职心得,希望能给正走在求职路上的朋友们,一点提醒,一点安慰,一点鼓励。尽量不要参加那些“无效”的面试,而是直接拒绝,这样做,只会增加你的信心。[/quote][b]有效的面试失败后要认真反省自己的表现,总结经验教训。继续迎接下次面试。...

2008-10-17 13:23:08 88

面试中,BubbleSort/BinarySearch 问到的几率真高

最近在找工作,经常被问及,所以备份一下。二分搜索:[code="java"]public class BinarySearch { public static int search(int[] a, int key) { return binarySearch(a, 0, a.length, key); } priva...

2008-10-16 18:18:40 99

原创 Oracle and SQL*Plus

在sqlplus中使用emacs编辑sql$ORACLE_HOME/sqlplus/admin:login.sql[code="java"]define _editor='emacs -nw' //在terminal中edit// define _editor=vimset serveroutput on size 1000000set trimspool on...

2008-10-15 18:25:49 70

原创 JavaScript Commpressor

JavaScript Tools:[url]http://dean.edwards.name/packer/[/url][url]http://javascriptcompressor.com/[/url]

2008-10-01 11:00:45 81

scim for firefox 无须设置LC_CTYPE="zh_CN.UTF-8"

[code="java"]mg@mg ~ $ localeLANG=en_US.UTF-8LC_CTYPE="en_US.UTF-8"LC_NUMERIC="en_US.UTF-8"...LC_ALL=en_US.UTF-8[/code]修改 etc\gtk-2.0\gtk.immodules 文件将中间的[code="java"]"/usr/lib/gtk-2.0...

2008-09-23 19:36:58 373

原创 Saving Power whith Linux

Saving power is a hot topic across the computer industry. For some, saving power means getting a longer battery life on their mobile devices, be it laptops or handhelds. For others, saving power means...

2008-08-06 12:04:01 81

原创 emerging Gentoo

2008-04-24 : net ok error: unkown host --- dns not setup2008-04-25: sound ok 终于可听音乐了19:20,gnome okUbuntu is an African word meaning "I can't install Debian."

2008-04-25 18:26:07 74

linux访问Windows资源

使用smbclient访问Windows资源[color=green]原文:[/color][url]http://tech.sina.com.cn/focus/FreeBSD/2000-01-10/183.shtml[/url]samba软件中用于访问网络上其他SMB资源的软件为smbclient,它是一个类似于ftp操作方式,通过远程操作的方式进行文件传递的软件。为了获得网络上可以...

2008-04-01 17:11:12 110

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除