Questions tagged [interactors]
9 questions
15
votes
1 answer
Clean Architecture - how to address database transactions?
In 'clean architecture' the interactors (use cases) are responsible for defining busines logic. Most of the examples define use cases in such a way:
public MyUseCase() {
public boolean execute(...) {
int id = repository.insert(a)
if(id >…

Marcin
- 893
- 7
- 19
6
votes
3 answers
Single Responsibility Principle in Clean Architecture, Aggregating UseCases in one UseCaseManager which can provide UseCase based on In & Out Object
I want to implement Single Responsibility principle in my projects Domain layer (Clean MVVM).
I've approximately 200 different use-cases which are being very hectic to manage. Now I'm thinking to create one UseCaseManager which can provide me…

Dipendra Sharma
- 2,404
- 2
- 18
- 35
4
votes
3 answers
How do we test interactor organizers using rspec?
I want to test below organizer interactor for, calling the 2 specified interactors without executing the calling interactors('SaveRecord, PushToService') code.
class Create
include Interactor::Organizer
organize SaveRecord, PushToService
end
I…

Prem
- 5,844
- 3
- 25
- 23
1
vote
0 answers
How to structure DTO class in a clean architecture project with parcelize?
I'm working on an Android app in Kotlin and am trying to implement Clean Architecture with viewmodels, repositories, datasources, interfaces etc.
Right now I have a DTO class that I'm parsing with Retrofit:
@Parcelize
data class NewsArticleDto(
…

JeeferSan
- 21
- 6
1
vote
1 answer
VIPER modules dependencies
I've been working on a personal project so to better understand the VIPER architecture. I really like the way I can keep modules separated, making the code cleaner.
I still have some doubts when it comes to modules dependencies:
I have one module…

Luigi Trevisi
- 81
- 1
- 7
0
votes
1 answer
`update` function doesn't work correctly for bokeh interactors in python
I have a source code that plots the alphashape of a stock price. There's a slider to update the plot dynamically. But the update function doesn't work as expected.
Here's the source…

David H. J.
- 340
- 2
- 12
0
votes
1 answer
Can I use the context as @context inside an interactor class?
In some interactors, several functions are defined to be used in call function (I'm not using utility for organize such functions).
Is it fine to use @context instead of context in this situation?
Ref URL:…

crazyoptimist
- 125
- 1
- 14
0
votes
1 answer
How do I use Repository pattern and Interactor pattern in a Model View Presenter pattern?
I am developing an application with the help of Model View Presenter pattern.
I make use of Retrofit and so I have a ApiClient and ApiInterface with endpoints. I implement the interface in a RemoteDataSource class which I call in the Repository…

Fiphe
- 320
- 3
- 18
0
votes
2 answers
uninitialized constant Admin::ModeratorsController::ModeratorInteractor
Hi i am working on a RoR project with ruby-2.3.0 and rails 4. I am trying to call a method of interactor from controller. My controller is inside the Admin directory as follows:
class Admin::ModeratorsController < Admin::ApplicationController
…

awsm sid
- 595
- 11
- 28