By my opinion, encapsulation and single responsibility principle
matter much more than just 1 dependency, which your application
already has. But it is just my opinion, you can have your own.

On Mar 3, 2:29 am, Krzysztof Koźmic <[email protected]>
wrote:
> There's no right or wrong here. Do your plugin classes have
> dependencies, configuration, non-standard needs?
>
> Installer will let you account for all of that. It lets you encapsulate
> that requirements in the plugin assembly. With the other approach you're
> dumbing it down to just a single class.
>
> On 03/03/2011 8:29 AM, Xavier wrote:
>
>
>
>
>
>
>
> > 2 interfaces (IPlugin + IWindsorInstaller) vs 1.
>
> > i don't want to bother, just to understand if i'm wrong. Anyway...
>
> > On 2 mar, 12:05, Krzysztof Koźmic<[email protected]>  wrote:
> >> So?
> >> On 02/03/2011 8:59 PM, "Xavier"<[email protected]>  wrote:
>
> >>> Why do you think it's "much" better ? If i'm not wrong, the plugin has
> >>> to implement an installer and therefore there is a new dependency
> >>> between the plugin and Windsor.
> >>> Isn't it just an alternative ?
> >>> Thxs
> >>> On 1 mar, 16:20, Dmitry Kryuchkov<[email protected]>  wrote:
> >>>> I think container.Install(FromAssembly.InDirectory(new
> >>>> AssemblyFilter("your_directory"))); looks much better.
> >>>> On Mar 1, 6:17 pm, Xavier<[email protected]>  wrote:>  I'm using 
> >>>> Windsor
> >> in such a scenario
> >>>>> - i'm filtering DLL in a specific folder based on their name
> >>>>> - then load each assembly:
> >>>>>                          foreach (var assembly in assemblies)
> >>>>>                          {
> >>>>>                                  try
> >>>>>                                  {
> >>>>>                                          _container.Register(
> >> AllTypes
>
> >> .FromAssembly(Assembly.LoadFile(assembly.FullName))
>
> >> .BasedOn<IPlugin>()
> >>>>>                                                                  );
> >>>>>                                  }
> >>>>>                                  catch (Exception e)
> >>>>>                                  {
> >>>>>                                          if(_log.IsErrorEnabled)
> >>>>>                                                  _log.ErrorFormat(@"An
> >> error has occured while loading assembly>>  >  {0}\n{1}", 
> >> assembly.FullName, e);
> >>>>>                                  }
> >>>>>                          }
> >>>>> Regards
> >>>>> Xavier
> >>> --
> >>> You received this message because you are subscribed to the Google Groups
> >> "Castle Project Users" group.>  To post to this group, send email to 
> >> [email protected]
> >> .
> >>> To unsubscribe from this group, send email to
> >> [email protected].>  For more options, 
> >> visit this group at
>
> >>http://groups.google.com/group/castle-project-users?hl=en.
>
> >> - Masquer le texte des messages précédents -
>
> >> - Afficher le texte des messages précédents -- Masquer le texte des 
> >> messages précédents -
>
> >> - Afficher le texte des messages précédents -

-- 
You received this message because you are subscribed to the Google Groups 
"Castle Project Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/castle-project-users?hl=en.

Reply via email to