decoupling Questions
8
Solved
I'm thinking about embedding arbitrary JSON in the DOM like this:
<script type="application/json" id="stuff">
{
"unicorns": "awesome",
"abc": [1, 2, 3]
}
</script>
This is simila...
Disgrace asked 16/2, 2012 at 22:58
7
Solved
It's good to split code up into functions and classes for modularity / decoupling, but if you do it too much, you get really fragmented code which is also not good.
What is the golden rule for whe...
Tipsy asked 24/6, 2010 at 5:18
3
Solved
I'm forced to keep my .env file in a non-standard path outside the root of my project (in a separate directory altogether).
Let's say I have my Django project in /var/projects/my_project, though I...
Samuelson asked 23/4, 2017 at 11:56
6
Solved
I'm your classic OOP developer. However since I discovered purely functional programming languages I've been ever intrigued to the why since OOP seemed to solve most business cases in a reasonable ...
Varick asked 28/6, 2021 at 9:42
4
Solved
I have a Python project in which I am using many non-code files. Currently these are all images, but I might use other kinds of files in the future. What would be a good scheme for storing and refe...
Cestoid asked 8/9, 2009 at 18:37
4
Solved
Lets say we have class A in package A and class B in package B . If object of class A has reference to class B, then the two classes are said to have coupling between them.
To address the coupling...
Melodeemelodeon asked 11/6, 2015 at 14:51
4
One of the goals of the REST API architecture is decoupling of the client and the server.
One of the questions I have run across in planning a REST API is: "how does the client know what is a vali...
Eaton asked 1/9, 2014 at 7:52
6
Solved
I am building an Android App using MVVM and DataBinding. And I have a function inside my ViewModel that starts an Activity.
Is it okay to have an onClick call inside a ViewModel?
Like this.
publi...
Surrounding asked 7/11, 2016 at 21:53
8
Solved
As someone who has tried to find a way to help content authors develop and maintain big web sites by creating (HTML) components for years, I'm really excited to see web components gaining tracction...
Sigil asked 1/12, 2013 at 12:6
4
Solved
I'm reading theory about dependency inversion and decoupling and I can't see the difference between the two.
Dependency inversion talks about decoupling functional components so that higher level ...
Oria asked 12/10, 2010 at 7:41
15
Solved
(1) List<?> myList = new ArrayList<?>();
(2) ArrayList<?> myList = new ArrayList<?>();
I understand that with (1), implementations of the List interface can be swap...
Clachan asked 17/2, 2010 at 7:40
2
Consider the following relation between classes:
int main(int, char**) { | class Window { | class Layout { | class Box {
/* Use argc/argv */ | Layout layout; | Box box; | int height,
Window wind...
Westbound asked 1/9, 2017 at 10:57
2
Solved
I am trying to understand what really defines tight coupling. I have read a number of posts on the subject but one thing still doesn't sit right with me.
I understand that classes should be inject...
Cloutman asked 5/5, 2017 at 10:31
4
Solved
In his talk at the 54:53 minute mark, Rich Hickey is talking about the usage of queues as a mean to decouple dependent program parts. Can you give me an example on how to deouple the following piec...
Gula asked 4/1, 2012 at 12:25
3
Solved
I don't understand what "CBO-Coupling between object classes" really means. The definition I found is so short that I think I'm missing something, so it would be great if you help me with an exampl...
At asked 16/12, 2014 at 23:1
2
Solved
In Domain-Driven Design, the domain layer is said to have no dependency on other layers, i.e. the repository interface is within the domain layer, while its implementation is at the infrastructure ...
Classieclassification asked 16/9, 2015 at 17:7
3
Solved
Is there a nuget package, or other "standard" that wraps the hard dependency created when your code is coupled to DateTime.Now?
I'm seeking guidance on this before writing my own. Albeit that it's...
Morsel asked 21/10, 2011 at 15:18
4
Solved
Lets imagine, that our application needs ETL (extract, transform, load) data from relation database to another relation database.
Most simple (and most performance, IMHO) way is to make link betwee...
Leschen asked 7/6, 2015 at 8:19
2
please be advised, this is a long post. Sorry for that but I want to make my point clear:
I was wondering how to separate Swing GUI from Presentation and Business Logic for quite a long time.
At w...
Khan asked 15/6, 2014 at 10:2
5
I'm struggling because of this:
My classes have some methods that have temporal coupling. This is, some method MethodA has to be invoked first to "initialize" the data that MethodB needs to work p...
Donnelldonnelly asked 7/4, 2015 at 19:18
3
Solved
I came across "Stairway" pattern description in the "Adaptive code via C#" book and I don't really understand how this is supposed to be implemented:
(source)
So I have client assembly:
using S...
Pathognomy asked 25/3, 2015 at 15:8
1
From all my readings and research on OO design/patterns/principles I've found that the general consensus is that loose coupling (and high cohesion) is the almost always the better design. I complet...
Sheffie asked 28/2, 2015 at 3:32
1
Solved
I've been using Dependency Injection for a while, and now I want to give a talk about IoC and DI to a group of new developers. I remember explaining it to one guy personally and he asked me:
"Why ...
Brannan asked 14/12, 2014 at 8:28
4
Solved
So I am trying to use events to decouple code that I have and here is my problem:
class WorldHandler
{
public void Notify(object sender, EventArgs e)
{
if (e is CameraMovedEventArgs)
{
// han...
Syncarpous asked 22/2, 2014 at 8:33
5
Solved
What are Cohesion and Decoupling? I found information about coupling but not about decoupling.
Whiny asked 21/5, 2010 at 11:26
1 Next >
© 2022 - 2024 — McMap. All rights reserved.