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

Module output #1

Open
zarochintsev opened this Issue May 4, 2017 · 6 comments

Comments

3 participants
@zarochintsev

zarochintsev commented May 4, 2017

Как реализовать module output при переходе?

@SpectralDragon

This comment has been minimized.

Owner

SpectralDragon commented May 4, 2017

Module output пока еще не реализована. Постараюсь в скором времени сделать это :)

@SpectralDragon SpectralDragon moved this from Plans to In Progress in Development LightRoute v2.1 Sep 29, 2017

@SpectralDragon SpectralDragon moved this from In Progress to Done in Development LightRoute v2.1 Oct 26, 2017

@SpectralDragon

This comment has been minimized.

Owner

SpectralDragon commented Oct 27, 2017

@zarochintsev Реализация по moduleOutput добавил.
Лично я считаю, что в ней есть некоторые проблемы.
Более подробный тест я не проводил, но в ближайшее время попытаюсь проделать эту работу и добавить документацию.

@zarochintsev

This comment has been minimized.

zarochintsev commented Jan 15, 2018

@SpectralDragon Я так и не понял, как можно реализовать moduleOutput?

@zarochintsev

This comment has been minimized.

zarochintsev commented Jan 15, 2018

@SpectralDragon

Скажем у меня есть следующий код:

func openScannerModule() {    
    try? transitionHandler
      .forSegue(identifier: C.SegueIdentifiers.scannerModule, to: ScannerModuleInput.self)
      .then { moduleInput in
        moduleInput.configure()
    }
  }
@Ikloo

This comment has been minimized.

Contributor

Ikloo commented Jan 15, 2018

@zarochintsev самое простое решение:

func openScannerModule(output: ScannerModuleOutput) {    
    try? transitionHandler
      .forSegue(identifier: C.SegueIdentifiers.scannerModule, to: ScannerModuleInput.self)
      .then { moduleInput in
        moduleInput.configure(output: ScannerModuleOutput)
    }
  }

class ScannerModulePresenter: ScannerModuleInput {
    ...
    var output: ScannerModuleOutput?

    func configure(output: ScannerModuleOutput) {
       self.output = output
    }
    ...
}
@zarochintsev

This comment has been minimized.

zarochintsev commented Jan 16, 2018

@Ikloo у меня сейчас так и реализовано

SpectralDragon pushed a commit that referenced this issue Jan 26, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment