Software design method and module division

Source: Internet
Author: User

In software design, the design process is generally divided into the following three steps:

The first step is to divide functional modules according to the software requirements. At this time, modules are divided according to functional requirements.

Step 2: submodules of the real-time function module are divided according to the professional fields. Specialized fields, such as data structure algorithms, graphic interfaces, I/O operations, network communication, and hardware operations.

Step 3: Based on some basic principles, submodules are subdivided into small modules that are similar to building blocks. These small modules are part of the coding implementation.

In terms of software structure design, a hierarchical structure should be adopted to improve software quality and facilitate future migration, upgrading, and maintenance. The software should be divided into at least the application layer, middle layer, and driver layer.

When dividing small modules, there are several standard principles that must be followed:

I. Maximize module independence

To maximize the independence of a module is an important principle of dividing the module, that is, the module should be "highly cohesive, low coupling ".

Ii. Proper module size division

There is no absolute standard for dividing the module size into the most reasonable ones. For the function module, it is appropriate to control the number of lines in the program within the range of less than 100 rows.

Iii. Centralized Management of hardware-related components

Hardware configuration-related programs belong to the driver layer in the software structure. The benefits of centralized management are convenience for future transplantation and program modification caused by hardware changes.

4. Establish a shared module to improve the reusability of the program

5. Maintain a reasonable module fan-out rate and fan-In Rate

The fan-out rate of a module refers to the number of other modules directly controlled by this module. The fan-in rate of a module refers to the number of modules directly controlled by this module.

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.