• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

newbie question about importing org.*

 
Eric Johnson
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i'm tryin to understand how to import ogr."whatever". in sample code i often see

or other types org imports, but i have no idea what this is about. looking at the ibm xml4j and other apis i see alot of org stuff, org.xml, org.w3c, org.this.that.andTheOtherThing. do i need to add an org folder to my C:\jdk1.3.0_01\lib folder, or add some cryptic line to my autoexec.bat file? how do i do this stuff?!?
please help. i'm sure it's something simple, but like so many things it's not simple until ya look at it in hindsight.
thanx in advance.
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Two points of concern here.
One you need to read up on packages, because that is what all this is about. Storing classes is particular packages / subdirectories of the classpath for organizing your classes.
The other thing is that there is a standard out there that says, in order for all of us developers not to trip over each others directory naming conventions, we should all use a unique starting directory. The agreed upon method of doing that is to take your company or organizations WWW id and use the nodes backwards. So all of the internet stuff for www.eds.com is stored on the webservers as
com.eds.whatevergroup.whateverapp.whatevertype
and www.xml.org uses
org.xml.etc
No chance that way of us accidentaly choosing the same names.

 
Eric Johnson
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you. i shamefacedly admint i glossed over packages. i'm payin for it now!
 
Marilyn de Queiroz
Sheriff
Posts: 9066
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Download org.xml.something from xml.org website and stick it into your classpath.
Then in the program where you want to use it, import org.xml.something.*
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic