Automatic object-oriented mnemonic code generation
This is a problem caused by the parent language. With the increasing maturity of computer application technology, the method that relies solely on coding to implement data operations has long expired. Implementing various operations through the mother tongue is an inevitable design goal.
4.2.4.1 proposition proposal
We are based on the Chinese environment, so Chinese is the best way to communicate data. The real problem is: the best performance is not consistent with the simplest operation method. To solve this contradiction, the most typical method is to use the combination of Chinese pinyin headers (often referred to as "mnemonic code", which can be continued by words) form a simple way to complete data operations. The question here is: How to automatically generate the standard form of "mnemonic code" data using Chinese characters. This is the most basic and specific requirement of Chinese users. Therefore, it is also the first problem to be solved in the encapsulation process.
4.2.4.2 Design Conception
Receive Chinese character data in a control and use a dedicated method and the Chinese character pinyin encoding mechanism in the runtime environment to obtain the "mnemonic code" string. Here, you need to solve the storage problem of the mnemonic code. Traditionally, the mnemonic code is stored in the database fields. It can be understood that the mnemonic code is bound to another control.
To maintain the correspondence between the Chinese character information and the help code, you can add an attribute for "Tb _" and enter the name of another "Tb _" instance, the dynamically generated mnemonic code is written to the physical table through this control.
Retrieve mnemonic codeProgramA special method is designed. As long as the Chinese character string can be obtained on the interface, this method returns a "mnemonic code" corresponding to the Chinese character string ". You can call this method to obtain the mnemonic code. Although this is a process-oriented conceptual model, it can also solve the problem. If you can implement this function through object-oriented encapsulation, you do not need to callCode.