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:
-
- What is the difference between wait and sleep in java?
- The difference between wait and sleep in Java: 1. Sleep comes from the Thread class, while wait comes from the Object class; 2. The sleep method does not release the lock, but the wait method releases the lock, allowing other threads to use synchronization control blocks or methods.
- JavaBase 4460 2019-12-27 15:31:17
-
- Java method to determine whether string is a number
- How to determine whether a string is a number in Java: Use the charAt() method in a loop to return the characters in the string one by one, and then use the isDigit() method to determine whether the specified character is a number.
- JavaBase 13670 2019-12-27 14:50:58
-
- What is the difference between html and java?
- HTML and java are essentially different. Java is an object-oriented programming language, and html is hypertext markup language. It is a markup language, not a programming language, and is used in almost all web pages.
- JavaBase 5354 2019-12-27 14:44:32
-
- How to create a folder in java
- In Java, you can use the mkdir() method to create a single folder. When using this method to create a directory, you must ensure that its parent folder exists. Or use the mkdirs() method to create a multi-level directory. This method does not require ensuring that its parent folder exists.
- JavaBase 10199 2019-12-27 14:37:30
-
- Is there any difference between c syntax and java syntax?
- There are differences between c syntax and java syntax, for example: 1. C language has pointers, but java does not have pointers. 2. The identifiers available in C language are numbers, uppercase and lowercase letters, and underscores, which cannot start with a number. In addition to the three types of identifiers in C, the identifiers available in Java have one more dollar sign ($), which also cannot start with a number.
- JavaBase 2907 2019-12-27 14:29:16
-
- How to get ip address in java
- How to get IP in java: You can return the IP address through the HttpServletRequest object, where the getRemoteAddr method returns the IP address of the client that made the request, and the getLocalAddr method returns the IP address of the WEB server.
- JavaBase 7219 2019-12-27 14:27:11
-
- What is the difference between java collection and array?
- Differences: 1. An array declares the type of elements it contains, while a collection does not. 2. Arrays are static. An array instance has a fixed size. Once created, the capacity cannot be changed. Collections can dynamically expand their capacity and change their size dynamically as needed. Collections provide more member methods to meet more needs.
- JavaBase 8207 2019-12-27 14:06:09
-
- Solutions to garbled characters in imported java projects
- Solution to garbled characters when importing java projects: 1. Right-click properties on the project, select Resource, and change Text file encoding. 2. Select Window-preferences-General-Workspace in the IDE and modify the encoding.
- JavaBase 3844 2019-12-27 13:50:52
-
- Java method to determine whether a string contains specified characters
- How to determine whether a string contains specified characters in Java: Use the contains method to determine if and only if the string contains the specified char value sequence, the contains() method returns true.
- JavaBase 10686 2019-12-27 13:36:14
-
- How to package java program
- Packaging java program: 1. Select the class or package you want to export in eclipse, right-click and select the Export sub-option. 2. In the pop-up dialog box, select the java file-JAR file-click next. 3. Select the storage location of the jar package and save it.
- JavaBase 6095 2019-12-27 13:25:35
-
- How to delete files in java
- Deleting files in java can be achieved using the File.delete() method. The Java File class represents file names and directory pathnames in an abstract way. This class is mainly used for creating files and directories, searching for files, and deleting files.
- JavaBase 5510 2019-12-27 11:54:59
-
- How to determine whether a file is an image in java
- How to determine whether a file is an image in Java: 1. Determine by the file suffix name. 2. Determine the file type through the file header. 3. Judge by MimetypesFileTypeMap. 4. Judge through ImageIO.
- JavaBase 8877 2019-12-27 11:37:06
-
- The difference between java inheritance and interface
- The difference between java inheritance and interface: 1. Use different modifiers to modify. 2. Only global constants and abstract methods can be defined in interfaces, while attribute methods, variables, constants, etc. can be defined in inheritance.
- JavaBase 4009 2019-12-27 10:48:41
-
- How to generate random numbers in java
- How to generate random numbers in java: 1. Use the java.util.Random class to generate a random number generator to generate random numbers. 2. Use the Math.random() method to generate random numbers. 3. Use the currentTimeMillis() method to generate random numbers.
- JavaBase 7483 2019-12-27 10:35:27
-
- How to call variables in java
- How to call variables in Java: 1. Use new to create a variable in the class, and then call the variable by calling a public variable in the class. 2. Define the variable as a static public variable, and then obtain it directly using the class name.variable name. 3. Use methods or interfaces to pass this variable from other classes.
- JavaBase 4787 2019-12-27 10:21:40