ResultBuilderGenerator class

A generator class that creates result handling utilities for Flutter applications.

This class generates three main components:

  1. A generic Result<T> class for handling operation states (init, loading, loaded, error)
  2. A ResultBuilder widget for building UI based on result states
  3. Freezed model classes for the Result type

The generated code follows best practices for state management in Flutter applications.

Constructors

ResultBuilderGenerator({required String mainPath})
Creates a new instance of ResultBuilderGenerator.

Properties

hashCode int
The hash code for this object.
no setterinherited
mainPath String
The main path where the generated files will be created.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

generateResultBuilder() → void
Generates all result builder related files.
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