0. 前期准备工作
|
1 2 3 4 5 6 7 8 9 |
cd ~/ mkdir ssl cd ssl mkdir demoCA cd demoCA mkdir newcerts mkdir private touch index.txt echo '01' > serial |
1. 制件 CA 证书 […]
不因成就而狂妄、不因失落而气馁、不因欲望而沉重、不因嫉妒而困扰
0. 前期准备工作
|
1 2 3 4 5 6 7 8 9 |
cd ~/ mkdir ssl cd ssl mkdir demoCA cd demoCA mkdir newcerts mkdir private touch index.txt echo '01' > serial |
1. 制件 CA 证书 […]
下载了Yii2 Advanced之后,启动一看,发现其默认是不启用UrlManager的。Url还是Get式的 […]
今天在MacBookPro上安装wordpress时,安装程序一直报错说连不上数据库。mysql客户端可以正常 […]
expect是一种能够按照脚本内容里面设定的方式与交互式程序进行“会话”的程序。根据脚本内容,Expect可以 […]
在Linux环境下,两台主机之间传输文件一般使用scp命令,通常用scp命令通过ssh获取对方linux主机文 […]
1.开启apache-rewrite LoadModule rewrite_module modules/mo […]
1.将php.exe加入环境变量path 2.下载composer https://getcomposer.o […]
根目录下的.htaccess文件内容:film Despicable Me 3 <IfModule mo […]
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 |
public class TFCardInfo { private static TFCardInfo instance; public String mTFCardName = null; public String mTFCardPath = null; public String mSDCardPath = null; public static synchronized TFCardInfo getInstance() { if (instance == null) { instance = new TFCardInfo(); } return instance; } /** * 功 能:得到TF卡的名字和路径,赋给类变量<br> * 时 间:2014年12月25日 上午10:31:26<br> * 注 意:<br> * 1.要判断磁盘是否准备好<br> * * @param context */ public void GetTFCardPathName(Context context) { /** 要排除的目录名称 */ String[] excludeDirs = { "media_rw", "asec", "cd-rom", "obb", "sdcard", "secure", "shell", "usbotg", "usb_storage", "UsbDrive" }; // 获取扩展存储设备的文件目录 File adbFile = new File("/mnt"); File[] tempList = adbFile.listFiles(); boolean isFind = false; for (File curFile : tempList) { isFind = false; if (curFile.isDirectory()) { for (String dirName : excludeDirs) {// 遍历筛选目录 if (curFile.getName().equals(dirName)) { isFind = true; break; } } if (isFind == false) {// 如果筛选项里没有的话,说明已经找到 mTFCardName = curFile.getName(); mTFCardPath = curFile.getAbsolutePath(); mTFCardPath = "/mnt/" + mTFCardName + "/"; break; } } } } /** * 功 能:判断TF卡是否存在<br> * 时 间:2014年12月19日 上午9:50:10<br> * 注 意:<br> * * @TODO:<br> * @param context * @return <br> */ public Boolean CheckTFCardExists(Context context) { if (mTFCardPath == null) { // 防止先调用了这个函数 GetTFCardPathName(context); } if (mTFCardPath == null) { // 路径不存在,则要返回 return false; } // 下面通过创建一个文件来判断是否存在tfcard String tempfilepathnameString = mTFCardPath + "checktfcard.txt"; File file = new File(tempfilepathnameString); try { file.createNewFile(); } catch (IOException e) { e.printStackTrace(); } if (file.exists()) { file.delete();// 删除此测试文件 return true; } return false; } /** * 功 能:获取SD卡路径<br> * 时 间:2015年4月14日 下午5:49:43<br> * 注 意:<br> * * @return */ public String getSDPath() { boolean sdCardExist = Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED); // 判断sd卡是否存在 if (sdCardExist) { File file = Environment.getExternalStorageDirectory();// 获取跟目录 mSDCardPath = file.toString(); } return mSDCardPath; } } |
使用 [crayon-696097f1d46 […]
i18n是internationalization的缩写,意思指i和n之间有18个字母。/etc/syscon […]
各发行包的大致描述如下: org.springframework.asm-3.0.0.M4.jar: 提供对A […]
The?Gestures?for?Chrome?extension is designed to add mo […]
封装Encapsulation 如下代码,这就算是封装了 [crayon-696097f1d4a9e14535 […]
问题:使用ArcMAP制作要发布的数据,保存成mxd后发布成服务,发现有些细节不合理,再次打开mxd进行修改, […]
|
1 |
jQuery |
1 关于text(),返回选择元素结果集,实 […]
A1000与A1000T的区别:A1000与A1000T的区别在于A1000的标配是不带空鼠的 A1000T的 […]
加入地图包括图层渲染,标注等,数据从ArcSDE中读出! 代码中有两个数据表:mapinfo(存储地图信息,k […]
Server发布地图都是基于Mxd去发布的,这点与IMS使用axl文件差不多。一般来说,发布后mxd尽可能不要 […]
1. 服务器 服务器端的选择:geoserver.选择它而不选择deegree的原因在于,deegree相当复 […]
SharePoint Server 2010用来取代MOSS 2007,它有标准版和企业版两个版本,使用SQL […]
使用XDocument时,用普通的ToString方式无法输出声明,可以按如下方式输出声明 [crayon-6 […]
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
如果你想连接你的mysql的时候发生这个错误: ERROR 1130: Host '210.13.92.66' is not allowed to connect to this MySQL server 请按照如下方法解决: login as: root ///登陆系统 root@tqwm.cn's password: ///输入密码 Last login: Tue Apr 15 14:06:54 2008 from 210.13.92.66 [root@myserver ~]# /usr/local/mysql/bin/mysql -uroot -hlocalhost -p ///登入mysql Enter password: ///输入mysql对应用户的密码 Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 431 Server version: 5.0.58-enterprise-gpl-log Source Type 'help;' or '\h' for help. Type '\c' to clear the buffer. ///登入成功的提示信息 mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'rootpasswd' WITH GRANT OPTION; ///输入这段指令并回车后允许所有用root用户并且输入rootpasswd密码的主机登入该mysql Server 如果将'%'换成'10.1.1.1'那么只有10.1.1.1的主机可以登陆. Query OK, 0 rows affected (0.07 sec) mysql> \q ///退出mysql Bye [root@myserver ~]# 另外还有一种方法转自其他地方 改表法。可能是你的帐号不允许从远程登陆,只能在localhost。这个时候只要在localhost的那台电脑,登入mysql后,更改 "mysql" 数据库里的 "user" 表里的 "host" 项,从"localhost"改称"%" mysql -u root -pvmwaremysql>use mysql;mysql>update user set host = '%' where user = 'root';mysql>select host, user from user; 自己的解决方法: 直接在cmd 下进入mysql\bin 下 运行 GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION |
Android和iOS那个好?应该先往哪个上面投入资源?多次被人问到此类问题,笔者刚好自己的项目也需要考虑iO […]
So if you’re upgrading to Flex SDK 4.5 and Air 2.6 Adob […]
一些内容来自于我能找到的资料和我自己的理解,不保证正确,但是大致应该是没错的。 一、排版引擎 首先厘清一下浏览 […]
开始在上面输入您的搜索词,然后按回车进行搜索。按ESC取消。