Navigation
API > API/Plugins > API/Plugins/RigVMDeveloper
Represents an Inja template file used for code generation.
Templates are lazily loaded from disk when first accessed. The template content is cached after loading to avoid repeated file I/O during rendering.
Template files use Inja syntax (similar to Jinja2) and are typically stored in: Content/CodeGeneration/CPlusPlus/{FileName}.template
| Name | FRigVMCodeTemplate |
| Type | struct |
| Header File | /Engine/Plugins/Runtime/RigVM/Source/RigVMDeveloper/Public/RigVMCompiler/RigVMCodeTemplate.h |
| Include Path | #include "RigVMCompiler/RigVMCodeTemplate.h" |
Syntax
struct FRigVMCodeTemplate
Derived Classes
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Content | TOptional< FString > | Lazily-loaded template content. Mutable to allow const GetContent() to trigger load. | RigVMCompiler/RigVMCodeTemplate.h | |
| FilePath | FString | Absolute path to the template file on disk. | RigVMCompiler/RigVMCodeTemplate.h | |
| Name | FString | Template identifier (e.g., "AssetNameVM.h" or "AssetNameVM.cpp"). | RigVMCompiler/RigVMCodeTemplate.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
const FString & GetContent() |
Returns the template content. Triggers lazy load if needed. | RigVMCompiler/RigVMCodeTemplate.h | |
void Load() |
Loads the template content from disk. Called automatically by LoadIfRequired(). | RigVMCompiler/RigVMCodeTemplate.h | |
void LoadIfRequired() |
Loads the template content if not already loaded. Thread-safe lazy initialization. | RigVMCompiler/RigVMCodeTemplate.h |
See Also
-
FRigVMCodeOutput for rendered output handling
-
FRigVMCodeGenerator for template discovery and rendering orchestration