Giter Site home page Giter Site logo

kishoressk / cleanarchitecture Goto Github PK

View Code? Open in Web Editor NEW

This project forked from scyks/cleanarchitecture

0.0 1.0 0.0 360 KB

This is a demo application by trying tu use a clean architecture (inspired by Robert C. Martin's talks about clean architecture)

PHP 100.00%

cleanarchitecture's Introduction

Clean Architecture Demo

inspired by Robert C. Martin's (Uncle Bob) Talks about clean architecture. http://vimeo.com/68215570

I also get inspired by a blog post of Benjamin Eberlei. http://www.whitewashing.de/2012/08/13/oop_business_applications_entity_boundary_interactor.html)

When you look at the file structure, you should know what this application is about. If you don't please send me an email and tell why not. Maybe i can do it a better way.

In this application i also tried to use to follow the rules of Robert C. Martin's Book "Clean Code". In my opinion he is totally right.

#Short Explanation of this Architecture

The basic principle is to decouple the business and application logic from delivery mechanisms and of course decoupling from any frameworks.

To execute a use case (Interactor), you need to create a RequestModel (App/Common/Request/Request Interface) and after finishing business logic, the interactor returns a ResponseModel (App/Common/Response/Response) that you can use.

Uncle Bob and Benjamin Eberlei talks/wrote about boundaries. These are object between delivery mechanism and application. The use case is to transform request to a RequestModel and a ResponseModel to an Object the UI can unterstand. Currently i don't implemented it but i will think about a way to implement that it become useful.

The console application receive the original Response Model and use it directly. Maybe a good use case is to save Models to the database as Benjamin Eberlei wrote in his Post.

cleanarchitecture's People

Contributors

scyks avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.