opentelemetry.proto.trace.v1.TraceConfig
*/
class TraceConfig extends \Google\Protobuf\Internal\Message
{
/**
* The global default max number of attributes per span.
*
* Generated from protobuf field int64 max_number_of_attributes = 4;
*/
protected $max_number_of_attributes = 0;
/**
* The global default max number of annotation events per span.
*
* Generated from protobuf field int64 max_number_of_timed_events = 5;
*/
protected $max_number_of_timed_events = 0;
/**
* The global default max number of attributes per timed event.
*
* Generated from protobuf field int64 max_number_of_attributes_per_timed_event = 6;
*/
protected $max_number_of_attributes_per_timed_event = 0;
/**
* The global default max number of link entries per span.
*
* Generated from protobuf field int64 max_number_of_links = 7;
*/
protected $max_number_of_links = 0;
/**
* The global default max number of attributes per span.
*
* Generated from protobuf field int64 max_number_of_attributes_per_link = 8;
*/
protected $max_number_of_attributes_per_link = 0;
protected $sampler;
/**
* Constructor.
*
* @param array $data {
* Optional. Data for populating the Message object.
*
* @type \Opentelemetry\Proto\Trace\V1\ConstantSampler $constant_sampler
* @type \Opentelemetry\Proto\Trace\V1\TraceIdRatioBased $trace_id_ratio_based
* @type \Opentelemetry\Proto\Trace\V1\RateLimitingSampler $rate_limiting_sampler
* @type int|string $max_number_of_attributes
* The global default max number of attributes per span.
* @type int|string $max_number_of_timed_events
* The global default max number of annotation events per span.
* @type int|string $max_number_of_attributes_per_timed_event
* The global default max number of attributes per timed event.
* @type int|string $max_number_of_links
* The global default max number of link entries per span.
* @type int|string $max_number_of_attributes_per_link
* The global default max number of attributes per span.
* }
*/
public function __construct($data = NULL) {
\GPBMetadata\Opentelemetry\Proto\Trace\V1\TraceConfig::initOnce();
parent::__construct($data);
}
/**
* Generated from protobuf field .opentelemetry.proto.trace.v1.ConstantSampler constant_sampler = 1;
* @return \Opentelemetry\Proto\Trace\V1\ConstantSampler|null
*/
public function getConstantSampler()
{
return $this->readOneof(1);
}
public function hasConstantSampler()
{
return $this->hasOneof(1);
}
/**
* Generated from protobuf field .opentelemetry.proto.trace.v1.ConstantSampler constant_sampler = 1;
* @param \Opentelemetry\Proto\Trace\V1\ConstantSampler $var
* @return $this
*/
public function setConstantSampler($var)
{
GPBUtil::checkMessage($var, \Opentelemetry\Proto\Trace\V1\ConstantSampler::class);
$this->writeOneof(1, $var);
return $this;
}
/**
* Generated from protobuf field .opentelemetry.proto.trace.v1.TraceIdRatioBased trace_id_ratio_based = 2;
* @return \Opentelemetry\Proto\Trace\V1\TraceIdRatioBased|null
*/
public function getTraceIdRatioBased()
{
return $this->readOneof(2);
}
public function hasTraceIdRatioBased()
{
return $this->hasOneof(2);
}
/**
* Generated from protobuf field .opentelemetry.proto.trace.v1.TraceIdRatioBased trace_id_ratio_based = 2;
* @param \Opentelemetry\Proto\Trace\V1\TraceIdRatioBased $var
* @return $this
*/
public function setTraceIdRatioBased($var)
{
GPBUtil::checkMessage($var, \Opentelemetry\Proto\Trace\V1\TraceIdRatioBased::class);
$this->writeOneof(2, $var);
return $this;
}
/**
* Generated from protobuf field .opentelemetry.proto.trace.v1.RateLimitingSampler rate_limiting_sampler = 3;
* @return \Opentelemetry\Proto\Trace\V1\RateLimitingSampler|null
*/
public function getRateLimitingSampler()
{
return $this->readOneof(3);
}
public function hasRateLimitingSampler()
{
return $this->hasOneof(3);
}
/**
* Generated from protobuf field .opentelemetry.proto.trace.v1.RateLimitingSampler rate_limiting_sampler = 3;
* @param \Opentelemetry\Proto\Trace\V1\RateLimitingSampler $var
* @return $this
*/
public function setRateLimitingSampler($var)
{
GPBUtil::checkMessage($var, \Opentelemetry\Proto\Trace\V1\RateLimitingSampler::class);
$this->writeOneof(3, $var);
return $this;
}
/**
* The global default max number of attributes per span.
*
* Generated from protobuf field int64 max_number_of_attributes = 4;
* @return int|string
*/
public function getMaxNumberOfAttributes()
{
return $this->max_number_of_attributes;
}
/**
* The global default max number of attributes per span.
*
* Generated from protobuf field int64 max_number_of_attributes = 4;
* @param int|string $var
* @return $this
*/
public function setMaxNumberOfAttributes($var)
{
GPBUtil::checkInt64($var);
$this->max_number_of_attributes = $var;
return $this;
}
/**
* The global default max number of annotation events per span.
*
* Generated from protobuf field int64 max_number_of_timed_events = 5;
* @return int|string
*/
public function getMaxNumberOfTimedEvents()
{
return $this->max_number_of_timed_events;
}
/**
* The global default max number of annotation events per span.
*
* Generated from protobuf field int64 max_number_of_timed_events = 5;
* @param int|string $var
* @return $this
*/
public function setMaxNumberOfTimedEvents($var)
{
GPBUtil::checkInt64($var);
$this->max_number_of_timed_events = $var;
return $this;
}
/**
* The global default max number of attributes per timed event.
*
* Generated from protobuf field int64 max_number_of_attributes_per_timed_event = 6;
* @return int|string
*/
public function getMaxNumberOfAttributesPerTimedEvent()
{
return $this->max_number_of_attributes_per_timed_event;
}
/**
* The global default max number of attributes per timed event.
*
* Generated from protobuf field int64 max_number_of_attributes_per_timed_event = 6;
* @param int|string $var
* @return $this
*/
public function setMaxNumberOfAttributesPerTimedEvent($var)
{
GPBUtil::checkInt64($var);
$this->max_number_of_attributes_per_timed_event = $var;
return $this;
}
/**
* The global default max number of link entries per span.
*
* Generated from protobuf field int64 max_number_of_links = 7;
* @return int|string
*/
public function getMaxNumberOfLinks()
{
return $this->max_number_of_links;
}
/**
* The global default max number of link entries per span.
*
* Generated from protobuf field int64 max_number_of_links = 7;
* @param int|string $var
* @return $this
*/
public function setMaxNumberOfLinks($var)
{
GPBUtil::checkInt64($var);
$this->max_number_of_links = $var;
return $this;
}
/**
* The global default max number of attributes per span.
*
* Generated from protobuf field int64 max_number_of_attributes_per_link = 8;
* @return int|string
*/
public function getMaxNumberOfAttributesPerLink()
{
return $this->max_number_of_attributes_per_link;
}
/**
* The global default max number of attributes per span.
*
* Generated from protobuf field int64 max_number_of_attributes_per_link = 8;
* @param int|string $var
* @return $this
*/
public function setMaxNumberOfAttributesPerLink($var)
{
GPBUtil::checkInt64($var);
$this->max_number_of_attributes_per_link = $var;
return $this;
}
/**
* @return string
*/
public function getSampler()
{
return $this->whichOneof("sampler");
}
}