-
-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2826 from ebean-orm/feature/json-node-module
Refactor extract ebean-jackson-jsonnode module - support for Jackson JsonNode (into separate module)
- Loading branch information
Showing
39 changed files
with
374 additions
and
214 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
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
28 changes: 28 additions & 0 deletions
28
ebean-core-type/src/main/java/io/ebean/core/type/ScalarTypeSet.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,28 @@ | ||
package io.ebean.core.type; | ||
|
||
import io.avaje.lang.Nullable; | ||
|
||
/** | ||
* A ScalarType that has variations based on the mapped JDBC type (like VARCHAR, CLOB, JSON etc). | ||
*/ | ||
public interface ScalarTypeSet<T> { | ||
|
||
/** | ||
* The property type these scalar types map to. | ||
*/ | ||
Class<?> type(); | ||
|
||
/** | ||
* Return a default ScalarType to use when no other annotations like {@code @DbJson} are present. | ||
*/ | ||
@Nullable | ||
ScalarType<?> defaultType(); | ||
|
||
/** | ||
* Return the scalarType to use for the given jdbc type. | ||
* <p> | ||
* For example VARCHAR, CLOB, JSON etc. | ||
*/ | ||
ScalarType<T> forType(int jdbcType); | ||
|
||
} |
17 changes: 17 additions & 0 deletions
17
ebean-core-type/src/main/java/io/ebean/core/type/ScalarTypeSetFactory.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,17 @@ | ||
package io.ebean.core.type; | ||
|
||
import io.avaje.lang.Nullable; | ||
import io.ebean.config.DatabaseConfig; | ||
|
||
/** | ||
* Factory to create ScalarTypeSet. | ||
*/ | ||
public interface ScalarTypeSetFactory { | ||
|
||
/** | ||
* Create the ScalarTypeSet given the config and optional objectMapper. | ||
*/ | ||
@Nullable | ||
ScalarTypeSet<?> createTypeSet(DatabaseConfig config, @Nullable Object objectMapper); | ||
|
||
} |
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
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.