Package io.grpc.xds.client
Class EnvoyProtoData
java.lang.Object
io.grpc.xds.client.EnvoyProtoData
Defines gRPC data types for Envoy protobuf messages used in xDS protocol. Each data type has
the same name as Envoy's corresponding protobuf message, but only with fields used by gRPC.
Each data type should define a fromEnvoyProtoXXX
static method to convert an Envoy
proto message to an instance of that data type.
For data types that need to be sent as protobuf messages, a toEnvoyProtoXXX
instance
method is defined to convert an instance to Envoy proto message.
Data conversion should follow the invariant: converted data is guaranteed to be valid for gRPC. If the protobuf message contains invalid data, the conversion should fail and no object should be instantiated.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static com.google.protobuf.Value
convertToValue
(Object rawObject) Converts Java representation of the given JSON value to protobuf'sValue
representation.
-
Constructor Details
-
EnvoyProtoData
private EnvoyProtoData()
-
-
Method Details
-
convertToValue
Converts Java representation of the given JSON value to protobuf'sValue
representation.The given
rawObject
must be a valid JSON value in Java representation, which is either aMap<String, ?>
,List<?>
,String
,Double
,Boolean
, ornull
.
-