_id stringlengths 2 7 | title stringlengths 3 151 | partition stringclasses 3
values | text stringlengths 33 8k | language stringclasses 1
value | meta_information dict |
|---|---|---|---|---|---|
q16000 | RowSet.setRowRanges | train | public function setRowRanges($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16001 | ClusterConfig.setSecondaryWorkerConfig | train | public function setSecondaryWorkerConfig($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dataproc\V1beta2\InstanceGroupConfig::class); | php | {
"resource": ""
} |
q16002 | ClusterConfig.setSoftwareConfig | train | public function setSoftwareConfig($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16003 | ClusterConfig.setLifecycleConfig | train | public function setLifecycleConfig($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16004 | ClusterConfig.setEncryptionConfig | train | public function setEncryptionConfig($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dataproc\V1beta2\EncryptionConfig::class); | php | {
"resource": ""
} |
q16005 | TransactionOptions.setPartitionedDml | train | public function setPartitionedDml($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Spanner\V1\TransactionOptions_PartitionedDml::class); | php | {
"resource": ""
} |
q16006 | Document.setType | train | public function setType($var)
{
GPBUtil::checkEnum($var, \Google\Cloud\Language\V1beta2\Document_Type::class); | php | {
"resource": ""
} |
q16007 | InputConfig.setGcsSource | train | public function setGcsSource($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Vision\V1\GcsSource::class);
| php | {
"resource": ""
} |
q16008 | UpdateCompanyRequest.setCompany | train | public function setCompany($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Talent\V4beta1\Company::class);
| php | {
"resource": ""
} |
q16009 | PublicKeyCredential.setFormat | train | public function setFormat($var)
{
GPBUtil::checkEnum($var, | php | {
"resource": ""
} |
q16010 | ListAssetsResponse.setListAssetsResults | train | public function setListAssetsResults($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16011 | ListTransferLogsResponse.setTransferMessages | train | public function setTransferMessages($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16012 | StructuredQuery.setSelect | train | public function setSelect($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Firestore\V1beta1\Structured | php | {
"resource": ""
} |
q16013 | StructuredQuery.setEndAt | train | public function setEndAt($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Firestore\V1beta1\Cursor::class);
| php | {
"resource": ""
} |
q16014 | StreamingPullRequest.setModifyDeadlineAckIds | train | public function setModifyDeadlineAckIds($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
| php | {
"resource": ""
} |
q16015 | OperationMetadata.setCreateModelDetails | train | public function setCreateModelDetails($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\AutoMl\V1beta1\CreateModelOperationMetadata::class); | php | {
"resource": ""
} |
q16016 | OperationMetadata.setPartialFailures | train | public function setPartialFailures($var)
{
$arr = GPBUtil::checkRepeatedField($var, | php | {
"resource": ""
} |
q16017 | AbortedException.getRetryDelay | train | public function getRetryDelay()
{
$metadata = array_filter($this->metadata, function ($metadataItem) {
return array_key_exists('retryDelay', $metadataItem);
});
if (count($metadata) === 0) {
| php | {
"resource": ""
} |
q16018 | Word.setSymbols | train | public function setSymbols($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16019 | NumericalStatsResult.setMinValue | train | public function setMinValue($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class);
| php | {
"resource": ""
} |
q16020 | NumericalStatsResult.setMaxValue | train | public function setMaxValue($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class);
| php | {
"resource": ""
} |
q16021 | NumericalStatsResult.setQuantileValues | train | public function setQuantileValues($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16022 | LDiversityConfig.setSensitiveAttribute | train | public function setSensitiveAttribute($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class);
| php | {
"resource": ""
} |
q16023 | HotwordRule.setHotwordRegex | train | public function setHotwordRegex($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16024 | HotwordRule.setLikelihoodAdjustment | train | public function setLikelihoodAdjustment($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_LikelihoodAdjustment::class); | php | {
"resource": ""
} |
q16025 | Company.setSize | train | public function setSize($var)
{
GPBUtil::checkEnum($var, \Google\Cloud\Talent\V4beta1\CompanySize::class);
| php | {
"resource": ""
} |
q16026 | Job.queryResults | train | public function queryResults(array $options = [])
{
$timeoutMs = $this->pluck('initialTimeoutMs', $options, false) ?: 0;
$queryResultsOptions = $options;
$options['timeoutMs'] = $timeoutMs;
return new QueryResults(
$this->connection,
| php | {
"resource": ""
} |
q16027 | Job.reload | train | public function reload(array $options = [])
{
return $this->info | php | {
"resource": ""
} |
q16028 | PartitionQueryRequest.setPartitionOptions | train | public function setPartitionOptions($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Spanner\V1\PartitionOptions::class);
| php | {
"resource": ""
} |
q16029 | RowFilter.setChain | train | public function setChain($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Bigtable\V2\RowFilter_Chain::class); | php | {
"resource": ""
} |
q16030 | RowFilter.setInterleave | train | public function setInterleave($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Bigtable\V2\RowFilter_Interleave::class);
| php | {
"resource": ""
} |
q16031 | RowFilter.setCondition | train | public function setCondition($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Bigtable\V2\RowFilter_Condition::class);
| php | {
"resource": ""
} |
q16032 | RowFilter.setColumnRangeFilter | train | public function setColumnRangeFilter($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16033 | RowFilter.setTimestampRangeFilter | train | public function setTimestampRangeFilter($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Bigtable\V2\TimestampRange::class);
| php | {
"resource": ""
} |
q16034 | RowFilter.setValueRangeFilter | train | public function setValueRangeFilter($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16035 | EncryptionTrait.formatEncryptionHeaders | train | public function formatEncryptionHeaders(array $options)
{
$encryptionHeaders = [];
$useCopySourceHeaders = isset($options['useCopySourceHeaders']) ? $options['useCopySourceHeaders'] : false;
$key = isset($options['encryptionKey']) ? $options['encryptionKey'] : null;
$keySHA256 = isse... | php | {
"resource": ""
} |
q16036 | EncryptionTrait.buildHeaders | train | private function buildHeaders($key, $keySHA256, $useCopySourceHeaders)
{
if ($key) {
$headerNames = $useCopySourceHeaders
? $this->copySourceEncryptionHeaderNames
: $this->encryptionHeaderNames;
if (!$keySHA256) {
$decodedKey = base64_... | php | {
"resource": ""
} |
q16037 | EncryptionTrait.signString | train | protected function signString($privateKey, $data, $forceOpenssl = false)
{
$signature = '';
if (class_exists(RSA::class) && !$forceOpenssl) {
$rsa = new RSA;
$rsa->loadKey($privateKey);
$rsa->setSignatureMode(RSA::SIGNATURE_PKCS1);
$rsa->setHash('sha2... | php | {
"resource": ""
} |
q16038 | MqttConfig.setMqttEnabledState | train | public function setMqttEnabledState($var)
{
GPBUtil::checkEnum($var, \Google\Cloud\Iot\V1\MqttState::class);
| php | {
"resource": ""
} |
q16039 | ErrorEvent.setServiceContext | train | public function setServiceContext($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\ErrorReporting\V1beta1\ServiceContext::class);
| php | {
"resource": ""
} |
q16040 | ErrorEvent.setContext | train | public function setContext($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\ErrorReporting\V1beta1\ErrorContext::class);
| php | {
"resource": ""
} |
q16041 | Token.setText | train | public function setText($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Language\V1\TextSpan::class);
| php | {
"resource": ""
} |
q16042 | Token.setPartOfSpeech | train | public function setPartOfSpeech($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Language\V1\PartOfSpeech::class);
| php | {
"resource": ""
} |
q16043 | Token.setDependencyEdge | train | public function setDependencyEdge($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Language\V1\DependencyEdge::class);
| php | {
"resource": ""
} |
q16044 | TimeTrait.parseTimeString | train | private function parseTimeString($timestamp)
{
$nanoRegex = '/\d{4}-\d{1,2}-\d{1,2}T\d{1,2}\:\d{1,2}\:\d{1,2}(?:\.(\d{1,}))?/';
preg_match($nanoRegex, $timestamp, $matches);
$subSeconds = isset($matches[1])
? $matches[1]
: '0';
if (strlen($subSeconds) > 6) {... | php | {
"resource": ""
} |
q16045 | TimeTrait.formatTimeAsString | train | private function formatTimeAsString(\DateTimeInterface $dateTime, $ns)
{
$dateTime = $dateTime->setTimeZone(new \DateTimeZone('UTC'));
if ($ns === null) {
return $dateTime->format(Timestamp::FORMAT);
} else {
$ns = (string) $ns;
$ns = str_pad($ns, 9, '0', ... | php | {
"resource": ""
} |
q16046 | UpdateTenantRequest.setTenant | train | public function setTenant($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Talent\V4beta1\Tenant::class);
| php | {
"resource": ""
} |
q16047 | StatusMessage.fromJson | train | public static function fromJson(array $data)
{
if (!$data) {
return null;
}
$data += [
'isError' => false,
'refersTo' => null,
'description' => null
| php | {
"resource": ""
} |
q16048 | StorageClient.buckets | train | public function buckets(array $options = [])
{
if (!$this->projectId) {
throw new GoogleException(
'No project ID was provided, ' .
'and we were unable to detect a default project ID.'
);
}
$resultLimit = $this->pluck('resultLimit', $o... | php | {
"resource": ""
} |
q16049 | StorageClient.signedUrlUploader | train | public function signedUrlUploader($uri, $data, array $options = [])
{
| php | {
"resource": ""
} |
q16050 | ListTopicsResponse.setTopics | train | public function setTopics($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16051 | WorkflowGraph.setNodes | train | public function setNodes($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16052 | ParameterValidation.setRegex | train | public function setRegex($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dataproc\V1beta2\RegexValidation::class); | php | {
"resource": ""
} |
q16053 | ParameterValidation.setValues | train | public function setValues($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Dataproc\V1beta2\ValueValidation::class);
| php | {
"resource": ""
} |
q16054 | LROTrait.setLroProperties | train | private function setLroProperties(
LongRunningConnectionInterface $lroConnection,
array $lroCallables,
| php | {
"resource": ""
} |
q16055 | LROTrait.resumeOperation | train | public function resumeOperation($operationName, array $info = [])
{
return new LongRunningOperation(
$this->lroConnection,
| php | {
"resource": ""
} |
q16056 | LROTrait.longRunningOperations | train | public function longRunningOperations(array $options = [])
{
if (is_null($this->lroResource)) {
throw new \BadMethodCallException('This service does list support listing operations.');
}
$resultLimit = $this->pluck('resultLimit', $options, false) ?: 0;
$options['name'] ... | php | {
"resource": ""
} |
q16057 | ListDevicesResponse.setDevices | train | public function setDevices($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16058 | ErrorGroup.setTrackingIssues | train | public function setTrackingIssues($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16059 | Annotation.filter | train | private function filter($items, $path, $type)
{
if (!$items) {
return null;
}
return array_filter($items, function ($item) use ($path, $type) {
$itemCopy = $item;
// key into the value with the given path
| php | {
"resource": ""
} |
q16060 | ListTransferRunsResponse.setTransferRuns | train | public function setTransferRuns($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16061 | SourceContext.setCloudRepo | train | public function setCloudRepo($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\DevTools\Source\V1\CloudRepoSourceContext::class); | php | {
"resource": ""
} |
q16062 | SourceContext.setCloudWorkspace | train | public function setCloudWorkspace($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\DevTools\Source\V1\CloudWorkspaceSourceContext::class); | php | {
"resource": ""
} |
q16063 | SourceContext.setGerrit | train | public function setGerrit($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\DevTools\Source\V1\GerritSourceContext::class);
| php | {
"resource": ""
} |
q16064 | UpdateSshPublicKeyRequest.setSshPublicKey | train | public function setSshPublicKey($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16065 | Value.setMapValue | train | public function setMapValue($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Firestore\V1beta1\MapValue::class); | php | {
"resource": ""
} |
q16066 | JobControllerGapicClient.getJob | train | public function getJob($projectId, $region, $jobId, array $optionalArgs = [])
{
$request = new GetJobRequest();
$request->setProjectId($projectId);
$request->setRegion($region);
$request->setJobId($jobId); | php | {
"resource": ""
} |
q16067 | JobControllerGapicClient.updateJob | train | public function updateJob($projectId, $region, $jobId, $job, $updateMask, array $optionalArgs = [])
{
$request = new UpdateJobRequest();
$request->setProjectId($projectId);
$request->setRegion($region);
| php | {
"resource": ""
} |
q16068 | DlpServiceGrpcClient.ActivateJobTrigger | train | public function ActivateJobTrigger(\Google\Cloud\Dlp\V2\ActivateJobTriggerRequest $argument,
$metadata = [], $options = []) {
| php | {
"resource": ""
} |
q16069 | LabelAnnotation.setEntity | train | public function setEntity($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\VideoIntelligence\V1\Entity::class);
| php | {
"resource": ""
} |
q16070 | LabelAnnotation.setFrames | train | public function setFrames($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16071 | Asset.setResource | train | public function setResource($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16072 | Asset.setIamPolicy | train | public function setIamPolicy($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Iam\V1\Policy::class);
| php | {
"resource": ""
} |
q16073 | SourceLocationResolver.resolve | train | public function resolve(SourceLocation $location)
{
$origPath = str_replace('/', DIRECTORY_SEPARATOR, $location->path());
$basename = basename($origPath);
$prefixes = $this->searchPrefixes($origPath);
$includePaths = array_filter($this->includePaths, function ($path) {
r... | php | {
"resource": ""
} |
q16074 | SourceLocationResolver.searchPrefixes | train | private function searchPrefixes($path)
{
$dirname = dirname($path);
$directoryParts = explode(DIRECTORY_SEPARATOR, $dirname);
| php | {
"resource": ""
} |
q16075 | ListDatasetsResponse.setDatasets | train | public function setDatasets($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16076 | Point.setValue | train | public function setValue($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Monitoring\V3\TypedValue::class);
| php | {
"resource": ""
} |
q16077 | FieldPath.fromString | train | public static function fromString($path, $splitPath = true)
{
self::validateString($path);
$parts = $splitPath
| php | {
"resource": ""
} |
q16078 | FieldPath.pathString | train | public function pathString()
{
$out = [];
foreach ($this->fieldNames as $part) {
$out[] = $this->escapePathPart($part);
| php | {
"resource": ""
} |
q16079 | VisionClient.annotate | train | public function annotate(Image $image, array $options = [])
{
| php | {
"resource": ""
} |
q16080 | VisionClient.annotateBatch | train | public function annotateBatch(array $images, array $options = [])
{
$this->validateBatch($images, Image::class);
$requests = [];
foreach ($images as $image) {
$requests[] = $image->requestObject();
| php | {
"resource": ""
} |
q16081 | Row.setExampleCount | train | public function setExampleCount($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
| php | {
"resource": ""
} |
q16082 | BigQueryOptions.setIdentifyingFields | train | public function setIdentifyingFields($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16083 | BigQueryOptions.setExcludedFields | train | public function setExcludedFields($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16084 | TransactionTrait.lookupBatch | train | public function lookupBatch(array $keys, array $options = [])
{
return $this->operation->lookup($keys, $options + [
| php | {
"resource": ""
} |
q16085 | TransactionTrait.runQuery | train | public function runQuery(QueryInterface $query, array $options = [])
{
return $this->operation->runQuery($query, $options + [
| php | {
"resource": ""
} |
q16086 | EntityAnnotation.setLocations | train | public function setLocations($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16087 | UpdateSnapshotRequest.setSnapshot | train | public function setSnapshot($var)
{
GPBUtil::checkMessage($var, | php | {
"resource": ""
} |
q16088 | EntityTrait.getProperty | train | public function getProperty($property)
{
return isset($this->entity[$property])
| php | {
"resource": ""
} |
q16089 | ListTablesRequest.setView | train | public function setView($var)
{
GPBUtil::checkEnum($var, \Google\Cloud\Bigtable\Admin\V2\Table_View::class); | php | {
"resource": ""
} |
q16090 | ListFindingsResponse.setListFindingsResults | train | public function setListFindingsResults($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, | php | {
"resource": ""
} |
q16091 | Button.setOpenUriAction | train | public function setOpenUriAction($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\D | php | {
"resource": ""
} |
q16092 | Field.setIndexConfig | train | public function setIndexConfig($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Firestore\Admin\V1\Field_IndexConfig::class);
| php | {
"resource": ""
} |
q16093 | Constraints.setSupportedCompressions | train | public function setSupportedCompressions($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, | php | {
"resource": ""
} |
q16094 | Variable.fromJson | train | public static function fromJson(array $data)
{
if (array_key_exists('members', $data)) {
$data['members'] = array_map([static::class, 'fromJson'], $data['members']);
}
if (array_key_exists('status', $data)) {
$data['status'] = | php | {
"resource": ""
} |
q16095 | Variable.byteSize | train | public function byteSize()
{
return mb_strlen($this->name) +
mb_strlen($this->type) | php | {
"resource": ""
} |
q16096 | Variable.fullByteSize | train | public function fullByteSize()
{
$size = $this->byteSize();
foreach ($this->members as $variable) {
$size += | php | {
"resource": ""
} |
q16097 | JobWaitTrait.wait | train | private function wait(
callable $isCompleteFn,
callable $reloadFn,
Job $job,
$maxRetries
) {
if (!$isCompleteFn()) {
if ($maxRetries === null) {
$maxRetries = Job::MAX_RETRIES;
}
$retryFn = function () use ($isCompleteFn, $... | php | {
"resource": ""
} |
q16098 | FormatMessage.setParameters | train | public function setParameters($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
| php | {
"resource": ""
} |
q16099 | CheckAndMutateRowRequest.setPredicateFilter | train | public function setPredicateFilter($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\Bigtable\V2\RowFilter::class);
| php | {
"resource": ""
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.