# DaprProtos.PublishEventRequestOrBuilder (dapr-sdk-parent 1.10.0 API)

Package io.dapr.v1

## Interface DaprProtos.PublishEventRequestOrBuilder

All Superinterfaces:
  `com.google.protobuf.MessageLiteOrBuilder`, `com.google.protobuf.MessageOrBuilder`

All Known Implementing Classes:
  `DaprProtos.PublishEventRequest`, `DaprProtos.PublishEventRequest.Builder`

Enclosing class:
  DaprProtos

    public static interface DaprProtos.PublishEventRequestOrBuilder
    extends com.google.protobuf.MessageOrBuilder

### Method Summary

All Methods Instance Methods Abstract Methods Deprecated Methods
`boolean` `containsMetadata​(String key)` The metadata passing to pub components metadata property: - key : the key of the message.
`com.google.protobuf.ByteString` `getData()` The data which will be published to topic.
`String` `getDataContentType()` The content type for the data (optional).
`com.google.protobuf.ByteString` `getDataContentTypeBytes()` The content type for the data (optional).
`Map<String,​String>` `getMetadata()` Deprecated.
`int` `getMetadataCount()` The metadata passing to pub components metadata property: - key : the key of the message.
`Map<String,​String>` `getMetadataMap()` The metadata passing to pub components metadata property: - key : the key of the message.
`String` `getMetadataOrDefault​(String key, String defaultValue)` The metadata passing to pub components metadata property: - key : the key of the message.
`String` `getMetadataOrThrow​(String key)` The metadata passing to pub components metadata property: - key : the key of the message.
`String` `getPubsubName()` The name of the pubsub component
`com.google.protobuf.ByteString` `getPubsubNameBytes()` The name of the pubsub component
`String` `getTopic()` The pubsub topic
`com.google.protobuf.ByteString` `getTopicBytes()` The pubsub topic

### Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder

`isInitialized`

### Methods inherited from interface com.google.protobuf.MessageOrBuilder

`findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof`

### Method Detail

#### getPubsubName

    String getPubsubName()

     The name of the pubsub component

`string pubsub_name = 1;`

Returns:
  The pubsubName.

#### getPubsubNameBytes

    com.google.protobuf.ByteString getPubsubNameBytes()

     The name of the pubsub component

`string pubsub_name = 1;`

Returns:
  The bytes for pubsubName.

#### getTopic

    String getTopic()

     The pubsub topic

`string topic = 2;`

Returns:
  The topic.

#### getTopicBytes

    com.google.protobuf.ByteString getTopicBytes()

     The pubsub topic

`string topic = 2;`

Returns:
  The bytes for topic.

#### getData

    com.google.protobuf.ByteString getData()

     The data which will be published to topic.

`bytes data = 3;`

Returns:
  The data.

#### getDataContentType

    String getDataContentType()

     The content type for the data (optional).

`string data_content_type = 4;`

Returns:
  The dataContentType.

#### getDataContentTypeBytes

    com.google.protobuf.ByteString getDataContentTypeBytes()

     The content type for the data (optional).

`string data_content_type = 4;`

Returns:
  The bytes for dataContentType.

#### getMetadataCount

    int getMetadataCount()

     The metadata passing to pub components
     metadata property:
     - key : the key of the message.

`map<string, string> metadata = 5;`

#### containsMetadata

    boolean containsMetadata​(String key)

     The metadata passing to pub components
     metadata property:
     - key : the key of the message.

`map<string, string> metadata = 5;`

#### getMetadata

    @Deprecated
    Map<String,​String> getMetadata()

Deprecated.
Use `getMetadataMap()` instead.

#### getMetadataMap

    Map<String,​String> getMetadataMap()

     The metadata passing to pub components
     metadata property:
     - key : the key of the message.

`map<string, string> metadata = 5;`

#### getMetadataOrDefault

    String getMetadataOrDefault​(String key,
                                String defaultValue)

     The metadata passing to pub components
     metadata property:
     - key : the key of the message.

`map<string, string> metadata = 5;`

#### getMetadataOrThrow

    String getMetadataOrThrow​(String key)

     The metadata passing to pub components
     metadata property:
     - key : the key of the message.

`map<string, string> metadata = 5;`