Why the classes is not accessible?

Viewed 18

I wrote a project called GameSAlgorithms, then I wrote another Project called GameServerProject. In the module of GameSAlgorithms I exports the packages of GameSAlgorithms like that

module GamesAlgorithms {
    
    exports com.hit.gameAlgo;
    exports com.hit.games;
}

Then in the module of the second project:

module GameServerProject {
    
    requires java.desktop;
    requires json.simple;
    requires GamesAlgorithms;
}

I tried this too

module GameServerProject {
    
    exports com.hit.exception;
    requires java.desktop;
    requires json.simple;
    requires GamesAlgorithms;
    requires com.hit.gameAlgo;
    requires com.hit.games;
}

but still it says - " cannot be resolved to a module ".

Somethins else- i save GamesAlgorithms as a JAr file. i tried to add it both, ad an internal jar and as external jar and still it's not working.

0 Answers
Related