On the way to work by bike in the morning, I thought of the question "Business is important or technical is important. In the process of thinking, I somehow think of it as a factory method model. The analysis is as follows:
"Customer" this object is equivalent to a called client. "company" is a factory here, it returns the specific implementation class "programmer a" or "Programmer B" to the client ". As shown in:
As shown in the figure, the customer object does not depend on a programmer A or B rather than a programmer interface. Because it focuses on the code programming method. The specific programmer is only generated when the company object is running (corresponding to when the project starts. Therefore, it is only the company object rather than the customer object that forms a call and dependency relationship for a specific programmer.
There are two ways to combine business and technology.
Practice 1:
This method uses a special salesman interface, which allows programmers to decouple with specific business analysis methods. The management method (manage method) is provided in the company object for the combination of coding and analysis services, of course, the specific implementation may be method interception or methods similar to template methods. This is similar to providing professional business training for programmers, rather than asking them to meet another requirement only during programming, "proficient in business" in the cycle of making mistakes and making changes constantly ".
Practice 2:
There is no management method in the company object (such as for companies with poor management), nor is there a dedicated salesman interface and its implementation class. As for the specific business problem, the solution can only be fully delegated to the code method of the programmer object for execution, that is, to implement the "analysis business" method in the coding process. Of course, this method can only be used to complete the business functions in the cycle of making mistakes and making corrections. This approach is like adding the database access code, transaction processing code, and log record code to the business logic code. Obviously, this practice has been widely abandoned in today's increasingly sophisticated programming theories and methods and is considered wrong and inappropriate! This is also the consensus of the IT solution. This kind of mistake can only be made by a novice programmer who has just begun learning programming.
Through the analysis of the above two methods, the advantages and disadvantages are obvious. The conclusion we need to draw is that for a programmer, its core value is its programming method rather than other businesses. If you do not think so, you think that the business is more important than the technology, so as to spend the main time and energy on the "proficient" of the business, it will inevitably reduce the time you spend on technology in the same situation. In the same case, you are far behind in technology than the programmers who have spent the most technical effort. When one day you face a better opportunity and need to choose a career again (cannot be guaranteed to be the same industry), your competitiveness will be worse than that programmer. The reason is as follows:
1. You are proficient in "specific business" rather than "flexible and quick access to business;
2. You are technically inferior to others;
3. If you use this method to do things, it is inevitable that company leaders will be technically tolerant and make specific mistakes for you because of your "dedication" and "seriousness ".
Default (because they do not provide business training, and you are so active in learning business ). This further deepens the idea that you will continue to do so to become a refined person in the business.
In short, A company with a well-designed "management architecture" that can achieve sustainable and sound development will follow the standard practices and professional ideas to accomplish specific things, rather than sending too many hopes to one or two business experts or technical experts. personal abilities. This is like a good software architecture design that won't let a class complete too many tasks or do too many things in a method. Of course, you may say that we are a start-up small company. We cannot do this because we want to survive. I did not deny your practice in this case.
I am only here to remind programmers that there is no way to do this when you are forced by life. However, you must remember that when your manager injects something similar to "Business importance is greater than technology" or "a large company is also supported by such a cool man" into you, I hope you will think this way in your heart. when "correct" is "trend, in your heart, you must understand that the world is not necessarily like this. Your manager either does not understand this truth, or deliberately misleads you for the benefit of the company. What you need to do is to clarify the identity and "object". In the object-oriented thinking, we need to clearly distinguish between the "programmer" object and the "Company" object. They have different "methods" (functions). This is like a capitalist, after all, not a proletarian, not a capitalist. When it comes to this, you may scold me: "employees must love the enterprise and have a sense of ownership! You advocate individualism !". Yes, employees should have this kind of spirit, but this problem is another category of morality. employees do not have to evaluate their functions with moral issues. In addition, it may not be a bad thing for the company to study the technology of its employees. On the contrary, this is exactly what many companies need.
To survive, you can pretend to recognize and worship it for the moment. However, your ideas and concepts must not agree with such incorrect and backward ideas, so that you may miss this idea when there is a really better opportunity in front of you! That is why programmers, especially those who participate in work, are easily misled and need new development !!!