//信1705-1 20173527 刘津鑫
package money;
import java.io.IOException;
import java.io.Serializable;
import java.util.Scanner;
import java.util.ArrayList;
public class Account implements Serializable{
private String accountID;//账户
private String accountname;//姓名
private String operatedate;//时间
private int operatetype;//操作类型
private String accountpassword;//密码
private int accountbalance;//余额
private int amount;//流水金额
public String getaccountID()
{
return accountID;
}
public String getaccountname()
{
return accountname;
}
public String getoperatedate()
{
return operatedate;
}
public int getoperatetype()
{
return operatetype;
}
public String getaccountpassword()
{
return accountpassword;
}
public int getaccountbalance()
{
return accountbalance;
}
public int getamount()
{
return amount;
}
public void setaccountID(String accountID)
{
this.accountID=accountID;
}
public void setaccountname(String accountname)
{
this.accountname=accountname;
}
public void setoperatedate(String operatedate)
{
this.operatedate=operatedate;
}
public void setoperatetype(int operatetype)
{
this.operatetype=operatetype;
}
public void setaccountpassword(String accountpassword)
{
this.accountpassword=accountpassword;
}
public void setaccountbalance(int accountbalance)
{
this.accountbalance=accountbalance;
}
public void setamount(int amount)
{
this.amount=amount;
}
public Account() { }
public String tostring() {
return "id="+accountID+",accountname="+accountname+",accountpassword="+accountpassword+",accountbalance="+accountbalance;
}
public String tostring1() {
return "id="+accountID+",accountname="+accountname+",operatedate="+operatedate+",operatetype="+operatetype+",aamount="+amount;
}
public Account(String accountID,String accountname,String operatedate,int operatetype,String accountpassword,int accountbalance,int amount) {
this.accountID=accountID;
this.accountname=accountname;
this.operatedate=operatedate;
this.operatetype=operatetype;
this.accountpassword=accountpassword;
this.accountbalance=accountbalance;
this.amount=amount;
}
public static void main(String[] args) throws IOException
{
AccountManager a=new AccountManager();
ArrayList<Account> people=new ArrayList<Account>();
ArrayList<Account> list=new ArrayList<Account>();
for(int i=0;i<5;i++)
{
a.addAccount(people);
}
a.show(people);
a.enterID(people,list);
}
}
//信1705-1 20173527 刘津鑫
package money;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.io.Serializable;
import java.text.SimpleDateFormat;
import java.util.Scanner;
import java.util.ArrayList;
import java.util.Date;
public class AccountManager {
public void addAccount(ArrayList<Account> people)
{
Scanner in = new Scanner(System.in);
Account ac=new Account();
System.out.println("请输入账户的账号、名称、密码、账户余额");
String accountID=in.next();
String accountname=in.next();
String accountpassword=in.next();
int accountbalance=in.nextInt();
ac.setaccountID(accountID);
ac.setaccountname(accountname);
ac.setaccountpassword(accountpassword);
ac.setaccountbalance(accountbalance);
people.add(ac);
File file = new File("accountinformation.txt");
// 对象输出流
ObjectOutputStream out = null;
try {
// 将数组对象写入文件
out = new ObjectOutputStream(new FileOutputStream(file));
out.writeObject(people);
out.flush();
out.close();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
}
public void show(ArrayList<Account> people)
{
File file = new File("accountinformation.txt");
ObjectInputStream in = null;
try {
in = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) in.readObject();
for (int i=0;i<people.size();i++) {
Account s=people.get(i);
System.out.println(s.tostring());
} }catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
}
public void enterID(ArrayList<Account> people,ArrayList<Account> list)
{
int a=1;
int flag=-1;
while(a==1) {
System.out.println("**************************************************");
System.out.println(" 欢迎使用中国工商银行自动柜员系统");
System.out.println("请输入您的账号:");
Scanner in = new Scanner(System.in);
String ID=in.next();
if(ID.length()!=8)
{
System.out.println("该卡不是工行卡");
a=1;
}
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
for (int i=0;i<people.size();i++) {
Account s=people.get(i);
if(s.getaccountID().equals(ID))
{
flag=i;a=1;
}
}
if(flag==-1)
{
System.out.println("该账号不存在");
}
else
{
a=2;
} }catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
}
enterpassword(people,flag,list);
}
public void enterpassword(ArrayList<Account> people,int i,ArrayList<Account> list)
{
System.out.println("**************************************************");
System.out.println(" 欢迎使用中国工商银行自动柜员系统");
System.out.println("请输入您的密码:");
Account s=new Account();
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
s=people.get(i);
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
for(int j=0;j<3;j++)
{
Scanner in = new Scanner(System.in);
String password=in.next();
if(s.getaccountpassword().equals(password))
{
enter(s.getaccountID(),people,list);
}
else
System.out.println("密码录入错误");
}
System.out.println("该账号三次录入密码错误,该卡已被系统没收,请与工行及时联系处理");
}
public void enter(String a,ArrayList<Account> people,ArrayList<Account> list)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"使用中国工商银行自助柜员系统");
System.out.println("1、存款;");
System.out.println("2、取款;");
System.out.println("3、转账汇款;");
System.out.println("4、修改密码;");
System.out.println("5、查询余额;");
System.out.println("请输入选择:");
Scanner in = new Scanner(System.in);
int operatetype=in.nextInt();
switch(operatetype) {
case 1:deposit(a,people,list);break;
case 2:withdrawal(a,people,list);break;
case 3:transfer(a,people,list);break;
case 4:alter(a,people,list);break;
case 5:seclect(a,people,list);break;
}
}
public void deposit(String a,ArrayList<Account> people,ArrayList<Account> list)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("请输入存款金额:");
Scanner in = new Scanner(System.in);
String money=in.next();
int flag=0;
if(money=="q")
{
enterID(people,list);
}
int num=Integer.valueOf(money);
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
Account ac=new Account();
for(int i=0;i<people.size();i++)
{
ac=people.get(i);
if(ac.getaccountID().equals(a))
{
flag=i;
break;
}
}
ac.setaccountbalance(ac.getaccountbalance()+num);
people.set(flag,ac);
System.out.println("当前账户存款操作成功。");
System.out.println("当前账户余额为:"+ac.getaccountbalance());
int operatetype=1;
ac.setoperatetype(operatetype);
ac.setamount(num);
Date date = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
String dateNowStr = sdf.format(date);
ac.setoperatedate(dateNowStr);
list.add(ac);
File file1 = new File("accountlist.txt");
// 对象输出流
ObjectOutputStream out = null;
ObjectOutputStream out1 = null;
try {
out = new ObjectOutputStream(new FileOutputStream(file));
out.writeObject(people);
out.flush();
out.close();
// 将数组对象写入文件
out1 = new ObjectOutputStream(new FileOutputStream(file1));
out1.writeObject(list);
out1.flush();
out1.close();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("1、返回输入账户界面");
System.out.println("2、返回操作界面");
int i=in.nextInt();
switch(i)
{
case 1:enterID(people,list);break;
case 2:enter(a,people,list);break;
}
}
public void withdrawal(String a,ArrayList<Account> people,ArrayList<Account> list)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println(" 当前账户每日可以支取2万元。");
System.out.println(" 1、100元");
System.out.println(" 2、500元");
System.out.println(" 3、1000元");
System.out.println(" 4、1500元");
System.out.println(" 5、2000元");
System.out.println(" 6、5000元");
System.out.println(" 7、其他金额");
System.out.println(" 8、退卡");
System.out.println(" 9、返回");
Scanner in = new Scanner(System.in);
int x=in.nextInt();
int flag = 0;
int money = 0;
switch(x)
{
case 1:money=100;break;
case 2:money=500;break;
case 3:money=1000;break;
case 4:money=1500;break;
case 5:money=2000;break;
case 6:money=5000;break;
case 8:enterID(people,list);break;
case 9:enter(a,people,list);break;
}
if(x==7)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("******************************************************");
System.out.println("请输入取款金额:");
money=in.nextInt();
}
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
Account ac=new Account();
for(int i=0;i<people.size();i++)
{
ac=people.get(i);
if(ac.getaccountID().equals(a))
{
flag=i;
break;
}
}
if(ac.getaccountbalance()<money)
{
System.out.println("账户余额不足");
}
else
{
ac.setaccountbalance(ac.getaccountbalance()-money);
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("当前账户取款操作"+money+"元成功。");
System.out.println("当前账户余额为:"+ac.getaccountbalance()+"元成功。");
}
int operatetype=2;
ac.setoperatetype(operatetype);
ac.setamount(money);
Date date = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
String dateNowStr = sdf.format(date);
ac.setoperatedate(dateNowStr);
list.add(ac);
people.set(flag, ac);
File file1 = new File("accountlist.txt");
ObjectOutputStream out = null;
ObjectOutputStream out1 = null;
try {
out = new ObjectOutputStream(new FileOutputStream(file));
out.writeObject(people);
out.flush();
out.close();
// 将数组对象写入文件
out1 = new ObjectOutputStream(new FileOutputStream(file1));
out1.writeObject(list);
out1.flush();
out1.close();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("1、返回输入账户界面");
System.out.println("2、返回操作界面");
int i=in.nextInt();
switch(i)
{
case 1:enterID(people,list);break;
case 2:enter(a,people,list);break;
}
}
public void transfer(String a,ArrayList<Account> people,ArrayList<Account> list)
{
int flag=0;
int money=0;
Account ab=new Account();
Scanner in = new Scanner(System.in);
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
Account ac=new Account();
for(int i=0;i<people.size();i++)
{
ac=people.get(i);
if(ac.getaccountID().equals(a))
{
flag=i;
break;
} }
int num=0;
int leap=-1;
while(num==0)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("******************************************************");
System.out.println("请输入转账账户:");
String b=in.next();
for(int i=0;i<people.size();i++)
{
int j=0;
ab=people.get(i);
if(ab.getaccountID().equals(b))
{
leap=i;
num=1;
break;
}
else
{
num=0;
}
}
if(num==0)
{
System.out.println("该账户不存在");
}
if(num==1)
{
int num2=0;
while(num2==0)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("******************************************************");
System.out.println("请输入转账金额:");
money=in.nextInt();
if(ac.getaccountbalance()<money)
{
System.out.println("户余额不足");
System.out.println("您当前的余额为"+ac.getaccountbalance()+"元");
}
if(ac.getaccountbalance()>=money)
{
num2=1;
}
}
String name=ab.getaccountname();
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("******************************************************");
System.out.println("请确认是否向"+name+"转账"+money+"元");
System.out.println("确认请按Y,否请按N");
String x=in.next();
if(x.equals("X"))
{
enter(a,people,list);
}
if(x.equals("Y"))
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("******************************************************");
System.out.println("成功向"+name+"转账"+money+"元");
ac.setaccountbalance(ac.getaccountbalance()-money);
ab.setaccountbalance(ab.getaccountbalance()+money);
System.out.println("当前账户余额为:"+ac.getaccountbalance());
num=1;
}
}
}
people.set(flag, ac);
people.set(leap, ab);
int operatetype=3;
ac.setoperatetype(operatetype);
Date date = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
String dateNowStr = sdf.format(date);
ac.setoperatedate(dateNowStr);
ac.setamount(money);
list.add(ac);
File file1 = new File("accountlist.txt");
ObjectOutputStream out = null;
ObjectOutputStream out1 = null;
try {
out = new ObjectOutputStream(new FileOutputStream(file));
out.writeObject(people);
out.flush();
out.close();
// 将数组对象写入文件
out1 = new ObjectOutputStream(new FileOutputStream(file1));
out1.writeObject(list);
out1.flush();
out1.close();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("1、返回输入账户界面");
System.out.println("2、返回操作界面");
int i=in.nextInt();
switch(i)
{
case 1:enterID(people,list);break;
case 2:enter(a,people,list);break;
}
}
public void alter(String a,ArrayList<Account> people,ArrayList<Account> list)
{
int flag=0;
Scanner in = new Scanner(System.in);
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
Account ac=new Account();
for(int i=0;i<people.size();i++)
{
ac=people.get(i);
if(ac.getaccountID().equals(a))
{
flag=i;
break;
} }
int num=0;
while(num==0)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println(" 请输入当前密码:");
String pass=in.next();
if(ac.getaccountpassword().equals(pass))
{
num=1;
}
if(num==0)
System.out.println(" 当前密码录入错误");
if(num==1)
{
System.out.println(" 请输入修改密码:");
String n1=in.next();
System.out.println(" 请输入确认密码:");
String n2=in.next();
if(n1.equals(n2))
{
num=1;
ac.setaccountpassword(n1);
}
else
{
num=0;
System.out.println(" 修改密码与确认密码不一致");
}
}
}
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("当前账户密码修改成功");
people.set(flag, ac);
/*int operatetype=4;
ac.setoperatetype(operatetype);
Date date = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
String dateNowStr = sdf.format(date);
ac.setoperatedate(dateNowStr);
list.add(ac);*/
File file1 = new File("accountlist.txt");
ObjectOutputStream out = null;
ObjectOutputStream out1 = null;
try {
out = new ObjectOutputStream(new FileOutputStream(file));
out.writeObject(people);
out.flush();
out.close();
// 将数组对象写入文件
out1 = new ObjectOutputStream(new FileOutputStream(file1));
out1.writeObject(list);
out1.flush();
out1.close();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("1、返回输入账户界面");
System.out.println("2、返回操作界面");
int i=in.nextInt();
switch(i)
{
case 1:enterID(people,list);break;
case 2:enter(a,people,list);break;
}
}
public void seclect(String a,ArrayList<Account> people,ArrayList<Account> list)
{
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("******************************************************");
Scanner in = new Scanner(System.in);
File file = new File("accountinformation.txt");
ObjectInputStream oin = null;
try {
oin = new ObjectInputStream(new FileInputStream(file));
people = (ArrayList<Account>) oin.readObject();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
Account ac=new Account();
for(int i=0;i<people.size();i++)
{
ac=people.get(i);
if(ac.getaccountID().equals(a))
{
break;
} }
System.out.println("当前账户余额为:"+ac.getaccountbalance()+"元");
System.out.println("账户清单信息为:");
File file1 = new File("accountlist.txt");
ObjectInputStream oon = null;
try {
oon = new ObjectInputStream(new FileInputStream(file1));
list = (ArrayList<Account>) oon.readObject();
}catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}
Account ab=new Account();
for(int i=0;i<list.size();i++)
{
ab=list.get(i);
if(ab.getaccountID().equals(a))
{
String op = null;
if(ab.getoperatetype()==1)
op="存款";
if(ab.getoperatetype()==2)
op="取款";
if(ab.getoperatetype()==3)
op="转账汇款";
System.out.println(""+ab.getoperatedate()+" "+op+" "+ab.getamount());
} }
System.out.println("******************************************************");
System.out.println(" 欢迎"+a+"用户使用中国工商银行自助柜员系统");
System.out.println("1、返回输入账户界面");
System.out.println("2、返回操作界面");
int i=in.nextInt();
switch(i)
{
case 1:enterID(people,list);break;
case 2:enter(a,people,list);break;
}
}
}

  

java源代码的更多相关文章

  1. 分治法解决合并排序(c++和Java源代码)

    Java源代码 public class Mergesort1 { public static void merge(int[]a,int low,int mid,int high){//对两组已经排 ...

  2. java程序保护如何知识产权,特别提供一个java 开发的java 源代码级的混淆器

    java程序保护如何知识产权,特别提供一个java 开发的java 源代码级的混淆器 下载地址:http://yunpan.cn/QXhEcGNYLgwTD 运行方式:java -jar Encryp ...

  3. 全中国的省市县镇乡村数据获取以及展示java源代码

    第一步.准备工作(数据源+工具): 数据源(截止目前最全面权威的官方数据):http://www.stats.gov.cn/tjsj/tjbz/tjyqhdmhcxhfdm/2013/ 爬取数据的工具 ...

  4. PowerDesigner(八)-面向对象模型(用例图,序列图,类图,生成Java源代码及Java源代码生成类图)(转)

    面向对象模型 面向对象模型是利用UML(统一建模语言)的图形来描述系统结构的模型,它从不同角度实现系统的工作状态.这些图形有助于用户,管理人员,系统分析人员,开发人员,测试人员和其他人员之间进行信息交 ...

  5. Android APK反编译得到Java源代码和资源文件

    在此郑重声明,贴出来的目的不是为了去破解人家的软件,完全是一种学习的态度,不过好像通过这种方式也可以去汉化一些外国软件. 一.反编译Apk得到Java源代码 首先要下载两个工具:dex2jar和JD- ...

  6. MyEclipse13中修改Servlet.java源代码

    Servlet.java源代码想要修改的步骤,与低版本的不同废话少说,直接来步骤: 1,在myEclipse的安装目录中搜索com.genuitec.eclipse.wizards文件,如图:选择co ...

  7. 看java源代码

    不会看JDK源代码,相当于没学过Java. 网上不容易找到一篇帮助我解决了如何在Eclipse下查看JDK源代码 的文章. 核心提示:在Eclipse中查看JDK类库的源代码!!! 设置: 1.点 w ...

  8. 混淆器:java程序保护如何知识产权,特别提供一个java 开发的java 源代码级的混淆器

    java程序保护如何知识产权,特别提供一个java 开发的java 源代码级的混淆器 下载地址:http://yunpan.cn/QXhEcGNYLgwTD 运行方式:java -jar Encryp ...

  9. [注意事项&amp;车轮]java源代码 产生局部javadoc api档

    随着Eclipse书写java码时间,有时候,因为我们不知道java函数返回.通过鼠标移动到java该功能,假设它javadoc相关内容将被显示. 但是,并非所有java代码javadoc:连装jav ...

  10. 调试Java源代码时变量的值无法追踪怎么办?

    问题:调试Java源代码时,只能看到源代码,却无法查看源代码中的变量的即时值 原因:jre为了节省空间,在打包时去掉了class文件中的调试信息. 思路:使用jdk里的src.zip源码重新编译生成完 ...

随机推荐

  1. Failed to read artifact ......明明之前可以的

    Type One or more constraints have not been satisfied. mybaits Failed to read artifact ....jar 右键proj ...

  2. IntelliJ IDEA 配置

    1.让IntelliJ IDEA 驼峰选择生效 驼峰选择,就是选择的时候按照驼峰规则选择单词,不是选择整个单词 让IntelliJ IDEA 驼峰选择生效 2.查看当前类中的所有方法 Alt+7 3. ...

  3. centos U盘挂载问题

    查看u盘路径 fdisk -l Disk /dev/sda: 16.2 GB, 16236150784 bytes, 31711232 sectors Units = sectors of 1 * 5 ...

  4. [Harbor]Docker登录Harbor仓库(HTTP方式)

    Docker登录到Harbor仓库时,不管是使用http协议还是使用https协议,都需要修改一些配置. 这篇文章来介绍一下,在使用http协议时,需要进行什么哪些配置. 首先,确定自己的Harbor ...

  5. mysql 二进包在linux下安装过程

    cp mysql-5.6.17-linux-glibc2.5-i686 /usr/local/mysql -r groupadd mysql和useradd -r -g mysql mysql 进入安 ...

  6. vue生命周期学习(watch跟computed)

    1.watch钩子函数监听数据的变化 watch 的一个特点是,最初绑定的时候是不会执行的,要等到 firstName 改变时才执行监听计算. <div> <p>FullNam ...

  7. 题解-hdu2866 Special Prime

    Problem hdu-2866 题意:求区间\([2,L]\)有多少素数\(p\)满足\(n^3+pn^2=m^3\),其中\(n,m\)属于任意整数 Solution 原式等价于\(n^2(p+n ...

  8. centos6.8上PHP5.3升级到PHP5.4及更高版本方法

    执行命令下载.安装yum源,当前是针对Centos6并且64位版本的源: [root@T_249 yum.repos.d]# rpm -ivh http://dl.fedoraproject.org/ ...

  9. <杂记>该换个背景图了

    ..当然我刚开始也是懵逼的,我有发现这里可以写css,但是还是缺个图片地址,想了想,这不是还有个相册功能吗. 那应该就是把自己要换的图片上传到相册吧. 右击图片,选择检查元素找到图片的src 如:ht ...

  10. Qt 出现“undefined reference to `vtable for”

    在QT中定义了一个线程类,继承自QThread, 在类中未加 Q_OBJECT 时编译正常,加入后报错如下: undefined reference to `vtable for myThread' ...