|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecttwitter4j.Annotation
public class Annotation
A data class representing an Annotation of a Status or a Tweet
| Constructor Summary | |
|---|---|
Annotation(java.lang.String type)
Construct an Annotation with a type but no attributes |
|
Annotation(java.lang.String type,
java.util.Map<java.lang.String,java.lang.String> attributes)
Construct an Annotation with a type and attributes |
|
| Method Summary | |
|---|---|
void |
addAttribute(java.lang.String name,
java.lang.String value)
Adds a single attribute |
Annotation |
attribute(java.lang.String name,
java.lang.String value)
Adds a single attribute |
Annotation |
attributes(java.util.Map<java.lang.String,java.lang.String> attributes)
Sets the attributes Ensures the class's property is not null |
int |
compareTo(Annotation other)
|
boolean |
equals(java.lang.Object obj)
|
java.util.Map<java.lang.String,java.lang.String> |
getAttributes()
|
java.lang.String |
getType()
|
int |
hashCode()
|
boolean |
isEmpty()
|
void |
setAttributes(java.util.Map<java.lang.String,java.lang.String> attributes)
Sets the attributes Ensures the class's property is not null |
void |
setType(java.lang.String type)
Sets the type Ensures the class's property is not null |
java.lang.Integer |
size()
|
java.lang.String |
toString()
|
Annotation |
type(java.lang.String type)
Sets the type Ensures the class's property is not null |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Annotation(java.lang.String type)
type - - the type
public Annotation(java.lang.String type,
java.util.Map<java.lang.String,java.lang.String> attributes)
type - attributes - | Method Detail |
|---|
public java.lang.String getType()
public void setType(java.lang.String type)
type - - the typepublic Annotation type(java.lang.String type)
type - - the type
public java.util.Map<java.lang.String,java.lang.String> getAttributes()
public void setAttributes(java.util.Map<java.lang.String,java.lang.String> attributes)
attributes - - the attributespublic Annotation attributes(java.util.Map<java.lang.String,java.lang.String> attributes)
attributes - - the attributes
public void addAttribute(java.lang.String name,
java.lang.String value)
name - - the attribute namevalue - - the attribute value
public Annotation attribute(java.lang.String name,
java.lang.String value)
name - - the attribute namevalue - - the attribute value
public boolean isEmpty()
public java.lang.Integer size()
public int compareTo(Annotation other)
compareTo in interface java.lang.Comparable<Annotation>public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||