-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Adriano Santos
committed
Oct 22, 2023
1 parent
58018cd
commit 982bdeb
Showing
11 changed files
with
325 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,38 @@ | ||
import 'package:spawn_dart/src/protocol/eigr/functions/protocol/actors/protocol.pb.dart'; | ||
|
||
enum ActorKind { named, unnamed, pooled, proxy } | ||
|
||
enum ActionDefinitionKind { normal, timer } | ||
|
||
class ActionDefinition { | ||
final ActionDefinitionKind kind; | ||
final String name; | ||
int seconds; | ||
|
||
ActionDefinition(this.kind, this.name, {this.seconds = 0}); | ||
|
||
String get actionName { | ||
return name; | ||
} | ||
|
||
ActionDefinitionKind get actionDefinitionKind { | ||
return kind; | ||
} | ||
|
||
int get timerSeconds { | ||
return seconds; | ||
} | ||
} | ||
|
||
abstract class ActorHandler { | ||
ActorKind getActorKind(); | ||
List<ActionDefinition> getActionDefinitions(); | ||
String getChannel(); | ||
int getDeactivatedTimeout(); | ||
String getRegisteredName(); | ||
int getSnapshotTimeout(); | ||
int getMaxPoolSize(); | ||
int getMinPoolSize(); | ||
bool isStateful(); | ||
ActorInvocationResponse handleInvoke(ActorInvocation invocation); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.