public virtual void Add(IFacetDecorator decorator) {
     foreach (Type type in decorator.ForFacetTypes) {
         if (!facetDecorators.ContainsKey(type)) {
             facetDecorators[type] = new List<IFacetDecorator>();
         }
         facetDecorators[type].Add(decorator);
     }
 }
 private void Add(IFacetDecorator decorator)
 {
     foreach (Type type in decorator.ForFacetTypes)
     {
         if (!facetDecorators.ContainsKey(type))
         {
             facetDecorators[type] = new List <IFacetDecorator>();
         }
         facetDecorators[type].Add(decorator);
     }
 }
Exemple #3
0
 public FacetDecoratorSet(IFacetDecorator[] decorators) {
     if (decorators != null) {
         decorators.ForEach(Add);
     }
 }