current location:Home > Technical Articles > Java > JavaBase
- Direction:
- All web3.0 Backend Development Web Front-end Database Operation and Maintenance Development Tools PHP Framework Daily Programming WeChat Applet Common Problem Other Tech CMS Tutorial Java System Tutorial Computer Tutorials Hardware Tutorial Mobile Tutorial Software Tutorial Mobile Game Tutorial
- Classify:
-
- The difference between equals and '==' in java
- The difference between equals and "==" in Java is: "==" compares the (heap) memory address of the object stored in the variable (stack) memory, and is used to determine whether the addresses of the two objects are the same, while equals is used to What is compared is whether the contents of the two objects are equal.
- JavaBase 2172 2019-11-19 17:03:35
-
- How to configure java
- Java configuration method: First download and install jdk, and then configure JAVA_HOME, PATH, and CLASSPATH according to the jdk installation path in the computer "Environment Variables" configuration interface. You can use the java -version command in cmd to check whether the environment variables are configured successfully.
- JavaBase 6126 2019-11-19 16:54:44
-
- Java prompts that the specified file cannot be found
- The reason why java prompts that the specified file cannot be found is: the file name or file suffix is wrong. Solution: First check whether the file name is correct, and then check whether the file suffix is correct.
- JavaBase 3623 2019-11-19 16:27:54
-
- Java determines whether it is a decimal
- How to determine whether it is a decimal in Java: You can convert the number into a string, and then use the contains() method to determine whether there is a decimal point in the string. If there is a decimal point, it is a decimal. If not, it is not a decimal.
- JavaBase 6864 2019-11-19 16:22:47
-
- Java uses regular expressions to match strings that do not contain a certain rule
- The way Java uses regular expressions to match strings that do not contain a certain rule is to use the regular expression "(?!match pattern)", such as the regular expression "^.*?(?!robots\.txt)", This regular expression represents any character at the beginning and a continuous string not followed by "robots.txt".
- JavaBase 8050 2019-11-19 16:16:56
-
- Java determines whether it is a picture
- How to determine whether it is a picture in java: 1. Determine whether it is a picture through the file suffix name. 2. Determine whether it is a picture through the file header. 3. Judge by MimetypesFileTypeMap. 4. Judge through ImageIO.
- JavaBase 3781 2019-11-19 16:07:34
-
- What are the forms and usages of if statements in java
- The form and usage of if statement in Java are: 1. if statement, usage: "if (conditional statement) {code block}"; 2. "if...else" statement, usage: "if (judgment condition) {execution Statement 1}else{Execute statement 2}".
- JavaBase 4630 2019-11-19 15:56:11
-
- Java determines whether it is a number
- How to determine whether it is a number in java: 1. Use the isDigit() method to determine whether the specified string is a number. 2. Use regular expressions to judge whether it is a number. The regular expressions to judge whether it is a number include "^[-\\+]?[\\d]*$", "[0-9]*", "^[0-9 ]*$" etc.
- JavaBase 49516 2019-11-19 15:54:56
-
- How to define methods in java
- The syntax for defining a method in Java is: "Access modifier + return value type + method name (parameter list) {method body}", where the access modifier is used to determine the scope of permissions to be accessed, and the method name must use a legal identifier symbol.
- JavaBase 9489 2019-11-19 15:37:13
-
- How to read files in java
- Methods of reading files in java: 1. Use the BufferedReader class to read files (text can be read from a character input stream). 2. Use the RandomAccessFile class to read the file. 3. Use the FileInputStream method to read the file.
- JavaBase 5321 2019-11-19 15:28:07
-
- Java determines whether the file is empty
- In Java, you can use the return value of the length() method to determine whether the file is empty. If the file does not exist or the file is empty, the length() method returns 0.
- JavaBase 4240 2019-11-19 15:06:02
-
- Java determines whether a file exists
- In Java, you can use the file.exists() method to detect whether a file exists, and public boolean exists() to test whether the file or directory represented by this abstract path name exists.
- JavaBase 4211 2019-11-19 14:46:18
-
- The difference between c# interface and java interface
- The difference between the C# interface and the Java interface is that the interface in Java can contain fields, but these fields are modified with the "static" and "final" keywords, while C# does not allow fields in the interface.
- JavaBase 4312 2019-11-19 14:45:15
-
- How is java output?
- There are four types of output statements in java: 1. System.out.println() (line feed printing). 2. System.out.print() (printing without line breaks). 3. System.out.write() (byte output). 4. System.out.printf().
- JavaBase 6278 2019-11-19 14:32:06
-
- Determine whether a character is a number in Java
- How to determine whether a character is a number in Java: You can use Java's own function "Character.isDigit(char a)" to determine. If character a is a number, it returns true, otherwise it returns false.
- JavaBase 2679 2019-11-19 14:24:50