mirror of
https://github.com/corda/corda.git
synced 2025-01-18 02:39:51 +00:00
Review comments
This commit is contained in:
parent
c783c431b1
commit
03850dabc2
@ -7,8 +7,8 @@ release, see :doc:`upgrade-notes`.
|
|||||||
Unreleased
|
Unreleased
|
||||||
==========
|
==========
|
||||||
|
|
||||||
* Fix CORDA-1229. Setter based serialization was broken with generic types when the property was stored
|
* Fix CORDA-1229. Setter-based serialization was broken with generic types when the property was stored
|
||||||
as the interface type, List for example.
|
as the raw type, List for example.
|
||||||
|
|
||||||
* java.security.cert.CRLReason added to the default Whitelist.
|
* java.security.cert.CRLReason added to the default Whitelist.
|
||||||
|
|
||||||
|
@ -314,7 +314,7 @@ fun propertiesForSerializationFromSetters(
|
|||||||
"${property.value.field?.genericType!!}")
|
"${property.value.field?.genericType!!}")
|
||||||
}
|
}
|
||||||
|
|
||||||
// make sure the getter returns the same type (within inheritance bounds) the setter accepts
|
// Make sure the getter returns the same type (within inheritance bounds) the setter accepts.
|
||||||
if (!(TypeToken.of (getter.genericReturnType).isSupertypeOf(setterType))) {
|
if (!(TypeToken.of (getter.genericReturnType).isSupertypeOf(setterType))) {
|
||||||
throw NotSerializableException("Defined setter for parameter ${property.value.field?.name} " +
|
throw NotSerializableException("Defined setter for parameter ${property.value.field?.name} " +
|
||||||
"takes parameter of type $setterType yet the defined getter returns a value of type " +
|
"takes parameter of type $setterType yet the defined getter returns a value of type " +
|
||||||
|
@ -345,8 +345,8 @@ public class SetterConstructorTests {
|
|||||||
evolutionSerialiserGetter,
|
evolutionSerialiserGetter,
|
||||||
fingerPrinter);
|
fingerPrinter);
|
||||||
|
|
||||||
// if we've got super / sub types on the setter vs the unerlaying type the wrong way around this will
|
// if we've got super / sub types on the setter vs the underlying type the wrong way around this will
|
||||||
// explode
|
// explode. See CORDA-1229 (https://r3-cev.atlassian.net/browse/CORDA-1229)
|
||||||
new SerializationOutput(factory1).serialize(cil);
|
new SerializationOutput(factory1).serialize(cil);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user