Class BoBData

    • Constructor Summary

      Constructors 
      Constructor Description
      BoBData​(java.lang.String type, byte[] content)  
      BoBData​(java.lang.String type, byte[] content, java.lang.Integer maxAge)
      BoB data constructor.
      BoBData​(java.lang.String type, java.lang.String content)  
      BoBData​(java.lang.String type, java.lang.String content, java.lang.Integer maxAge)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      byte[] getContent()
      Get the content.
      java.lang.String getContentBase64Encoded()
      Get the content in a Base64 encoded String.
      java.lang.Integer getMaxAge()
      Get the max age.
      java.lang.String getType()
      Get the type.
      boolean isOfReasonableSize()
      Check if the data is of reasonable size.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • BoBData

        public BoBData​(java.lang.String type,
                       byte[] content)
      • BoBData

        public BoBData​(java.lang.String type,
                       byte[] content,
                       java.lang.Integer maxAge)
        BoB data constructor.
        Parameters:
        type - TODO javadoc me please
        content - TODO javadoc me please
        maxAge - TODO javadoc me please
      • BoBData

        public BoBData​(java.lang.String type,
                       java.lang.String content)
      • BoBData

        public BoBData​(java.lang.String type,
                       java.lang.String content,
                       java.lang.Integer maxAge)
    • Method Detail

      • getMaxAge

        public java.lang.Integer getMaxAge()
        Get the max age.
        Returns:
        the max age
      • getType

        public java.lang.String getType()
        Get the type.
        Returns:
        the type
      • getContent

        public byte[] getContent()
        Get the content.
        Returns:
        the content
      • getContentBase64Encoded

        public java.lang.String getContentBase64Encoded()
        Get the content in a Base64 encoded String.
        Returns:
        the content in a Base64 encoded String
      • isOfReasonableSize

        public boolean isOfReasonableSize()
        Check if the data is of reasonable size. XEP-0231 suggest that the size should not be more than 8 KiB.
        Returns:
        true if the data if of reasonable size.