Reference documentation and code samples for the Google Cloud Eventarc Publishing V1 Client class PublishRequest.
The request message for the Publish method.
Generated from protobuf message google.cloud.eventarc.publishing.v1.PublishRequest
Namespace
Google \ Cloud \ Eventarc \ Publishing \ V1Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ message_bus |
string
Required. The full name of the message bus to publish events to. Format: |
↳ proto_message |
CloudEvent
The Protobuf format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/protobuf-format.md |
↳ json_message |
string
The JSON format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/json-format.md |
↳ avro_message |
string
The Avro format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/avro-format.md |
getMessageBus
Required. The full name of the message bus to publish events to. Format:
projects/{project}/locations/{location}/messageBuses/{messageBus}
.
Returns | |
---|---|
Type | Description |
string |
setMessageBus
Required. The full name of the message bus to publish events to. Format:
projects/{project}/locations/{location}/messageBuses/{messageBus}
.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getProtoMessage
The Protobuf format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/protobuf-format.md
Returns | |
---|---|
Type | Description |
CloudEvent|null |
hasProtoMessage
setProtoMessage
The Protobuf format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/protobuf-format.md
Parameter | |
---|---|
Name | Description |
var |
CloudEvent
|
Returns | |
---|---|
Type | Description |
$this |
getJsonMessage
The JSON format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/json-format.md
Returns | |
---|---|
Type | Description |
string |
hasJsonMessage
setJsonMessage
The JSON format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/json-format.md
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getAvroMessage
The Avro format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/avro-format.md
Returns | |
---|---|
Type | Description |
string |
hasAvroMessage
setAvroMessage
The Avro format of the CloudEvent being published. Specification can be found here: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/formats/avro-format.md
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getFormat
Returns | |
---|---|
Type | Description |
string |