yohe | : smiling_imp : powerful static blog generator | Blog library
kandi X-RAY | yohe Summary
kandi X-RAY | yohe Summary
a static blog generator, powered by Node.js. Yohe means that you will say "Wow, so cute" after you tried it.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of yohe
yohe Key Features
yohe Examples and Code Snippets
Community Discussions
Trending Discussions on yohe
QUESTION
I am trying to write the names of the passengers in an ArrayList to an XML file. I have to put the code for the XML document creation into my Aircraft class. Below is both my code for the Aircraft class. This also includes my code for the main calling method App.java. There are no errors in either of these classes; however, part of me thinks that it is not correctly creating the XML file. I was wondering if I have to call the writeNames() method anywhere in the App.java for it to work correctly?
Aircraft Class:
...ANSWER
Answered 2017-Feb-17 at 22:06Yes, based off the code you provided, if you want to write the passengers to an XML file, you will need to call the Aircraft's writePassengers method and pass in the list of passengers you would like to write.
This doesn't seem to make sense since you are setting the list of passengers locally when you create the class and still requiring it as a parameter in the method. You should be able to remove the parameter and still have proper functionality:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install yohe
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page