public class BlockStateDefinitionProvider extends Object implements DataProvider
Modifier and Type | Field and Description |
---|---|
private DataGenerator |
generator |
private static Gson |
GSON |
private static Logger |
LOGGER |
SHA1
Constructor and Description |
---|
BlockStateDefinitionProvider(DataGenerator generator) |
Modifier and Type | Method and Description |
---|---|
private static Path |
getBlockStateJsonPath(Path root,
Block block) |
private static Path |
getModelJsonPath(Path root,
Identifier id) |
String |
getName() |
void |
run(DataCache cache) |
private <T> void |
writeJsons(DataCache cache,
Path root,
Map<T,? extends Supplier<JsonElement>> jsons,
BiFunction<Path,T,Path> locator) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
writeToPath
private static final Logger LOGGER
private static final Gson GSON
private final DataGenerator generator
public BlockStateDefinitionProvider(DataGenerator generator)
public void run(DataCache cache)
run
in interface DataProvider
private <T> void writeJsons(DataCache cache, Path root, Map<T,? extends Supplier<JsonElement>> jsons, BiFunction<Path,T,Path> locator)
private static Path getModelJsonPath(Path root, Identifier id)
public String getName()
getName
in interface DataProvider