What is Component-Driven Development?

2019-01-01 13:26发布

Component-Driven Development term is starting to get used widely, esp. in connection with Inversion of Control.

  1. What is it?
  2. What problems does it solve?
  3. When is it appropriate and when not?

7条回答
君临天下
2楼-- · 2019-01-01 14:12

If you're interested in combining components (or other reusable assets) into applications you should also take a look at the software product lines methodology.

In a software product line the dependencies between components (or lower-level code elements) are explicitly managed outside those components. This is typically done using a feature model that contains rules such as

  • These two components must not be used together (mutual exclusivity)
  • If this component is used then this other component must be used or (interdependency)
  • Any combination of some specified set of components may be used (optionality)

Other more complex rules are possible depending on the complexity of the dependencies you wish to model.

Another approach that is sometimes used instead of feature modelling is to use a code generator to configure the different components that are to be assembled into the finished application. It's also possible to combine feature modelling with code generation.

Aside from Code Generation, some other terms you might search for as domain-specific modelling, model-driven software development, software family.

查看更多
登录 后发表回答