Using decorator pattern
-
Hi guys Check my example below: CrazyBitz is an employment agency specializing in matching IT staff with specific skill sets to the needs of prospective employers. An employer might need someone with a c# background and SQL-server experience, who’re also qualified as a CCNA. They need an application that will automatically evaluate how well the skills of applicants match the needs of employers. Outline arguing that this IS or IS NOT a suitable problem to address with the aid of the decorator pattern... I say a decorator pattern will be useful since a person that will be employed can have additional skills other than c# and Sql-server as time goes... What are your personal views about this example?
-
Hi guys Check my example below: CrazyBitz is an employment agency specializing in matching IT staff with specific skill sets to the needs of prospective employers. An employer might need someone with a c# background and SQL-server experience, who’re also qualified as a CCNA. They need an application that will automatically evaluate how well the skills of applicants match the needs of employers. Outline arguing that this IS or IS NOT a suitable problem to address with the aid of the decorator pattern... I say a decorator pattern will be useful since a person that will be employed can have additional skills other than c# and Sql-server as time goes... What are your personal views about this example?
A Decorator is used when the original class cannot be "extended" (because it is sealed or final, or written by someone else and you don't have source, etc.). In your example, the skills associated with a person can easily be maintained as an array of skills on the Person class. So this does not qualify as an apt example for a decorator pattern.