java.lang.Object
net.i2p.router.news.NewsMetadata.Update
All Implemented Interfaces:
Comparable<NewsMetadata.Update>
Enclosing class:
NewsMetadata

public static class NewsMetadata.Updateextends Object implements Comparable<NewsMetadata.Update>
Represents an update source with multiple distribution methods.

Defines update types and their associated distribution sources including torrent, clearnet, SSL, and I2P network URLs. Supports type-based ordering for update priority management.

All source lists may be empty if no sources are available for this update type.

  • Field Details

    • type

      public String type
      The update type (su3, su2, etc.).
    • torrent

      public String torrent
      The torrent source URL.
    • clearnet

      public List<String> clearnet
      Stored as of 0.9.52, but there is no registered handler.
    • ssl

      public List<String> ssl
      Stored as of 0.9.52, but there is no registered handler.
    • i2pnet

      public List<String> i2pnet
      In-net URLs.
  • Constructor Details

    • Update

      public Update()
      Every field is left null; the Atom parser fills in whichever of the source URLs the update element actually carries.
  • Method Details

    • compareTo

      public int compareTo(NewsMetadata.Update other)
      Specified by:
      compareTo in interface Comparable<NewsMetadata.Update>
    • getTypeOrder

      protected int getTypeOrder()
      Get the numeric order for this update type. Lower is preferred.
      Returns:
      the type order
    • equals

      public boolean equals(Object o)
      For findbugs. Warning, not a complete comparison. Must be enhanced before using in a Map or Set.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      For findbugs.
      Overrides:
      hashCode in class Object
      Returns:
      whether h code is present