Question

I'm going through all sorts of WPF documentation, and I'm feeling unnecessarily confused. The term 'business logic' is scattered throughout it, as if everyone should know what it is.

I can see what business logic is, according to this question here: What exactly consists of 'Business Logic' in an application?

But where did the term come from? Why is it called 'business logic' and not, say, 'core logic' or 'main algorithms' or any other more generic terms? Very few of the programs I write have anything to do with 'business logic', and when I think of 'business logic' I think of things handling credit card transactions, customer database maintenance, and the like. In other words, things that relate to a fraction of the entirety of computer science. When I write an imaging application, there is no 'business' involved, no customers, no money-based transactions, nothing of the sort. So saying that I have 'business logic' really confuses me, since I'm not conducting business, I'm processing images.

Was it helpful?

Solution

For the same reason that the end of a gun which the bullets come out of is called the “business end”. It's where the primary action happens.

OTHER TIPS

If you were a professional graphic designer, there certainly would be business involved with using your imaging application - your job is your business!

So "business logic" refers to the parts of the code that define how the user conducts his business (in this case, manipulating images).

Don't forget that back in the day, all software was "business software" - no-one could afford the expensive equipment and skills required to write software for anything other than business purposes. It if didn't make money or save money for a business, it didn't get written.

Not sure, but I think the term should be replaced with domain logic instead.

You could have called it "core logic", but I believe that the first (well-known) multi-tiered apps were actually written for insurance or banking, hence the term "business logic". From there, the pattern took form, and the naming stuck.

Had the first multi-tiered apps been a research project or something, it probably would have been called "core logic".

When I write an imaging application, there is no 'business' involved, no customers, no money-based transactions, nothing of the sort. So saying that I have 'business logic' really confuses me, since I'm not conducting business, I'm processing images.

Furthermore, much of the advice about presentation and data starts going south too, as operations such as effects and filters which would be extras in a 'presentation layer' in a business application are the core of yours.

"Visualisation", "Engine" and "Persistent storage", are quite common names for the layers in the simulations I tend to work on. There's no problem using names meaningful in your domain. But then I get confused about all the job ads for SAS programmers, as that means something else in a UK defence setting; if you want to talk to business people you have to translate for them.

The origin of the term is in business software, where business specific rules were separated in their own modules. That merely got transferred to all the other software.

Thinking about early computer systems, like credit card processing, there are two large parts to the code, the parts doing the io, talking to the back-ends, tape, etc, and the parts doing the logic of the business, rules like, is the card valid, has the limit been exceeded.

Another way to think about it, it's the things a business person would say are the 'rules' to capture.

Business logic is that part of an application where "how" is should work is determined by someone other than the programming team. Usually it is the code that does what the customer wants to get done. The term generally only applies to in house software built for a non-IT group.

I think many times its sarcastic, because business logic is not always logical. its done certain way only, because business wants it that way - many times its not the best way. you can fight with them and (if youre lucky) make them see the light or just accept the fact that its business logic and be ready to change it when they realize they made mistake.

It is a term used mainly for Line of business applications & one more way people know of it is CRUD app (create, read, update, delete).

I think it means the class(es) contain the logic of how the business process works for given business process(es).

I think I agree with DVK - IIRC, at the time, the whole Data->Logic->Presentation layer thing was an "enterprise" (basically: business) software buzzword.

Now that every goddamn web page should be three-tiered, it's much more common.

You also have to remember that while there's a lot of code other than business code, the amount of business code is huge, and a huge business (har har) as well. It's not really surprising that some terms originated there.

Just like the pretty you goes to the bathroom to do your business, your pretty GUI goes to the logic to do its business..

(Sorry, couldn't resist :) )

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top