I have a project directory:
.
├── data
│ ├── items.json
│ └── users.json
├── jparser
│ ├── Item.class
│ ├── Item.java
│ ├── jackson.jar
│ └── Person.java
├── README.md
└── spec.md
Where I want to use the jackson.jar
file without using Maven or Gradle.
I tried following the instructions on another post, with the following code:
package jparser;
import jparser.jackson.databind.ObjectMapper;
public class Item {
// some code here
}
and executed it (following the UNIX instructions) with:
javac -cp '.:jparser.jackson.jar' jparser/Item.java
where I get the following error:
jparser/Item.java:2: error: package jackson.databind does not exist
import jackson.databind.ObjectMapper;
^
1 error
Other things I have tried (which still returned errors):
javac -cp '.:jparser/jackson.jar' jparser/Item.java
javac -cp 'jparser.jackson.jar' jparser/Item.java
javac -cp 'jparser/jackson.jar' jparser/Item.java