current location:Home > Technical Articles > Java > JavaBase
- Direction:
- All web3.0 Backend Development Web Front-end Database Operation and Maintenance Development Tools PHP Framework Common Problem Other Tech CMS Tutorial Java System Tutorial Computer Tutorials Hardware Tutorial Mobile Tutorial Software Tutorial Mobile Game Tutorial
- Classify:
-
- How to enter a string in java
- Steps to input strings in java: First, import the java.util.* package; then, you need to create a new scanner object (Scanner) that reads standard input (keyboard); now you can input strings from the keyboard, use Scanner.nextLine () method to get the string.
- JavaBase 43070 2019-11-13 10:10:15
-
- Three ways to traverse arrays in java
- There are three ways to traverse an array in Java, namely: 1. Use a for loop to traverse the array; 2. Use the foreach statement to traverse the array; 3. Use the toString static method in the Arrays tool class to traverse the array.
- JavaBase 8693 2019-11-13 09:56:41
-
- How to read data from file in java
- The method for java to read data from a file is: 1. Create a new Class class; 2. Write the Main method; 3. Create a new txt document in the root directory of the C drive for testing; 4. Create a File object; 5. Create a StringBuilder object; 6. , read the file content.
- JavaBase 8620 2019-11-13 09:41:47
-
- How to define functions in java
- The syntax format of defining a function in Java is: modifier + return value type + function name ([parameter type 1 + parameter name 1], parameter type 2 + parameter name 2...) {execution statement + return + return value}.
- JavaBase 6519 2019-11-13 09:23:47
-
- The difference between processes and threads in java
- The difference between processes and threads in Java is: 1. Threads in the same process share the address space of this process, while processes have independent address spaces; 2. Threads in the same process share the resources of this process, but between processes The resources are independent.
- JavaBase 3897 2019-11-12 17:26:41
-
- How to understand reflection in java
- Reflection in Java means that in the running state, for any class, you can know what methods and properties the class has, and for any object, you can call its methods and properties.
- JavaBase 6759 2019-11-12 17:07:17
-
- What is rewriting in java
- The inheritance feature of classes in Java programs can produce a subclass. When the subclass inherits the parent class, it will have the non-private properties of the parent class. In the subclass, you can add your own properties, and you can also extend the methods in the parent class. , to enhance its own functions, which is called rewriting, also called copying or overwriting.
- JavaBase 6237 2019-11-12 16:54:01
-
- Understanding the concept of caching in java
- The cache in Java refers to the buffer for data exchange. When a certain piece of hardware wants to read data, it will first query the data from the cache and execute it directly. If it does not exist, it will get it from the memory.
- JavaBase 2307 2019-11-12 16:51:12
-
- Eclipse cannot create java virtual machine
- Solution to the inability to create a virtual machine: 1. Open the eclipse.ini file in the eclipse directory; 2. Modify the –launcher.XXMaxPermSize property; 3. Modify it to 128m, save and restart.
- JavaBase 3252 2019-11-12 16:35:48
-
- What is static in java? How to understand?
- Static (static) in Java is a keyword mainly used to create domain variables or methods that are independent of specific objects. If a member variable is shared by all objects, then the member variable should be defined as a static variable.
- JavaBase 5957 2019-11-12 16:34:09
-
- The file name downloaded by java is garbled
- Solution to the garbled file name downloaded by java: 1. Use URLEncoder for encoding for the IE browser core; 2. Use getBytes for non-IE browsers to transcode; 3. Change tomcat and eclipse encoding to utf-8.
- JavaBase 2497 2019-11-12 16:19:14
-
- What software is written in java
- Software written in Java includes: 1. Eclipse and IDEA programming software; 2. Games include "Minecraft"; 3. Big data storage software includes Hadoop and Elasticsearch; 4. Most Android applications are also developed using Java; 5. Enterprise management application software and so on.
- JavaBase 12842 2019-11-12 16:04:46
-
- What are the design patterns in Java?
- The design patterns in Java include: Strategy pattern, Agent pattern, Singleton pattern, Multiple instance pattern, Factory method pattern, Abstract factory pattern, Facade pattern, Adapter pattern, Template method pattern, Builder pattern, Bridge pattern, and Command pattern.
- JavaBase 2865 2019-11-12 15:53:07
-
- What are the exceptions in java
- Java exceptions include: 1. Null pointer exception; 2. Mathematical operator exception; 3. Array subscript out-of-bounds exception; 4. Access permission exception; 5. Method parameter exception; 6. Specified class does not exist exception, etc.
- JavaBase 4346 2019-11-12 15:44:27
-
- Examples of sorting methods in java
- To implement sorting in Java, you can move the largest element in the sequence to be sorted to the end in each pass, and the remainder is the new sequence to be sorted. Repeat this step until all elements are sorted.
- JavaBase 4217 2019-11-12 15:36:28