Class SavedAssetCollection<T extends PackAsset>

    • Constructor Detail

      • SavedAssetCollection

        public SavedAssetCollection​(ItemModsPack parent,
                                    @Nullable
                                    java.lang.String directoryName,
                                    java.util.function.BiFunction<java.lang.String,​com.google.gson.JsonElement,​T> assetFactory)
                             throws java.io.IOException
        Throws:
        java.io.IOException
      • SavedAssetCollection

        public SavedAssetCollection​(ItemModsPack parent,
                                    java.util.Set<T> assets,
                                    @Nullable
                                    java.lang.String directoryName,
                                    java.util.function.BiFunction<java.lang.String,​com.google.gson.JsonElement,​T> assetFactory)
                             throws java.io.IOException
        Throws:
        java.io.IOException
    • Method Detail

      • getDirectoryPath

        public java.nio.file.Path getDirectoryPath()
      • createDirectory

        public void createDirectory()
                             throws java.io.IOException
        Throws:
        java.io.IOException
      • save

        public void save​(T asset)
                  throws java.io.IOException
        Throws:
        java.io.IOException
      • save

        public void save()