cluster1
cluster1

Reputation: 5752

Are Android Kotlin modules the same as Java packages?

The definition of the "internal"-keyword in Kotlin says: "Internal: Visible inside the same module".

What is meant with "module"?

I know the concept of packages from Java. Is that meant? Or are Kotlin-"modules" something different?

Upvotes: 0

Views: 217

Answers (1)

Alexey Romanov
Alexey Romanov

Reputation: 170919

A module is a set of Kotlin sources compiled together:

  • an IntelliJ IDEA module;

  • a Maven project;

  • a Gradle source set (with the exception that the test source set can access the internal declarations of main);

  • a set of files compiled with one invocation of the Ant task.

The equivalent of Java packages in Kotlin is... well, packages.

Upvotes: 1

Related Questions