current location:Home > Technical Articles > Java > JavaBase

  • How to determine whether a specified character exists in java
    How to determine whether a specified character exists in java
    In Java, you can use the contains method to determine whether the specified character exists. The java.lang.String.contains() method returns true if and only if this string contains the specified char value sequence.
    JavaBase 3355 2019-12-28 15:10:02
  • How java is cross-platform
    How java is cross-platform
    Methods for java to achieve cross-platform: 1. By specifying the value range and behavior of basic data types in the Java language. 2. Compile all java files into class files. 3. Convert the Class file into a binary file corresponding to the platform through the Java virtual machine.
    JavaBase 5023 2019-12-28 14:55:53
  • Java determines whether a string contains the specified string
    Java determines whether a string contains the specified string
    Java can use the indexOf(String s) method to determine whether a string contains the specified string. If it does, the returned value is the starting position of the substring in the parent string. If it does not contain, the entire return value must be -1. .
    JavaBase 4044 2019-12-28 14:19:14
  • How to compile java into class file
    How to compile java into class file
    Method to compile java into class file: 1. Open cmd and enter the bin directory of jdk installation. 2. Then find the Java file to be compiled and use the Javac command to compile the java file into a class file.
    JavaBase 8646 2019-12-28 14:03:29
  • Java determines whether a string is Chinese
    Java determines whether a string is Chinese
    How to determine whether a string is Chinese in java: You can use "string.matches("[\u4E00-\u9FA5]+")" to determine whether a string is Chinese. "\u4E00-\u9FA5" is the Chinese Unicode encoding range.
    JavaBase 5919 2019-12-28 13:31:54
  • What is the function of java method
    What is the function of java method
    A Java method is a collection of statements that together perform a function. The role of the java method: it can make the program shorter and clearer, improve the efficiency of program development, and improve the reusability of the code.
    JavaBase 5036 2019-12-28 11:16:08
  • How to write a file in java
    How to write a file in java
    How to write files in java: 1. Use FileWritter to write files. The character stream writes characters to the file. By default, new content will be used to replace all existing content. 2. Use BufferedWriter to write files.
    JavaBase 7405 2019-12-28 10:57:43
  • Java determines whether the database exists
    Java determines whether the database exists
    Whether the Java database exists can be judged by using statements such as "String sql="SELECT COUNT(*) FROM information_schema.schemata WHERE schema_name=\""+database+"\""".
    JavaBase 3260 2019-12-28 10:42:46
  • How to use t in java
    How to use t in java
    <T>T in Java means that the return value is a generic type, and a single T means to limit the parameter type you pass. It is mostly used to jointly operate a class object and then obtain the collection information inside.
    JavaBase 3980 2019-12-28 10:04:46
  • How to generate exe from java program
    How to generate exe from java program
    How to generate exe from java: 1. First package the java program into a jar file. 2. Use exe4j to generate the jar package into an exe file. First click next, then enter the Project type, select "JRA IN EXE", and then perform some configurations to generate the packaged jar file into an exe.
    JavaBase 8673 2019-12-28 09:53:02
  • Java uses regular rules to determine whether it is a number
    Java uses regular rules to determine whether it is a number
    Java regular method to determine whether a string is a number: first define the regular expression "^-?\\d+(\\.\\d+)?$", and then use the matches() method to detect whether the string matches the given regular expression You can use the formula to determine whether it is a number.
    JavaBase 4614 2019-12-28 09:27:51
  • Java method to determine whether socket is disconnected
    Java method to determine whether socket is disconnected
    How to determine whether the socket is disconnected in java: You can use the sendUrgentData method in the socket class to determine whether the SO_OOBINLINE attribute of the socket is turned on. An exception will be thrown in java.
    JavaBase 2890 2019-12-27 16:51:28
  • Solution to Chinese garbled characters in Java database
    Solution to Chinese garbled characters in Java database
    Solution to Chinese garbled characters in Java database: Add useUnicode=true&characterEncoding=UTF-8 parameters after the URL configured in the database to solve the problem of database garbled characters.
    JavaBase 3511 2019-12-27 16:31:46
  • How to determine whether two dates are the same day in java
    How to determine whether two dates are the same day in java
    How to determine whether two dates are on the same day in java: 1. Use the Calendar.YEAR and Calendar.DAY_OF_YEAR methods to determine whether two dates are on the same day in the same year. 2. Use SimpleDateFormat to format the two dates, and then use equals to judge.
    JavaBase 11503 2019-12-27 16:13:58
  • Java determines whether a date is a weekend
    Java determines whether a date is a weekend
    Use the "get(Calendar.DAY_OF_WEEK)-1" method to obtain the number corresponding to the specified date. When the obtained number is 0 or 6, it means that the date is a weekend. In Java, you can use the Calendar.DAY_OF_WEEK method to get the number corresponding to the day of the week for a specified date, 1-7 corresponds to Sunday to Saturday.
    JavaBase 3826 2019-12-27 15:39:00

Tool Recommendations

jQuery enterprise message form contact code

jQuery enterprise message form contact code is a simple and practical enterprise message form and contact us introduction page code.
form button
2024-02-29

HTML5 MP3 music box playback effects

HTML5 MP3 music box playback special effect is an mp3 music player based on HTML5 css3 to create cute music box emoticons and click the switch button.

HTML5 cool particle animation navigation menu special effects

HTML5 cool particle animation navigation menu special effect is a special effect that changes color when the navigation menu is hovered by the mouse.
Menu navigation
2024-02-29

jQuery visual form drag and drop editing code

jQuery visual form drag and drop editing code is a visual form based on jQuery and bootstrap framework.
form button
2024-02-29

Organic fruit and vegetable supplier web template Bootstrap5

An organic fruit and vegetable supplier web template-Bootstrap5
Bootstrap template
2023-02-03

Bootstrap3 multifunctional data information background management responsive web page template-Novus

Bootstrap3 multifunctional data information background management responsive web page template-Novus
backend template
2023-02-02

Real estate resource service platform web page template Bootstrap5

Real estate resource service platform web page template Bootstrap5
Bootstrap template
2023-02-02

Simple resume information web template Bootstrap4

Simple resume information web template Bootstrap4
Bootstrap template
2023-02-02

Cute summer elements vector material (EPS PNG)

This is a cute summer element vector material, including the sun, sun hat, coconut tree, bikini, airplane, watermelon, ice cream, ice cream, cold drink, swimming ring, flip-flops, pineapple, conch, shell, starfish, crab, Lemons, sunscreen, sunglasses, etc., the materials are provided in EPS and PNG formats, including JPG previews.
PNG material
2024-05-09

Four red 2023 graduation badges vector material (AI EPS PNG)

This is a red 2023 graduation badge vector material, four in total, available in AI, EPS and PNG formats, including JPG preview.
PNG material
2024-02-29

Singing bird and cart filled with flowers design spring banner vector material (AI EPS)

This is a spring banner vector material designed with singing birds and a cart full of flowers. It is available in AI and EPS formats, including JPG preview.
banner picture
2024-02-29

Golden graduation cap vector material (EPS PNG)

This is a golden graduation cap vector material, available in EPS and PNG formats, including JPG preview.
PNG material
2024-02-27

Home Decor Cleaning and Repair Service Company Website Template

Home Decoration Cleaning and Maintenance Service Company Website Template is a website template download suitable for promotional websites that provide home decoration, cleaning, maintenance and other service organizations. Tip: This template calls the Google font library, and the page may open slowly.
Front-end template
2024-05-09

Fresh color personal resume guide page template

Fresh color matching personal job application resume guide page template is a personal job search resume work display guide page web template download suitable for fresh color matching style. Tip: This template calls the Google font library, and the page may open slowly.
Front-end template
2024-02-29

Designer Creative Job Resume Web Template

Designer Creative Job Resume Web Template is a downloadable web template for personal job resume display suitable for various designer positions. Tip: This template calls the Google font library, and the page may open slowly.
Front-end template
2024-02-28

Modern engineering construction company website template

The modern engineering and construction company website template is a downloadable website template suitable for promotion of the engineering and construction service industry. Tip: This template calls the Google font library, and the page may open slowly.
Front-end template
2024-02-28