Skip to content

Commit

Permalink
Make the json node field public to be able to extract it in the place…
Browse files Browse the repository at this point in the history
…s where it is needed. (apache#7020)

### Motivation

It is possible to [reach](https://github.com/apache/pulsar/blob/f90fab280c931d457877de87c12b7d59074f6f6c/pulsar-client/src/main/java/org/apache/pulsar/client/impl/schema/generic/GenericAvroRecord.java#L64) the field containing the native Avro record, but GenericJsonRecord hides the JsonNode field. It makes sense to even it out and make the JsonNode publicly available.

### Modifications

The public access modifier was added to the getter for JsonNode and the GenericJsonRecord class.
  • Loading branch information
vzhikserg authored May 26, 2020
1 parent b021871 commit 806b83f
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
/**
* Generic json record.
*/
class GenericJsonRecord extends VersionedGenericRecord {
public class GenericJsonRecord extends VersionedGenericRecord {

private final JsonNode jn;

Expand All @@ -39,7 +39,7 @@ class GenericJsonRecord extends VersionedGenericRecord {
this.jn = jn;
}

JsonNode getJsonNode() {
public JsonNode getJsonNode() {
return jn;
}

Expand Down

0 comments on commit 806b83f

Please sign in to comment.