Class DefaultGroupKey

  • All Implemented Interfaces:
    GroupKey

    public class DefaultGroupKey
    extends java.lang.Object
    implements GroupKey
    Default implementation of group key interface.
    • Constructor Summary

      Constructors 
      Constructor Description
      DefaultGroupKey​(byte[] key)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object o)  
      int hashCode()  
      byte[] key()
      Returns the byte representation of key.
      java.lang.String toString()
      Returns a hex string representation of the byte array that is used as a group key.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • DefaultGroupKey

        public DefaultGroupKey​(byte[] key)
    • Method Detail

      • key

        public byte[] key()
        Description copied from interface: GroupKey
        Returns the byte representation of key.
        Specified by:
        key in interface GroupKey
        Returns:
        byte array
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Returns a hex string representation of the byte array that is used as a group key. This solution was adapted from http://stackoverflow.com/questions/9655181/
        Overrides:
        toString in class java.lang.Object