2011-01-26 103 views

回答

6

您可以通過實現IWantCustomInitialization並在代碼中指定它爲您的自定義初始化代碼:

void IWantCustomInitialization.Init() 
    { 
     NServiceBus.Configure.With() 
      .DefaultBuilder() 
      .MsmqTransport() 
      .DoNotCreateQueues() 
      .XmlSerializer(); 
    }