Insights Blog
-- Browse All Articles --
Physics Articles
Physics Tutorials
Physics Guides
Physics FAQ
Math Articles
Math Tutorials
Math Guides
Math FAQ
Education Articles
Education Guides
Bio/Chem Articles
Technology Guides
Computer Science Tutorials
Forums
Chemistry
Biology and Medical
Earth Sciences
Computer Science
Computing and Technology
DIY Projects
Trending
Featured Threads
Log in
Register
What's new
Search
Search
Search titles only
By:
Chemistry
Biology and Medical
Earth Sciences
Computer Science
Computing and Technology
DIY Projects
Menu
Log in
Register
Navigation
More options
Contact us
Close Menu
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Forums
Other Sciences
Programming and Computer Science
Question about input format file (for creating a net)
Reply to thread
Message
[QUOTE="ORF, post: 5901430, member: 528012"] Hello I am not sure about what should be the best format for a input text file. I think before start shooting in the dark, it's better to ask experienced people. The (C++) program has to create a net. The nodes will be defined in a input text file. For convenience, the net will be a bunch of std::vector (so each path inside the net, starting from the first node, will correspond to a single std::vector). I know a bunch of std::vector is not the best way of storing a net, but it's the best way for the function which will use the net. The nodes may be connected up to 4 nodes. I thought in three different input format, but I don't know what could be the best option, and if the input format can be optimized: -JSON: the nodes can be defined one-by-one. In addition to the node information, the next nodes should be defined. The problem of defining the nodes individually is that you should create the net at runtime. The net is not defined in a visual/intuitive-way (that means the probability of writing a wrong input is high). -XML: implementing hierarchy is relatively easy, but for such number of connections, the problem is similar to the previous option: the net is not defined in a visual/intuitive-way. -CSV: as a primitive version of JSON format. To sum up, I think JSON would be the best option, but a strict control section is needed. I don't know if there are other ways of defining a net/tree from a text file. Thank you for your time. Regards, ORF [/QUOTE]
Insert quotes…
Post reply
Forums
Other Sciences
Programming and Computer Science
Question about input format file (for creating a net)
Back
Top