Reputation: 95
When I see a package such as "com.mycompany.myname", in Eclipse, if I were to create these packages myself, would I do it as follows?
• Create "com"
• Create "mycompany" inside of "com"
• Lastly, create "myname" inside of "mycompany".
Thanks for any help.
Upvotes: 0
Views: 37
Reputation: 262494
In Eclipse, you could directly "Create New Package" com.mycompany.myname
. That will create the necessary directory structure. There is no need to create intermediate packages.
But, there is no need to create the package at all, you can just "Create New Class" and put com.mycompany.myname
as its package name (in the dialog or in source code). Eclipse will automatically create the package if it is missing.
Upvotes: 1