Questions tagged [code-layout]

11 questions
16
votes
6 answers

Vertical alignment: yea or nay?

For instance, non-vertically aligned: Name: Hamt Version: 0.1.0 Cabal-Version: >= 1.2 License: BSD3 Author: Jason Baker Or vertically aligned: Name: Hamt Version: 0.1.0 Cabal-Version: >= 1.2 License: BSD3 Author: …
Jason Baker
  • 9,625
  • 8
  • 44
  • 67
11
votes
1 answer

How can I best organise a Jekyll + Bootstrap + Git site?

So after many many many years of building sites from scratch (and doing a lot of the lifting myself) I've dipped my toes into two projects that have been around for a few years that I've been avoiding: Bootstrap and Jekyll. The design was a very…
Oli
  • 297
  • 2
  • 6
7
votes
4 answers

n-layers architecture design, really worth the effort?

I was building an application in .Net for almost a year (almost alone), I took the decision to build it with a 3-layer design. Recently when finished the project, I analyzed if the effort of creating this application with layer design in mind really…
Rafael
  • 687
  • 1
  • 8
  • 16
5
votes
3 answers

Why do teams still insist on a code-styling policy?

Many teams (such as Google have rules how code should look, including how indentation should be done, how many spaces, in which order should includes be included, etc. Some of those thing can't be automated away. Fine. But a few definitely can. All…
Charles Shiller
  • 305
  • 2
  • 4
5
votes
1 answer

How to avoid dragging arguments from function to function

When I do my code layout, I like to start with a rather high level view, and then start to delegate actual computation to class or functions that have a bit more detail. Then in these classes of functions, I do the same, layer by layer, until I get…
Isaac
  • 223
  • 1
  • 6
2
votes
0 answers

How to "orchestrate" a multi-repository installation

Suppose I'm working on software to be installed on a Linux machine (not mine). Say the software consists of applications the user might start independently; an application which will likely be started on desktop environment login, a service which…
einpoklum
  • 2,478
  • 1
  • 13
  • 30
2
votes
2 answers

Object To Be Used By Service Layer

My project has a UI layer, a Service Layer and a Repository layer. The latter has Entity objects as part of the ORM (.net Entity Framework). The service later returns a Dto to the UI layer. My question is what object should the service layer work…
John Steed
  • 179
  • 5
2
votes
2 answers

source code file system layout for 2 very similar projects (with git)

we're working on "two" android apps that are very similar; in fact, they're the same apps with different graphics and color schemes, slightly different configuration and one or two unique activities that are not in the other project - but the…
stefs
  • 191
  • 8
1
vote
4 answers

Business layer access to the data layer

I have a Business layer (BL) and a Data layer (DL). I have an object o with a child objects collection of Type C. I would like to provide a semantics like the following o.Children.Add("info"). In the BL I would like to have a static CLASS that…
rerun
  • 2,045
  • 12
  • 24
1
vote
2 answers

In C#, is it reasonable to use a #region when I need several members to implement a common interface?

I know that lots of people hate #regions in C#. IMO there is at least one legitimate use of them: Sometimes I have a class which, in addition to its core functionality, needs to implement a commonly used interface such as IEquatable or IEnumerable.…
Claus Appel
  • 119
  • 2
0
votes
1 answer

Is it good or bad practice to create alternate styles of rows(eg:alternate background color) in ListView using separate xml?

For example,to create alternate layout in ListView which uses different alternate color :
ggrr
  • 5,725
  • 11
  • 35
  • 37