-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add support of code generation for array types
- Loading branch information
Showing
59 changed files
with
1,286 additions
and
142 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,19 @@ | ||
dependencies { | ||
implementation project(':common') | ||
implementation project(':pallet') | ||
implementation project(':rpc') | ||
implementation project(':rpc:rpc-core') | ||
implementation project(':rpc:rpc-sections') | ||
implementation project(':transport') | ||
implementation project(':pallet') | ||
implementation project(':scale') | ||
implementation project(':types') | ||
implementation project(':rpc:rpc-types') | ||
implementation project(':scale') | ||
implementation project(':storage') | ||
implementation project(':transport') | ||
implementation project(':types') | ||
|
||
testImplementation project(':tests') | ||
|
||
testImplementation 'org.testcontainers:testcontainers:1.16.3' | ||
testImplementation 'org.testcontainers:junit-jupiter:1.16.3' | ||
testImplementation 'org.testcontainers:testcontainers:1.17.1' | ||
testImplementation 'org.testcontainers:junit-jupiter:1.17.1' | ||
|
||
testAnnotationProcessor project(':pallet:pallet-codegen') | ||
} |
6 changes: 6 additions & 0 deletions
6
common/src/main/java/com/strategyobject/substrateclient/common/CommonType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package com.strategyobject.substrateclient.common; | ||
|
||
public interface CommonType { | ||
class Array<T> implements CommonType { | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
common/src/main/java/com/strategyobject/substrateclient/common/codegen/Constants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package com.strategyobject.substrateclient.common.codegen; | ||
|
||
import com.strategyobject.substrateclient.common.CommonType; | ||
|
||
public class Constants { | ||
public static final Class<?> ARRAY_TYPE = CommonType.Array.class; | ||
|
||
private Constants() { | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
...ain/java/com/strategyobject/substrateclient/common/codegen/TypeNotSupportedException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package com.strategyobject.substrateclient.common.codegen; | ||
|
||
import javax.lang.model.type.TypeMirror; | ||
|
||
public class TypeNotSupportedException extends IllegalArgumentException { | ||
public TypeNotSupportedException(TypeMirror type) { | ||
super("Type is not supported: " + type); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.