{"id":15069759,"url":"https://github.com/dev-rem/java-pdf-writing","last_synced_at":"2026-01-03T02:33:46.018Z","repository":{"id":171275710,"uuid":"266559087","full_name":"Dev-Rem/Java-PDF-writing","owner":"Dev-Rem","description":"This is a java application that is able to create and write data into and xml file using DOM, the application is also able to read data from the written xml into a pdf file Automatically.","archived":false,"fork":false,"pushed_at":"2020-06-04T13:31:41.000Z","size":71,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-16T09:16:06.015Z","etag":null,"topics":["java-development-kit","java-se","pdf","pdf-generation","xml"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Dev-Rem.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-05-24T14:33:51.000Z","updated_at":"2020-09-12T09:44:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"272254cd-fba7-4c2e-936d-355a9fde733d","html_url":"https://github.com/Dev-Rem/Java-PDF-writing","commit_stats":null,"previous_names":["dev-rem/java-pdf-writing"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Rem%2FJava-PDF-writing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Rem%2FJava-PDF-writing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Rem%2FJava-PDF-writing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Rem%2FJava-PDF-writing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dev-Rem","download_url":"https://codeload.github.com/Dev-Rem/Java-PDF-writing/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243847056,"owners_count":20357317,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java-development-kit","java-se","pdf","pdf-generation","xml"],"created_at":"2024-09-25T01:44:34.778Z","updated_at":"2026-01-03T02:33:45.958Z","avatar_url":"https://github.com/Dev-Rem.png","language":"Java","readme":"# Java-XML-parsing-and-PDF-writing\n\nThis is a java application that is able to create and write data into and xml file using DOM, the application is also able to read data from the written xml into a pdf file Automatically.\nThe Application is and examples of a restaurant receipt that is sent to a customer, it contains information about the restaurant, Customer, items ordered from the restaurant and their prices.\n\nThe WriteXml.java class contains a static WriteToXml method which uses various java modules to such as \"javax.xml.parsers.DocumentBuilder\" for creating the xml document and \"javax.xml.transform.TransformerFactory\" for transforming the DOM object to an XML file.\n\nThe javaApplication3 class reads \n\n\n#  Getting Started (Downloading and installing Java Development Kit)\n\nTo run the Application on your local machine you need to have the Java Development Kit(JDK) installed.\nI recommend that you install only the latest JDK. Although you can install multiple versions of JDK/JRE concurrently, it is messy.\n\nIf you have previously installed older version(s) of JDK/JRE, un-install ALL of them. Goto \"Control Panel\" ⇒ (optional) \"Programs\" ⇒ \"Programs and Features\" ⇒ Un-install ALL programs begin with \"Java\", such as \"Java SE Development Kit ...\", \"Java SE Runtime ...\", \"Java X Update ...\", and etc.\n\nSTEP 1: Download JDK\n  1. Goto Java SE download site @ http://www.oracle.com/technetwork/java/javase/downloads/index.html.\n  2. Under \"Java Platform, Standard Edition\" ⇒ \"Java SE 13.0.{x}\", where {x} denotes a fast running security-update number ⇒ Click the      \"Oracle JDK Download\" button.\n  3. Under \"Java SE Development Kit 13.0.{x}\" ⇒ Check \"Accept License Agreement\".\n     Choose the JDK for your operating system, i.e., \"Windows\". Download the \"exe\" installer (e.g., \"jdk-13.0.{x}_windows-x64_bin.exe\" -      about 159MB).\n     \nSTEP 2: Install JDK\n  Run the downloaded installer (e.g., \"jdk-13.0.{x}_windows-x64_bin.exe\"), which installs both the JDK and JRE.\n\n  By default, JDK is installed in directory \"C:\\Program Files\\Java\\jdk-13.0.{x}\", where {x} denotes the update number. Accept the         defaults and follow the screen instructions to install JDK.\n\n  Use your \"File Explorer\", navigate to \"C:\\Program Files\\Java\" to inspect the sub-directories. Take note of your JDK installed           directory jdk-13.0.{x}, in particular, the update number {x}, which you will need in the next step.\n\nGOTTEN FROM: https://www.ntu.edu.sg/home/ehchua/programming/howto/JDK_HowTo.html ALSO ARTICLE FOR INSTALLING JDK ON WINDOWS AND OTHER MACHINES\n\n#  Installing NetBeans IDE for running java programs\nSTEP 1: Download\n  Download \"NetBeans IDE\" installer from http://netbeans.org/downloads/index.html. There are many \"bundles\" available. For beginners,     choose the 1st entry \"Java SE\" (e.g., \"netbeans-8.2-javase-windows.exe\" 95MB).\n\nSTEP 2: Run the Installer\n  Run the downloaded installer.\n  \n# Cloning the repository\n\nTo clone the repo you need to have git bash installed to be able to clone it remotely.\nBelow there is a link to the official git bash site on how to install git bash on windows and other machines.\nhttps://www.stanleyulili.com/git/how-to-install-git-bash-on-windows/\n\nBelow is a link from github help on how to clone the repo on various  machines Download or remote clone.\nhttps://help.github.com/en/enterprise/2.13/user/articles/cloning-a-repository\n  \n\n# Running Application on Netbeans\n\nTo run the application ensure all above steps were followed without any exceptions, the instructions below are for windows users, links on how to open the project on other machines will be provided.\n\nWINDOWS:\n  Launch the netbeans IDE wait for it to load and a start page will be displayed.\n  Click on File -\u003e OpenProject\n  Navigate to the cloned project click on it\n  Click on \"Open Project\".\n  The project will open IDE.\n  FOR MORE DETAILED EXPLANATIONS: http://blog.jdevelop.eu/?p=29\n  \nMACOS and LINUX:\n  https://www.youtube.com/watch?v=tSTLrQCTlYE\n  \n\n# Running unit tests\n\nThe Application has unit test written with JUnit for all classes. You can run JUnit tests on the entire application or on individual files and see the results in the IDE. \n\nThe easiest way to run all the unit tests for the project is to choose Run \u003e Test \u003cPROJECT_NAME\u003e from the main menu. And to run individual test on a particular class then right click on the Files -\u003e Expand JavaApplication3 folder -\u003e Expand src folder -\u003e Expand javaApplication3 folder -\u003e Right click on the class you want to test and click on \"Test file\".\nFOR FURTHER READING: https://netbeans.org/kb/docs/java/junit-intro.html#:~:text=The%20easiest%20way%20to%20run,node%20and%20choose%20Run%20File.\nAll test files are in the JavaApplication3 -\u003e test -\u003e javaApplication3 folder.\n\n\n# Conclucion\n\nThis is my actual first project in java, contributions and pull requests are highly welcomed as well as critism.\nDuring the creation of the application a few articles were used for knowledge of writing/reading xml files with java and also writing to a pdf file references to the articles will be listed below.\n\nReferences:\n  \n  General Knowledge of java - https://www.w3schools.com/java/default.asp\n \n Writing to xml file - https://examples.javacodegeeks.com/core-java/xml/parsers/documentbuilderfactory/create-xml-file-in-java-using-dom-parser-example/\n  \n  Reading from xml file - https://www.javatpoint.com/how-to-read-xml-file-in-java\n  \n  Writing to pdf file - https://www.chillyfacts.com/create-pdf-dynamically-images-using-java/\n  \n\n\n\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-rem%2Fjava-pdf-writing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdev-rem%2Fjava-pdf-writing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-rem%2Fjava-pdf-writing/lists"}