Class FirmwareFragment.FirmwareEntry

java.lang.Object
com.kosdev.kos.commons.util.json.fragments.FirmwareFragment.FirmwareEntry
Enclosing class:
FirmwareFragment

public static class FirmwareFragment.FirmwareEntry extends Object
Describes a single firmware file within a kos.firmware KAB file. This information is encoded in the descriptor.json file so that KOS can automatically detect all available firmware.
Since:
1
Version:
1
  • Constructor Details

    • FirmwareEntry

      public FirmwareEntry()
  • Method Details

    • getBoardType

      public String getBoardType()
      The type of board this firmware is compatible with. This corresponds to the value of Board.getType() .
      Since:
      1
    • getBoardRevisions

      public List<String> getBoardRevisions()
      The list of revisions of the board this firmware is compatible with. This is only used if the firmware updater for the board specifies a board revision, otherwise it will be ignored.
      Since:
      1
    • getFirmwareType

      public String getFirmwareType()
      The type of firmware. Types are user defined and must be coordinated with the corresponding firmware updater for the board. This handles the case where a single board may have more than one firmware image installed, such as a bootloader and an application.
      Since:
      1
    • getVersion

      public String getVersion()
      The version of the firmware. KOS currently expects this to be in major.minor.patch.build format. The default internal comparator of FirmwareService will sort according to this format.
      Since:
      1
    • getFilePath

      public String getFilePath()
      Path to the firmware file within the KAB file.
      Since:
      1
    • setBoardType

      public void setBoardType(String boardType)
      The type of board this firmware is compatible with. This corresponds to the value of Board.getType() .
      Since:
      1
    • setBoardRevisions

      public void setBoardRevisions(List<String> boardRevisions)
      The list of revisions of the board this firmware is compatible with. This is only used if the firmware updater for the board specifies a board revision, otherwise it will be ignored.
      Since:
      1
    • setFirmwareType

      public void setFirmwareType(String firmwareType)
      The type of firmware. Types are user defined and must be coordinated with the corresponding firmware updater for the board. This handles the case where a single board may have more than one firmware image installed, such as a bootloader and an application.
      Since:
      1
    • setVersion

      public void setVersion(String version)
      The version of the firmware. KOS currently expects this to be in major.minor.patch.build format. The default internal comparator of FirmwareService will sort according to this format.
      Since:
      1
    • setFilePath

      public void setFilePath(String filePath)
      Path to the firmware file within the KAB file.
      Since:
      1
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

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

      public String toString()
      Overrides:
      toString in class Object