Board index » jbuilder » Package creation

Package creation


2004-04-11 07:39:35 AM
jbuilder1
Hi Group,
How do I use JBuilder to create a package with 2 folders where all of the
classes must reside in the 2nd folder.
For example, the requirement is java statement: package socket.server;
When I create my project with JBuilder it creates a project and package with
either socket or server but not socket.server. I can do this manually and
just open the classes individually but then classA does not know classB
exists even though both classes exist in the server folder of socket.server.
I tried to import socket.server.*; but that did not help either.
I must be missing something simple.
Any help would be appreciated, Thanks!
Dan
 
 

Re:Package creation

Dan Behrens wrote:
Quote
Hi Group,

How do I use JBuilder to create a package with 2 folders where all of the
classes must reside in the 2nd folder.

For example, the requirement is java statement: package socket.server;

When I create my project with JBuilder it creates a project and package with
either socket or server but not socket.server. I can do this manually and
just open the classes individually but then classA does not know classB
exists even though both classes exist in the server folder of socket.server.
I tried to import socket.server.*; but that did not help either.

I must be missing something simple.

Any help would be appreciated, Thanks!

Dan


JBuilder will create the folders automatically when you create the
class, and specify the package for the new class as socket.server.
If you have the java files already, then they must live under the source
directory for the project (Project | Project Properties, Paths).
<src-dir>\socket\server\classA.java and
<src-dir>\socket\server\classB.java
classA.java and classB.java must also contain the statement :
package socket.server;
--
Regards,
Lori Olson (TeamB)
------------
Save yourself, and everyone else, some time and search the
newsgroups and the FAQ-O-Matic before posting your next
question.
Google Advanced Newsgroup Search
www.google.ca/advanced_group_search
Other Newsgroup Searches:
www.borland.com/newsgroups/ngsearch.html
Joi Ellis's FAQ-O-Matic:
www.visi.com/~gyles19/fom-serve/cache/1.html
 

Re:Package creation

Thanks for responding! But I found the answer about an hour after I posted,
unfortunately my 'Nevermind' post did not make it to the message board for
some reason. Thanks for your time anyway,
Dan
"Lori M Olson (TeamB)" < XXXX@XXXXX.COM >wrote in message
Quote
Dan Behrens wrote:

>Hi Group,
>
>How do I use JBuilder to create a package with 2 folders where all of
the
>classes must reside in the 2nd folder.
>
>For example, the requirement is java statement: package socket.server;
>
>When I create my project with JBuilder it creates a project and package
with
>either socket or server but not socket.server. I can do this manually
and
>just open the classes individually but then classA does not know classB
>exists even though both classes exist in the server folder of
socket.server.
>I tried to import socket.server.*; but that did not help either.
>
>I must be missing something simple.
>
>Any help would be appreciated, Thanks!
>
>Dan
>
>

JBuilder will create the folders automatically when you create the
class, and specify the package for the new class as socket.server.

If you have the java files already, then they must live under the source
directory for the project (Project | Project Properties, Paths).

<src-dir>\socket\server\classA.java and
<src-dir>\socket\server\classB.java

classA.java and classB.java must also contain the statement :

package socket.server;

--

Regards,

Lori Olson (TeamB)

------------

Save yourself, and everyone else, some time and search the
newsgroups and the FAQ-O-Matic before posting your next
question.

Google Advanced Newsgroup Search
www.google.ca/advanced_group_search
Other Newsgroup Searches:
www.borland.com/newsgroups/ngsearch.html
Joi Ellis's FAQ-O-Matic:
www.visi.com/~gyles19/fom-serve/cache/1.html

 

{smallsort}