public ShowImageCommandProcessor(IImageAccessor imageAccessor , LineService lineService , IRandomNumberService randomNumberService) : base(Keyword.ShowImage, lineService) { _imageAccessor = imageAccessor; }
public IEnumerable <ITransmitterCommand> Adapt( MessageContext <MatchSummary> messageContext, Language language, LineService lineService ) { var message = messageContext.Message; var status = message.SportEventStatus; if (status != null) { yield return(new UpdateGameEventStateCommand ( lineService: lineService, gameEventId: message.SportEvent.Id.ToTransmitterEventId(), receivedOn: messageContext.ReceivedOn, incomingId: messageContext.IncomingId, description: GetDescription() )); UpdateGameEventStateCommandDescription GetDescription() { var builder = new UpdateGameEventStateCommandDescription.Builder(); // Status if (status.MatchStatusCode.HasValue && lineService != LineService.BetradarUnifiedFeedLCoO) { builder.WithStatus(MatchStatusConverter.Convert(status.MatchStatusCode.Value)); } if (status.HomeScore.HasValue || status.AwayScore.HasValue) { var home = status.HomeScore ?? 0; var away = status.AwayScore ?? 0; builder.WithScoresTotal ( home.ToString(CultureInfo.InvariantCulture), away.ToString(CultureInfo.InvariantCulture) ); } if (status.PeriodScores.Any()) { var scoreLine = CalcScoreLine(status); builder.WithScoresByParts(scoreLine); } if (status.Clock != null) { int ParseTime(string s) { var fractions = s.Split(':'); var seconds = 0; var multiplier = 1; for (var i = fractions.Length - 1; i >= 0; i--) { seconds = int.Parse(fractions[i]) * multiplier; multiplier = multiplier * 60; } return(seconds); } if (!string.IsNullOrEmpty(status.Clock.MatchTime)) { builder.WithElapsedTime( ParseTime(status.Clock.MatchTime)); } } return(builder.ToImmutable()); } } }
public FlagCommandProcessor(IFlagAccessor flagAccessor, LineService lineService) : base(Keyword.Flag, lineService) { _flagAccessor = flagAccessor; _lineService = lineService; }
public ShowCensorshipBarCommandProcessor(LineService lineService) : base(Keyword.ShowCensorshipBar, lineService) { }
public PartController(PartService partService, PlantService plantService, MachineService machineService, LineService lineService) { // this._lineService = lineService; this._partService = partService; this._plantService = plantService; this._machineService = machineService; this._lineService = lineService; }
public PreventiveMaintenanceController(SiteService siteService, PlantService plantService, LineService lineService, MachineService machineService, UserService userService, PreventiveMaintenanceService pmServices, UserAssignmentsService uaServices, PreventiveWorkDescriptionService pwdServices, PreventiveReviewHistoryService prhServices, ScheduleTypeService pstServices, VendorCategoryService vcServices, VendorService vendorServices) { this._siteService = siteService; this._plantService = plantService; this._lineService = lineService; this._machineService = machineService; this._userService = userService; this._pmServices = pmServices; this._uaServices = uaServices; this._pwdServices = pwdServices; this._prhServices = prhServices; this._pstServices = pstServices; this._vcServices = vcServices; this._vendorServices = vendorServices; }
public LinesController(DataContext db, IMapper mapper, LineService service) { _db = db; _mapper = mapper; _service = service; }
public static List <Line> GetLines() { return(LineService.GetLines()); }
public static List <Line> GetLinesByStopId(string id) { return(LineService.GetLinesByStopId(id)); }
public IncreaseRuinChanceCommand(LineService lineService) : base(Keyword.IncreaseRuinChance, lineService) { }
public MaintenanceRequestController(MaintenanceRequestServices mrServices, SiteService siteService, PlantService plantService, LineService lineService, MachineService machineService, MaintenancePriorityTypeServices mtpService, StatusServices statusService, UserService userService) { this._mrServices = mrServices; this._siteService = siteService; this._plantService = plantService; this._lineService = lineService; this._machineService = machineService; this._mtpService = mtpService; this._statusService = statusService; this._userService = userService; }
public PlayVideoCommandProcessor(LineService lineService , IVideoAccessor videoAccessor) : base(Keyword.PlayVideo, lineService) { _videoAccessor = videoAccessor; }
public bool ShouldKeepLine(string inputString, DommePersonality domme) { var lineService = new LineService(); if (inputString.Contains(Keyword.AllowsOrgasm) && !lineService.GetParenData(inputString, Keyword.AllowsOrgasm).GetResultOrDefault(new List <string>()).Contains(domme.AllowsOrgasms.ToString())) { return(false); } if (inputString.ToLower().Contains("@alwaysallowsorgasm") && domme.AllowsOrgasms != AllowsOrgasms.Always) { return(false); } if (inputString.ToLower().Contains("@oftenallowsorgasm") && domme.AllowsOrgasms != AllowsOrgasms.Often) { return(false); } if (inputString.ToLower().Contains("@sometimesallowsorgasm") && domme.AllowsOrgasms != AllowsOrgasms.Sometimes) { return(false); } if (inputString.ToLower().Contains("@rarelyallowsorgasm") && domme.AllowsOrgasms != AllowsOrgasms.Rarely) { return(false); } if (inputString.ToLower().Contains("@neverallowsorgasm") && domme.AllowsOrgasms != AllowsOrgasms.Never) { return(false); } if (inputString.ToLower().Contains("@notalwaysallowsorgasm") && domme.AllowsOrgasms == AllowsOrgasms.Always) { return(false); } if (inputString.ToLower().Contains("@notneverallowsorgasm") && domme.AllowsOrgasms == AllowsOrgasms.Never) { return(false); } if (inputString.Contains(Keyword.RuinsOrgasm) && !lineService.GetParenData(inputString, Keyword.RuinsOrgasm).GetResultOrDefault(new List <string>()).Contains(domme.RuinsOrgasms.ToString())) { return(false); } if (inputString.ToLower().Contains("@alwaysruinsorgasm") && domme.RuinsOrgasms != RuinsOrgasms.Always) { return(false); } if (inputString.ToLower().Contains("@oftenruinsorgasm") && domme.RuinsOrgasms != RuinsOrgasms.Often) { return(false); } if (inputString.ToLower().Contains("@sometimesruinsorgasm") && domme.RuinsOrgasms != RuinsOrgasms.Sometimes) { return(false); } if (inputString.ToLower().Contains("@rarelyruinsorgasm") && domme.RuinsOrgasms != RuinsOrgasms.Rarely) { return(false); } if (inputString.ToLower().Contains("@neverruinsorgasm") && domme.RuinsOrgasms != RuinsOrgasms.Never) { return(false); } if (inputString.ToLower().Contains("@notalwaysruinsorgasm") && domme.RuinsOrgasms == RuinsOrgasms.Always) { return(false); } if (inputString.ToLower().Contains("@notneverruinsorgasm") && domme.RuinsOrgasms == RuinsOrgasms.Never) { return(false); } // Filter based on apathy level if (inputString.Contains(Keyword.ApathyLevel) && !lineService.GetParenData(inputString, Keyword.ApathyLevel).GetResultOrDefault(new List <string>()).Contains(domme.ApathyLevel.ToString())) { return(false); } if (inputString.Contains(Keyword.ApathyLevelNum + "1") && domme.ApathyLevel != ApathyLevel.Cautious) { return(false); } if (inputString.Contains(Keyword.ApathyLevelNum + "2") && domme.ApathyLevel != ApathyLevel.Caring) { return(false); } if (inputString.Contains(Keyword.ApathyLevelNum + "3") && domme.ApathyLevel != ApathyLevel.Moderate) { return(false); } if (inputString.Contains(Keyword.ApathyLevelNum + "4") && domme.ApathyLevel != ApathyLevel.Cruel) { return(false); } if (inputString.Contains(Keyword.ApathyLevelNum + "5") && domme.ApathyLevel != ApathyLevel.Merciless) { return(false); } // Domme Level if (inputString.ToLower().Contains("@DommeLevel(") && !lineService.GetParenData(inputString, "@DommeLevel(").GetResultOrDefault(new List <string>()).Contains(domme.DomLevel.ToString())) { return(false); } if (inputString.ToLower().Contains("@dommelevel1") && domme.DomLevel != DomLevel.Gentle) { return(false); } if (inputString.ToLower().Contains("@dommelevel2") && domme.DomLevel != DomLevel.Lenient) { return(false); } if (inputString.ToLower().Contains("@dommelevel3") && domme.DomLevel != DomLevel.Tease) { return(false); } if (inputString.ToLower().Contains("@dommelevel4") && domme.DomLevel != DomLevel.Rough) { return(false); } if (inputString.ToLower().Contains("@dommelevel5") && domme.DomLevel != DomLevel.Sadistic) { return(false); } // Cup size if (inputString.Contains("@Cup(") && !lineService.GetParenData(inputString, "@Cup(").GetResultOrDefault(new List <string>()).Contains(domme.CupSize.ToString())) { return(false); } if (inputString.ToLower().Contains("@acup") && domme.CupSize != CupSize.ACup) { return(false); } if (inputString.ToLower().Contains("@bcup") && domme.CupSize != CupSize.BCup) { return(false); } if (inputString.ToLower().Contains("@ccup") && domme.CupSize != CupSize.CCup) { return(false); } if (inputString.ToLower().Contains("@dcup") && domme.CupSize != CupSize.DCup) { return(false); } if (inputString.ToLower().Contains("@ddcup") && domme.CupSize != CupSize.DdCup) { return(false); } if (inputString.ToLower().Contains("@ddd+cup") && domme.CupSize != CupSize.DddCup) { return(false); } // Personality flags if (inputString.ToLower().Contains(Keyword.Crazy.ToLower()) && !domme.IsCrazy) { return(false); } if (inputString.ToLower().Contains(Keyword.Vulgar.ToLower()) && !domme.IsVulgar) { return(false); } if (inputString.ToLower().Contains(Keyword.Degrading.ToLower()) && !domme.IsDegrading) { return(false); } if (inputString.ToLower().Contains(Keyword.Supremacist.ToLower()) && !domme.IsSupremacist) { return(false); } if (inputString.ToLower().Contains(Keyword.Sadistic.ToLower()) && !domme.IsSadistic) { return(false); } // Domme Age if (inputString.ToLower().Contains("@selfyoung") && domme.Age > domme.AgeYoungLimit - 1) { return(false); } if (inputString.ToLower().Contains("@selfold") && domme.Age > domme.AgeOldLimit + 1) { return(false); } // Domme mood if (inputString.Contains("@GoodMood") && domme.MoodLevel <= domme.MoodHappy) { return(false); } if (inputString.Contains("@BadMood") && domme.MoodLevel >= domme.MoodAngry) { return(false); } if (inputString.Contains("@NeutralMood")) { if (domme.MoodLevel > domme.MoodHappy || domme.MoodLevel < domme.MoodAngry) { return(false); } } if (inputString.ToLower().Contains("@dombirthday") && DateTime.Now.Month != domme.BirthDay.Month && DateTime.Now.Day != domme.BirthDay.Day) { return(false); } return(true); }
public OrgasmDenyCommandProcessor(LineService lineService , IBookmarkService bookmarkService) : base(Keyword.OrgasmAllow, lineService) { _lineService = lineService; _bookmarkService = bookmarkService; }
public AfkOnCommandProcessor(LineService lineService) : base(Keyword.AfkOn, lineService) { }
public RandomNumberCommandProcessor(LineService lineService , IRandomNumberService randomNumberService) : base(Keyword.RandomNumber, lineService) { _randomNumberService = randomNumberService; }
public CommandProcessorBase(string keyword, LineService lineService) { _keyword = keyword; _lineService = lineService; }
public BreakdownController(/*ApplicationUserManager userManager,*/ SiteService siteService, PlantService plantService, LineService lineService, MachineService machineService, BreakdownService breakDownService, VendorService vendorServices, PartService partServices, EmployeeTypeService etServices, BreakDownAttachmentServices breakdownattachmentServices) { this._siteService = siteService; this._plantService = plantService; this._lineService = lineService; this._machineService = machineService; //this._subAssemblyService = subAssemblyService; this._breakDownService = breakDownService; this._vendorServices = vendorServices; //this._userManager = userManager; this._partServices = partServices; this._etServices = etServices; this._breakdownattachmentServices = breakdownattachmentServices; }
public MachineController(SiteService siteService, PlantService plantService, MachineService machineService, LineService lineService, DashboardService dashboardService, PreventiveReviewHistoryService preventiveReviewHistoryService, PreventiveMaintenanceService preventiveMaintenanceService) { this._lineService = lineService; this._siteService = siteService; this._plantService = plantService; this._machineService = machineService; this._dashboardService = dashboardService; this._preventiveReviewHistoryService = preventiveReviewHistoryService; this._preventiveMaintenanceService = preventiveMaintenanceService; }
public ChastityOn(LineService lineService, ISettingsAccessor settingsAccessor) : base(Keyword.ChastityOn, lineService) { _settingsAccessor = settingsAccessor; }
public HomeController(PreventiveMaintenanceService pmServices, PreventiveReviewHistoryService prhServices, PreventiveHoldHistoryService phhServices, BreakdownService breakDownService, PlantService plantService, MaintenanceRequestServices mrServices, StatusServices statusService, LineService lineService, UserService userService, FormulationRequestService formulationRequestService) { this._pmServices = pmServices; this._prhServices = prhServices; this._phhServices = phhServices; this._breakDownService = breakDownService; this._plantService = plantService; this._mrServices = mrServices; this._statusService = statusService; this._lineService = lineService; this._userService = userService; this._formulationRequestService = formulationRequestService; }
protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e) { base.OnPropertyChanged(e); if (e.Property.Name == "GanttItemsSourceHeader") { PageChartList = new ObservableCollection <PageChartModel>(); if (GanttItemsSourceHeader.Count <= 16) { PageChartList.Add(new PageChartModel() { PageIndex = 1 }); } else { for (int i = 0; i < Convert.ToInt32(Math.Ceiling(GanttItemsSourceHeader.Count / Convert.ToDouble(16))); i++) { PageChartList.Add(new PageChartModel() { PageIndex = i + 1 }); } } this.ItemsSource = PageChartList; foreach (var item in this.ItemsSource) { int index = (item as PageChartModel).PageIndex; OperationMonitorChartControl chart = this.ItemContainerGenerator.ContainerFromItem(item) as OperationMonitorChartControl; int count = (GanttItemsSourceHeader.Count - (index - 1) * 16) >= 16 ? (index - 1) * 16 + 16 : GanttItemsSourceHeader.Count; ObservableCollection <TimeItemModel> temp = new ObservableCollection <TimeItemModel>(); for (int i = (index - 1) * 16; i < count; i++) { temp.Add(GanttItemsSourceHeader[i]); } chart.StartTime = temp[0].TimeName; chart.EndTime = temp[temp.Count - 1].DateTimeList[temp[temp.Count - 1].DateTimeList.Count - 1]; chart.GanttItemsSourceHeader = new ObservableCollection <TimeItemModel>(temp); } } else if (e.Property.Name == "ProjectGroupInfo") { foreach (var item in this.ItemsSource) { int index = (item as PageChartModel).PageIndex; OperationMonitorChartControl chart = this.ItemContainerGenerator.ContainerFromItem(item) as OperationMonitorChartControl; ObservableCollection <LineLegendGroupModel> temp = new ObservableCollection <LineLegendGroupModel>(); LineLegendGroupModel tempGroup = null; int count = 1; foreach (var group in ProjectGroupInfo) { foreach (var legend in group.LegendItemList) { if (legend.ProjectTime >= chart.StartTime && legend.ProjectTime <= chart.EndTime) { if (count == 9) { tempGroup = new LineLegendGroupModel(); temp.Add(tempGroup); count = 0; } if (count < 10) { if (tempGroup == null) { tempGroup = new LineLegendGroupModel(); temp.Add(tempGroup); } tempGroup.LegendItemList.Add(legend); } count++; } } } chart.ProjectGroupInfo = new ObservableCollection <LineLegendGroupModel>(temp); } } else if (e.Property.Name == "LineServiceData") { foreach (var item in this.ItemsSource) { int index = (item as PageChartModel).PageIndex; OperationMonitorChartControl chart = this.ItemContainerGenerator.ContainerFromItem(item) as OperationMonitorChartControl; ObservableCollection <LineService> temp = new ObservableCollection <LineService>(); foreach (var lineData in LineServiceData) { LineService lineService = ObjectMapper.CopyTo <LineService>(lineData); ObservableCollection <LineData> lineDatas = new ObservableCollection <LineData>(); foreach (var time in lineData.LineServicesData) { if (time.PointXDate >= chart.StartTime && time.PointXDate <= chart.EndTime.AddMinutes(5)) { lineDatas.Add(time); } } lineService.LineServicesData = lineDatas; temp.Add(lineService); } chart.LineServiceData = new ObservableCollection <LineService>(temp); } } }
public void Initialize() { _service = new LineService(); }
public FormMain() { InitializeComponent(); _lineService = new LineService(); }
public TempFlagCommandProcessor(FlagService flagService , LineService lineService) : base(Keyword.SetTempFlag, lineService) { _flagService = flagService; _lineService = lineService; }
public DifferentAnswerCommandProcessor(LineService lineService) : base(Keyword.DifferentAnswer, lineService) { }
public GotoDommeLevelCommandProcessor(LineService lineService , IBookmarkService bookmarkService) : base(Keyword.GotoDommeApathy, lineService) { _lineService = lineService; _bookmarkService = bookmarkService; }
public ShowCaptionsImageCommandProcessor(IImageAccessor imageAccessor , LineService lineService , IRandomNumberService randomNumberService) : base(Common.Constants.Keyword.ShowCaptionsImage, ImageGenre.Captions, lineService, imageAccessor, randomNumberService) { }
public AcceptAnswerCommandProcessor(LineService lineService) : base(Keyword.AcceptAnswer, lineService) { }
public AfkOffCommandProcessor(LineService lineService) : base(Keyword.AfkOff, lineService) { _lineService = lineService; }