Ignore:
Timestamp:
2017-07-22T22:41:19+02:00 (7 years ago)
Author:
Don-vip
Message:

add Changeset.getComment()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/Changeset.java

    r12033 r12494  
    1010import java.util.Map;
    1111import java.util.Objects;
     12import java.util.Optional;
    1213
    1314import org.openstreetmap.josm.data.Bounds;
     
    264265
    265266    /**
    266      * Replies the number of comments for this changeset.
    267      * @return the number of comments for this changeset
     267     * Replies this changeset comment.
     268     * @return this changeset comment (empty string if missing)
     269     * @since 12494
     270     */
     271    public String getComment() {
     272        return Optional.ofNullable(get("comment")).orElse("");
     273    }
     274
     275    /**
     276     * Replies the number of comments for this changeset discussion.
     277     * @return the number of comments for this changeset discussion
    268278     * @since 7700
    269279     */
     
    273283
    274284    /**
    275      * Sets the number of comments for this changeset.
    276      * @param commentsCount the number of comments for this changeset
     285     * Sets the number of comments for this changeset discussion.
     286     * @param commentsCount the number of comments for this changeset discussion
    277287     * @since 7700
    278288     */
Note: See TracChangeset for help on using the changeset viewer.