google.devtools.source.v1.ExtendedSourceContext
*/
class ExtendedSourceContext extends \Google\Protobuf\Internal\Message
{
/**
* Any source context.
*
* Generated from protobuf field .google.devtools.source.v1.SourceContext context = 1;
*/
private $context = null;
/**
* Labels with user defined metadata.
*
* Generated from protobuf field map labels = 2;
*/
private $labels;
/**
* Constructor.
*
* @param array $data {
* Optional. Data for populating the Message object.
*
* @type \Google\Cloud\DevTools\Source\V1\SourceContext $context
* Any source context.
* @type array|\Google\Protobuf\Internal\MapField $labels
* Labels with user defined metadata.
* }
*/
public function __construct($data = NULL) {
\GPBMetadata\Google\Devtools\Source\V1\SourceContext::initOnce();
parent::__construct($data);
}
/**
* Any source context.
*
* Generated from protobuf field .google.devtools.source.v1.SourceContext context = 1;
* @return \Google\Cloud\DevTools\Source\V1\SourceContext
*/
public function getContext()
{
return $this->context;
}
/**
* Any source context.
*
* Generated from protobuf field .google.devtools.source.v1.SourceContext context = 1;
* @param \Google\Cloud\DevTools\Source\V1\SourceContext $var
* @return $this
*/
public function setContext($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\DevTools\Source\V1\SourceContext::class);
$this->context = $var;
return $this;
}
/**
* Labels with user defined metadata.
*
* Generated from protobuf field map labels = 2;
* @return \Google\Protobuf\Internal\MapField
*/
public function getLabels()
{
return $this->labels;
}
/**
* Labels with user defined metadata.
*
* Generated from protobuf field map labels = 2;
* @param array|\Google\Protobuf\Internal\MapField $var
* @return $this
*/
public function setLabels($var)
{
$arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING);
$this->labels = $arr;
return $this;
}
}