google.api.UsageRule */ class UsageRule extends \Google\Protobuf\Internal\Message { /** * Selects the methods to which this rule applies. Use '*' to indicate all * methods in all APIs. * Refer to [selector][google.api.DocumentationRule.selector] for syntax details. * * Generated from protobuf field string selector = 1; */ private $selector = ''; /** * If true, the selected method allows unregistered calls, e.g. calls * that don't identify any user or application. * * Generated from protobuf field bool allow_unregistered_calls = 2; */ private $allow_unregistered_calls = false; /** * If true, the selected method should skip service control and the control * plane features, such as quota and billing, will not be available. * This flag is used by Google Cloud Endpoints to bypass checks for internal * methods, such as service health check methods. * * Generated from protobuf field bool skip_service_control = 3; */ private $skip_service_control = false; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $selector * Selects the methods to which this rule applies. Use '*' to indicate all * methods in all APIs. * Refer to [selector][google.api.DocumentationRule.selector] for syntax details. * @type bool $allow_unregistered_calls * If true, the selected method allows unregistered calls, e.g. calls * that don't identify any user or application. * @type bool $skip_service_control * If true, the selected method should skip service control and the control * plane features, such as quota and billing, will not be available. * This flag is used by Google Cloud Endpoints to bypass checks for internal * methods, such as service health check methods. * } */ public function __construct($data = NULL) { \GPBMetadata\Google\Api\Usage::initOnce(); parent::__construct($data); } /** * Selects the methods to which this rule applies. Use '*' to indicate all * methods in all APIs. * Refer to [selector][google.api.DocumentationRule.selector] for syntax details. * * Generated from protobuf field string selector = 1; * @return string */ public function getSelector() { return $this->selector; } /** * Selects the methods to which this rule applies. Use '*' to indicate all * methods in all APIs. * Refer to [selector][google.api.DocumentationRule.selector] for syntax details. * * Generated from protobuf field string selector = 1; * @param string $var * @return $this */ public function setSelector($var) { GPBUtil::checkString($var, True); $this->selector = $var; return $this; } /** * If true, the selected method allows unregistered calls, e.g. calls * that don't identify any user or application. * * Generated from protobuf field bool allow_unregistered_calls = 2; * @return bool */ public function getAllowUnregisteredCalls() { return $this->allow_unregistered_calls; } /** * If true, the selected method allows unregistered calls, e.g. calls * that don't identify any user or application. * * Generated from protobuf field bool allow_unregistered_calls = 2; * @param bool $var * @return $this */ public function setAllowUnregisteredCalls($var) { GPBUtil::checkBool($var); $this->allow_unregistered_calls = $var; return $this; } /** * If true, the selected method should skip service control and the control * plane features, such as quota and billing, will not be available. * This flag is used by Google Cloud Endpoints to bypass checks for internal * methods, such as service health check methods. * * Generated from protobuf field bool skip_service_control = 3; * @return bool */ public function getSkipServiceControl() { return $this->skip_service_control; } /** * If true, the selected method should skip service control and the control * plane features, such as quota and billing, will not be available. * This flag is used by Google Cloud Endpoints to bypass checks for internal * methods, such as service health check methods. * * Generated from protobuf field bool skip_service_control = 3; * @param bool $var * @return $this */ public function setSkipServiceControl($var) { GPBUtil::checkBool($var); $this->skip_service_control = $var; return $this; } }