Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
feat: adds getValue to ResultSet (#1073)
* feat: adds getValue method to result set Adds a generic getValue method to the result set. It can be used to retrieve any type from the database. * feat: removes custom int64 and float64 arrays * feat: fixes clirr checks Clirr does not support java 8 default implementations, so it thinks this are breaking changes. These in fact are not breaking changes, since we provide implementations in the interfaces. * test: fixes GrpcResultSet serialize test * feat: implements getValueInternal in result set Adds a less intrusive implementation of getValueInternal for the AbstractResultSet. * fix: fixes struct value decoding Uses the correct type for decoding structs from the result set * feat: makes the structArray method public Makes it public the method to retrieve an array of structs from a Value * test: adds tests for value literals * feat: accepts null in arrays for getValue * feat: allows nulls in values from result sets * docs: fixes java doc for getValue
- Loading branch information
Showing
with
700 additions
and 23 deletions.
- +13 −0 google-cloud-spanner/clirr-ignored-differences.xml
- +62 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/AbstractResultSet.java
- +16 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/AbstractStructReader.java
- +12 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/ForwardingStructReader.java
- +10 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/ResultSets.java
- +5 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/Struct.java
- +10 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/StructReader.java
- +1 −1 google-cloud-spanner/src/main/java/com/google/cloud/spanner/Value.java
- +13 −0 google-cloud-spanner/src/main/java/com/google/cloud/spanner/connection/DirectExecuteResultSet.java
- +13 −0 ...oud-spanner/src/main/java/com/google/cloud/spanner/connection/ReplaceableForwardingResultSet.java
- +57 −21 google-cloud-spanner/src/test/java/com/google/cloud/spanner/AbstractStructReaderTypesTest.java
- +41 −1 google-cloud-spanner/src/test/java/com/google/cloud/spanner/ResultSetsTest.java
- +447 −0 google-cloud-spanner/src/test/java/com/google/cloud/spanner/it/ITResultSetGetValue.java
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
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.