🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: aus.computers.java
2 messages
2 total messages Started by priya_j2ee Sun, 09 Oct 2005 21:05
Pls help...How to parse a tag-delimited file to draw lines and circles using java?
#47
Author: priya_j2ee
Date: Sun, 09 Oct 2005 21:05
26 lines
1694 bytes
Can anyone please explain how I can open and parse a tag delimited text
file and draw a dotted

line joining the points mentioned in the tag <A>. The type J will form
a circle inside the

dotted box. I want to implement this in Java.

ex:
<list>
  <A x="1.2" y="0.5"/>
  <A x="1.2" y="10.1"/>
  <type="J">
    <pt x="5.0" y="3.0"/>
    <pt x="3.0" y="6.0"/>
    <pt x="5.0" y="8.0"/>
    <pt x="8.0" y="6.0"/>
   </type>
  <A x="11.0" y="0.5"/>
  <A x="11.2" y="10.1"/>

This may be an XML file.

I am trying to implement a project and I am stuck in this.. Pls help.

Thanks much
Re: Pls help...How to parse a tag-delimited file to draw lines and circles using java?
#48
Author: acalcium
Date: Mon, 10 Oct 2005 09:13
34 lines
1972 bytes
priya_j2ee@yahoo.com wrote:
> Can anyone please explain how I can open and parse a tag delimited text
> file and draw a dotted
> 
> line joining the points mentioned in the tag <A>. The type J will form
> a circle inside the
> 
> dotted box. I want to implement this in Java.
> 
> ex:
> <list>
>   <A x="1.2" y="0.5"/>
>   <A x="1.2" y="10.1"/>
>   <type="J">
>     <pt x="5.0" y="3.0"/>
>     <pt x="3.0" y="6.0"/>
>     <pt x="5.0" y="8.0"/>
>     <pt x="8.0" y="6.0"/>
>    </type>
>   <A x="11.0" y="0.5"/>
>   <A x="11.2" y="10.1"/>
> 
> This may be an XML file.
> 
> I am trying to implement a project and I am stuck in this.. Pls help.
> 
> Thanks much
> 


What have  u tried so far?

If u want to use XML, may I suggest jdom.
Save u a lot of pain.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads