public class TopicMetadata extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
GENERATION_KEY |
static String |
TTL_KEY |
| Constructor and Description |
|---|
TopicMetadata(co.cask.cdap.proto.id.TopicId topicId,
Map<String,String> properties)
Creates a new instance for the given topic with the associated properties.
|
TopicMetadata(co.cask.cdap.proto.id.TopicId topicId,
Map<String,String> properties,
boolean validate)
Creates a new instance for the given topic with the associated properties.
|
TopicMetadata(co.cask.cdap.proto.id.TopicId topicId,
Object... properties)
Creates a new instance for the given topic with the associated properties.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
boolean |
exists()
Check whether the topic exists.
|
int |
getGeneration()
Returns the generation id for the topic.
|
Map<String,String> |
getProperties()
Returns the raw properties for the topic.
|
co.cask.cdap.proto.id.TopicId |
getTopicId()
Returns the topic id that this metadata is associated with.
|
long |
getTTL()
Returns the time-to-live in seconds property of the topic.
|
int |
hashCode() |
String |
toString() |
public static final String GENERATION_KEY
public static final String TTL_KEY
public TopicMetadata(co.cask.cdap.proto.id.TopicId topicId,
Map<String,String> properties)
public TopicMetadata(co.cask.cdap.proto.id.TopicId topicId,
Map<String,String> properties,
boolean validate)
IllegalArgumentException - if validate is true and the provided properties is not valid.public co.cask.cdap.proto.id.TopicId getTopicId()
public int getGeneration()
public boolean exists()
public long getTTL()
Copyright © 2017 Cask Data, Inc. Licensed under the Apache License, Version 2.0.