Skip to content

SharedType/sharedtype

Repository files navigation

sharedtype-logo

Gitter CI Maven Central

SharedType - Lightweight Java Type Sharing

From Java:

@SharedType
record User(String name, int age, String email) {}

To Typescript:

export interface User {
    name: string;
    age: number;
    email: string;
}

Go:

type User struct {
    Name string
    Age int
    Email string
}

Rust:

pub struct User {
    name: String,
    age: i32,
    email: String,
}

Features

  • Java8+ compatible.
  • Generics support.
  • Compile-time constant support.
  • Fast. (Execution takes milliseconds with -proc:only.)
  • Simple global + type level configurations.

Documentation

Similar Projects

Authors

Cause Chung (cuzfrog@gmail.com), Jeremy Zhou (hb.zhou.jeremy@gmail.com)

License

CC BY 4.0 CC BY 4.0