TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ruby on Rails with Interactors

9 点作者 RKlophaus将近 12 年前

3 条评论

metaphorm将近 12 年前
I'm not sure I understand the point of this. Am I just dense? Can someone explain in some detail?<p>To me this looks like a superfluous layer of indirection that causes you to have to manage your object method calls through an "interactor" instead of the object itself. That's just breaking the encapsulation pattern of OOP and I imagine this is nightmarish in terms of its impact on reusability of your code.<p>did I get it wrong or is this actually just a huge anti-pattern?
评论 #5786431 未加载
评论 #5786595 未加载
danso将近 12 年前
Pedantic question here: Which of the classic Gang of Four patterns does interactors fall into? Mediator?<p><a href="http://geekswithblogs.net/subodhnpushpak/archive/2009/09/18/the-23-gang-of-four-design-patterns-.-revisited.aspx" rel="nofollow">http://geekswithblogs.net/subodhnpushpak/archive/2009/09/18/...</a>
static_typed将近 12 年前
Once upon a time the Rails Brogrammers laughed at Java, where there was endless design pattern abuse and needless armchair architecture. Now the same has happened to Rails.<p>When you even think you might need to use Inter actors, it's time to roll onto a better and maybe newer platform, as it's downhill all way from now on.