Class EmptyCollectionHelper

java.lang.Object
org.freedesktop.dbus.messages.EmptyCollectionHelper

final class EmptyCollectionHelper extends Object
  • Constructor Details

    • EmptyCollectionHelper

      private EmptyCollectionHelper()
  • Method Details

    • determineSignatureOffsetDict

      static int determineSignatureOffsetDict(byte[] _sigb, int _currentOffset)
      This function determine the new offset in signature for empty Dictionary/Map collections. Normally the element inside a collection determines the new offset, however in case of empty collections there is no element to determine the sub signature of the list so this function determines which part of the signature to skip
      Parameters:
      _sigb - the total signature
      _currentOffset - the current offset within the signature
      Returns:
      the index of the last element of the collection (subtype)
    • determineSignatureOffsetArray

      static int determineSignatureOffsetArray(byte[] _sigb, int _currentOffset)
      This function determine the new offset in signature for empty Array/List collections. Normally the element inside a collection determines the new offset, however in case of empty collections there is no element to determine the sub signature of the list so this function determines which part of the signature to skip
      Parameters:
      _sigb - the total signature
      _currentOffset - the current offset within the signature
      Returns:
      the index of the last element of the collection (subtype)
    • determineSignatureOffsetStruct

      private static int determineSignatureOffsetStruct(byte[] _sigb, int _currentOffset)
    • determineEndOfBracketStructure

      private static int determineEndOfBracketStructure(byte[] _sigb, int _currentOffset, char _openChar, char _closeChar)
      This is a generic function to determine the end of a structure that has opening and closing characters. Currently used for Struct () and Dict {}
    • determineSubSignature

      private static String determineSubSignature(byte[] _sigb, int _currentOffset)
    • determineCollectionSubType

      private static EmptyCollectionHelper.ECollectionSubType determineCollectionSubType(char _sig)
      The starting type determines of a collection determines when it ends
      Parameters:
      _sig - the signature letter of the type