ControllerGenerator class
Generates a GetX controller class.
Constructors
- ControllerGenerator.new({required String name, required String service, String output = 'output/controllers'})
- Creates a new instance of ControllerGenerator.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- name ↔ String
-
The name of the controller.
getter/setter pair
- output ↔ String
-
The output path for the generated file.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- service ↔ String
-
The name of the service to be injected.
getter/setter pair
Methods
-
generate(
List< String> functionList) → void - Generates the controller file.
-
getControllerCode(
List< String> functions) → String - Generates the code for the controller class.
-
getFunctionCode(
{required String name}) → StringBuffer - Generates a function for the controller.
-
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