aspose file tools*
The moose likes Beginning Java and the fly likes Please give suggestion or hint Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Please give suggestion or hint" Watch "Please give suggestion or hint" New topic
Author

Please give suggestion or hint

gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
I have to solve below problem

write a java code that will use a dtd to create a xml that will contain the marksheet information of student.

Please give hint how should I do it.
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 10925
    
  12

What have you tried? What do you know how to do? What doesn't make sense?

With such a general question, you can really only expect general answers. so...

Start small.
compile often (every 2-3 lines)
test often
write tons of code you expect to throw away (used for the above item)
figure out the steps on paper before you ever write a line of java

There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
fred rosenberger wrote:What have you tried? What do you know how to do? What doesn't make sense?

With such a general question, you can really only expect general answers. so...

Start small.
compile often (every 2-3 lines)
test often
write tons of code you expect to throw away (used for the above item)
figure out the steps on paper before you ever write a line of java


Thanks for reply.

first I want to create a dtd.
after that I will creeate xml file ( but how) using java and keeping dtd as external dtd?
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 10925
    
  12

well...have you created the DTD?
gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
Yes I have created the dtd , based on that I have xml also.
AnujS Sharma
Greenhorn

Joined: Jul 30, 2011
Posts: 15
Google for SAX, StAX
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 10925
    
  12

I'm trying to get you to tell us what exactly your problem is. where are you stuck? what don't you know/understand how to do?

Further, i'm trying to help you break down your problem into small, more manageable problems. you started by saying "I don't know how to do this project". after some back and forth, it turns out you do know how to do some of it, but it is still not clear (at least to me) where you are stuck. Each time I ask "Did you do this", you reply with "yes, i know how to do that, and now I'm stuck".

You apparently know how to create a DTD. you apparently know how to create xml. Do you know how to compile a java program? Do you know if you have a JDK? do you know how to run a program once it is compiled?

you need to tell us SPECIFICALLY where you need help.
gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
I know compiling java and runing java program.
classpath,java-home and path is set in my system.

now the question is which is package I should use , and what is the easy way.
Ove Lindström
Ranch Hand

Joined: Mar 10, 2008
Posts: 326

gyan kumar wrote:I know compiling java and runing java program.
classpath,java-home and path is set in my system.

now the question is which is package I should use , and what is the easy way.


Normaly the cube is about 10x9.4x7.199234 inches.

We don't know... do you have a domain registered? Then use that. If not, use something that describes what you are doing.
gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
Ove Lindström wrote:

Normaly the cube is about 10x9.4x7.199234 inches.

We don't know... do you have a domain registered? Then use that. If not, use something that describes what you are doing.

Actually reply was given for Mr. Fred Rosenberger's reply.
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 10925
    
  12

are you asking about what your package statement should be and how to set up your directories?
gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
fred rosenberger wrote:are you asking about what your package statement should be and how to set up your directories?


yes Mr. Fred Rosenberger.

Will javax.xml package helpful?
Ove Lindström
Ranch Hand

Joined: Mar 10, 2008
Posts: 326

gyan kumar wrote:
Ove Lindström wrote:

Normaly the cube is about 10x9.4x7.199234 inches.

We don't know... do you have a domain registered? Then use that. If not, use something that describes what you are doing.

Actually reply was given for Mr. Fred Rosenberger's reply.


Sorry, I didn't understand that you and Fred was having a private conversation on an open channel.

gyan kumar wrote:
fred rosenberger wrote:are you asking about what your package statement should be and how to set up your directories?


yes Mr. Fred Rosenberger.

Will javax.xml package helpful?


Yes, in javax.xml you find classes that is helpful when working with XML in Java.

However, if you are asking in what package to put YOUR developed files, javax.xml is not the package to use, since that is used by Oracle in the Java API. You may put your files and classes in any package that you like. The commonly used standard is to have a registered domain that you control as base and then add a project or product specific sub-package to it. Under that, there are some patterns that you could use, like have all the specifications (interface and abstract classes) in one package and implementations in another.

I recommend that you take a look at http://java.sun.com/xml/tutorial_intro.html
gyan kumar
Ranch Hand

Joined: Sep 28, 2011
Posts: 61
Thanks Mr. Ove Lindström.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Please give suggestion or hint
 
Similar Threads
simple questions
Hibernate Interview Questions
JPanels with different content should have the same size
Applet with Theme does not refresh properly
Mark Mail as SEEN