Modifier and Type | Field and Description |
---|---|
private java.util.Date |
closedAt
the date this changeset was closed at
|
private int |
commentsCount
the number of comments for this changeset
|
private ChangesetDataSet |
content
the changeset content
|
private java.util.Date |
createdAt
date this changeset was created at
|
private java.util.List<ChangesetDiscussionComment> |
discussion
the changeset discussion
|
private int |
id
the changeset id
|
private boolean |
incomplete
indicates whether this changeset is incomplete.
|
private LatLon |
max
the max.
|
static int |
MAX_CHANGESET_TAG_LENGTH
The maximum changeset tag length allowed by API 0.6
|
private LatLon |
min
the min.
|
private boolean |
open
indicates whether this changeset is still open or not
|
private java.util.Map<java.lang.String,java.lang.String> |
tags
the map of tags
|
private User |
user
the user who owns the changeset
|
Constructor and Description |
---|
Changeset()
Creates a new changeset with id 0.
|
Changeset(Changeset other)
Creates a clone of
other |
Changeset(int id)
Creates a changeset with id
id . |
Modifier and Type | Method and Description |
---|---|
void |
addDiscussionComment(ChangesetDiscussionComment comment)
Adds a comment to the changeset discussion.
|
int |
compareTo(Changeset other) |
boolean |
equals(java.lang.Object obj) |
java.lang.String |
get(java.lang.String key)
Replies the value of the given key; null, if there is no value for this key
|
Bounds |
getBounds() |
java.util.Date |
getClosedAt() |
int |
getCommentsCount()
Replies the number of comments for this changeset.
|
ChangesetDataSet |
getContent() |
java.util.Date |
getCreatedAt() |
java.util.List<ChangesetDiscussionComment> |
getDiscussion()
Replies the list of comments in the changeset discussion, if any.
|
java.lang.String |
getDisplayName(NameFormatter formatter) |
int |
getId() |
java.util.Map<java.lang.String,java.lang.String> |
getKeys()
Replies the map of key/value pairs.
|
LatLon |
getMax() |
LatLon |
getMin() |
java.lang.String |
getName() |
User |
getUser() |
boolean |
hasContent() |
boolean |
hasEqualSemanticAttributes(Changeset other) |
int |
hashCode() |
boolean |
hasKeys()
Replies true, if there is at least one key/value pair; false, otherwise
|
boolean |
isIncomplete() |
boolean |
isNew() |
boolean |
isOpen() |
java.util.Collection<java.lang.String> |
keySet()
Replies the set of keys
|
void |
mergeFrom(Changeset other) |
void |
put(java.lang.String key,
java.lang.String value)
Sets a key/value pairs
|
void |
remove(java.lang.String key)
Removes a given key/value pair
|
void |
removeAll()
Removes all tags
|
void |
setClosedAt(java.util.Date closedAt) |
void |
setCommentsCount(int commentsCount)
Sets the number of comments for this changeset.
|
void |
setContent(ChangesetDataSet content) |
void |
setCreatedAt(java.util.Date createdAt) |
void |
setId(int id) |
void |
setIncomplete(boolean incomplete) |
void |
setKeys(java.util.Map<java.lang.String,java.lang.String> keys)
Sets the map of key/value pairs
|
void |
setMax(LatLon max) |
void |
setMin(LatLon min) |
void |
setOpen(boolean open) |
void |
setUser(User user) |
void |
visit(Visitor v) |
public static final int MAX_CHANGESET_TAG_LENGTH
private int id
private java.util.Date createdAt
private java.util.Date closedAt
private boolean open
private int commentsCount
private java.util.Map<java.lang.String,java.lang.String> tags
private boolean incomplete
private ChangesetDataSet content
private java.util.List<ChangesetDiscussionComment> discussion
public Changeset()
public Changeset(int id)
id
. If id > 0, sets incomplete to true.id
- the idpublic java.lang.String getName()
public java.lang.String getDisplayName(NameFormatter formatter)
public int getId()
public void setId(int id)
public java.util.Date getCreatedAt()
public void setCreatedAt(java.util.Date createdAt)
public java.util.Date getClosedAt()
public void setClosedAt(java.util.Date closedAt)
public boolean isOpen()
public void setOpen(boolean open)
public int getCommentsCount()
public void setCommentsCount(int commentsCount)
commentsCount
- the number of comments for this changesetpublic java.util.Map<java.lang.String,java.lang.String> getKeys()
Tagged
public void setKeys(java.util.Map<java.lang.String,java.lang.String> keys)
Tagged
public boolean isIncomplete()
public void setIncomplete(boolean incomplete)
public void put(java.lang.String key, java.lang.String value)
Tagged
public java.lang.String get(java.lang.String key)
Tagged
public void remove(java.lang.String key)
Tagged
public boolean hasEqualSemanticAttributes(Changeset other)
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public boolean hasKeys()
Tagged
public java.util.Collection<java.lang.String> keySet()
Tagged
public boolean isNew()
public boolean hasContent()
public ChangesetDataSet getContent()
public void setContent(ChangesetDataSet content)
public java.util.List<ChangesetDiscussionComment> getDiscussion()
public void addDiscussionComment(ChangesetDiscussionComment comment)
comment
- the comment to add. Ignored if null