SpareJ is a set of high performance standard library extensions
Find a file
2025-07-29 14:41:04 +12:00
.idea Initial commit 2025-07-21 19:24:29 +12:00
gradle/wrapper Initial commit 2025-07-21 19:24:29 +12:00
src New version: iterators on evicting lists 2025-07-29 14:41:04 +12:00
.gitignore Initial commit 2025-07-21 19:24:29 +12:00
build.gradle.kts New version: iterators on evicting lists 2025-07-29 14:41:04 +12:00
gradlew Initial commit 2025-07-21 19:24:29 +12:00
gradlew.bat Initial commit 2025-07-21 19:24:29 +12:00
LICENSE.md Initial commit 2025-07-21 19:24:29 +12:00
README.md javadoc link 2025-07-21 19:40:41 +12:00
settings.gradle.kts Initial commit 2025-07-21 19:24:29 +12:00

SpareJ

SpareJ is a set of high performance standard library extensions.

Installation

To include SpareJ in your project, add the appropriate repository and dependency configuration for your build tool.

Maven

Add the following repository to your pom.xml:

<repositories>
  <repository>
    <id>spare-repo-mirror</id>
    <name>SpareWTF Repository</name>
    <url>https://repository.spare.wtf/mirror</url>
  </repository>
</repositories>

Then, add the dependency:

<dependency>
  <groupId>wtf.spare</groupId>
  <artifactId>sparej</artifactId>
  <version>1.0.0</version>
</dependency>

Gradle (Kotlin DSL)

Add the repository to your build.gradle.kts:

repositories {
    maven {
        name = "spareRepoMirror"
        url = uri("https://repository.spare.wtf/mirror")
    }
}

Then, add the dependency:

dependencies {
    implementation("wtf.spare:sparej:1.0.0")
}

Gradle (Groovy DSL)

Add the repository to your build.gradle:

repositories {
    maven {
        name "spareRepoMirror"
        url "https://repository.spare.wtf/mirror"
    }
}

Then, add the dependency:

dependencies {
    implementation "wtf.spare:sparej:1.0.0"
}

Javadoc

You can find the full Javadoc documentation here.

Usage Example

Here's a simple example demonstrating the use of MathUtil.average:

import wtf.spare.sparej.MathUtil;

public class Example {
    public static void main(String[] args) {
        double[] numbers = {1.0, 2.0, 3.0, 4.0, 5.0};
        double average = MathUtil.average(numbers);
        System.out.println("Average: " + average); // Output: Average: 3.0
    }
}