java.lang.Object
net.ME1312.SubServers.Client.Common.Network.API.Proxy

public class Proxy extends Object
Simplified Proxy Data Class
  • Constructor Details

    • Proxy

      public Proxy(ObjectMap<String> raw)
      Create an API representation of a Proxy
      Parameters:
      raw - Raw representation of the Proxy
  • Method Details

    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • refresh

      public void refresh()
      Download a new copy of the data from SubData
    • getSubData

      public DataSender[] getSubData()
      Gets the SubData Client Channel IDs
      Returns:
      SubData Client Channel ID Array
    • getName

      public String getName()
      Get the Name of this Proxy
      Returns:
      Name
    • getDisplayName

      public String getDisplayName()
      Get the Display Name of this Proxy
      Returns:
      Display Name
    • isMaster

      public boolean isMaster()
      Determine if the proxy is the Master Proxy
      Returns:
      Master Proxy Status
    • getPlayers

      public Collection<Pair<String,UUID>> getPlayers()
      Get the players on this proxy
      Returns:
      Remote Player Collection
    • getPlayers

      public void getPlayers(Consumer<Collection<RemotePlayer>> callback)
      Get the players on this proxy
      Parameters:
      callback - Remote Player Collection
    • getSignature

      public final String getSignature()
      Get the Signature of this Object
      Returns:
      Object Signature
    • getTimestamp

      public long getTimestamp()
      Get the Timestamp for when the data was last refreshed
      Returns:
      Data Timestamp
    • hasExtra

      public boolean hasExtra(String handle)
      Determine if an extra value exists
      Parameters:
      handle - Handle
      Returns:
      Value Status
    • getExtra

      public ObjectMapValue<String> getExtra(String handle)
      Get an extra value
      Parameters:
      handle - Handle
      Returns:
      Value
    • getExtra

      public ObjectMap<String> getExtra()
      Get the extra value section
      Returns:
      Extra Value Section
    • getRaw

      public ObjectMap<String> getRaw()
      Get the raw representation of the Proxy
      Returns:
      Raw Proxy