The right way to name your Java App Engine project is Google.

I am starting with the Google App Engine in Java. I saw a training video , but I do not understand the name of the project package.

It will be a guest book, so the name is a guest book, I understand this part. But after that I see the package name.1)Is that something you import into the project, or is is something you create.

I saw this a lot in projects, something like com.xxx.xxx. 2)How do you name this type of thing or is this an import.

I looked through another tutorial , where they take naming to a whole new level. The name of both the project and the package is de.vogella.gae.java.todo.3)What does this mean in java terms.

4)Maybe one of you can help me with this specific project I want to start.I want to create a Google App project, which so far is only for static files. I will leave the project empty and simply put all my static files in the project’s military directory. I want the domain name to be mydomainstatic

+3
source share
2 answers

1 and 2) The name of the package is a com.xxx.xxxthing that you have already seen in other projects. It provides a namespace so that you do not encounter the naming scheme used by other applications.

A namespace is also a directory structure from which source files flow. com.xxx.xxx will have its files assrc/com/xxx/xxx/Classname.java

The most common use for a package is in import lines, to get Java to look in specific packages for code files. import com.xxx.xxx.*;will allow you to use anything directly in com.xxx.xxx(but not com.xxx.xxx.yyy) without providing the whole package name every time.

, - , .

, StackOverflow , Java, com.stackoverflow.guestbook.

3) de - (TLD) (Deutschland). : TLD.domain name.Google App Engine.language(Java).

4) . , com.mydomainstatic.gae.java.project , java , gae .

+3

, , Java-. , . , - =)

, GAE , .

. , , ?

"com.yourdomain.Guestbook", "com.mydomain.Guestbook". /, .

0

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


All Articles