Example #1
0
        protected virtual AssemblyHandlerEventArgs OnBeforeAddAssembly(Assembly assembly)
        {
            Requires.NotNull(assembly, "assembly");

            var args = new AssemblyHandlerEventArgs(assembly);

            var hanlder = BeforeAddAssembly;

            if (hanlder != null)
            {
                hanlder(this, args);
            }

            return(args);
        }
Example #2
0
 void AssemblyManagerBeforeAddAssembly(object sender, AssemblyHandlerEventArgs e)
 {
   e.Cancel = e.Assembly != typeof(Runtime).Assembly;
 }
    protected virtual AssemblyHandlerEventArgs OnBeforeAddAssembly(Assembly assembly)
    {
      Requires.NotNull(assembly, "assembly");

      var args = new AssemblyHandlerEventArgs(assembly);

      var hanlder = BeforeAddAssembly;
      if (hanlder != null) hanlder(this, args);

      return args;
    }