TemplateDefinition class
Defines a UI template with its properties and builder function
Constructors
-
TemplateDefinition({required String id, required String category, required String description, List<
String> requiredWidgets = const [], List<String> requiredPackages = const [], required String builder({bool addApiCalling, required String className, List<String> drawerNames, bool hasBottomBar, bool hasDrawer, required String isLoading, String? projectName, List<String> tabNames})}) -
Creates a new template definition
const
Properties
-
builder
→ String Function({bool addApiCalling, required String className, List<
String> drawerNames, bool hasBottomBar, bool hasDrawer, required String isLoading, String? projectName, List<String> tabNames}) -
Function that returns the generated code string
final
- category → String
-
Category name (e.g., 'auth', 'social')
final
- description → String
-
Human-readable description
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Unique identifier for the template
final
-
requiredPackages
→ List<
String> -
List of required external packages
final
-
requiredWidgets
→ List<
String> -
List of required custom widgets
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited