web123456

Java converts json to jar packages that need to be imported, org/apache/commons/lang/exception/NestableRuntimeException

There will be exceptions if the corresponding jar package is missing. Please find the jar package to import according to the exception...
 
Here I will talk about the lang package, because I have been looking for this package for a long time:
 
I'm using: commons-lang3-3. Exception appears:
: org/apache/commons/lang/exception/NestableRuntimeException
It can be seen that it is because of the lack of jar package, but it is obvious that I have imported it, so why does this error still report?
 
After searching for a long time, I finally understood. Look at the picture below:
Many people left messages saying that there was no picture, they lost it if they didn’t pay attention, and they were too lazy to find it. This picture is commons-lang3-3. The package directory, lazy to cut it off
 
Let's take a look at commons-lang-2. The following directory of this version of jar package:
As shown in the figure below:
This picture is commons-lang-2. The package directory, I'm lazy to cut it off
 
For the lang package, the new version has actually changed the package name. I really didn’t expect that. I just checked these two versions for the time being. Whether the other versions have the same problem, I’ll pay attention to it in the future. . . . Post a blog to record it!
 
If you report an error, which package is missing, go find it correspondingly. If you feel that the package is imported, you will still report an error. Open the directory of the package to see if there is any class. If you don’t, change to another version. There are changes to the lang3 and lang directories, so there will be errors.



The following are searched online, you can ignore if you don’t want to see:
If there are similar errors, you can refer to them. The versions are different. Remember to see if the package name corresponds to the error message.
 
commons-beanutils-1.8. Do not add this package
: org/apache/commons/beanutils/DynaBean
Don't add this bag
: org/apache/commons/collections/map/ListOrderedMap
commons-lang-2. Don't add this package
: org/apache/commons/lang/exception/NestableRuntimeException
commons-logging-1.1. Do not add this package
: org/apache/commons/logging/LogFactory
ezmorph-1.0. Without adding this package
: net/sf/ezmorph/Morpher
json-lib-2. Don't add this package
: net/sf/json/JSONObject
The corresponding jar package can be downloaded online, or you can use the ones provided below!

Example:
import ;
import ;

import ;

public class JsonTest {

/**
* @param args
*/
public static void main(String[] args) throws Exception{
boolean[] boolArray = new boolean[]{true,false,true};
JSONArray jsonArray = ( boolArray );
( jsonArray );

List list = new ArrayList();
( "first" );
( "second" );
JSONArray jsonArray2 = ( list );
( jsonArray2 );
}
}