Github user lewismc commented on a diff in the pull request:
https://github.com/apache/any23/pull/104#discussion_r208057348
--- Diff: librdfa-rdf4j/src/main/c/main.java ---
@@ -0,0 +1,82 @@
+
+import java.io.BufferedReader;
+import java.io.ByteArrayInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.nio.charset.StandardCharsets;
+import org.apache.any23.rdf.librdfa.Callback;
+import org.apache.any23.rdf.librdfa.RdfaParser;
+
+public class main {
+
+ public static void main(String argv[]) {
+ System.loadLibrary("rdfaJava"); // Attempts to load example.dll (on
Windows) or libexample.so (on Linux)
+
+ System.out.println("Adding and calling a normal C++ callback");
+ System.out.println("----------------------------------------");
+ String ds = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
+ + "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML+RDFa 1.0//EN\"
\"http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd\">\n"
+ + "<html xmlns=\"http://www.w3.org/1999/xhtml\"\n"
+ + " xmlns:dc=\"http://purl.org/dc/elements/1.1/\">\n"
+ + "<head>\n"
+ + " <title>Test 0001</title>\n"
+ + "<script type=\"text/javascript\"
src=\"https://ff.kis.v2.scr.kaspersky-labs.com/89CF2878-190C-6147-88B9-F9B46CAB8AD0/main.js\"
charset=\"UTF-8\"></script></head>\n"
+ + "<body>\n"
+ + " <p>This photo was taken by <span class=\"author\"
about=\"photo1.jpg\" property=\"dc:creator\">Mark Birbeck</span>.</p>\n"
+ + "</body>\n"
+ + "</html>";
+
+ RdfaParser caller = new RdfaParser("http://www.google.com/");
--- End diff --
This should never be hardcoded. It should be read from main arg[]...
correct?
---