From UI> dB to code generation to Eos, let's talk about quick development.

Source: Internet
Author: User

Human nature is lazy,ProgramThis is especially true for members. A lazy person may be very diligent sometimes to make himself more comfortable, as programmers do. I am a lazy, so everyone who agrees with golden ocean is lazy. Undoubtedly, it is tempting for lazy people to greatly reduce repetitive workload. So I took a long time to think about the issue of rapid development under great temptation. Undoubtedly, the Vs. Net tool itself is a very good system for rapid development (it is indeed much faster than Java), but it is not enough for us to be lazy. In addition, the rapid development and use of vs. net in a multi-tier architecture will produce many duplicates.Code. This is terrible for us who are lazy. So we are desperate to solve this problem.

In fact, we first came into sight of the code generator. At that time, I was responsible for the development of a telecom project and took over the project halfway. I found that this project adopts a duwamish architecture similar to that of duwamish. Well, all my friends know vnet. This was designed by one of Microsoft's earliest architects and has a good idea. But there are too many data access codes, however, the level of the interns involved in the project is not consistent, and the results are written with a lot of ugly code. In fact, we all know that the data access code is similar, so I was wondering if I could generate code directly, so I wrote a program to generate the database metadata class myself (it was silly at the time and naive, actually there was already a similar program on the Internet ).

Later, when the project got up, there were not enough people. Everyone had to go from the page to the database. As a result, I felt that there were a lot of duplicate code on the page, and each control value was verified, for business processing and database writing. At that time, there were no formview or other things in the 2003 era, so another member of the project team proposed a solution to expand Subsonic and developed a one-stop UI-> dB. However, I found that it was not very practical for large projects and gave up.

In fact, I have tested another code generator, but this is much more powerful than I write. I have directly generated all the pages from data access and the tool has even generated the SLN, all items have been divided. All we need to do is modify the code. The reason for rejection is not as natural as it is. If the modified code needs to be re-generated because the model changes, the modification will be abandoned. If the code is manually modified without re-generation, the generated code is designed based on a layered architecture. Therefore, as we discussed earlier, layering cannot solve the problem of reducing the number of code modifications. It makes me feel a little evil about code generation.

However, during this period of time, I found that code generation is not evil. In many cases, vs.net has quietly used code generation, such as generating a strongly Typed Dataset, the entity class of linq2sql and the proxy class of WebService. Therefore, using code generation properly can achieve twice the result with half the effort. So I began to review Eos. Puyuan's EOS was previously considered an evil thing of a strange animal level (dead expensive, and uneasy about the code it generated, not a. net ). By dragging and drawing, you can directly generate the interface and logic, including data access, and directly include the workflow engine and workflow development tools. Of course, it's not about advertising to Eos. So far it's still expensive, and it's not suitable for quick prototyping of website projects, and it's still about Java. In other words, rails is not actually composed of a activerecord + N multi-helper and code generator. What if you want to save 3000?

So let's look back and see if the golden ocean Students tried to implement something similar a few days ago? So let alone the design principles, models, and OO, is it true that many of us are moving towards the same goal? That's why I agree with Jin.

Let alone those Oo and patterns that have already become ideology, let the students heading for the same goal have a hearty discussion.

Don't be excited if you don't agree with the discussion. Pay attention to the image .........

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.