473,327 Members | 1,930 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Java and parsing xsd to build a user interface

Hi guys,
unfortunately i'm a newbee to java and xml and xsd...
part of my xsd looks like this:
<xs:simpleType name="val">
<xs:restriction base="xs:string">
<xs:enumeration value="aa"></xs:enumeration>
<xs:enumeration value="bb"></xs:enumeration>
<xs:enumeration value="cc"></xs:enumeration>
</xs:restriction>
</xs:simpleType>

could anyone give me a hint, how to parse my xsd in java
to fill a combobox out of the values in the enumeration tags?
I guess I have to work around with jdom?!?
I'm working with java 1.4.1..
would be glad for any help or hint
thanks in advance
tiana
Jul 20 '05 #1
1 6100
TIANA wrote:
Hi guys,
unfortunately i'm a newbee to java and xml and xsd...
part of my xsd looks like this:
<xs:simpleType name="val">
<xs:restriction base="xs:string">
<xs:enumeration value="aa"></xs:enumeration>
<xs:enumeration value="bb"></xs:enumeration>
<xs:enumeration value="cc"></xs:enumeration>
</xs:restriction>
</xs:simpleType>

could anyone give me a hint, how to parse my xsd in java
to fill a combobox out of the values in the enumeration tags?
I guess I have to work around with jdom?!?
I'm working with java 1.4.1..
would be glad for any help or hint
thanks in advance
tiana

Your right, you have to use some kind of xml reader, that can be a dom or sax,
just use what you think is suitable for the situation.
If you only have to read the values you can use SAX, but i find sax somewhat strange
to use, jdom is more logical i think; only it consumes more memmory and is slower.

If you dont know how to use JDom just read the api's.
Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Ravi Tallury | last post by:
Hi We are having issues with our application, certain portions of it stop responding while the rest of the application is fine. I am attaching the Java Core dump. If someone can let me know what...
6
by: John Smith | last post by:
Hello, I have a rather odd question. My company is an all java/oracle shop. We do everything is Java... no matter what it is... parsing of text files, messaging, gui you name it. My question...
13
by: Ajay | last post by:
hi! can you call a Python application from a Java program? does this require any additional package to be installed? thanks cheers
11
by: DrUg13 | last post by:
In java, this seems so easy. You need a new object Object test = new Object() gives me exactly what I want. could someone please help me understand the different ways to do the same thing in...
1
by: David Van D | last post by:
Hi there, A few weeks until I begin my journey towards a degree in Computer Science at Canterbury University in New Zealand, Anyway the course tutors are going to be teaching us JAVA wth bluej...
2
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of...
15
by: Xah Lee | last post by:
On Java's Interface Xah Lee, 20050223 In Java the language, there's this a keyword “interface”. In a functional language, a function can be specified by its name and parameter specs....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, youll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shllpp 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.