Skip to content
Merged
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
2 changes: 1 addition & 1 deletion annotation/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>online.sharedtype</groupId>
<artifactId>sharedtype-parent</artifactId>
<version>0.10.0-SNAPSHOT</version>
<version>0.9.2-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
5 changes: 5 additions & 0 deletions client-test/rust/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ pub static CUSTOM_CODE_TYPE: types::CustomInjectedStruct = types::CustomInjected
field: 33,
};

pub static MATH_CLASS: types::MathClass = types::MathClass {
bigInteger: 500000000i128,
bigDecimal: 6.534543474564f64,
};

#[cfg(test)]
mod tests {
use std::collections::HashMap;
Expand Down
6 changes: 6 additions & 0 deletions client-test/typescript/src/types.java17.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import {
type ArrayClass,
type JavaTimeClass,
type JodaTimeClass,
type MathClass,
} from "./index.java17";

export const list1: EnumGalaxy[] = ["Andromeda", "MilkyWay", "Triangulum"];
Expand Down Expand Up @@ -129,3 +130,8 @@ export const jodaTime: JodaTimeClass = {
jodaLocalDateTime: "2022-01-01T00:00:00.000+08:00",
jodaOffsetDateTime: "2022-01-01T00:00:00.000+08:00",
}

export const mathClass: MathClass = {
bigDecimal: 1,
bigInteger: 1,
}
2 changes: 1 addition & 1 deletion doc/Usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Add Maven properties:
```xml
<properties>
<compilerArg /> <!-- Placeholder -->
<sharedtype.version>0.10.0</sharedtype.version>
<sharedtype.version>0.9.1</sharedtype.version>
<sharedtype.enabled>false</sharedtype.enabled> <!-- Disable by default so not to participate in every compilation -->
</properties>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ public final class Constants {
PREDEFINED_OBJECT_TYPES.put("java.lang.Object", OBJECT_TYPE_INFO);
PREDEFINED_OBJECT_TYPES.put("java.lang.Class", CLASS_TYPE_INFO);
PREDEFINED_OBJECT_TYPES.put("java.lang.Enum", ENUM_TYPE_INFO);
PREDEFINED_OBJECT_TYPES.put("java.math.BigDecimal", BIG_DECIMAL_TYPE_INFO);
PREDEFINED_OBJECT_TYPES.put("java.math.BigInteger", BIG_INTEGER_TYPE_INFO);
}

public static final Set<TypeInfo> STRING_AND_NUMBER_TYPES = new HashSet<>(14);
Expand Down
2 changes: 1 addition & 1 deletion it/java17/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>online.sharedtype</groupId>
<artifactId>sharedtype-it-parent</artifactId>
<version>0.10.0-SNAPSHOT</version>
<version>0.9.2-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion it/java8/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>online.sharedtype</groupId>
<artifactId>sharedtype-it-parent</artifactId>
<version>0.10.0-SNAPSHOT</version>
<version>0.9.2-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
12 changes: 12 additions & 0 deletions it/java8/src/main/java/online/sharedtype/it/java8/MathClass.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package online.sharedtype.it.java8;

import online.sharedtype.SharedType;

import java.math.BigDecimal;
import java.math.BigInteger;

@SharedType
final class MathClass {
private BigInteger bigInteger;
private BigDecimal bigDecimal;
}
2 changes: 1 addition & 1 deletion it/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>online.sharedtype</groupId>
<artifactId>sharedtype-parent</artifactId>
<version>0.10.0-SNAPSHOT</version>
<version>0.9.2-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
1 change: 1 addition & 0 deletions misc/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ snapshotVersion=$(./mvnw help:evaluate -Dexpression=project.version -q -DforceSt
version="$(printf '%s' "$snapshotVersion" | sed -e "s/-SNAPSHOT//g")"

./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$version" --ntp -B
sed -i -E "s/<sharedtype\.version>[0-9]+\.[0-9\.\[0-9]+\.[0-9]+<\/sharedtype\.version>/<sharedtype.version>$version<\/sharedtype.version>/g" doc/Usage.md
./mvnw deploy -DskipTests -Prelease --ntp -B # to debug release can add -DskipPublishing=true to prevent actual upload
NEW_VERSION="$(increment_version "$version" 1)-SNAPSHOT"
./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$NEW_VERSION" --ntp -B
Expand Down
3 changes: 3 additions & 0 deletions misc/setversion.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$1" --ntp
1 change: 1 addition & 0 deletions mount-tmpfs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@ mountTmpfs "$DIR/processor/target" 64M
mountTmpfs "$DIR/it/java17/target" 64M
mountTmpfs "$DIR/it/java8/target" 64M
mountTmpfs "$MAVEN_REPO_DIR" 64M
mountTmpfs "$DIR/client-test/rust/target" 128M
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<groupId>online.sharedtype</groupId>
<artifactId>sharedtype-parent</artifactId>
<version>0.10.0-SNAPSHOT</version>
<version>0.9.2-SNAPSHOT</version>
<packaging>pom</packaging>

<name>SharedType Parent</name>
Expand Down
2 changes: 1 addition & 1 deletion processor/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>online.sharedtype</groupId>
<artifactId>sharedtype-parent</artifactId>
<version>0.10.0-SNAPSHOT</version>
<version>0.9.2-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
Loading