public class NewsSummary extends Object implements Serializable, Comparable<NewsSummary>
Modifier and Type | Field and Description |
---|---|
static int |
MAX_TITLE_LENGTH
Maximum length of title string.
|
static String |
MESSAGE_SYMBOL |
Constructor and Description |
---|
NewsSummary(NewsKey key,
String sourceId,
long time,
String title,
String source,
Map<String,Collection<String>> tags) |
NewsSummary(NewsSummary summary,
Collection<String> filterTags) |
Modifier and Type | Method and Description |
---|---|
void |
assignKey(NewsKey key) |
int |
compareTo(NewsSummary o) |
boolean |
equals(Object o) |
NewsKey |
getKey()
Returns news key for identifying news.
|
String |
getSource()
Returns news source provider.
|
String |
getSourceId()
Returns external ID assigned by news provider.
|
Collection<String> |
getSymbols()
Returns set of instrument symbols for this news.
|
Set<String> |
getTagNames()
Returns set of tags available for the news
|
Collection<String> |
getTagValues(String tag)
Returns values for the specified tag, or null if not found.
|
long |
getTime()
Returns news time.
|
String |
getTitle()
Returns news title.
|
int |
hashCode() |
String |
toString() |
public static final String MESSAGE_SYMBOL
public static final int MAX_TITLE_LENGTH
public NewsSummary(NewsKey key, String sourceId, long time, String title, String source, Map<String,Collection<String>> tags)
public NewsSummary(NewsSummary summary, Collection<String> filterTags)
public NewsKey getKey()
public void assignKey(NewsKey key)
public String getSourceId()
public long getTime()
public String getTitle()
public String getSource()
public Set<String> getTagNames()
public Collection<String> getTagValues(String tag)
tag
- tag name.public Collection<String> getSymbols()
public int compareTo(NewsSummary o)
compareTo
in interface Comparable<NewsSummary>
Copyright © 2021 Devexperts. All Rights Reserved.