wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes Folder and package oranization (please I need this o procced) Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Folder and package oranization (please I need this o procced)" Watch "Folder and package oranization (please I need this o procced)" New topic
Author

Folder and package oranization (please I need this o procced)

Vinicius Souza
Ranch Hand

Joined: May 18, 2011
Posts: 45

Hi! This is my first post, my first language is not english but I will try to expose my problem
Im new on Java world but not new as a programmer, and Im using Netbeans. To learn Java Im creating a lot of mini projects on the structure showed below:


Im working on the project called DeskApplet and I need a public class that I created on the project called YCreator. I like my projects very organised, so I need to know how can I share classes among all projects, but on a organized way.
Thanks in advance for all replyes!

Java is the best (I love C too) heehhh
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14164
    
  19

Welcome to the Ranch!

To make the classes from one project available in another project, you will have to create a dependency in NetBeans from the other project to the first project, or you will have to add the classes from the first project in the classpath of the other project. You can set this by selecting File / Project Properties, Libraries. Use the buttons "Add Project...", "Add Library..." or "Add JAR/Folder" to add a depencency on another project, a library or a JAR file or folder with class files.

Please check your private messages for an administrative matter.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
Vinicius Souza
Ranch Hand

Joined: May 18, 2011
Posts: 45

Thank you a lot! Exactly that I was searching for! I started using Netbeans and Java and I like to learn the correct way to do something. Now I can move on!
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Folder and package oranization (please I need this o procced)