About Question enthuware.ocpjp.ii.v11.2.3429 :

All the posts and topics that contain only an error report will be moved here after the error is corrected. This is to ensure that when users view a question in ETS Viewer, the "Discuss" button will not indicate the presence of a discussion that adds no value to the question.

Moderators: Site Manager, fjwalraven

Post Reply
BinSlayer
Posts: 10
Joined: Tue Jul 09, 2019 8:33 am
Contact:

About Question enthuware.ocpjp.ii.v11.2.3429 :

Post by BinSlayer »

Hi
Could you explain why this option number 4 is not also correct?
java -p mysql-connector-java-8.0.11.jar;datalayer.jar;myapp.jar -m abc.myapp/com.abc.myapp.Main

You put all 3 jars on the module path, so there's your jar "myapp" and when you place the other 2 on the module-path they should become Automatic Modules, right? Your module-info says it requires "datalayer", this being an automatic module should then depend perfectly fine on all other named modules, automatic modules and jars on the classpath.
As far as I know that's the rule for Automatic Module. They shall require everything (named modules, automatic modules and jars on classpath) and they should export all their packages to the outside.
Am I not right? Maybe I'm missing something here. Any help is appreciated.

admin
Site Admin
Posts: 8915
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.ocpjp.ii.v11.2.3429 :

Post by admin »

You are right. This option would work as well. Updated.

thank you for your feedback!
Paul.
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest