Interface PlatformCatalog

All Known Subinterfaces:
PlatformCatalog.Mutable
All Known Implementing Classes:
PlatformCatalogImpl, PlatformCatalogImpl.Builder

public interface PlatformCatalog
  • Method Details

    • getPlatforms

      Collection<Platform> getPlatforms()
    • getMetadata

      Map<String,Object> getMetadata()
    • getPlatform

      Platform getPlatform(String platformId)
    • getRecommendedPlatform

      default Platform getRecommendedPlatform()
    • mutable

      default PlatformCatalog.Mutable mutable()
      Returns:
      a mutable copy of this configuration
    • persist

      default void persist(Path p) throws IOException
      Persist this configuration to the specified file.
      Parameters:
      p - Target path
      Throws:
      IOException - if the specified file can not be written to.
    • builder

      static PlatformCatalog.Mutable builder()
      Returns:
      a new mutable instance
    • fromFile

      static PlatformCatalog fromFile(Path path) throws IOException
      Read config from the specified file
      Parameters:
      path - File to read from (yaml or json)
      Returns:
      read-only PlatformCatalog object
      Throws:
      IOException
    • mutableFromFile

      static PlatformCatalog.Mutable mutableFromFile(Path path) throws IOException
      Read config from the specified file
      Parameters:
      path - File to read from (yaml or json)
      Returns:
      read-only PlatformCatalog object (empty/default for an empty file)
      Throws:
      IOException