log4j:WARN No appenders could be found for logger (com.hp.hpl.jena.rdf.model.impl.RDFDefaultErrorHandler). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.How do I fix this?
static { org.apache.jena.atlas.logging.LogCtl.setCmdLogging(); }
Scanner input = new Scanner(myFile);
input.useDelimiter("\\t|[\\n\\r\\f]+");Note, the string "\\t" by itself won't work, because the end of a line will not be treated as the end of a token.
String albumLine = input.nextLine(); String[] albumParts = albumLine.split("\\t");The elements of the albumsParts array will be the strings from the line that were separated by tabs. If you want some of these strings to be turned into integers, you'll have to use Integer.parseInt().
java -cp C:/Users/heflin/Documents/Code/apache-jena-2.12.0/lib/*;. userid.AlbumsToRdf top20albums.txtIn Unix, Linux and Mac, you will need to change the separator character used for classpaths from ";" to ":":
java -cp C:/Users/heflin/Documents/Code/apache-jena-2.12.0/lib/*:. userid.AlbumsToRdf top20albums.txt
package userid;and put it in your userid directory. Be sure to include this file with your submission. Note, earlier today I said it was okay to leave the file out of your submission and I would have it available in the default package. That only works with very old versions of Java. If you already submitted it, do not fear, I will make the necessary correction for you (but only for this issue).