OpenRouterDrafter class

OpenRouter-backed drafter (synchronous via blocking HTTP through a helper). Note: Dart HTTP is async; the compiler awaits these, so this exposes async variants. The Drafter interface stays sync for the offline path; the async OpenRouter calls are used by the async compiler entry points.

Constructors

OpenRouterDrafter({String model = defaultModel, String? apiKey, Client? client})

Properties

apiKey String?
final
hashCode int
The hash code for this object.
no setterinherited
model String
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

close() → void
draftEnum(String value, String locale, String language, String? context) Future<String>
draftTemplate(String baseText, String locale, String language, String axisDesc, Set<String> placeholders) Future<String>
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