What do you call a Java package if it is not part of a top-level domain?

I have read the syntax conventions for naming Java packages, and I know the general rule, but what if you just started building your application, you did not choose a license, and this is a personal project? It makes no sense to drop "com.mycompany" or "org.myorganization" if it is not. Anyone have any suggestions for this?

+3
source share
8 answers

Many Java books and online examples simply use the name of the book or project, i.e. ejb3inaction.*or tutorial.*.

+4
source

- lastname.firstname.<other packages>. , , , ( , - ).

+2

org.{myname}?

, . , , () {servicename} ( ). ( ) , , , .

+1

Java- . , ! , , , .

+1

org.{projectname}? (, org.hibernate, org.springframework org.junit)... , - ?

, , , .

+1

name.yourname.myproject net.sf.myproject com.googlecode.myproject myproject.

, ( , , ). , ...

+1

, ( ), , - "net.sf. {project-name}. * ', , unix ( , :)

+1

I usually use nl.myname.myappfor all personal projects. There is no rule against open source using your personal name. If you decide to make the project larger and create a website for it, you can always rename packages if you want.

0
source

Source: https://habr.com/ru/post/1730672/


All Articles