Hello Everyone,
I have run into into some weird runtime error. I have a json data file that I am trying to parse into my code . I am using json-simple-1.1.1.jar external library that I have added to my classpath and verified that it exists there by doing echo $CLASSPATH.
When I compile my code using javac codeTest.java the program compiles with no issues .
But when I try to run the program using
java -classpath . codeTest I am receiveing the error : java.lang.NoClassDefFoundError: org/jason/simple/parser/ParseException.
I have opened the json-simple-1.1.1.jar folder and verified that ParseException.class does exist in the folder.
If I run the code without the class path (i.e. java codeTest) then I am receiving "could not find or load main class codeTest", which is expected.
Please help me troubleshoot this.
Thank you
my code snippet :