Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add onInitialStateReceived callback, update Kotlin to 2.0 #33

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

VasilyRylov
Copy link
Contributor

No description provided.

import ru.kontur.mobile.visualfsm.Transition
import ru.kontur.mobile.visualfsm.TransitionCallbacks

class LogTransitionCallbacks<STATE : State>(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Похоже не дописана реализация

}
}

override fun e(message: String, exception: Exception, errorGroupId: String) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

А точно мы хотим целых 4 сообщения выдавать? Ещё и message 2 раза выводим

import ru.kontur.mobile.visualfsm.TransitionCallbacks


class TransitionCallbacksAggregator<STATE : State>(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Не используется. Точно хотим оставить? Как будто пользователи сами в состоянии в случае необходимости написать агрегатор или декоратор

@@ -63,6 +72,6 @@ interface TransitionCallbacks<STATE : State> {
*/
fun onMultipleTransitionError(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Обсуждали с тобой, что в этот колбэк метод было бы неплохо передать все подошедшие транзишены для отладки

@@ -5,6 +5,15 @@ package ru.kontur.mobile.visualfsm
*/
interface TransitionCallbacks<STATE : State> {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

И вот здесь если накинуть ACTION в дженерик параметры, то в реализациях можно будет when по экшену без каста делать

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants