public class Annotations
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
private java.util.List<Annotation> |
annotations |
static int |
lengthLimit |
private static long |
serialVersionUID |
Constructor and Description |
---|
Annotations()
Construct empty Annotations instance
|
Annotations(twitter4j.internal.org.json.JSONArray jsonArray)
Construct Annotations instance from a JSON Array, returned from Twitter API
Package visibility only!
|
Annotations(java.util.List<Annotation> annotations)
Construct Annotations instance from an exisiting List of Annotation instances
|
Modifier and Type | Method and Description |
---|---|
void |
addAnnotation(Annotation annotation)
Adds a single Annotation to the List of Annotation instances
|
Annotations |
annotation(Annotation annotation)
Adds a single Annotation to the List of Annotation instances
|
(package private) java.lang.String |
asParameterValue()
Package visibility only!
|
boolean |
equals(java.lang.Object obj) |
java.util.List<Annotation> |
getAnnotations() |
private java.util.List<Annotation> |
getSortedAnnotations() |
int |
hashCode() |
boolean |
isEmpty() |
boolean |
isExceedingLengthLimit() |
static boolean |
isExceedingLengthLimit(Annotations annotations) |
void |
setAnnotations(java.util.List<Annotation> annotations)
Sets the List of Annotation instances
Ensures the class's property is not null
|
java.lang.Integer |
size() |
java.lang.String |
toString() |
private static final long serialVersionUID
public static final int lengthLimit
private java.util.List<Annotation> annotations
public Annotations()
public Annotations(java.util.List<Annotation> annotations)
annotations
- - the List of Annotation instancesAnnotations(twitter4j.internal.org.json.JSONArray jsonArray)
jsonArray
- - the JSON Arraypublic java.util.List<Annotation> getAnnotations()
public void setAnnotations(java.util.List<Annotation> annotations)
annotations
- - the List of Annotation instancespublic void addAnnotation(Annotation annotation)
annotation
- - the Annotation to addpublic Annotations annotation(Annotation annotation)
annotation
- - the Annotation to addpublic boolean isEmpty()
public java.lang.Integer size()
public static boolean isExceedingLengthLimit(Annotations annotations)
annotations
- - the instance to testpublic boolean isExceedingLengthLimit()
isExceedingLengthLimit(Annotations annotations)
java.lang.String asParameterValue()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
private java.util.List<Annotation> getSortedAnnotations()