Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x

Schedule.php

Namespace

Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse

File

vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Metrics/Experimental/MetricConfigResponse/Schedule.php

View source
<?php


# Generated by the protocol buffer compiler.  DO NOT EDIT!

# source: opentelemetry/proto/metrics/experimental/metrics_config_service.proto
namespace Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * A Schedule is used to apply a particular scheduling configuration to
 * a metric. If a metric name matches a schedule's patterns, then the metric
 * adopts the configuration specified by the schedule.
 *
 * Generated from protobuf message <code>opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule</code>
 */
class Schedule extends \Google\Protobuf\Internal\Message {
    
    /**
     * Metrics with names that match a rule in the inclusion_patterns are
     * targeted by this schedule. Metrics that match the exclusion_patterns
     * are not targeted for this schedule, even if they match an inclusion
     * pattern.
     *
     * Generated from protobuf field <code>repeated .opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule.Pattern exclusion_patterns = 1;</code>
     */
    private $exclusion_patterns;
    
    /**
     * Generated from protobuf field <code>repeated .opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule.Pattern inclusion_patterns = 2;</code>
     */
    private $inclusion_patterns;
    
    /**
     * Describes the collection period for each metric in seconds.
     * A period of 0 means to not export.
     *
     * Generated from protobuf field <code>int32 period_sec = 3;</code>
     */
    protected $period_sec = 0;
    
    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse\Schedule\Pattern[]|\Google\Protobuf\Internal\RepeatedField $exclusion_patterns
     *           Metrics with names that match a rule in the inclusion_patterns are
     *           targeted by this schedule. Metrics that match the exclusion_patterns
     *           are not targeted for this schedule, even if they match an inclusion
     *           pattern.
     *     @type \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse\Schedule\Pattern[]|\Google\Protobuf\Internal\RepeatedField $inclusion_patterns
     *     @type int $period_sec
     *           Describes the collection period for each metric in seconds.
     *           A period of 0 means to not export.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Opentelemetry\Proto\Metrics\Experimental\MetricsConfigService::initOnce();
        parent::__construct($data);
    }
    
    /**
     * Metrics with names that match a rule in the inclusion_patterns are
     * targeted by this schedule. Metrics that match the exclusion_patterns
     * are not targeted for this schedule, even if they match an inclusion
     * pattern.
     *
     * Generated from protobuf field <code>repeated .opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule.Pattern exclusion_patterns = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getExclusionPatterns() {
        return $this->exclusion_patterns;
    }
    
    /**
     * Metrics with names that match a rule in the inclusion_patterns are
     * targeted by this schedule. Metrics that match the exclusion_patterns
     * are not targeted for this schedule, even if they match an inclusion
     * pattern.
     *
     * Generated from protobuf field <code>repeated .opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule.Pattern exclusion_patterns = 1;</code>
     * @param \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse\Schedule\Pattern[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setExclusionPatterns($var) {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse\Schedule\Pattern::class);
        $this->exclusion_patterns = $arr;
        return $this;
    }
    
    /**
     * Generated from protobuf field <code>repeated .opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule.Pattern inclusion_patterns = 2;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getInclusionPatterns() {
        return $this->inclusion_patterns;
    }
    
    /**
     * Generated from protobuf field <code>repeated .opentelemetry.proto.metrics.experimental.MetricConfigResponse.Schedule.Pattern inclusion_patterns = 2;</code>
     * @param \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse\Schedule\Pattern[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setInclusionPatterns($var) {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse\Schedule\Pattern::class);
        $this->inclusion_patterns = $arr;
        return $this;
    }
    
    /**
     * Describes the collection period for each metric in seconds.
     * A period of 0 means to not export.
     *
     * Generated from protobuf field <code>int32 period_sec = 3;</code>
     * @return int
     */
    public function getPeriodSec() {
        return $this->period_sec;
    }
    
    /**
     * Describes the collection period for each metric in seconds.
     * A period of 0 means to not export.
     *
     * Generated from protobuf field <code>int32 period_sec = 3;</code>
     * @param int $var
     * @return $this
     */
    public function setPeriodSec($var) {
        GPBUtil::checkInt32($var);
        $this->period_sec = $var;
        return $this;
    }

}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Schedule::class, \Opentelemetry\Proto\Metrics\Experimental\MetricConfigResponse_Schedule::class);

Classes

Title Deprecated Summary
Schedule A Schedule is used to apply a particular scheduling configuration to a metric. If a metric name matches a schedule's patterns, then the metric adopts the configuration specified by the schedule.

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal