Package guideme.compiler
Class PageCompiler
java.lang.Object
guideme.compiler.PageCompiler
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionPageCompiler
(PageCollection pages, ExtensionCollection extensions, String sourcePack, net.minecraft.resources.ResourceLocation pageId, String pageContent) -
Method Summary
Modifier and TypeMethodDescription<T> void
clearCompilerState
(PageCompiler.State<T> state) static GuidePage
compile
(PageCollection pages, ExtensionCollection extensions, ParsedGuidePage parsedPage) void
compileBlockContext
(guideme.libs.mdast.model.MdAstParent<?> markdownParent, LytBlockContainer layoutParent) void
compileBlockContext
(List<? extends guideme.libs.mdast.model.MdAstAnyContent> children, LytBlockContainer layoutParent) void
compileFlowContext
(guideme.libs.mdast.model.MdAstParent<?> markdownParent, LytFlowParent layoutParent) void
compileFlowContext
(Collection<? extends guideme.libs.mdast.model.MdAstAnyContent> children, LytFlowParent layoutParent) createErrorBlock
(String text, guideme.libs.unist.UnistNode child) createErrorFlowContent
(String text, guideme.libs.unist.UnistNode child) <T> T
getCompilerState
(PageCompiler.State<T> state) getExtensions
(ExtensionPoint<T> extensionPoint) <T extends PageIndex>
Tnet.minecraft.resources.ResourceLocation
Get the current page id.byte @Nullable []
loadAsset
(net.minecraft.resources.ResourceLocation imageId) static ParsedGuidePage
parse
(String sourcePack, net.minecraft.resources.ResourceLocation id, InputStream in) static ParsedGuidePage
net.minecraft.resources.ResourceLocation
<T> void
setCompilerState
(PageCompiler.State<T> state, T value)
-
Constructor Details
-
PageCompiler
public PageCompiler(PageCollection pages, ExtensionCollection extensions, String sourcePack, net.minecraft.resources.ResourceLocation pageId, String pageContent)
-
-
Method Details
-
parse
public static ParsedGuidePage parse(String sourcePack, net.minecraft.resources.ResourceLocation id, InputStream in) throws IOException - Throws:
IOException
-
parse
public static ParsedGuidePage parse(String sourcePack, net.minecraft.resources.ResourceLocation id, String pageContent) -
compile
public static GuidePage compile(PageCollection pages, ExtensionCollection extensions, ParsedGuidePage parsedPage) -
getExtensions
-
getExtensions
-
compileBlockContext
public void compileBlockContext(guideme.libs.mdast.model.MdAstParent<?> markdownParent, LytBlockContainer layoutParent) -
compileBlockContext
public void compileBlockContext(List<? extends guideme.libs.mdast.model.MdAstAnyContent> children, LytBlockContainer layoutParent) -
compileFlowContext
public void compileFlowContext(guideme.libs.mdast.model.MdAstParent<?> markdownParent, LytFlowParent layoutParent) -
compileFlowContext
public void compileFlowContext(Collection<? extends guideme.libs.mdast.model.MdAstAnyContent> children, LytFlowParent layoutParent) -
createErrorBlock
-
createErrorFlowContent
-
resolveId
-
getPageId
public net.minecraft.resources.ResourceLocation getPageId()Get the current page id. -
getPageCollection
-
loadAsset
public byte @Nullable [] loadAsset(net.minecraft.resources.ResourceLocation imageId) -
getIndex
-
getCompilerState
-
setCompilerState
-
clearCompilerState
-