Reference documentation and code samples for the Google Cloud Functions V2 Client class PBFunction.
Describes a Cloud Function that contains user computation executed in response to an event. It encapsulates function and trigger configurations.
Generated from protobuf message google.cloud.functions.v2.Function
Namespace
Google \ Cloud \ Functions \ V2Methods
__construct
Constructor.
data
array
Optional. Data for populating the Message object.
↳ name
string
A user-defined name of the function. Function names must be unique globally and match pattern projects/*/locations/*/functions/*
↳ description
string
User-provided description of a function.
↳ build_config
Google\Cloud\Functions\V2\BuildConfig
Describes the Build step of the function that builds a container from the given source.
↳ service_config
Google\Cloud\Functions\V2\ServiceConfig
Describes the Service being deployed. Currently deploys services to Cloud Run (fully managed).
↳ event_trigger
Google\Cloud\Functions\V2\EventTrigger
An Eventarc trigger managed by Google Cloud Functions that fires events in response to a condition in another service.
↳ state
int
Output only. State of the function.
↳ update_time
↳ labels
↳ state_messages
array< Google\Cloud\Functions\V2\StateMessage
>
Output only. State Messages for this Cloud Function.
↳ environment
int
Describe whether the function is 1st Gen or 2nd Gen.
↳ url
string
Output only. The deployed url for the function.
↳ kms_key_name
string
[Preview] Resource name of a KMS crypto key (managed by the user) used to encrypt/decrypt function resources. It must match the pattern projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}
.
getName
A user-defined name of the function. Function names must be unique
globally and match pattern projects/*/locations/*/functions/*
string
setName
A user-defined name of the function. Function names must be unique
globally and match pattern projects/*/locations/*/functions/*
var
string
$this
getDescription
User-provided description of a function.
string
setDescription
User-provided description of a function.
var
string
$this
getBuildConfig
Describes the Build step of the function that builds a container from the given source.
hasBuildConfig
clearBuildConfig
setBuildConfig
Describes the Build step of the function that builds a container from the given source.
$this
getServiceConfig
Describes the Service being deployed. Currently deploys services to Cloud Run (fully managed).
hasServiceConfig
clearServiceConfig
setServiceConfig
Describes the Service being deployed. Currently deploys services to Cloud Run (fully managed).
$this
getEventTrigger
An Eventarc trigger managed by Google Cloud Functions that fires events in response to a condition in another service.
hasEventTrigger
clearEventTrigger
setEventTrigger
An Eventarc trigger managed by Google Cloud Functions that fires events in response to a condition in another service.
$this
getState
Output only. State of the function.
int
setState
Output only. State of the function.
var
int
$this
getUpdateTime
Output only. The last update timestamp of a Cloud Function.
hasUpdateTime
clearUpdateTime
setUpdateTime
Output only. The last update timestamp of a Cloud Function.
$this
getLabels
Labels associated with this Cloud Function.
setLabels
Labels associated with this Cloud Function.
$this
getStateMessages
Output only. State Messages for this Cloud Function.
setStateMessages
Output only. State Messages for this Cloud Function.
$this
getEnvironment
Describe whether the function is 1st Gen or 2nd Gen.
int
setEnvironment
Describe whether the function is 1st Gen or 2nd Gen.
var
int
$this
getUrl
Output only. The deployed url for the function.
string
setUrl
Output only. The deployed url for the function.
var
string
$this
getKmsKeyName
[Preview] Resource name of a KMS crypto key (managed by the user) used to encrypt/decrypt function resources.
It must match the pattern projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}
.
string
setKmsKeyName
[Preview] Resource name of a KMS crypto key (managed by the user) used to encrypt/decrypt function resources.
It must match the pattern projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}
.
var
string
$this