1<?php 2# Generated by the protocol buffer compiler. DO NOT EDIT! 3# source: src/proto/grpc/testing/messages.proto 4 5namespace Grpc\Testing; 6 7use Google\Protobuf\Internal\GPBType; 8use Google\Protobuf\Internal\RepeatedField; 9use Google\Protobuf\Internal\GPBUtil; 10 11/** 12 * Accumulated stats for RPCs sent by a test client. 13 * 14 * Generated from protobuf message <code>grpc.testing.LoadBalancerAccumulatedStatsResponse</code> 15 */ 16class LoadBalancerAccumulatedStatsResponse extends \Google\Protobuf\Internal\Message 17{ 18 /** 19 * The total number of RPCs have ever issued for each type. 20 * Deprecated: use stats_per_method.rpcs_started instead. 21 * 22 * Generated from protobuf field <code>map<string, int32> num_rpcs_started_by_method = 1 [deprecated = true];</code> 23 */ 24 private $num_rpcs_started_by_method; 25 /** 26 * The total number of RPCs have ever completed successfully for each type. 27 * Deprecated: use stats_per_method.result instead. 28 * 29 * Generated from protobuf field <code>map<string, int32> num_rpcs_succeeded_by_method = 2 [deprecated = true];</code> 30 */ 31 private $num_rpcs_succeeded_by_method; 32 /** 33 * The total number of RPCs have ever failed for each type. 34 * Deprecated: use stats_per_method.result instead. 35 * 36 * Generated from protobuf field <code>map<string, int32> num_rpcs_failed_by_method = 3 [deprecated = true];</code> 37 */ 38 private $num_rpcs_failed_by_method; 39 /** 40 * Per-method RPC statistics. The key is the full method path; i.e. 41 * "/proto.package.ServiceName/MethodName". 42 * 43 * Generated from protobuf field <code>map<string, .grpc.testing.LoadBalancerAccumulatedStatsResponse.MethodStats> stats_per_method = 4;</code> 44 */ 45 private $stats_per_method; 46 47 /** 48 * Constructor. 49 * 50 * @param array $data { 51 * Optional. Data for populating the Message object. 52 * 53 * @type array|\Google\Protobuf\Internal\MapField $num_rpcs_started_by_method 54 * The total number of RPCs have ever issued for each type. 55 * Deprecated: use stats_per_method.rpcs_started instead. 56 * @type array|\Google\Protobuf\Internal\MapField $num_rpcs_succeeded_by_method 57 * The total number of RPCs have ever completed successfully for each type. 58 * Deprecated: use stats_per_method.result instead. 59 * @type array|\Google\Protobuf\Internal\MapField $num_rpcs_failed_by_method 60 * The total number of RPCs have ever failed for each type. 61 * Deprecated: use stats_per_method.result instead. 62 * @type array|\Google\Protobuf\Internal\MapField $stats_per_method 63 * Per-method RPC statistics. The key is the full method path; i.e. 64 * "/proto.package.ServiceName/MethodName". 65 * } 66 */ 67 public function __construct($data = NULL) { 68 \GPBMetadata\Src\Proto\Grpc\Testing\Messages::initOnce(); 69 parent::__construct($data); 70 } 71 72 /** 73 * The total number of RPCs have ever issued for each type. 74 * Deprecated: use stats_per_method.rpcs_started instead. 75 * 76 * Generated from protobuf field <code>map<string, int32> num_rpcs_started_by_method = 1 [deprecated = true];</code> 77 * @return \Google\Protobuf\Internal\MapField 78 */ 79 public function getNumRpcsStartedByMethod() 80 { 81 return $this->num_rpcs_started_by_method; 82 } 83 84 /** 85 * The total number of RPCs have ever issued for each type. 86 * Deprecated: use stats_per_method.rpcs_started instead. 87 * 88 * Generated from protobuf field <code>map<string, int32> num_rpcs_started_by_method = 1 [deprecated = true];</code> 89 * @param array|\Google\Protobuf\Internal\MapField $var 90 * @return $this 91 */ 92 public function setNumRpcsStartedByMethod($var) 93 { 94 $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::INT32); 95 $this->num_rpcs_started_by_method = $arr; 96 97 return $this; 98 } 99 100 /** 101 * The total number of RPCs have ever completed successfully for each type. 102 * Deprecated: use stats_per_method.result instead. 103 * 104 * Generated from protobuf field <code>map<string, int32> num_rpcs_succeeded_by_method = 2 [deprecated = true];</code> 105 * @return \Google\Protobuf\Internal\MapField 106 */ 107 public function getNumRpcsSucceededByMethod() 108 { 109 return $this->num_rpcs_succeeded_by_method; 110 } 111 112 /** 113 * The total number of RPCs have ever completed successfully for each type. 114 * Deprecated: use stats_per_method.result instead. 115 * 116 * Generated from protobuf field <code>map<string, int32> num_rpcs_succeeded_by_method = 2 [deprecated = true];</code> 117 * @param array|\Google\Protobuf\Internal\MapField $var 118 * @return $this 119 */ 120 public function setNumRpcsSucceededByMethod($var) 121 { 122 $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::INT32); 123 $this->num_rpcs_succeeded_by_method = $arr; 124 125 return $this; 126 } 127 128 /** 129 * The total number of RPCs have ever failed for each type. 130 * Deprecated: use stats_per_method.result instead. 131 * 132 * Generated from protobuf field <code>map<string, int32> num_rpcs_failed_by_method = 3 [deprecated = true];</code> 133 * @return \Google\Protobuf\Internal\MapField 134 */ 135 public function getNumRpcsFailedByMethod() 136 { 137 return $this->num_rpcs_failed_by_method; 138 } 139 140 /** 141 * The total number of RPCs have ever failed for each type. 142 * Deprecated: use stats_per_method.result instead. 143 * 144 * Generated from protobuf field <code>map<string, int32> num_rpcs_failed_by_method = 3 [deprecated = true];</code> 145 * @param array|\Google\Protobuf\Internal\MapField $var 146 * @return $this 147 */ 148 public function setNumRpcsFailedByMethod($var) 149 { 150 $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::INT32); 151 $this->num_rpcs_failed_by_method = $arr; 152 153 return $this; 154 } 155 156 /** 157 * Per-method RPC statistics. The key is the full method path; i.e. 158 * "/proto.package.ServiceName/MethodName". 159 * 160 * Generated from protobuf field <code>map<string, .grpc.testing.LoadBalancerAccumulatedStatsResponse.MethodStats> stats_per_method = 4;</code> 161 * @return \Google\Protobuf\Internal\MapField 162 */ 163 public function getStatsPerMethod() 164 { 165 return $this->stats_per_method; 166 } 167 168 /** 169 * Per-method RPC statistics. The key is the full method path; i.e. 170 * "/proto.package.ServiceName/MethodName". 171 * 172 * Generated from protobuf field <code>map<string, .grpc.testing.LoadBalancerAccumulatedStatsResponse.MethodStats> stats_per_method = 4;</code> 173 * @param array|\Google\Protobuf\Internal\MapField $var 174 * @return $this 175 */ 176 public function setStatsPerMethod($var) 177 { 178 $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grpc\Testing\LoadBalancerAccumulatedStatsResponse\MethodStats::class); 179 $this->stats_per_method = $arr; 180 181 return $this; 182 } 183 184} 185 186