Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion docs/StardustDocs/topics/Compiler-Plugin.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ Sync the project. This is not needed anymore from Kotlin 2.4.0+.

The DataFrame compiler plugin can be used in Maven projects starting from IntelliJ IDEA 2025.3, available now as EAP builds

Setup plugin in pom.xml:
Update the `<kotlin-maven-plugin>` in the `<plugin>` section of your `pom.xml`::
Comment on lines 74 to +76

```xml
<plugin>
Expand All @@ -82,11 +82,13 @@ Setup plugin in pom.xml:
<version>%compilerPluginKotlinVersion%</version>

<configuration>
<!-- Specify the Kotlin-dataframe plugin -->
<compilerPlugins>
<plugin>kotlin-dataframe</plugin>
</compilerPlugins>
</configuration>

<!-- Add the Kotlin-dataframe plugin dependency -->
<dependencies>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
Expand Down
120 changes: 40 additions & 80 deletions docs/StardustDocs/topics/setup/SetupAndroid.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,39 +14,24 @@ How to use Kotlin DataFrame in your Android project with Gradle setup and compil

> See an [Android project example](https://github.com/Kotlin/dataframe/tree/master/examples/projects/android-example).

Kotlin DataFrame doesn't provide a dedicated Android artifact yet,
but you can add the Kotlin DataFrame JVM dependency to your Android project with minimal configuration:

### 1. Add the plugin

[Kotlin DataFrame Compiler Plugin](Compiler-Plugin.md) enables automatic generation
of [extension properties](extensionPropertiesApi.md) and updates [data schemas](schemas.md)
on-the-fly in Android projects, making development with Kotlin DataFrame
faster, more convenient, and fully type- and name-safe.

> Requires Kotlin 2.2.20-Beta1 or higher.

Comment on lines +25 to +26
To enable the plugin in your Gradle project, add it to the `plugins` section:

<tabs>
<tab title="Kotlin DSL">

```kotlin
dependencies {
// Core Kotlin DataFrame API, CSV and JSON IO.
// See custom Gradle setup:
// https://kotlin.github.io/dataframe/setupcustomgradle.html
implementation("org.jetbrains.kotlinx:dataframe-core:%dataFrameVersion%")
implementation("org.jetbrains.kotlinx:dataframe-json:%dataFrameVersion%")
implementation("org.jetbrains.kotlinx:dataframe-csv:%dataFrameVersion%")
// You can add any additional IO modules you like, except for 'dataframe-arrow'.
// Apache Arrow is not supported well on Android.
}

android {
defaultConfig {
minSdk = 21
}
// Requires Java 8 or higher
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
}
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
kotlinOptions.jvmTarget = "1.8"
plugins {
kotlin("plugin.dataframe") version "%compilerPluginKotlinVersion%"
}
```

Expand All @@ -55,61 +40,38 @@ tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
<tab title="Groovy DSL">

```groovy
dependencies {
// Core Kotlin DataFrame API, CSV and JSON IO.
// See custom Gradle setup:
// https://kotlin.github.io/dataframe/setupcustomgradle.html
implementation 'org.jetbrains.kotlinx:dataframe-core:%dataFrameVersion%'
implementation 'org.jetbrains.kotlinx:dataframe-json:%dataFrameVersion%'
implementation 'org.jetbrains.kotlinx:dataframe-csv:%dataFrameVersion%'
// You can add any additional IO modules you like, except for 'dataframe-arrow'.
// Apache Arrow is not supported well on Android.
}

android {
defaultConfig {
minSdk 21
}
// Requires Java 8 or higher
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
}
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).configureEach {
kotlinOptions.jvmTarget = "1.8"
plugins {
id 'org.jetbrains.kotlin.plugin.dataframe' version '%compilerPluginKotlinVersion%'
}
```

</tab>
</tabs>

This setup adds the [Kotlin DataFrame core](Modules.md#dataframe-core)
as well as a subset of the [IO modules](Modules.md#io-modules)
(excluding [experimental ones](Modules.md#experimental-modules)).
For flexible configuration, see [Custom configuration](SetupCustomGradle.md).
In versions older than Kotlin 2.4.0 add following line to your `gradle.properties`:

## Kotlin DataFrame Compiler Plugin

[Kotlin DataFrame Compiler Plugin](Compiler-Plugin.md) enables automatic generation
of [extension properties](extensionPropertiesApi.md) and updates [data schemas](schemas.md)
on-the-fly in Android projects, making development with Kotlin DataFrame
faster, more convenient, and fully type- and name-safe.
```properties
kotlin.incremental=false
```

> Requires Kotlin 2.2.20-Beta1 or higher.
> { style = "note" }
### 2. Add the library

To enable the plugin in your Gradle project, add it to the `plugins` section:
Kotlin DataFrame doesn't provide a dedicated Android artifact yet,
but you can add the Kotlin DataFrame JVM dependency to your Android project with minimal configuration:

<tabs>
<tab title="Kotlin DSL">

```kotlin
plugins {
kotlin("plugin.dataframe") version "%compilerPluginKotlinVersion%"
dependencies {
// Core Kotlin DataFrame API, CSV and JSON IO.
// See custom Gradle setup:
// https://kotlin.github.io/dataframe/setupcustomgradle.html
implementation("org.jetbrains.kotlinx:dataframe-core:%dataFrameVersion%")
implementation("org.jetbrains.kotlinx:dataframe-json:%dataFrameVersion%")
implementation("org.jetbrains.kotlinx:dataframe-csv:%dataFrameVersion%")
// You can add any additional IO modules you like, except for 'dataframe-arrow'.
// Apache Arrow is not well supported on Android.
}
```

Expand All @@ -118,23 +80,21 @@ plugins {
<tab title="Groovy DSL">

```groovy
plugins {
id 'org.jetbrains.kotlin.plugin.dataframe' version '%compilerPluginKotlinVersion%'
dependencies {
// Core Kotlin DataFrame API, CSV and JSON IO.
// See custom Gradle setup:
// https://kotlin.github.io/dataframe/setupcustomgradle.html
implementation 'org.jetbrains.kotlinx:dataframe-core:%dataFrameVersion%'
implementation 'org.jetbrains.kotlinx:dataframe-json:%dataFrameVersion%'
implementation 'org.jetbrains.kotlinx:dataframe-csv:%dataFrameVersion%'
// You can add any additional IO modules you like, except for 'dataframe-arrow'.
// Apache Arrow is not supported well on Android.
}
Comment on lines +89 to 92
```

</tab>
</tabs>

If you're using a version older than Kotlin 2.4.0,
incremental compilation must be disabled due to [this issue](https://youtrack.jetbrains.com/issue/KT-66735),

Add the following line to your `gradle.properties` file:

```properties
kotlin.incremental=false
```

## Next Steps

* Once Kotlin DataFrame is set up in your Android project, continue with the [](quickstart.md)
Expand Down
82 changes: 38 additions & 44 deletions docs/StardustDocs/topics/setup/SetupGradle.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,45 @@ that you want to use in your project. The minimum supported version is JDK 8.

You have successfully created a project with Gradle.

## Add Kotlin DataFrame Gradle dependency
## Setup Kotlin DataFrame

### 1. Add the plugin
[Kotlin DataFrame Compiler Plugin](Compiler-Plugin.md) enables automatic generation of
[extension properties](extensionPropertiesApi.md) and updates [data schemas](schemas.md)
on-the-fly in Gradle projects, making development with Kotlin DataFrame faster,
more convenient, and fully type- and name-safe.

> Requires Kotlin 2.2.20-Beta1 or higher

Comment on lines +49 to +50
To enable the plugin in your Gradle project, add it to the `plugins` section:

<tabs>
<tab title="Kotlin DSL">

```kotlin
plugins {
kotlin("plugin.dataframe") version "%compilerPluginKotlinVersion%"
}
```
</tab>
<tab title="Groovy DSL">

```groovy
plugins {
id 'org.jetbrains.kotlin.plugin.dataframe' version '%compilerPluginKotlinVersion%'
}
```

</tab>
</tabs>

In versions older than Kotlin 2.4.0 add following line to your `gradle.properties`:

```properties
kotlin.incremental=false
```

### 2. Add the library dependency
In your Gradle build file (`build.gradle` or `build.gradle.kts`), add the Kotlin DataFrame library as a dependency:

<tabs>
Expand Down Expand Up @@ -87,49 +124,6 @@ fun main() {
}
```

## Kotlin DataFrame Compiler Plugin

[Kotlin DataFrame Compiler Plugin](Compiler-Plugin.md) enables automatic generation of
[extension properties](extensionPropertiesApi.md) and updates [data schemas](schemas.md)
on-the-fly in Gradle projects, making development with Kotlin DataFrame faster,
more convenient, and fully type- and name-safe.

> Requires Kotlin 2.2.20-Beta1 or higher.
> { style = "note" }

To enable the plugin in your Gradle project, add it to the `plugins` section:

<tabs>
<tab title="Kotlin DSL">

```kotlin
plugins {
kotlin("plugin.dataframe") version "%compilerPluginKotlinVersion%"
}
```

</tab>

<tab title="Groovy DSL">

```groovy
plugins {
id 'org.jetbrains.kotlin.plugin.dataframe' version '%compilerPluginKotlinVersion%'
}
```

</tab>
</tabs>

If you're using a version older than Kotlin 2.4.0,
incremental compilation must be disabled due to [this issue](https://youtrack.jetbrains.com/issue/KT-66735),

Add the following line to your `gradle.properties` file:

```properties
kotlin.incremental=false
```

## Project Example

See [the Gradle example project with the Kotlin DataFrame Compiler Plugin enabled on GitHub](https://github.com/Kotlin/dataframe/tree/master/examples/projects/kotlin-dataframe-plugin-gradle-example).
Expand Down
73 changes: 39 additions & 34 deletions docs/StardustDocs/topics/setup/SetupMaven.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,45 @@ that you want to use in your project. The minimum supported version is JDK 8.

You have successfully created a project with Maven.

## Add Kotlin DataFrame Maven dependency
## Setup Kotlin DataFrame

### 1. Add the plugin

[Kotlin DataFrame Compiler Plugin](Compiler-Plugin.md) enables automatic generation of
[extension properties](extensionPropertiesApi.md) and updates [data schemas](schemas.md)
on-the-fly in Maven projects, making development with Kotlin DataFrame faster,
more convenient, and fully type- and name-safe.

> Requires Kotlin 2.2.20-Beta1 or higher and IntelliJ IDEA 2025.3 or higher.
> { style = "note" }

To enable the plugin in your Maven project, update the `<kotlin-maven-plugin>` in the `<plugin>` section of your `pom.xml`:

```xml
<plugin>
<artifactId>kotlin-maven-plugin</artifactId>
<groupId>org.jetbrains.kotlin</groupId>
<version>%compilerPluginKotlinVersion%</version>

<configuration>
<!-- Specify the Kotlin-dataframe plugin -->
<compilerPlugins>
<plugin>kotlin-dataframe</plugin>
</compilerPlugins>
</configuration>

<!-- Add the Kotlin-dataframe plugin dependency -->
<dependencies>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-maven-dataframe</artifactId>
<version>%compilerPluginKotlinVersion%</version>
</dependency>
</dependencies>
</plugin>
```

### 2. Add the library dependency

In your Maven build file (`pom.xml`), add the Kotlin DataFrame library as a dependency:

Expand Down Expand Up @@ -73,39 +111,6 @@ fun main() {
}
```

## Kotlin DataFrame Compiler Plugin

[Kotlin DataFrame Compiler Plugin](Compiler-Plugin.md) enables automatic generation of
[extension properties](extensionPropertiesApi.md) and updates [data schemas](schemas.md)
on-the-fly in Maven projects, making development with Kotlin DataFrame faster,
more convenient, and fully type- and name-safe.

> Requires Kotlin 2.2.20-Beta1 or higher and IntelliJ IDEA 2025.3 or higher.
> { style = "note" }

To enable the plugin in your Maven project, add it to the `plugins` section:

```xml
<plugin>
<artifactId>kotlin-maven-plugin</artifactId>
<groupId>org.jetbrains.kotlin</groupId>
<version>%compilerPluginKotlinVersion%</version>

<configuration>
<compilerPlugins>
<plugin>kotlin-dataframe</plugin>
</compilerPlugins>
</configuration>

<dependencies>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-maven-dataframe</artifactId>
<version>%compilerPluginKotlinVersion%</version>
</dependency>
</dependencies>
</plugin>
```

## Project Example

Expand Down
Loading