Are modules and projects redundant?
Of the many praises/criticisms of the new modules support, three in particular stand out:
1. Adds too much confusing complexity
2. Adds great flexibility for large projects
3. XXX should be configurable on a per-project basis
What if there were no modules? What if there were just projects, but projects could depend on other projects?
Basically, promote the concept of "module" all the way up to a full-fledged "project". Then add all the features unique to modules, like dependency checking and resource sharing, to projects.
请先登录再写评论。
Precisely. This fragment will compile and run under either 1.3 or 1.4 (with a performance bump under 1.4). If compiled under 1.3, it will run under 1.4 (no performance bump). If compiled under 1.4, however, it will give a NoSuchMethodError when run under 1.3. All without requiring anything outside of java.lang!
--Dave
I did not understand - are you questioning something or make some
statements?
--
Valentin Kipiatkov
JetBrains, Inc
http://www.intellij.com
"Develop with pleasure!"
"Alain Ravet" <alain.ravet.list@wanadoo.be> wrote in message
news:bpvs8n$9iq$1@is.intellij.net...
>
>
>
feature?!
>
>
>
>
>
Valentin Kipiatkov (JetBrains) wrote:
>I did not understand - are you questioning something or make some
>statements?
>
It's a genuine question : what are modules missing, to be "runnable",
"workable with"?
A corollary : should single modules be "runnable", what would be the
benefits of wrapping a project around a single module?
Alain
Rayz,
After some consideration I think that I like current IDEA solution more than
your proposal. Logically often modules don't form parent-child relationship
while they still share some common properties like compiler, JDK, libraries
and so on. Ability to specify and maintain these properties in one place
simplifies not only logical structure but maintainability of the project.
But logically project is not a module it has no source files ...
Regards,
Alex Oscherov
"Rayz" <no_mail@jetbrains.com> wrote in message
news:28205914.1069848102220.JavaMail.itn@is.intellij.net...
are
not
JDK.
So
>
are not, then they are inherited from the parent.
>
that allows it to override the settings in its child projects.
>
automatically pick up a separate set of JARS when it is part of another
project ...
>
+Logically often modules don't form parent-child relationship while they still share some common properties like compiler, JDK, libraries
and so on.+
Not sure what you mean here. Modules are always a child of something, because they can't form projects on their own.
At the moment, I cannot see what a module gives you, that you don't get from a project.
Projects should have their own settings, or get overridden (optionally) when they form part of a larger project.
Rayz,
maybe small example can help. Let's imagine I have three modules: "business
logic", "administrative console" and "persistent schema" all these modules
are independent in terms that they have independent sources and use support
of the different libraries. But I still want to compile all of them using
the same compiler and test all of them using the same JDK. So it looks
convelient to me that now I can create project "server" and include all thee
modules into it. As a conclusion to make long things short I find it a good
idea to have projects that don't have source files of their own separate
from the modules that have some.
Regards,
Alex Oscherov
"Rayz" <no_mail@jetbrains.com> wrote in message
news:32317033.1070085230743.JavaMail.javamailuser@localhost...
still share some common properties like compiler, JDK, libraries
>
because they can't form projects on their own.
>
from a project.
>
when they form part of a larger project.
>
>
But I believe intellij's intention is to allow each module to specify it's own jdk. So apparently, in some cases, different modules would use difference jdks within the same project.
This is the same flexibility offered in the "Workspace,project" organization: each project could specify it's own jdk, or could inherit it from a parent project, or could use the workspace default jdk.