Reference documentation and code samples for the Stackdriver Logging V2 Client class Link.
Describes a link connected to an analytics enabled bucket.
Generated from protobuf messagegoogle.logging.v2.Link
Namespace
Google \ Cloud \ Logging \ V2
Methods
__construct
Constructor.
Parameters
Name
Description
data
array
Optional. Data for populating the Message object.
↳ name
string
The resource name of the link. The name can have up to 100 characters. A valid link id (at the end of the link name) must only have alphanumeric characters and underscores within it. "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]" "organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]" "billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]" "folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]" For example: `projects/my-project/locations/global/buckets/my-bucket/links/my_link
↳ description
string
Describes this link. The maximum length of the description is 8000 characters.
The information of a BigQuery Dataset. When a link is created, a BigQuery dataset is created along with it, in the same project as the LogBucket it's linked to. This dataset will also have BigQuery Views corresponding to the LogViews in the bucket.
getName
The resource name of the link. The name can have up to 100 characters.
A valid link id (at the end of the link name) must only have alphanumeric
characters and underscores within it.
"projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
"organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
"billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
"folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
For example:
`projects/my-project/locations/global/buckets/my-bucket/links/my_link
Returns
Type
Description
string
setName
The resource name of the link. The name can have up to 100 characters.
A valid link id (at the end of the link name) must only have alphanumeric
characters and underscores within it.
"projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
"organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
"billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
"folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]"
For example:
`projects/my-project/locations/global/buckets/my-bucket/links/my_link
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getDescription
Describes this link.
The maximum length of the description is 8000 characters.
Returns
Type
Description
string
setDescription
Describes this link.
The maximum length of the description is 8000 characters.
The information of a BigQuery Dataset. When a link is created, a BigQuery
dataset is created along with it, in the same project as the LogBucket it's
linked to. This dataset will also have BigQuery Views corresponding to the
LogViews in the bucket.
The information of a BigQuery Dataset. When a link is created, a BigQuery
dataset is created along with it, in the same project as the LogBucket it's
linked to. This dataset will also have BigQuery Views corresponding to the
LogViews in the bucket.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Stackdriver Logging V2 Client - Class Link (1.32.3)\n\nVersion latestkeyboard_arrow_down\n\n- [1.32.3 (latest)](/php/docs/reference/cloud-logging/latest/V2.Link)\n- [1.32.2](/php/docs/reference/cloud-logging/1.32.2/V2.Link)\n- [1.31.3](/php/docs/reference/cloud-logging/1.31.3/V2.Link)\n- [1.30.3](/php/docs/reference/cloud-logging/1.30.3/V2.Link)\n- [1.29.0](/php/docs/reference/cloud-logging/1.29.0/V2.Link)\n- [1.28.5](/php/docs/reference/cloud-logging/1.28.5/V2.Link)\n- [1.27.1](/php/docs/reference/cloud-logging/1.27.1/V2.Link)\n- [1.26.0](/php/docs/reference/cloud-logging/1.26.0/V2.Link)\n- [1.25.5](/php/docs/reference/cloud-logging/1.25.5/V2.Link)\n- [1.24.10](/php/docs/reference/cloud-logging/1.24.10/V2.Link) \nReference documentation and code samples for the Stackdriver Logging V2 Client class Link.\n\nDescribes a link connected to an analytics enabled bucket.\n\nGenerated from protobuf message `google.logging.v2.Link`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Logging \\\\ V2\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getName\n\nThe resource name of the link. The name can have up to 100 characters.\n\nA valid link id (at the end of the link name) must only have alphanumeric\ncharacters and underscores within it.\n\"projects/\\[PROJECT_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\n\"organizations/\\[ORGANIZATION_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\n\"billingAccounts/\\[BILLING_ACCOUNT_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\n\"folders/\\[FOLDER_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\nFor example:\n\\`projects/my-project/locations/global/buckets/my-bucket/links/my_link\n\n### setName\n\nThe resource name of the link. The name can have up to 100 characters.\n\nA valid link id (at the end of the link name) must only have alphanumeric\ncharacters and underscores within it.\n\"projects/\\[PROJECT_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\n\"organizations/\\[ORGANIZATION_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\n\"billingAccounts/\\[BILLING_ACCOUNT_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\n\"folders/\\[FOLDER_ID\\]/locations/\\[LOCATION_ID\\]/buckets/\\[BUCKET_ID\\]/links/\\[LINK_ID\\]\"\nFor example:\n\\`projects/my-project/locations/global/buckets/my-bucket/links/my_link\n\n### getDescription\n\nDescribes this link.\n\nThe maximum length of the description is 8000 characters.\n\n### setDescription\n\nDescribes this link.\n\nThe maximum length of the description is 8000 characters.\n\n### getCreateTime\n\nOutput only. The creation timestamp of the link.\n\n### hasCreateTime\n\n### clearCreateTime\n\n### setCreateTime\n\nOutput only. The creation timestamp of the link.\n\n### getLifecycleState\n\nOutput only. The resource lifecycle state.\n\n### setLifecycleState\n\nOutput only. The resource lifecycle state.\n\n### getBigqueryDataset\n\nThe information of a BigQuery Dataset. When a link is created, a BigQuery\ndataset is created along with it, in the same project as the LogBucket it's\nlinked to. This dataset will also have BigQuery Views corresponding to the\nLogViews in the bucket.\n\n### hasBigqueryDataset\n\n### clearBigqueryDataset\n\n### setBigqueryDataset\n\nThe information of a BigQuery Dataset. When a link is created, a BigQuery\ndataset is created along with it, in the same project as the LogBucket it's\nlinked to. This dataset will also have BigQuery Views corresponding to the\nLogViews in the bucket."]]