Forgive my confusion with Java imports -- I come from a Python background.
I have some code that makes use of the itext library:
public static void makeADoc (Person p, String outfile) throws DocumentException,FileNotFoundException{
Document document = new Document;
PdfWriter.getInstance(document, new FileOutputStream(outfile));
document.open();
document.add(new Paragraph("Hello " + p.getFirst() + ",\n" + "You've just won the lotto!"));
document.close();
}
I have added the applicable itext-pdf jar files to the project's path. I have imported the entire library at the beginning of this class with a wildcard import statement:
import com.itextpdf.*;
Yet Eclipse is still giving me red underlined errors for Document objects and DocumentException and FileNotFound Exception objects. I am given the option to import the Document class from itextpdf, but it seems like my wildcard statement should have covered that. What's going on?