public class ResourcePackList<T extends ResourcePackInfo>
extends java.lang.Object
implements java.lang.AutoCloseable
Modifier and Type | Field and Description |
---|---|
private java.util.List<T> |
enabled |
private java.util.Set<IPackFinder> |
packFinders |
private ResourcePackInfo.IFactory<T> |
packInfoFactory |
private java.util.Map<java.lang.String,T> |
packNameToInfo |
Constructor and Description |
---|
ResourcePackList(ResourcePackInfo.IFactory<T> packInfoFactoryIn) |
Modifier and Type | Method and Description |
---|---|
void |
addPackFinder(IPackFinder packFinder) |
void |
close() |
java.util.Collection<T> |
getAllPacks() |
java.util.Collection<T> |
getAvailablePacks() |
java.util.Collection<T> |
getEnabledPacks() |
T |
getPackInfo(java.lang.String name) |
void |
reloadPacksFromFinders() |
void |
setEnabledPacks(java.util.Collection<T> p_198985_1_) |
private void |
sortPackNameToInfo() |
private final java.util.Set<IPackFinder> packFinders
private final java.util.Map<java.lang.String,T extends ResourcePackInfo> packNameToInfo
private final java.util.List<T extends ResourcePackInfo> enabled
private final ResourcePackInfo.IFactory<T extends ResourcePackInfo> packInfoFactory
public ResourcePackList(ResourcePackInfo.IFactory<T> packInfoFactoryIn)
public void reloadPacksFromFinders()
private void sortPackNameToInfo()
public void setEnabledPacks(java.util.Collection<T> p_198985_1_)
public java.util.Collection<T> getAllPacks()
public java.util.Collection<T> getAvailablePacks()
public java.util.Collection<T> getEnabledPacks()
@Nullable public T getPackInfo(java.lang.String name)
public void addPackFinder(IPackFinder packFinder)
public void close()
close
in interface java.lang.AutoCloseable