X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fcore%2Fevent%2FUpdateFoundEvent.java;h=2884090d84428e63a8146b822032b92a26230caf;hp=e8cb8e54fd0119cb40e7a7422bc9d84f13deb6da;hb=b4d2d68b5ea4f4edc7337f380cfe078756678126;hpb=76ed638264e531a26e35647d13702db865a52321 diff --git a/src/main/java/net/pterodactylus/sone/core/event/UpdateFoundEvent.java b/src/main/java/net/pterodactylus/sone/core/event/UpdateFoundEvent.java index e8cb8e5..2884090 100644 --- a/src/main/java/net/pterodactylus/sone/core/event/UpdateFoundEvent.java +++ b/src/main/java/net/pterodactylus/sone/core/event/UpdateFoundEvent.java @@ -1,5 +1,5 @@ /* - * Sone - UpdateFoundEvent.java - Copyright © 2013–2015 David Roden + * Sone - UpdateFoundEvent.java - Copyright © 2013–2019 David Roden * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -21,66 +21,35 @@ import net.pterodactylus.util.version.Version; /** * Event that signals that an update for Sone was found. - * - * @author David ‘Bombe’ Roden */ public class UpdateFoundEvent { - /** The version that was found. */ private final Version version; - - /** The time the update was released. */ private final long releaseTime; - - /** The latest edition of the update page. */ private final long latestEdition; + private final boolean disruptive; - /** - * Creates a new “update found” event. - * - * @param version - * The version of the update - * @param releaseTime - * The release time of the update - * @param latestEdition - * The latest edition of the update page - */ - public UpdateFoundEvent(Version version, long releaseTime, long latestEdition) { + public UpdateFoundEvent(Version version, long releaseTime, long latestEdition, boolean disruptive) { this.version = version; this.releaseTime = releaseTime; this.latestEdition = latestEdition; + this.disruptive = disruptive; } - // - // ACCESSORS - // - - /** - * Returns the version of the update. - * - * @return The version of the update - */ public Version version() { return version; } - /** - * Returns the release time of the update. - * - * @return The releae time of the update (in milliseconds since Jan 1, 1970 - * UTC) - */ public long releaseTime() { return releaseTime; } - /** - * Returns the latest edition of the update page. - * - * @return The latest edition of the update page - */ public long latestEdition() { return latestEdition; } + public boolean disruptive() { + return disruptive; + } + }