最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

Java簡(jiǎn)單實(shí)現(xiàn)銀行ATM系統(tǒng)

 更新時(shí)間:2022年05月27日 10:15:21   作者:息壤愛學(xué)習(xí)  
這篇文章主要為大家詳細(xì)介紹了Java簡(jiǎn)單實(shí)現(xiàn)銀行ATM系統(tǒng),文中示例代碼介紹的非常詳細(xì),具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下

本文實(shí)例為大家分享了Java實(shí)現(xiàn)銀行ATM系統(tǒng)的具體代碼,供大家參考,具體內(nèi)容如下

實(shí)現(xiàn)步驟:

定義賬戶類,用于后期創(chuàng)建賬戶對(duì)象封裝用戶的賬戶信息。

賬戶類中的信息至少需要包含(卡號(hào)、姓名、密碼、余額、取現(xiàn)額度)

需要準(zhǔn)備一個(gè)ArrayList的集合,用于存儲(chǔ)系統(tǒng)用戶的賬戶對(duì)象。

定義一個(gè)系統(tǒng)啟動(dòng)類ATMSystem需要展示歡迎頁(yè)包含2個(gè)功能:開戶功能、登錄賬戶。

賬戶類 Account

package test;
/*賬戶類*/
public class Account {
? ? private String cardId; //卡號(hào)
? ? private String userName; //客戶名字
? ? private String password; //密碼
? ? private double money; //余額
? ? private double quoteMoney; //當(dāng)次限額
? ? public Account(){}
? ? public Account(String cardId,String userName,String password,double quoteMoney){
? ? ? ? this.cardId = cardId;
? ? ? ? this.userName =userName;
? ? ? ? this.password = password;
? ? ? ? this.quoteMoney = quoteMoney;
? ? }

? ? public String getCardId() {
? ? ? ? return cardId;
? ? }

? ? public void setCardId(String cardId) {
? ? ? ? this.cardId = cardId;
? ? }

? ? public double getMoney() {
? ? ? ? return money;
? ? }

? ? public void setMoney(double money) {
? ? ? ? this.money = money;
? ? }

? ? public double getQuoteMoney() {
? ? ? ? return quoteMoney;
? ? }

? ? public void setQuoteMoney(double quoteMoney) {
? ? ? ? this.quoteMoney = quoteMoney;
? ? }

? ? public String getPassword() {
? ? ? ? return password;
? ? }

? ? public void setPassword(String password) {
? ? ? ? this.password = password;
? ? }

? ? public String getUserName() {
? ? ? ? return userName;
? ? }

? ? public void setUserName(String userName) {
? ? ? ? this.userName = userName;
? ? }
}

AtmSystem 類

package test;

import java.util.ArrayList;
import java.util.Random;
import java.util.Scanner;

public class AtmSystem {
? ? public static void main(String[] args) {
? ? ? ? //用數(shù)組儲(chǔ)存賬戶對(duì)象
? ? ? ? ArrayList<Account> accounts = new ArrayList<>();
? ? ? ? //首頁(yè):登錄 開戶
? ? ? ? showMain(accounts);
? ? }
? ? public static void showMain(ArrayList<Account> accounts){
? ? ? ? System.out.println("================歡迎進(jìn)入首頁(yè)界面===============");
? ? ? ? Scanner sc = new Scanner(System.in);
? ? ? ? while (true){
? ? ? ? ? ? System.out.println("請(qǐng)輸入您想要進(jìn)行的操作:");
? ? ? ? ? ? System.out.println("1.登錄");
? ? ? ? ? ? System.out.println("2.開戶");
? ? ? ? ? ? System.out.println("您可以輸入命令了:");
? ? ? ? ? ? int command = sc.nextInt();
? ? ? ? ? ? switch (command){
? ? ? ? ? ? ? ? case 1:
? ? ? ? ? ? ? ? ? ? //登錄
? ? ? ? ? ? ? ? ? ? login(accounts,sc);
? ? ? ? ? ? ? ? ? ? break;
? ? ? ? ? ? ? ? case 2:
? ? ? ? ? ? ? ? ? ? //開戶
? ? ? ? ? ? ? ? ? ? register(accounts,sc);
? ? ? ? ? ? ? ? ? ? break;
? ? ? ? ? ? ? ? default:
? ? ? ? ? ? ? ? ? ? System.out.println("您的輸入有誤!");
? ? ? ? ? ? }
? ? ? ? }
? ? }
// ? ? ? ? ? ?鍵盤錄入姓名、密碼、確認(rèn)密碼(需保證兩次密碼一致)
//
// ? ? ? ? ? ?生成賬戶卡號(hào),卡號(hào)必須由系統(tǒng)自動(dòng)生成8位數(shù)字(必須保證卡號(hào)的唯一)
//
// ? ? ? ? ? ?創(chuàng)建Account賬戶類對(duì)象用于封裝賬戶信息(姓名、密碼、卡號(hào))
//
// ? ? ? ? ? ?把Account賬戶類對(duì)象存入到集合accounts中去。
? ? public static void register(ArrayList<Account> accounts,Scanner sc){
? ? ? ? System.out.println("===============用戶開戶================");
? ? ? ? System.out.println("請(qǐng)輸入開戶名稱:");
? ? ? ? String name = sc.next();
? ? ? ? String password = "";
? ? ? ? while (true){
? ? ? ? ? ? System.out.println("請(qǐng)輸入開戶密碼:");
? ? ? ? ? ? password = sc.next();
? ? ? ? ? ? System.out.println("請(qǐng)?jiān)俅未_認(rèn)密碼:");
? ? ? ? ? ? String okPassword = sc.next();
? ? ? ? ? ? //判斷兩次輸入密碼
? ? ? ? ? ? if (okPassword.equals(password)){
? ? ? ? ? ? ? ? break;
? ? ? ? ? ? }else{
? ? ? ? ? ? ? ? System.out.println("兩次密碼必須一致");
? ? ? ? ? ? }
? ? ? ? }
? ? ? ? System.out.println("請(qǐng)輸入當(dāng)次限額:");
? ? ? ? double quotaMoney = sc.nextDouble();
? ? ? ? String cardId = createCard(accounts);
? ? ? ? //封裝賬戶
? ? ? ? Account account = new Account(cardId,name,password,quotaMoney);
? ? ? ? accounts.add(account);
? ? ? ? System.out.println("恭喜您,開戶成功!你的卡號(hào)是:"+account.getCardId()+"請(qǐng)您妥善保管!");
? ? }
? ? public static String createCard(ArrayList<Account> accounts){
? ? ? ? while (true){
? ? ? ? ? ? //生成8位隨機(jī)號(hào)碼,且不重復(fù)
? ? ? ? ? ? String cardId = "";
? ? ? ? ? ? Random r = new Random();
? ? ? ? ? ? for (int i=0;i<8;i++){
? ? ? ? ? ? ? ? cardId += r.nextInt(10);
? ? ? ? ? ? }
? ? ? ? ? ? Account acc = getAccountByCardId(cardId, accounts);
? ? ? ? ? ? if (acc == null){
? ? ? ? ? ? ? ? return cardId;
? ? ? ? ? ? }
? ? ? ? }
? ? }
? ? public static Account getAccountByCardId(String cardId,ArrayList<Account> accounts){
? ? ? ? for (int i=0;i< accounts.size();i++){
? ? ? ? ? ? Account acc = accounts.get(i);
? ? ? ? ? ? if (acc.getCardId().equals(cardId)){
? ? ? ? ? ? ? ? return acc;
? ? ? ? ? ? }
? ? ? ? }
? ? ? ? return null;
? ? }
? ? //登錄
// ? ? ? ? ? ?讓用戶鍵盤錄入卡號(hào),根據(jù)卡號(hào)查詢賬戶對(duì)象。
//
// ? ? ? ? ? ?如果沒有找到了賬戶對(duì)象,說(shuō)明卡號(hào)不存在,提示繼續(xù)輸入卡號(hào)。
//
// ? ? ? ? ? ?如果找到了賬戶對(duì)象,說(shuō)明卡號(hào)存在,繼續(xù)輸入密碼。
//
// ? ? ? ? ? ?如果密碼不正確,提示繼續(xù)輸入密碼
//
// ? ? ? ? ? ?如果密碼正確,提示登陸成功??!
? ? public static void login(ArrayList<Account> accounts,Scanner sc){
? ? ? ? //判斷系統(tǒng)中是否存在賬戶
? ? ? ? if (accounts.size()==0){
? ? ? ? ? ? System.out.println("當(dāng)前系統(tǒng)查無(wú)此賬戶,請(qǐng)注冊(cè)!");
? ? ? ? ? ? return;
? ? ? ? }
? ? ? ? while (true){
? ? ? ? ? ? System.out.println("請(qǐng)輸入登錄賬號(hào):");
? ? ? ? ? ? String cardId = sc.next();
? ? ? ? ? ? Account acc = getAccountByCardId(cardId,accounts);
? ? ? ? ? ? if (acc!=null){
? ? ? ? ? ? ? ? while (true){
? ? ? ? ? ? ? ? ? ? //輸入密碼
? ? ? ? ? ? ? ? ? ? System.out.println("請(qǐng)輸入密碼:");
? ? ? ? ? ? ? ? ? ? String password = sc.next();
? ? ? ? ? ? ? ? ? ? if (acc.getPassword().equals(password)){
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("恭喜您," + acc.getUserName() + "先生/女士成功登錄!" + "您的賬戶:" + acc.getCardId());
? ? ? ? ? ? ? ? ? ? ? ? //展示操作頁(yè)面
? ? ? ? ? ? ? ? ? ? ? ? showUserCommand(sc,acc,accounts);
? ? ? ? ? ? ? ? ? ? ? ? return;
? ? ? ? ? ? ? ? ? ? }else{
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("Sorry,該賬戶不存在!");
? ? ? ? ? ? ? ? ? ? }
? ? ? ? ? ? ? ? }
? ? ? ? ? ? }
? ? ? ? }
? ? }
? ? private static void showUserCommand(Scanner sc, Account acc , ArrayList<Account> accounts) {
? ? ? ? while (true) {
? ? ? ? ? ? System.out.println("==================用戶操作界面===================");
? ? ? ? ? ? System.out.println("1、查詢賬戶");
? ? ? ? ? ? System.out.println("2、存款");
? ? ? ? ? ? System.out.println("3、取款");
? ? ? ? ? ? System.out.println("4、轉(zhuǎn)賬");
? ? ? ? ? ? System.out.println("5、修改密碼");
? ? ? ? ? ? System.out.println("6、退出");
? ? ? ? ? ? System.out.println("7、注銷賬戶");
? ? ? ? ? ? System.out.println("請(qǐng)您輸入操作命令:");
? ? ? ? ? ? int command = sc.nextInt();
? ? ? ? ? ? switch (command) {
? ? ? ? ? ? ? ? case 1:
? ? ? ? ? ? ? ? ? ? // 查詢賬戶
? ? ? ? ? ? ? ? ? ? showAccount(acc);
? ? ? ? ? ? ? ? ? ? break;
? ? ? ? ? ? ? ? case 2:
? ? ? ? ? ? ? ? ? ? // 存款
? ? ? ? ? ? ? ? ? ? depositMoney(acc, sc);
? ? ? ? ? ? ? ? ? ? break;
? ? ? ? ? ? ? ? case 3:
? ? ? ? ? ? ? ? ? ? // 取款
? ? ? ? ? ? ? ? ? ? drawMoney(acc,sc);
? ? ? ? ? ? ? ? ? ? break;
? ? ? ? ? ? ? ? case 4:
? ? ? ? ? ? ? ? ? ? // 轉(zhuǎn)賬
? ? ? ? ? ? ? ? ? ? transferMoney(accounts, acc , sc);
? ? ? ? ? ? ? ? ? ? break;
? ? ? ? ? ? ? ? case 5:
? ? ? ? ? ? ? ? ? ? // 修改密碼
? ? ? ? ? ? ? ? ? ? updatePassWord(acc,sc);
? ? ? ? ? ? ? ? ? ? return; // 結(jié)束當(dāng)前操作的方法
? ? ? ? ? ? ? ? case 6:
? ? ? ? ? ? ? ? ? ? // 退出
? ? ? ? ? ? ? ? ? ? System.out.println("歡迎下次光臨!!");
? ? ? ? ? ? ? ? ? ? return; // 結(jié)束當(dāng)前操作的方法!
? ? ? ? ? ? ? ? case 7:
? ? ? ? ? ? ? ? ? ? // 注銷賬戶
? ? ? ? ? ? ? ? ? ? // 從當(dāng)前集合中抹掉當(dāng)前賬戶對(duì)象即可
? ? ? ? ? ? ? ? ? ? accounts.remove(acc);
? ? ? ? ? ? ? ? ? ? System.out.println("銷戶成功了!!");
? ? ? ? ? ? ? ? ? ? return;// 結(jié)束當(dāng)前操作的方法!
? ? ? ? ? ? ? ? default:
? ? ? ? ? ? ? ? ? ? System.out.println("您的命令輸入有誤~~~");
? ? ? ? ? ? }
? ? ? ? }
? ? }
? ? private static void showAccount(Account acc) {
? ? ? ? System.out.println("==================當(dāng)前賬戶詳情===================");
? ? ? ? System.out.println("卡號(hào):" + acc.getCardId());
? ? ? ? System.out.println("姓名:" + acc.getUserName());
? ? ? ? System.out.println("余額:" + acc.getMoney());
? ? ? ? System.out.println("當(dāng)次限額:" + acc.getQuoteMoney());
? ? }
// ? ? ? ? ? ?存款就是拿到當(dāng)前賬戶對(duì)象。
//
// ? ? ? ? ? ?然后讓用戶輸入存款的金額。
//
// ? ? ? ? ? ?調(diào)用賬戶對(duì)象的setMoney方法將賬戶余額修改成存錢后的余額。
//
// ? ? ? ? ? ?存錢后需要查詢一下賬戶信息,確認(rèn)是否存錢成功了!
? ? private static void depositMoney(Account acc, Scanner sc) {
? ? ? ? System.out.println("==================存錢操作===================");
? ? ? ? System.out.println("請(qǐng)您輸入存款的金額:");
? ? ? ? double money = sc.nextDouble();

? ? ? ? // 直接把金額修改到賬戶對(duì)象的money屬性中去
? ? ? ? acc.setMoney(acc.getMoney() + money);
? ? ? ? System.out.println("存款完成!!");
? ? ? ? showAccount(acc);
? ? }
// ? ? ? ? ? ?取款需要先判斷賬戶是否有錢。
//
// ? ? ? ? ? ?有錢則拿到自己賬戶對(duì)象。
//
// ? ? ? ? ? ?然后讓用戶輸入取款金額
//
// ? ? ? ? ? ?判斷取款金額是否超過(guò)了當(dāng)次限額,以及余額是否足夠
//
// ? ? ? ? ? ?滿足要求則調(diào)用賬戶對(duì)象的setMoney方法完成金額的修改。
? ? private static void drawMoney(Account acc, Scanner sc) {
? ? ? ? System.out.println("==================取款操作===================");
? ? ? ? // 1、判斷它的賬戶是否足夠100元
? ? ? ? if(acc.getMoney() >= 100){
? ? ? ? ? ? while (true) {
? ? ? ? ? ? ? ? System.out.println("請(qǐng)您輸入取款的金額:");
? ? ? ? ? ? ? ? double money = sc.nextDouble();
? ? ? ? ? ? ? ? // 2、判斷這個(gè)金額有沒有超過(guò)當(dāng)次限額
? ? ? ? ? ? ? ? if(money > acc.getQuoteMoney()){
? ? ? ? ? ? ? ? ? ? System.out.println("您當(dāng)次取款金額超過(guò)每次限額,不要取那么多,每次最多可以?。? + acc.getQuoteMoney());
? ? ? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? ? ? // 3、判斷當(dāng)前余額是否足夠你取錢
? ? ? ? ? ? ? ? ? ? if(acc.getMoney() >= money){
? ? ? ? ? ? ? ? ? ? ? ? // 夠錢,可以取錢了
? ? ? ? ? ? ? ? ? ? ? ? acc.setMoney(acc.getMoney() - money);
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("恭喜您,取錢" + money + "成功了!當(dāng)前賬戶還剩余:" + acc.getMoney());
? ? ? ? ? ? ? ? ? ? ? ? return;// 取錢后干掉取錢方法
? ? ? ? ? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("余額不足啊!");
? ? ? ? ? ? ? ? ? ? }
? ? ? ? ? ? ? ? }
? ? ? ? ? ? }
? ? ? ? }else {
? ? ? ? ? ? System.out.println("您自己的金額沒有超過(guò)100元,就別取了~~~");
? ? ? ? }
? ? }
// ? ? ? ? ? ?轉(zhuǎn)賬功能需要判斷系統(tǒng)中是否有2個(gè)賬戶對(duì)象及以上。
//
// ? ? ? ? ? ?同時(shí)還要判斷自己賬戶是否有錢。
//
// ? ? ? ? ? ?接下來(lái)需要輸入對(duì)方卡號(hào),判斷對(duì)方賬戶是否存在。
//
// ? ? ? ? ? ?對(duì)方賬戶存在還需要認(rèn)證對(duì)方戶主的姓氏。
//
// ? ? ? ? ? ?滿足要求則可以把自己賬戶對(duì)象的金額修改到對(duì)方賬戶對(duì)象中去。
? ? private static void transferMoney(ArrayList<Account> accounts, Account acc, Scanner sc) {
? ? ? ? // 1、判斷系統(tǒng)中是否有2個(gè)賬戶及以上
? ? ? ? if(accounts.size() < 2){
? ? ? ? ? ? System.out.println("對(duì)不起,系統(tǒng)中無(wú)其他賬戶,您不可以轉(zhuǎn)賬!");
? ? ? ? ? ? return;
? ? ? ? }

? ? ? ? // 2、判斷自己的賬戶對(duì)象中是否有錢
? ? ? ? if(acc.getMoney() == 0){
? ? ? ? ? ? System.out.println("對(duì)不起,您自己都沒錢,就別轉(zhuǎn)了~~");
? ? ? ? ? ? return;
? ? ? ? }

? ? ? ? // 3、開始轉(zhuǎn)賬邏輯
? ? ? ? while (true) {
? ? ? ? ? ? System.out.println("請(qǐng)您輸入對(duì)方賬戶的卡號(hào):");
? ? ? ? ? ? String cardId = sc.next();
? ? ? ? ? ? Account account = getAccountByCardId(cardId , accounts);
? ? ? ? ? ? // 判斷這個(gè)賬戶對(duì)象是否存在,存在說(shuō)明對(duì)方卡號(hào)輸入正確
? ? ? ? ? ? if(account != null){
? ? ? ? ? ? ? ? // 判斷這個(gè)賬戶對(duì)象是否是當(dāng)前登錄的賬戶自己
? ? ? ? ? ? ? ? if(account.getCardId().equals(acc.getCardId())){
? ? ? ? ? ? ? ? ? ? // 正在給自己轉(zhuǎn)賬
? ? ? ? ? ? ? ? ? ? System.out.println("您不可以為自己轉(zhuǎn)賬!");
? ? ? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? ? ? // 確認(rèn)對(duì)方的姓氏
? ? ? ? ? ? ? ? ? ? String name = "*" + account.getUserName().substring(1);
? ? ? ? ? ? ? ? ? ? System.out.print("請(qǐng)您確認(rèn)【" + name + "】的姓氏:");
? ? ? ? ? ? ? ? ? ? String preName = sc.next(); // 王
? ? ? ? ? ? ? ? ? ? if(account.getUserName().startsWith(preName)){
? ? ? ? ? ? ? ? ? ? ? ? // 真正開始轉(zhuǎn)賬了
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("請(qǐng)您輸入轉(zhuǎn)賬的金額:");
? ? ? ? ? ? ? ? ? ? ? ? double money = sc.nextDouble();
? ? ? ? ? ? ? ? ? ? ? ? // 判斷這個(gè)金額是否超過(guò)了自己的余額
? ? ? ? ? ? ? ? ? ? ? ? if(money > acc.getMoney() ){
? ? ? ? ? ? ? ? ? ? ? ? ? ? System.out.println("對(duì)不起,您要轉(zhuǎn)賬的金額太多,您最多可以轉(zhuǎn)賬多少:" + acc.getMoney());
? ? ? ? ? ? ? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? ? ? ? ? ? ? // 真的可以轉(zhuǎn)了
? ? ? ? ? ? ? ? ? ? ? ? ? ? acc.setMoney(acc.getMoney() - money);
? ? ? ? ? ? ? ? ? ? ? ? ? ? account.setMoney(account.getMoney() + money);
? ? ? ? ? ? ? ? ? ? ? ? ? ? System.out.println("恭喜您,轉(zhuǎn)賬成功了,已經(jīng)為" + account.getUserName() +"轉(zhuǎn)賬多少:" + money);
? ? ? ? ? ? ? ? ? ? ? ? ? ? showAccount(acc);
? ? ? ? ? ? ? ? ? ? ? ? ? ? return;
? ? ? ? ? ? ? ? ? ? ? ? }
? ? ? ? ? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("對(duì)不起,您認(rèn)證的信息有誤~~~");
? ? ? ? ? ? ? ? ? ? }
? ? ? ? ? ? ? ? }
? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? System.out.println("對(duì)不起,您輸入的轉(zhuǎn)賬卡號(hào)有問(wèn)題!");
? ? ? ? ? ? }
? ? ? ? }
? ? }
? ? private static void updatePassWord(Account acc, Scanner sc) {
? ? ? ? System.out.println("===========修改密碼=======================");
? ? ? ? while (true) {
? ? ? ? ? ? System.out.println("請(qǐng)您輸入正確的密碼:");
? ? ? ? ? ? String okPassWord = sc.next();
? ? ? ? ? ? // 判斷密碼是否正確
? ? ? ? ? ? if(acc.getPassword().equals(okPassWord)){
? ? ? ? ? ? ? ? while (true) {
? ? ? ? ? ? ? ? ? ? // 可以輸入新密碼
? ? ? ? ? ? ? ? ? ? System.out.println("請(qǐng)您輸入新的密碼:");
? ? ? ? ? ? ? ? ? ? String newPassWord = sc.next();

? ? ? ? ? ? ? ? ? ? System.out.println("請(qǐng)您輸入確認(rèn)密碼:");
? ? ? ? ? ? ? ? ? ? String okNewPassWord = sc.next();

? ? ? ? ? ? ? ? ? ? if(newPassWord.equals(okNewPassWord)) {
? ? ? ? ? ? ? ? ? ? ? ? // 修改賬戶對(duì)象的密碼為新密碼
? ? ? ? ? ? ? ? ? ? ? ? acc.setPassword(newPassWord);
? ? ? ? ? ? ? ? ? ? ? ? return; // 直接結(jié)束掉??!
? ? ? ? ? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? ? ? ? ? System.out.println("您兩次輸入的密碼不一致~~");
? ? ? ? ? ? ? ? ? ? }
? ? ? ? ? ? ? ? }

? ? ? ? ? ? }else {
? ? ? ? ? ? ? ? System.out.println("當(dāng)前輸入的密碼不正確~~~");
? ? ? ? ? ? }
? ? ? ? }

? ? }
}

以上就是本文的全部?jī)?nèi)容,希望對(duì)大家的學(xué)習(xí)有所幫助,也希望大家多多支持腳本之家。

相關(guān)文章

  • SpringBoot?內(nèi)置工具類的使用

    SpringBoot?內(nèi)置工具類的使用

    本文主要介紹了SpringBoot?內(nèi)置工具類的使用,文中通過(guò)示例代碼介紹的非常詳細(xì),具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下
    2021-12-12
  • java的Arrays工具類實(shí)戰(zhàn)

    java的Arrays工具類實(shí)戰(zhàn)

    java.util.Arrays類能方便地操作數(shù)組,它提供的所有方法都是靜態(tài)的。Arrays作為一個(gè)工具類,能很好的操作數(shù)組。下面介紹主要使用的幾個(gè)函數(shù)
    2016-12-12
  • JAVA重復(fù)調(diào)用接口導(dǎo)致數(shù)據(jù)不一致的問(wèn)題解決

    JAVA重復(fù)調(diào)用接口導(dǎo)致數(shù)據(jù)不一致的問(wèn)題解決

    在使用JAVA進(jìn)行開發(fā)時(shí),我們經(jīng)常會(huì)遇到要調(diào)用接口來(lái)獲取數(shù)據(jù)的情況,本文主要介紹了JAVA重復(fù)調(diào)用接口導(dǎo)致數(shù)據(jù)不一致的問(wèn)題解決,具有一定的參考價(jià)值,感興趣的可以了解一下
    2024-01-01
  • Activiti流程圖查看實(shí)例

    Activiti流程圖查看實(shí)例

    這篇文章主要介紹了Activiti流程圖查看實(shí)例,需要的朋友可以參考下
    2014-08-08
  • Java字符串逆序方法詳情

    Java字符串逆序方法詳情

    這篇文章主要介紹了Java字符逆序,字符逆序主要原理就是將一個(gè)字符串str的內(nèi)容顛倒過(guò)來(lái),并輸出,下文操作分享需要的小伙伴可以參考一下
    2022-03-03
  • Java用POI解析excel并獲取所有單元格數(shù)據(jù)的實(shí)例

    Java用POI解析excel并獲取所有單元格數(shù)據(jù)的實(shí)例

    下面小編就為大家?guī)?lái)一篇Java用POI解析excel并獲取所有單元格數(shù)據(jù)的實(shí)例。小編覺得挺不錯(cuò)的,現(xiàn)在就分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2017-10-10
  • Maven管理多模塊應(yīng)用的統(tǒng)一版本號(hào)實(shí)現(xiàn)

    Maven管理多模塊應(yīng)用的統(tǒng)一版本號(hào)實(shí)現(xiàn)

    本文主要介紹了Maven管理多模塊應(yīng)用的統(tǒng)一版本號(hào)實(shí)現(xiàn),使用versions-maven-plugin插件和占位符結(jié)合flatten-maven-plugin插件來(lái)實(shí)現(xiàn),感興趣的可以了解一下
    2024-12-12
  • 在springboot中對(duì)kafka進(jìn)行讀寫的示例代碼

    在springboot中對(duì)kafka進(jìn)行讀寫的示例代碼

    本篇文章主要介紹了在springboot中對(duì)kafka進(jìn)行讀寫的示例代碼,小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2017-09-09
  • springboot3生成本地文件url的實(shí)現(xiàn)示例

    springboot3生成本地文件url的實(shí)現(xiàn)示例

    本文主要介紹了springboot3生成本地文件url的實(shí)現(xiàn)示例,從而提供一種高效的文件管理方式,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)學(xué)習(xí)吧
    2024-01-01
  • Mybatis全面分頁(yè)插件

    Mybatis全面分頁(yè)插件

    這篇文章主要為大家詳細(xì)介紹了Mybatis全面分頁(yè)插件的使用方法,比較適用于在分頁(yè)時(shí)候進(jìn)行攔截,感興趣的小伙伴們可以參考一下
    2016-08-08

最新評(píng)論

麻江县| 临漳县| 马尔康县| 青川县| 即墨市| 抚州市| 巴塘县| 桓仁| 石台县| 蕉岭县| 涿州市| 西乌珠穆沁旗| 康平县| 铜陵市| 余江县| 明水县| 射阳县| 保德县| 锡林郭勒盟| 漳平市| 新泰市| 岳阳县| 汤原县| 西城区| 大兴区| 山丹县| 大新县| 澄迈县| 新野县| 阿拉善左旗| 通辽市| 新龙县| 田东县| 曲阜市| 吴川市| 乾安县| 贵阳市| 安徽省| 阳原县| 深圳市| 桓仁|