摘要:Design pattern is a reusable solution to a commonly occurring design problem in certain context. Using design patterns in software development improves the product’s quality, understandability and productivity. However, it is a challenging task for novice developers to select the right design pattern to solve a design problem. The paper proposes a methodology for the automatic selection of the fit design pattern from a list of patterns. The proposed methodology is based on Text retrieval approach where the design problem scenarios are described in natural language. A vector space model (VSM) was created for the catalogue of design patterns. A vector of features consists of unigrams and bigrams is generated for the given design problem scenario. The recommended design pattern is the closest to the problem scenario. The proposed mechanism was evaluated using the Gang of four design patterns and the experimental results showed the effectiveness of the proposed methodology.
其他关键词:Design pattern selection, Gang of four, Information retrieval, Recommendation, Vector space model.