public static IPlantEx Run(object plant, ISettingsBox rootSettingsBox) { var args = new InitializePlantArgs(plant, rootSettingsBox); HatcherGuide <IPipelineManager> .Instance.InvokePipeline("initializePlant", args); return(args.ResolvedPlantEx); }
public virtual void Initialize( [NotNull] IPlant plant, [NotNull] List <object> workhorses, [NotNull] string id, [NotNull] ISettingsBox mySettingsBox) { Assert.ArgumentNotNull(plant, "plant"); Assert.ArgumentNotNull(workhorses, "workhorses"); Assert.ArgumentNotNullOrEmpty(id, "id"); Assert.ArgumentNotNull(mySettingsBox, "mySettingsBox"); this.Workhorses = workhorses; this.Plant = plant; this.ID = id; this.MySettingsBox = mySettingsBox; this.Initialized = true; }
protected virtual void SetCustomSettingsBox(IPlantEx plantEx) { var asExpected = plantEx.GetFirstWorkhorseOfType <IGetCustomSettingsStorage>(); if (asExpected == null) { return; } ISettingsBox settingsBox = plantEx.MySettingsBox.GetSubBox(this.LuggageName); asExpected.StoreCustomSettingsStorage(settingsBox); //Store luggage var luggage = new CustomSettingsServicePlantBox { RelatedPlantEx = plantEx, SettingsBox = settingsBox, IsEnabled = true, }; plantEx.PutLuggage(this.LuggageName, luggage); }
public static IPlantEx Run(object plant, ISettingsBox rootSettingsBox) { var args = new InitializePlantArgs(plant, rootSettingsBox); HatcherGuide<IPipelineManager>.Instance.InvokePipeline("initializePlant", args); return args.ResolvedPlantEx; }
public virtual void Process(InitPlantSIArgs args) { ISettingsBox settingsBox = args.SIBox.RelatedPlantEx.MySettingsBox.GetSubBox("StandaloneIconService"); args.SIBox.SettingsBox = settingsBox; }
public InitializePlantArgs(object plant, ISettingsBox rootSettingsBox) { this.PlantObject = plant; this.RootSettingsBox = rootSettingsBox; }
public UserSettingsBuilder(ISettingsBox underlyingBox) { this.UnderlyingBox = underlyingBox; }
protected IUserSettingsBuilder GetSettingBuilder(ISettingsBox settingBox) { return(this.SettingsBuilder ?? new UserSettingsBuilder(settingBox)); }
protected IUserSettingsBuilder GetSettingBuilder(ISettingsBox settingBox) { return this.SettingsBuilder ?? new UserSettingsBuilder(settingBox); }