conflict_resolution
stringlengths 27
16k
|
---|
<<<<<<<
List<string> parts = Environment.GetCommandLineArgs().ToList();
option_nowindowreposition = parts.FindIndex(x => x.Equals("-NoRepositionWindow", StringComparison.InvariantCultureIgnoreCase)) != -1 ||
parts.FindIndex(x => x.Equals("-NRW", StringComparison.InvariantCultureIgnoreCase)) != -1;
int ai = parts.FindIndex(x => x.Equals("-Appfolder", StringComparison.InvariantCultureIgnoreCase));
if (ai != -1 && ai < parts.Count - 1)
{
Tools.appfolder = parts[ai + 1];
label_version.Text += " (Using " + Tools.appfolder + ")";
}
option_debugoptions = parts.FindIndex(x => x.Equals("-Debug", StringComparison.InvariantCultureIgnoreCase)) != -1;
option_tracelog = parts.FindIndex(x => x.Equals("-TraceLog", StringComparison.InvariantCultureIgnoreCase)) != -1;
option_fcexcept = parts.FindIndex(x => x.Equals("-LogExceptions", StringComparison.InvariantCultureIgnoreCase)) != -1;
if (parts.FindIndex(x => x.Equals("-EDSMBeta", StringComparison.InvariantCultureIgnoreCase)) != -1)
{
EDSMClass.ServerAddress = "http://beta.edsm.net:8080/";
label_version.Text += " (EDSMBeta)";
}
if (parts.FindIndex(x => x.Equals("-EDSMNull", StringComparison.InvariantCultureIgnoreCase)) != -1)
{
EDSMClass.ServerAddress = "";
label_version.Text += " (EDSM No server)";
}
if (parts.FindIndex(x => x.Equals("-DISABLEBETACHECK", StringComparison.InvariantCultureIgnoreCase)) != -1)
=======
if (EDDConfig.Options.ReadJournal != null)
>>>>>>>
List<string> parts = Environment.GetCommandLineArgs().ToList();
option_nowindowreposition = parts.FindIndex(x => x.Equals("-NoRepositionWindow", StringComparison.InvariantCultureIgnoreCase)) != -1 ||
parts.FindIndex(x => x.Equals("-NRW", StringComparison.InvariantCultureIgnoreCase)) != -1;
int ai = parts.FindIndex(x => x.Equals("-Appfolder", StringComparison.InvariantCultureIgnoreCase));
if (ai != -1 && ai < parts.Count - 1)
<<<<<<<
#region Buttons, Mouse, Menus
=======
#region Buttons, Mouse, Menus, NotifyIcon
>>>>>>>
#region Buttons, Mouse, Menus, NotifyIcon |
<<<<<<<
=======
this.TopPanel = new System.Windows.Forms.Panel();
this.eDDNTestToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
>>>>>>>
this.TopPanel = new System.Windows.Forms.Panel();
this.eDDNTestToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
<<<<<<<
this.historyContextMenu.Size = new System.Drawing.Size(294, 180);
=======
this.historyContextMenu.Size = new System.Drawing.Size(294, 224);
>>>>>>>
this.historyContextMenu.Size = new System.Drawing.Size(294, 180);
this.historyContextMenu.Size = new System.Drawing.Size(294, 224);
<<<<<<<
=======
// TopPanel
//
this.TopPanel.Controls.Add(this.buttonFilter);
this.TopPanel.Controls.Add(this.textBoxFilter);
this.TopPanel.Controls.Add(this.label1);
this.TopPanel.Controls.Add(this.comboBoxHistoryWindow);
this.TopPanel.Controls.Add(this.label2);
this.TopPanel.Dock = System.Windows.Forms.DockStyle.Top;
this.TopPanel.Location = new System.Drawing.Point(0, 0);
this.TopPanel.Name = "TopPanel";
this.TopPanel.Size = new System.Drawing.Size(594, 32);
this.TopPanel.TabIndex = 26;
//
// eDDNTestToolStripMenuItem
//
this.eDDNTestToolStripMenuItem.Name = "eDDNTestToolStripMenuItem";
this.eDDNTestToolStripMenuItem.Size = new System.Drawing.Size(293, 22);
this.eDDNTestToolStripMenuItem.Text = "EDDN test";
this.eDDNTestToolStripMenuItem.Click += new System.EventHandler(this.eDDNTestToolStripMenuItem_Click);
//
>>>>>>>
// TopPanel
//
this.TopPanel.Controls.Add(this.buttonFilter);
this.TopPanel.Controls.Add(this.textBoxFilter);
this.TopPanel.Controls.Add(this.label1);
this.TopPanel.Controls.Add(this.comboBoxHistoryWindow);
this.TopPanel.Controls.Add(this.label2);
this.TopPanel.Dock = System.Windows.Forms.DockStyle.Top;
this.TopPanel.Location = new System.Drawing.Point(0, 0);
this.TopPanel.Name = "TopPanel";
this.TopPanel.Size = new System.Drawing.Size(594, 32);
this.TopPanel.TabIndex = 26;
//
// eDDNTestToolStripMenuItem
//
this.eDDNTestToolStripMenuItem.Name = "eDDNTestToolStripMenuItem";
this.eDDNTestToolStripMenuItem.Size = new System.Drawing.Size(293, 22);
this.eDDNTestToolStripMenuItem.Text = "EDDN test";
this.eDDNTestToolStripMenuItem.Click += new System.EventHandler(this.eDDNTestToolStripMenuItem_Click);
//
<<<<<<<
=======
private ExtendedControls.ButtonExt buttonFilter;
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItemStartStop;
private System.Windows.Forms.ToolStripMenuItem eDDNTestToolStripMenuItem;
>>>>>>>
private System.Windows.Forms.ToolStripMenuItem eDDNTestToolStripMenuItem; |
<<<<<<<
=======
string namecalc ="!"; // need to keep the name as TryTake empties the string
>>>>>>>
<<<<<<<
vsc = cursys;
while (closestsystem_queue.TryTake(out nextsys)) // try and empty the queue in case multiple ones are there
=======
if (closestname == "!!!!!!CLOSE!!!!!")
return;
string nextname;
while (closestsystem_queue.TryTake(out nextname)) // try and empty the queue in case multiple ones are there
>>>>>>>
if (closestname == "!!!!!!CLOSE!!!!!")
return;
vsc = cursys;
while (closestsystem_queue.TryTake(out nextsys)) // try and empty the queue in case multiple ones are there
<<<<<<<
vsc = nextsys;
=======
closestname = nextname;
if (closestname == "!!!!!!CLOSE!!!!!")
return;
>>>>>>>
vsc = nextsys;
if (closestname == "!!!!!!CLOSE!!!!!")
return; |
<<<<<<<
=======
this.viewOnEDSMToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.comboBoxHistoryWindow = new System.Windows.Forms.ComboBox();
>>>>>>>
this.viewOnEDSMToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.comboBoxHistoryWindow = new System.Windows.Forms.ComboBox();
<<<<<<<
this.TopPanel = new System.Windows.Forms.Panel();
this.dataViewScrollerPanel1 = new ExtendedControls.DataViewScrollerPanel();
this.vScrollBarCustom1 = new ExtendedControls.VScrollBarCustom();
this.dataGridViewTravel = new System.Windows.Forms.DataGridView();
this.ColumnTime = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ColumnSystem = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ColumnDistance = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ColumnNote = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.mapColour = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.textBoxFilter = new ExtendedControls.TextBoxBorder();
this.button_RefreshHistory = new ExtendedControls.ButtonExt();
this.comboBoxHistoryWindow = new ExtendedControls.ComboBoxCustom();
this.richTextBox_History = new ExtendedControls.RichTextBoxScroll();
this.dataViewScrollerPanel2 = new ExtendedControls.DataViewScrollerPanel();
this.vScrollBarCustom2 = new ExtendedControls.VScrollBarCustom();
this.textBoxSolDist = new ExtendedControls.TextBoxBorder();
this.buttonTrilaterate = new ExtendedControls.ButtonExt();
this.buttonRoss = new ExtendedControls.DrawnPanel();
this.buttonEDDB = new ExtendedControls.DrawnPanel();
this.textBoxState = new ExtendedControls.TextBoxBorder();
this.textBoxEconomy = new ExtendedControls.TextBoxBorder();
this.textBoxGovernment = new ExtendedControls.TextBoxBorder();
this.textBoxAllegiance = new ExtendedControls.TextBoxBorder();
this.textBoxVisits = new ExtendedControls.TextBoxBorder();
this.richTextBoxNote = new ExtendedControls.RichTextBoxScroll();
this.buttonUpdate = new ExtendedControls.ButtonExt();
this.textBoxDistance = new ExtendedControls.TextBoxBorder();
this.textBoxPrevSystem = new ExtendedControls.TextBoxBorder();
this.textBoxZ = new ExtendedControls.TextBoxBorder();
this.textBoxY = new ExtendedControls.TextBoxBorder();
this.textBoxX = new ExtendedControls.TextBoxBorder();
this.textBoxSystem = new ExtendedControls.TextBoxBorder();
this.checkBoxEDSMSyncFrom = new ExtendedControls.CheckBoxCustom();
this.checkBoxEDSMSyncTo = new ExtendedControls.CheckBoxCustom();
this.comboBoxCommander = new ExtendedControls.ComboBoxCustom();
this.textBoxDistanceToNextSystem = new ExtendedControls.TextBoxBorder();
this.buttonMap = new ExtendedControls.ButtonExt();
this.buttonSync = new ExtendedControls.ButtonExt();
=======
this.mapColorDialog = new System.Windows.Forms.ColorDialog();
this.viewOnEDSMToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
((System.ComponentModel.ISupportInitialize)(this.dataGridViewTravel)).BeginInit();
>>>>>>>
this.mapColorDialog = new System.Windows.Forms.ColorDialog();
this.viewOnEDSMToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
((System.ComponentModel.ISupportInitialize)(this.dataGridViewTravel)).BeginInit();
this.TopPanel = new System.Windows.Forms.Panel();
this.dataViewScrollerPanel1 = new ExtendedControls.DataViewScrollerPanel();
this.vScrollBarCustom1 = new ExtendedControls.VScrollBarCustom();
this.dataGridViewTravel = new System.Windows.Forms.DataGridView();
this.ColumnTime = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ColumnSystem = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ColumnDistance = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ColumnNote = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.mapColour = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.textBoxFilter = new ExtendedControls.TextBoxBorder();
this.button_RefreshHistory = new ExtendedControls.ButtonExt();
this.comboBoxHistoryWindow = new ExtendedControls.ComboBoxCustom();
this.richTextBox_History = new ExtendedControls.RichTextBoxScroll();
this.dataViewScrollerPanel2 = new ExtendedControls.DataViewScrollerPanel();
this.vScrollBarCustom2 = new ExtendedControls.VScrollBarCustom();
this.textBoxSolDist = new ExtendedControls.TextBoxBorder();
this.buttonTrilaterate = new ExtendedControls.ButtonExt();
this.buttonRoss = new ExtendedControls.DrawnPanel();
this.buttonEDDB = new ExtendedControls.DrawnPanel();
this.textBoxState = new ExtendedControls.TextBoxBorder();
this.textBoxEconomy = new ExtendedControls.TextBoxBorder();
this.textBoxGovernment = new ExtendedControls.TextBoxBorder();
this.textBoxAllegiance = new ExtendedControls.TextBoxBorder();
this.textBoxVisits = new ExtendedControls.TextBoxBorder();
this.richTextBoxNote = new ExtendedControls.RichTextBoxScroll();
this.buttonUpdate = new ExtendedControls.ButtonExt();
this.textBoxDistance = new ExtendedControls.TextBoxBorder();
this.textBoxPrevSystem = new ExtendedControls.TextBoxBorder();
this.textBoxZ = new ExtendedControls.TextBoxBorder();
this.textBoxY = new ExtendedControls.TextBoxBorder();
this.textBoxX = new ExtendedControls.TextBoxBorder();
this.textBoxSystem = new ExtendedControls.TextBoxBorder();
this.checkBoxEDSMSyncFrom = new ExtendedControls.CheckBoxCustom();
this.checkBoxEDSMSyncTo = new ExtendedControls.CheckBoxCustom();
this.comboBoxCommander = new ExtendedControls.ComboBoxCustom();
this.textBoxDistanceToNextSystem = new ExtendedControls.TextBoxBorder();
this.buttonMap = new ExtendedControls.ButtonExt();
this.buttonSync = new ExtendedControls.ButtonExt();
<<<<<<<
=======
// viewOnEDSMToolStripMenuItem
//
this.viewOnEDSMToolStripMenuItem.Name = "viewOnEDSMToolStripMenuItem";
this.viewOnEDSMToolStripMenuItem.Size = new System.Drawing.Size(232, 22);
this.viewOnEDSMToolStripMenuItem.Text = "View on EDSM";
this.viewOnEDSMToolStripMenuItem.Click += new System.EventHandler(this.viewOnEDSMToolStripMenuItem_Click);
//
// comboBoxHistoryWindow
//
this.comboBoxHistoryWindow.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboBoxHistoryWindow.FormattingEnabled = true;
this.comboBoxHistoryWindow.Items.AddRange(new object[] {
"6 Hours",
"12 Hours",
"24 Hours",
"3 days",
"Week",
"2 Weeks",
"Month",
"Last 20",
"All"});
this.comboBoxHistoryWindow.Location = new System.Drawing.Point(101, 6);
this.comboBoxHistoryWindow.Name = "comboBoxHistoryWindow";
this.comboBoxHistoryWindow.Size = new System.Drawing.Size(94, 21);
this.comboBoxHistoryWindow.TabIndex = 0;
this.comboBoxHistoryWindow.SelectedIndexChanged += new System.EventHandler(this.comboBoxHistoryWindow_SelectedIndexChanged);
//
>>>>>>>
// viewOnEDSMToolStripMenuItem
//
this.viewOnEDSMToolStripMenuItem.Name = "viewOnEDSMToolStripMenuItem";
this.viewOnEDSMToolStripMenuItem.Size = new System.Drawing.Size(232, 22);
this.viewOnEDSMToolStripMenuItem.Text = "View on EDSM";
this.viewOnEDSMToolStripMenuItem.Click += new System.EventHandler(this.viewOnEDSMToolStripMenuItem_Click);
//
// comboBoxHistoryWindow
//
this.comboBoxHistoryWindow.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboBoxHistoryWindow.FormattingEnabled = true;
this.comboBoxHistoryWindow.Items.AddRange(new object[] {
"6 Hours",
"12 Hours",
"24 Hours",
"3 days",
"Week",
"2 Weeks",
"Month",
"Last 20",
"All"});
this.comboBoxHistoryWindow.Location = new System.Drawing.Point(101, 6);
this.comboBoxHistoryWindow.Name = "comboBoxHistoryWindow";
this.comboBoxHistoryWindow.Size = new System.Drawing.Size(94, 21);
this.comboBoxHistoryWindow.TabIndex = 0;
this.comboBoxHistoryWindow.SelectedIndexChanged += new System.EventHandler(this.comboBoxHistoryWindow_SelectedIndexChanged);
//
<<<<<<<
this.closestContextMenu.Size = new System.Drawing.Size(177, 26);
=======
this.closestContextMenu.Size = new System.Drawing.Size(178, 70);
>>>>>>>
this.closestContextMenu.Size = new System.Drawing.Size(178, 70);
<<<<<<<
private ExtendedControls.TextBoxBorder textBoxDistance;
=======
private System.Windows.Forms.ToolStripMenuItem viewOnEDSMToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem viewOnEDSMToolStripMenuItem1;
>>>>>>>
private System.Windows.Forms.ToolStripMenuItem viewOnEDSMToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem viewOnEDSMToolStripMenuItem1;
private ExtendedControls.TextBoxBorder textBoxDistance; |
<<<<<<<
ArrowObj arrow = new ArrowObj(xSelected.Value, ySelected.Value, xSelected.Value,
ySelected.Value) { Line = { Color = GraphSummary.ColorSelected } };
zedGraphControl.GraphPane.GraphObjList.Insert(0, arrow);
=======
const float selectedLineWidth = 2;
>>>>>>>
const float selectedLineWidth = 2;
ArrowObj arrow = new ArrowObj(xSelected.Value, ySelected.Value, xSelected.Value,
ySelected.Value) { Line = { Color = GraphSummary.ColorSelected } };
zedGraphControl.GraphPane.GraphObjList.Insert(0, arrow); |
<<<<<<<
using osu.Game.Rulesets.Tau.Configuration;
using osu.Game.Rulesets.Tau.UI;
using osu.Game.Rulesets.Tau.UI.Particles;
=======
using osu.Framework.Allocation;
using osu.Game.Rulesets.Tau.UI;
>>>>>>>
using osu.Framework.Allocation;
using osu.Game.Rulesets.Tau.UI;
using osu.Game.Rulesets.Tau.Configuration;
using osu.Game.Rulesets.Tau.UI;
using osu.Game.Rulesets.Tau.UI.Particles;
<<<<<<<
[Resolved]
private TauPlayfield playfield { get; set; }
[Resolved]
private OsuColour colour { get; set; }
=======
[Resolved]
private TauPlayfield playfield { get; set; }
public DrawableSlider() : this(null)
{
}
>>>>>>>
[Resolved]
private TauPlayfield playfield { get; set; }
public DrawableSlider() : this(null)
{
}
[Resolved]
private OsuColour colour { get; set; }
<<<<<<<
private readonly Bindable<KiaiType> effect = new Bindable<KiaiType>();
[BackgroundDependencyLoader(true)]
private void load(TauRulesetConfigManager config)
{
config?.BindWith(TauRulesetSettings.KiaiEffect, effect);
}
=======
protected override void OnApply()
{
base.OnApply();
totalTimeHeld = 0;
}
>>>>>>>
protected override void OnApply()
{
base.OnApply();
totalTimeHeld = 0;
}
private readonly Bindable<KiaiType> effect = new Bindable<KiaiType>();
[BackgroundDependencyLoader(true)]
private void load(TauRulesetConfigManager config)
{
config?.BindWith(TauRulesetSettings.KiaiEffect, effect);
} |
<<<<<<<
/// Looks up a localized resource of type System.Drawing.Bitmap.
/// </summary>
public static System.Drawing.Bitmap SmallMoleculeMethodDevCEOpt_thumb {
get {
object obj = ResourceManager.GetObject("SmallMoleculeMethodDevCEOpt_thumb", resourceCulture);
return ((System.Drawing.Bitmap)(obj));
}
}
/// <summary>
/// Looks up a localized resource of type System.Drawing.Bitmap.
/// </summary>
public static System.Drawing.Bitmap SmallMoleculeQuantification_thumb {
get {
object obj = ResourceManager.GetObject("SmallMoleculeQuantification_thumb", resourceCulture);
return ((System.Drawing.Bitmap)(obj));
}
}
/// <summary>
=======
/// Looks up a localized string similar to Compound.
/// </summary>
public static string SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders_Compound {
get {
return ResourceManager.GetString("SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders" +
"_Compound", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Molecule.
/// </summary>
public static string SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders_Molecule {
get {
return ResourceManager.GetString("SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders" +
"_Molecule", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to RT (min).
/// </summary>
public static string SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders_RT__min_ {
get {
return ResourceManager.GetString("SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders" +
"_RT__min_", resourceCulture);
}
}
/// <summary>
>>>>>>>
/// Looks up a localized string similar to Compound.
/// </summary>
public static string SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders_Compound {
get {
return ResourceManager.GetString("SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders" +
"_Compound", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Molecule.
/// </summary>
public static string SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders_Molecule {
get {
return ResourceManager.GetString("SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders" +
"_Molecule", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to RT (min).
/// </summary>
public static string SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders_RT__min_ {
get {
return ResourceManager.GetString("SmallMoleculeTransitionListColumnHeaders_SmallMoleculeTransitionListColumnHeaders" +
"_RT__min_", resourceCulture);
}
}
/// <summary>
/// Looks up a localized resource of type System.Drawing.Bitmap.
/// </summary>
public static System.Drawing.Bitmap SmallMoleculeMethodDevCEOpt_thumb {
get {
object obj = ResourceManager.GetObject("SmallMoleculeMethodDevCEOpt_thumb", resourceCulture);
return ((System.Drawing.Bitmap)(obj));
}
}
/// <summary>
/// Looks up a localized resource of type System.Drawing.Bitmap.
/// </summary>
public static System.Drawing.Bitmap SmallMoleculeQuantification_thumb {
get {
object obj = ResourceManager.GetObject("SmallMoleculeQuantification_thumb", resourceCulture);
return ((System.Drawing.Bitmap)(obj));
}
}
/// <summary> |
<<<<<<<
using System;
using System.Linq;
=======
using System;
using System.Collections.Generic;
using System.Linq;
using osu.Framework.Graphics.Pooling;
>>>>>>>
using System;
using System.Collections.Generic;
using System.Linq;
using osu.Framework.Graphics.Pooling;
<<<<<<<
using osu.Framework.Timing;
using osu.Framework.Utils;
=======
using osu.Framework.Logging;
using osu.Framework.Utils;
>>>>>>>
using osu.Framework.Utils;
<<<<<<<
for (int i = 0; i < 8; i++)
{
SliderParticleEmitter.Vortices.Add(new Vortex
{
Speed = RNG.NextSingle() * (10.5f + 2),
Scale = new Vector2(50),
Position = Extensions.GetCircularPosition(500f, (360 / 8) * i),
Velocity = Extensions.GetCircularPosition(50, (360 / 8) * i)
});
}
=======
NewResult += onNewResult;
var hitWindows = new TauHitWindows();
foreach (var result in Enum.GetValues(typeof(HitResult)).OfType<HitResult>().Where(r => r > HitResult.None && hitWindows.IsHitResultAllowed(r)))
poolDictionary.Add(result, new DrawableJudgementPool(result, onJudgmentLoaded));
AddRangeInternal(poolDictionary.Values);
}
private void onJudgmentLoaded(DrawableTauJudgement judgement)
{
judgementLayer.Add(judgement.GetProxyAboveHitObjectsContent());
>>>>>>>
NewResult += onNewResult;
var hitWindows = new TauHitWindows();
foreach (var result in Enum.GetValues(typeof(HitResult)).OfType<HitResult>().Where(r => r > HitResult.None && hitWindows.IsHitResultAllowed(r)))
poolDictionary.Add(result, new DrawableJudgementPool(result, onJudgmentLoaded));
AddRangeInternal(poolDictionary.Values);
for (int i = 0; i < 8; i++)
{
SliderParticleEmitter.Vortices.Add(new Vortex
{
Speed = RNG.NextSingle() * (10.5f + 2),
Scale = new Vector2(50),
Position = Extensions.GetCircularPosition(500f, (360 / 8) * i),
Velocity = Extensions.GetCircularPosition(50, (360 / 8) * i)
});
}
}
private void onJudgmentLoaded(DrawableTauJudgement judgement)
{
judgementLayer.Add(judgement.GetProxyAboveHitObjectsContent());
<<<<<<<
if (judgedObject.HitObject.Kiai && result.Type != HitResult.Miss)
{
switch (effect.Value)
{
case KiaiType.Turbulent:
for (int i = 0; i < 10; i++)
{
SliderParticleEmitter.AddParticle(sAngle, result.Type);
}
break;
case KiaiType.Classic:
kiaiExplosionContainer.Add(new KiaiHitExplosion(colour.ForHitResult(judgedObject.Result.Type))
{
Position = Extensions.GetCircularPosition(.5f, sAngle),
Angle = sAngle,
Anchor = Anchor.Centre,
Origin = Anchor.Centre
});
break;
}
}
break;
case DrawableBeat beat:
var angle = beat.HitObject.Angle;
explosion.Position = Extensions.GetCircularPosition(.6f, angle);
explosion.Rotation = angle;
if (judgedObject.HitObject.Kiai && result.Type != HitResult.Miss)
{
switch (effect.Value)
{
case KiaiType.Turbulent:
for (int i = 0; i < 10; i++)
{
SliderParticleEmitter.AddParticle(angle, result.Type);
}
break;
case KiaiType.Classic:
kiaiExplosionContainer.Add(new KiaiHitExplosion(colour.ForHitResult(judgedObject.Result.Type))
{
Position = Extensions.GetCircularPosition(.5f, angle),
Angle = angle,
Anchor = Anchor.Centre,
Origin = Anchor.Centre
});
break;
}
}
=======
kiaiExplosionContainer.Add(new KiaiHitExplosion(colour.ForHitResult(judgedObject.Result.Type), judgedObject is DrawableHardBeat)
{
Position = judgedObject is DrawableHardBeat ? Vector2.Zero : Extensions.GetCircularPosition(.5f, angle),
Angle = angle,
Anchor = Anchor.Centre,
Origin = Anchor.Centre
});
}
}
>>>>>>>
var isHardBeat = judgedObject is DrawableHardBeat;
switch (effect.Value)
{
case KiaiType.Turbulent:
for (int i = 0; i < (isHardBeat ? 50 : 10); i++)
{
SliderParticleEmitter.AddParticle((isHardBeat ? RNG.NextSingle(0, 360) : angle), result.Type);
}
break;
case KiaiType.Classic:
kiaiExplosionContainer.Add(new KiaiHitExplosion(colour.ForHitResult(judgedObject.Result.Type), judgedObject is DrawableHardBeat)
{
Position = judgedObject is DrawableHardBeat ? Vector2.Zero : Extensions.GetCircularPosition(.5f, angle),
Angle = angle,
Anchor = Anchor.Centre,
Origin = Anchor.Centre
});
break;
}
}
}
<<<<<<<
if (judgedObject.HitObject.Kiai && result.Type != HitResult.Miss)
{
switch (effect.Value)
{
case KiaiType.Turbulent:
for (int i = 0; i < 50; i++)
{
var randomAngle = RNG.NextSingle(0, 360);
SliderParticleEmitter.AddParticle(randomAngle, result.Type);
}
break;
case KiaiType.Classic:
kiaiExplosionContainer.Add(new KiaiHitExplosion(colour.ForHitResult(judgedObject.Result.Type), true)
{
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
});
break;
}
}
=======
protected override DrawableTauJudgement CreateNewDrawable()
{
var judgement = base.CreateNewDrawable();
>>>>>>>
protected override DrawableTauJudgement CreateNewDrawable()
{
var judgement = base.CreateNewDrawable(); |
<<<<<<<
protected override ReplayRecorder CreateReplayRecorder(Replay replay) => new TauReplayRecorder(replay);
=======
public override PlayfieldAdjustmentContainer CreatePlayfieldAdjustmentContainer() => new TauPlayfieldAdjustmentContainer();
>>>>>>>
public override PlayfieldAdjustmentContainer CreatePlayfieldAdjustmentContainer() => new TauPlayfieldAdjustmentContainer();
protected override ReplayRecorder CreateReplayRecorder(Replay replay) => new TauReplayRecorder(replay); |
<<<<<<<
=======
using osu.Game.Rulesets.UI;
using osuTK;
>>>>>>>
<<<<<<<
=======
private const float playfield_size_adjust = 0.8f;
>>>>>>>
private const float playfield_size_adjust = 0.8f;
<<<<<<<
Size = new Vector2(1f);
=======
// Calculated from osu!stable as 512 (default gamefield size) / 640 (default window size)
Size = new Vector2(playfield_size_adjust);
>>>>>>>
// Calculated from osu!stable as 512 (default gamefield size) / 640 (default window size)
Size = new Vector2(playfield_size_adjust); |
<<<<<<<
using Npgsql.Bulk.SampleRunner.DotNetStandard20.DAL;
=======
using System.Transactions;
>>>>>>>
using Npgsql.Bulk.SampleRunner.DotNetStandard20.DAL;
using System.Transactions; |
<<<<<<<
[Test]
public void FlushCatchExceptions()
{
_mockRequestHandler.Setup(r => r.MakeRequest(It.IsAny<Batch>())).Throws<System.Exception>();
_ = _handler.Process(new Track(null, null, null, null));
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), times: Times.Exactly(1));
}
=======
[Test]
public async Task BatchMeetTheMaxNumberOfActions()
{
var flushAt = 20;
var actionNumber = 45;
_handler = GetFlushHandler(1000, flushAt, 10000);
await Task.Delay(100);
var actions = GetActions(actionNumber, GetEventName(30));
foreach (var action in actions)
{
_ = _handler.Process(action);
}
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), Times.Exactly(3));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == flushAt)), Times.Exactly(2));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == 5)), Times.Exactly(1));
}
>>>>>>>
[Test]
public async Task BatchMeetTheMaxNumberOfActions()
{
var flushAt = 20;
var actionNumber = 45;
_handler = GetFlushHandler(1000, flushAt, 10000);
await Task.Delay(100);
var actions = GetActions(actionNumber, GetEventName(30));
foreach (var action in actions)
{
_ = _handler.Process(action);
}
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), Times.Exactly(3));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == flushAt)), Times.Exactly(2));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == 5)), Times.Exactly(1));
}
[Test]
public void FlushCatchExceptions()
{
_mockRequestHandler.Setup(r => r.MakeRequest(It.IsAny<Batch>())).Throws<System.Exception>();
_ = _handler.Process(new Track(null, null, null, null));
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), times: Times.Exactly(1));
} |
<<<<<<<
using System.Threading;
using System.Threading.Tasks;
using Moq;
=======
>>>>>>>
using System.Threading;
using System.Threading.Tasks;
using Moq; |
<<<<<<<
[Test]
public void FlushCatchExceptions()
{
_mockRequestHandler.Setup(r => r.MakeRequest(It.IsAny<Batch>())).Throws<System.Exception>();
_ = _handler.Process(new Track(null, null, null, null));
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), times: Times.Exactly(1));
}
=======
[Test]
public async Task BatchMeetTheMaxNumberOfActions()
{
var flushAt = 20;
var actionNumber = 45;
_handler = GetFlushHandler(1000, flushAt, 10000);
await Task.Delay(100);
var actions = GetActions(actionNumber, GetEventName(30));
foreach (var action in actions)
{
_ = _handler.Process(action);
}
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), Times.Exactly(3));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == flushAt)), Times.Exactly(2));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == 5)), Times.Exactly(1));
}
>>>>>>>
[Test]
public void FlushCatchExceptions()
{
_mockRequestHandler.Setup(r => r.MakeRequest(It.IsAny<Batch>())).Throws<System.Exception>();
_ = _handler.Process(new Track(null, null, null, null));
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), times: Times.Exactly(1));
}
[Test]
public async Task BatchMeetTheMaxNumberOfActions()
{
var flushAt = 20;
var actionNumber = 45;
_handler = GetFlushHandler(1000, flushAt, 10000);
await Task.Delay(100);
var actions = GetActions(actionNumber, GetEventName(30));
foreach (var action in actions)
{
_ = _handler.Process(action);
}
_handler.Flush();
_mockRequestHandler.Verify(r => r.MakeRequest(It.IsAny<Batch>()), Times.Exactly(3));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == flushAt)), Times.Exactly(2));
_mockRequestHandler.Verify(r => r.MakeRequest(It.Is<Batch>(b => b.batch.Count == 5)), Times.Exactly(1));
} |
<<<<<<<
RegisterCommand(new PlaceBaseCommand());
RegisterCommand(new PlaceFurnitureCommand());
=======
RegisterCommand(new AniCommand());
RegisterCommand(new BuildCommand());
>>>>>>>
RegisterCommand(new PlaceBaseCommand());
RegisterCommand(new PlaceFurnitureCommand());
RegisterCommand(new AniCommand()); |
<<<<<<<
using NzbDrone.Model;
=======
using Ninject;
>>>>>>>
using Ninject;
using NzbDrone.Model;
<<<<<<<
public virtual AuthenticationType AuthenticationType
{
get { return (AuthenticationType)GetValueInt("AuthenticationType", 0); }
set { SetValue("AuthenticationType", (int)value); }
}
=======
>>>>>>>
public virtual AuthenticationType AuthenticationType
{
get { return (AuthenticationType)GetValueInt("AuthenticationType", 0); }
set { SetValue("AuthenticationType", (int)value); }
}
<<<<<<<
public virtual string GetValue(string key, object defaultValue, string parent = null)
=======
private void WriteDefaultConfig()
>>>>>>>
private string GetValue(string key, object defaultValue, string parent = null) |
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification); |
<<<<<<<
_logger.Info("Skipping refresh of artist: {0}", artist.ArtistName);
_diskScanService.Scan(artist);
=======
_logger.Info("Skipping refresh of artist: {0}", artist.Name);
//TODO: _diskScanService.Scan(artist);
>>>>>>>
_logger.Info("Skipping refresh of artist: {0}", artist.Name);
_diskScanService.Scan(artist); |
<<<<<<<
using Ninject;
=======
using NzbDrone.Model;
>>>>>>>
using Ninject;
using NzbDrone.Model;
<<<<<<<
=======
public virtual AuthenticationType AuthenticationType
{
get { return (AuthenticationType)GetValueInt("AuthenticationType", 0); }
set { SetValue("AuthenticationType", (int)value); }
}
>>>>>>>
public virtual AuthenticationType AuthenticationType
{
get { return (AuthenticationType)GetValueInt("AuthenticationType", 0); }
}
<<<<<<<
private void WriteDefaultConfig()
=======
public virtual string GetValue(string key, object defaultValue, string parent = null)
>>>>>>>
public virtual string GetValue(string key, object defaultValue, string parent = null) |
<<<<<<<
int priority = (int)Enum.Parse(typeof(SabnzbdPriorityType), _configProvider.SabTvPriority);
=======
string priority = _configProvider.SabTvPriority;
>>>>>>>
int priority = (int)Enum.Parse(typeof(SabnzbdPriorityType), _configProvider.SabTvPriority);
<<<<<<<
public virtual bool AddById(string id, string title)
{
//mode=addid&name=333333&pp=3&script=customscript.cmd&cat=Example&priority=-1
const string mode = "addid";
string cat = _configProvider.SabTvCategory;
int priority = (int)Enum.Parse(typeof(SabnzbdPriorityType), _configProvider.SabTvPriority);
string nzbName = HttpUtility.UrlEncode(title);
string action = string.Format("mode={0}&name={1}&priority={2}&cat={3}&nzbname={4}", mode, id, priority, cat,
nzbName);
string request = GetSabRequest(action);
Logger.Debug("Adding report [{0}] to the queue.", nzbName);
string response = _httpProvider.DownloadString(request).Replace("\n", String.Empty);
Logger.Debug("Queue Repsonse: [{0}]", response);
if (response == "ok")
return true;
return false;
}
=======
>>>>>>>
<<<<<<<
string sabnzbdInfo = _configProvider.SabHost + ":" +
_configProvider.SabPort;
string username = _configProvider.SabUsername;
string password = _configProvider.SabPassword;
string apiKey = _configProvider.SabApiKey;
return
string.Format(@"http://{0}/api?$Action&apikey={1}&ma_username={2}&ma_password={3}", sabnzbdInfo, apiKey,
username, password).Replace("$Action", action);
=======
return string.Format(@"http://{0}:{1}/api?{2}&apikey={3}&ma_username={4}&ma_password={5}",
_configProvider.SabHost,
_configProvider.SabPort,
action,
_configProvider.SabApiKey,
_configProvider.SabUsername,
_configProvider.SabPassword);
>>>>>>>
return string.Format(@"http://{0}:{1}/api?{2}&apikey={3}&ma_username={4}&ma_password={5}",
_configProvider.SabHost,
_configProvider.SabPort,
action,
_configProvider.SabApiKey,
_configProvider.SabUsername,
_configProvider.SabPassword); |
<<<<<<<
//Remove the error prefix before processing
var parseResult = Parser.ParseTitle(directoryInfo.Name.Substring(GetPrefixLength(postDownloadStatus)));
=======
//Add to InfoList for possible later processing
InfoList.Add(new PostDownloadInfoModel
{
Name = directoryInfo.FullName,
Added = DateTime.Now,
Status = postDownloadStatus
});
//Remove the first 8 characters of the folder name (removes _UNPACK_ or _FAILED_) before processing
var parseResult = Parser.ParseTitle(directoryInfo.Name.Substring(8));
>>>>>>>
//Add to InfoList for possible later processing
InfoList.Add(new PostDownloadInfoModel{ Name = directoryInfo.FullName,
Added = DateTime.Now,
Status = postDownloadStatus
});
//Remove the error prefix before processing
var parseResult = Parser.ParseTitle(directoryInfo.Name.Substring(GetPrefixLength(postDownloadStatus))); |
<<<<<<<
parseResult.AirDate, parseResult.EpisodeTitle, parseResult.Quality.Quality);
=======
parseResult.AirDate, parseResult.Episodes.First().Title, parseResult.Quality.QualityType);
>>>>>>>
parseResult.AirDate, parseResult.Episodes.First().Title, parseResult.Quality.Quality);
<<<<<<<
var result = String.Format("{0} - {1} - {2} [{3}]", seriesTitle, epNumberString, parseResult.EpisodeTitle, parseResult.Quality.Quality);
=======
if (episodeNames.Distinct().Count() == 1)
episodeName = episodeNames.First();
else
episodeName = String.Join(" + ", episodeNames.Distinct());
var result = String.Format("{0} - {1} - {2} [{3}]", seriesTitle, epNumberString, episodeName, parseResult.Quality.QualityType);
>>>>>>>
if (episodeNames.Distinct().Count() == 1)
episodeName = episodeNames.First();
else
episodeName = String.Join(" + ", episodeNames.Distinct());
var result = String.Format("{0} - {1} - {2} [{3}]", seriesTitle, epNumberString, episodeName, parseResult.Quality.Quality); |
<<<<<<<
// start logging here...
LogManagerFactory.Initialize();
LogManagerFactory.ConfigureGlobalHandler();
=======
this.UnhandledException += App_UnhandledException;
}
async void App_UnhandledException(object sender, UnhandledExceptionEventArgs e)
{
var log = (ILoggerAsync)LogManagerFactory.DefaultLogManager.GetLogger<App>();
await log.FatalAsync("The application crashed: " + e.Message, e.Exception);
>>>>>>>
LogManagerFactory.ConfigureGlobalHandler(); |
<<<<<<<
private MethodDeclarationSyntax GenerateShadowCallback(CsCallable csElement, PlatformDetectionType platform, InteropMethodSignature sig)
=======
private static CatchClauseSyntax GenerateCatchClause(CatchClauseSyntax catchClause, CsCallable csElement, SyntaxToken exceptionVariableIdentifier, params StatementSyntax[] statements)
{
var toShadowStatement = LocalDeclarationStatement(
VariableDeclaration(
IdentifierName(csElement.Parent.Name))
.WithVariables(
SingletonSeparatedList(
VariableDeclarator(
Identifier("@this"))
.WithInitializer(
EqualsValueClause(
CastExpression(
IdentifierName(csElement.Parent.Name),
MemberAccessExpression(
SyntaxKind.SimpleMemberAccessExpression,
InvocationExpression(
GenericName(
Identifier("ToShadow"))
.WithTypeArgumentList(
TypeArgumentList(
SingletonSeparatedList<TypeSyntax>(
IdentifierName(csElement.GetParent<CsInterface>().ShadowName)))))
.WithArgumentList(
ArgumentList(
SingletonSeparatedList(
Argument(
IdentifierName("thisObject"))))),
IdentifierName("Callback"))))))));
var exceptionCallbackStatement = ExpressionStatement(
ConditionalAccessExpression(
ParenthesizedExpression(
BinaryExpression(
SyntaxKind.AsExpression,
(IdentifierName(@"@this")),
IdentifierName("SharpGen.Runtime.IExceptionCallback"))),
InvocationExpression(
MemberBindingExpression(
IdentifierName("RaiseException")))
.WithArgumentList(
ArgumentList(
SingletonSeparatedList<ArgumentSyntax>(
Argument(
IdentifierName(exceptionVariableIdentifier)))))));
var statementList = new List<StatementSyntax> { toShadowStatement, exceptionCallbackStatement };
statementList.AddRange(statements);
return catchClause
.WithDeclaration(
CatchDeclaration(ParseTypeName("System.Exception"))
.WithIdentifier(exceptionVariableIdentifier))
.WithBlock(Block(statementList.ToArray()));
}
private MethodDeclarationSyntax GenerateShadowCallback(CsCallable csElement)
>>>>>>>
private static CatchClauseSyntax GenerateCatchClause(CatchClauseSyntax catchClause, CsCallable csElement, SyntaxToken exceptionVariableIdentifier, params StatementSyntax[] statements)
{
var toShadowStatement = LocalDeclarationStatement(
VariableDeclaration(
IdentifierName(csElement.Parent.Name))
.WithVariables(
SingletonSeparatedList(
VariableDeclarator(
Identifier("@this"))
.WithInitializer(
EqualsValueClause(
CastExpression(
IdentifierName(csElement.Parent.Name),
MemberAccessExpression(
SyntaxKind.SimpleMemberAccessExpression,
InvocationExpression(
GenericName(
Identifier("ToShadow"))
.WithTypeArgumentList(
TypeArgumentList(
SingletonSeparatedList<TypeSyntax>(
IdentifierName(csElement.GetParent<CsInterface>().ShadowName)))))
.WithArgumentList(
ArgumentList(
SingletonSeparatedList(
Argument(
IdentifierName("thisObject"))))),
IdentifierName("Callback"))))))));
var exceptionCallbackStatement = ExpressionStatement(
ConditionalAccessExpression(
ParenthesizedExpression(
BinaryExpression(
SyntaxKind.AsExpression,
(IdentifierName(@"@this")),
IdentifierName("SharpGen.Runtime.IExceptionCallback"))),
InvocationExpression(
MemberBindingExpression(
IdentifierName("RaiseException")))
.WithArgumentList(
ArgumentList(
SingletonSeparatedList<ArgumentSyntax>(
Argument(
IdentifierName(exceptionVariableIdentifier)))))));
var statementList = new List<StatementSyntax> { toShadowStatement, exceptionCallbackStatement };
statementList.AddRange(statements);
return catchClause
.WithDeclaration(
CatchDeclaration(ParseTypeName("System.Exception"))
.WithIdentifier(exceptionVariableIdentifier))
.WithBlock(Block(statementList.ToArray()));
}
private MethodDeclarationSyntax GenerateShadowCallback(CsCallable csElement, PlatformDetectionType platform, InteropMethodSignature sig) |
<<<<<<<
//gameObject.guiText.fontSize = 60;
Debug.Log(ArabicSupport.ArabicFixer.Fix("نص عربي على يونيتي، أهلا وسهلا", ShowTashkeel, UseHinduNumbers));
}
// Update is called once per frame
void Update () {
=======
>>>>>>>
//gameObject.guiText.fontSize = 60;
Debug.Log(ArabicSupport.ArabicFixer.Fix("نص عربي على يونيتي، أهلا وسهلا", ShowTashkeel, UseHinduNumbers)); |
<<<<<<<
Book = item.Book,
ContainerItems = item.ContainerItems,
=======
Container =
{
Size = item.Container.Size,
Items = item.Container.Items,
IsOpen = item.Container.IsOpen,
IsLocked = item.Container.IsLocked,
AssociatedKeyId = item.Container.AssociatedKeyId
},
>>>>>>>
Container =
{
Size = item.Container.Size,
Items = item.Container.Items,
IsOpen = item.Container.IsOpen,
IsLocked = item.Container.IsLocked,
AssociatedKeyId = item.Container.AssociatedKeyId
},
Book = item.Book, |
<<<<<<<
[typeof(IApiKey)] = typeof(DefaultApiKey),
=======
[typeof(ISamlPolicy)] = typeof(DefaultSamlPolicy),
[typeof(ISamlServiceProvider)] = typeof(DefaultSamlServiceProvider),
[typeof(ISsoInitiationEndpoint)] = typeof(DefaultSsoInitiationEndpoint),
[typeof(ISamlAccountResult)] = typeof(DefaultSamlAccountResult),
>>>>>>>
[typeof(IApiKey)] = typeof(DefaultApiKey),
[typeof(ISamlPolicy)] = typeof(DefaultSamlPolicy),
[typeof(ISamlServiceProvider)] = typeof(DefaultSamlServiceProvider),
[typeof(ISsoInitiationEndpoint)] = typeof(DefaultSsoInitiationEndpoint),
[typeof(ISamlAccountResult)] = typeof(DefaultSamlAccountResult), |
<<<<<<<
/// <summary>
/// Synchronously gets an <see cref="IApiKey">API Key</see>, by its ID, that belongs to an <see cref="IAccount">Account</see>
/// that has access to this application by a mapped account store.
/// </summary>
/// <param name="application">The application.</param>
/// <param name="apiKeyId">The API Key ID.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
public static IApiKey GetApiKey(this IApplication application, string apiKeyId)
=> (application as IApplicationSync).GetApiKey(apiKeyId);
/// <summary>
/// Synchronously gets an <see cref="IApiKey">API Key</see>, by its ID, that belongs to an <see cref="IAccount">Account</see>
/// that has access to this application by a mapped account store.
/// </summary>
/// <param name="application">The application.</param>
/// <param name="apiKeyId">The API Key ID.</param>
/// <param name="retrievalOptionsAction">The options to apply to the request.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
public static IApiKey GetApiKey(this IApplication application, string apiKeyId, Action<IRetrievalOptions<IApiKey>> retrievalOptionsAction)
=> (application as IApplicationSync).GetApiKey(apiKeyId, retrievalOptionsAction);
=======
/// <summary>
/// Synchronously retrieves the <see cref="ISamlPolicy">SAML Policy</see> associated with this <see cref="IApplication">Application</see>.
/// </summary>
/// <param name="application">The application.</param>
/// <returns>The <see cref="ISamlPolicy">SAML Policy</see> associated with this <see cref="IApplication">Application</see>.</returns>
public static ISamlPolicy GetSamlPolicy(this IApplication application)
=> (application as IApplicationSync).GetSamlPolicy();
/// <summary>
/// Synchronously creates a new <see cref="ISamlIdpUrlBuilder"/> that allows you to build a URL you can use to redirect
/// your application users to an external SAML Identity Provider.
/// </summary>
/// <param name="application">The application.</param>
/// <returns>A new <see cref="ISamlIdpUrlBuilder"/> that can build a URL to redirect your users to a SAML Identity Provider.</returns>
public static ISamlIdpUrlBuilder NewSamlIdpUrlBuilder(this IApplication application)
=> (application as IApplicationSync).NewSamlIdpUrlBuilder();
/// <summary>
/// Creates a new <see cref="ISamlSyncCallbackHandler"/> used to handle HTTP replies from an external SAML Identity Provider to your
/// application's <c>callbackUri</c>.
/// </summary>
/// <param name="application">The application.</param>
/// <param name="request">
/// An instance of <see cref="IHttpRequest"/>.
/// See the <see cref="HttpRequests"/> helper class to help build this from an existing request.
/// </param>
/// <returns>A new <see cref="ISamlSyncCallbackHandler"/> that allows your to customize how the <paramref name="request"/> will be handled.</returns>
public static ISamlSyncCallbackHandler NewSamlSyncCallbackHandler(this IApplication application, IHttpRequest request)
=> (application as IApplicationSync).NewSamlSyncCallbackHandler(request);
>>>>>>>
/// <summary>
/// Synchronously retrieves the <see cref="ISamlPolicy">SAML Policy</see> associated with this <see cref="IApplication">Application</see>.
/// </summary>
/// <param name="application">The application.</param>
/// <returns>The <see cref="ISamlPolicy">SAML Policy</see> associated with this <see cref="IApplication">Application</see>.</returns>
public static ISamlPolicy GetSamlPolicy(this IApplication application)
=> (application as IApplicationSync).GetSamlPolicy();
/// <summary>
/// Synchronously creates a new <see cref="ISamlIdpUrlBuilder"/> that allows you to build a URL you can use to redirect
/// your application users to an external SAML Identity Provider.
/// </summary>
/// <param name="application">The application.</param>
/// <returns>A new <see cref="ISamlIdpUrlBuilder"/> that can build a URL to redirect your users to a SAML Identity Provider.</returns>
public static ISamlIdpUrlBuilder NewSamlIdpUrlBuilder(this IApplication application)
=> (application as IApplicationSync).NewSamlIdpUrlBuilder();
/// <summary>
/// Creates a new <see cref="ISamlSyncCallbackHandler"/> used to handle HTTP replies from an external SAML Identity Provider to your
/// application's <c>callbackUri</c>.
/// </summary>
/// <param name="application">The application.</param>
/// <param name="request">
/// An instance of <see cref="IHttpRequest"/>.
/// See the <see cref="HttpRequests"/> helper class to help build this from an existing request.
/// </param>
/// <returns>A new <see cref="ISamlSyncCallbackHandler"/> that allows your to customize how the <paramref name="request"/> will be handled.</returns>
public static ISamlSyncCallbackHandler NewSamlSyncCallbackHandler(this IApplication application, IHttpRequest request)
=> (application as IApplicationSync).NewSamlSyncCallbackHandler(request);
/// <summary>
/// Synchronously gets an <see cref="IApiKey">API Key</see>, by its ID, that belongs to an <see cref="IAccount">Account</see>
/// that has access to this application by a mapped account store.
/// </summary>
/// <param name="application">The application.</param>
/// <param name="apiKeyId">The API Key ID.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
public static IApiKey GetApiKey(this IApplication application, string apiKeyId)
=> (application as IApplicationSync).GetApiKey(apiKeyId);
/// <summary>
/// Synchronously gets an <see cref="IApiKey">API Key</see>, by its ID, that belongs to an <see cref="IAccount">Account</see>
/// that has access to this application by a mapped account store.
/// </summary>
/// <param name="application">The application.</param>
/// <param name="apiKeyId">The API Key ID.</param>
/// <param name="retrievalOptionsAction">The options to apply to the request.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
public static IApiKey GetApiKey(this IApplication application, string apiKeyId, Action<IRetrievalOptions<IApiKey>> retrievalOptionsAction)
=> (application as IApplicationSync).GetApiKey(apiKeyId, retrievalOptionsAction); |
<<<<<<<
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.GetApiKeyAsync(string, System.Threading.CancellationToken)"/>.
/// </summary>
/// <param name="apiKeyId">The API Key ID.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
IApiKey GetApiKey(string apiKeyId);
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.GetApiKeyAsync(string, Action{IRetrievalOptions{IApiKey}}, System.Threading.CancellationToken)"/>.
/// </summary>
/// <param name="apiKeyId">The API Key ID.</param>
/// <param name="retrievalOptionsAction">The options to apply to the request.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
IApiKey GetApiKey(string apiKeyId, Action<IRetrievalOptions<IApiKey>> retrievalOptionsAction);
=======
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.GetSamlPolicyAsync(System.Threading.CancellationToken)"/>.
/// </summary>
/// <returns>The <see cref="ISamlPolicy">SAML Policy</see> associated with this <see cref="IApplication">Application</see>.</returns>
ISamlPolicy GetSamlPolicy();
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.NewSamlIdpUrlBuilderAsync(System.Threading.CancellationToken)"/>.
/// </summary>
/// <returns>A new <see cref="ISamlIdpUrlBuilder"/> that can build a URL to redirect your users to a SAML Identity Provider.</returns>
ISamlIdpUrlBuilder NewSamlIdpUrlBuilder();
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.NewSamlAsyncCallbackHandler(IHttpRequest)"/>.
/// </summary>
/// <param name="request">
/// An instance of <see cref="IHttpRequest"/>.
/// See the <see cref="HttpRequests"/> helper class to help build this from an existing request.
/// </param>
/// <returns>A new <see cref="ISamlSyncCallbackHandler"/> that allows your to customize how the <paramref name="request"/> will be handled.</returns>
ISamlSyncCallbackHandler NewSamlSyncCallbackHandler(IHttpRequest request);
>>>>>>>
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.GetSamlPolicyAsync(System.Threading.CancellationToken)"/>.
/// </summary>
/// <returns>The <see cref="ISamlPolicy">SAML Policy</see> associated with this <see cref="IApplication">Application</see>.</returns>
ISamlPolicy GetSamlPolicy();
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.NewSamlIdpUrlBuilderAsync(System.Threading.CancellationToken)"/>.
/// </summary>
/// <returns>A new <see cref="ISamlIdpUrlBuilder"/> that can build a URL to redirect your users to a SAML Identity Provider.</returns>
ISamlIdpUrlBuilder NewSamlIdpUrlBuilder();
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.NewSamlAsyncCallbackHandler(IHttpRequest)"/>.
/// </summary>
/// <param name="request">
/// An instance of <see cref="IHttpRequest"/>.
/// See the <see cref="HttpRequests"/> helper class to help build this from an existing request.
/// </param>
/// <returns>A new <see cref="ISamlSyncCallbackHandler"/> that allows your to customize how the <paramref name="request"/> will be handled.</returns>
ISamlSyncCallbackHandler NewSamlSyncCallbackHandler(IHttpRequest request);
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.GetApiKeyAsync(string, System.Threading.CancellationToken)"/>.
/// </summary>
/// <param name="apiKeyId">The API Key ID.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
IApiKey GetApiKey(string apiKeyId);
/// <summary>
/// Synchronous counterpart to <see cref="IApplication.GetApiKeyAsync(string, Action{IRetrievalOptions{IApiKey}}, System.Threading.CancellationToken)"/>.
/// </summary>
/// <param name="apiKeyId">The API Key ID.</param>
/// <param name="retrievalOptionsAction">The options to apply to the request.</param>
/// <exception cref="ArgumentNullException"><paramref name="apiKeyId"/> is null or empty.</exception>
/// <returns>The API Key, or <see langword="null"/> if no API Key could be found.</returns>
IApiKey GetApiKey(string apiKeyId, Action<IRetrievalOptions<IApiKey>> retrievalOptionsAction); |
<<<<<<<
// ReSharper disable once NotAccessedField.Local
public PropertyInfo PropertyInfo { get; private set; }
=======
// ReSharper disable once NotAccessedField.Global
public PropertyInfo _propertyInfo;
>>>>>>>
// ReSharper disable once NotAccessedField.Global
public PropertyInfo PropertyInfo { get; private set; } |
<<<<<<<
public bool VerticalHUD { get; set; } = false;
public bool SingleplayerHUD { get; set; } = false;
public bool Hologram { get; set; } = true;
public bool CustomSongs { get; set; } = true;
public bool FreeMod { get; set; } = false;
public string Color { get; set; } = "#08C0FF";
public int MaxPlayers { get; set; } = 10;
=======
public virtual bool VerticalHUD { get; set; } = false;
public virtual bool SingleplayerHUD { get; set; } = false;
public virtual bool Hologram { get; set; } = true;
public virtual bool CustomSongs { get; set; } = true;
public virtual bool EnforceMods { get; set; } = true;
public virtual string Color { get; set; } = "#08C0FF";
public virtual int MaxPlayers { get; set; } = 10;
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public virtual DebugConfig? DebugConfig { get; set; }
}
public class DebugConfig
{
public virtual bool FailDownloads { get; set; } = false;
public virtual int MinDownloadTime { get; set; } = 0;
>>>>>>>
public virtual bool VerticalHUD { get; set; } = false;
public virtual bool SingleplayerHUD { get; set; } = false;
public virtual bool Hologram { get; set; } = true;
public virtual bool CustomSongs { get; set; } = true;
public virtual bool FreeMod { get; set; } = false;
public virtual string Color { get; set; } = "#08C0FF";
public virtual int MaxPlayers { get; set; } = 10;
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public virtual DebugConfig? DebugConfig { get; set; }
}
public class DebugConfig
{
public virtual bool FailDownloads { get; set; } = false;
public virtual int MinDownloadTime { get; set; } = 0; |
<<<<<<<
IList keyCodeList;
KeyCode[] reservedKeys = new KeyCode[] { KeyCode.Escape, KeyCode.BackQuote };
=======
KeyCode[] reservedKeys = new KeyCode[] { KeyCode.Escape, KeyCode.BackQuote, KeyCode.F8 };
>>>>>>>
IList keyCodeList;
KeyCode[] reservedKeys = new KeyCode[] { KeyCode.Escape, KeyCode.BackQuote, KeyCode.F8 };
<<<<<<<
Dictionary<String, AxisActions> axisActionKeyDict = new Dictionary<String, AxisActions>();
KeyCode[] controllerUIDict = new KeyCode[3]; //leftClick, rightClick, MiddleClick
String[] cameraAxisBindingCache = new String[2];
String[] movementAxisBindingCache = new String[2];
=======
Dictionary<KeyCode, string> unknownActions = new Dictionary<KeyCode, string>();
>>>>>>>
Dictionary<String, AxisActions> axisActionKeyDict = new Dictionary<String, AxisActions>();
Dictionary<KeyCode, string> unknownActions = new Dictionary<KeyCode, string>();
KeyCode[] controllerUIDict = new KeyCode[3]; //leftClick, rightClick, MiddleClick
String[] cameraAxisBindingCache = new String[2];
String[] movementAxisBindingCache = new String[2];
<<<<<<<
public Dictionary<String, Actions> actionKeyBinds;
public Dictionary<String, AxisActions> axisActionKeyBinds;
=======
public Dictionary<KeyCode, string> actionKeyBinds;
>>>>>>>
public Dictionary<String, string> actionKeyBinds;
public Dictionary<String, AxisActions> axisActionKeyBinds;
<<<<<<<
keyBindsData.actionKeyBinds = actionKeyDict.Select(x => x).ToDictionary(entry => GetKeyString(entry.Key), entry => (Actions)entry.Value);
keyBindsData.axisActionKeyBinds = axisActionKeyDict;
=======
keyBindsData.actionKeyBinds = new Dictionary<KeyCode, string>();
foreach (var item in actionKeyDict)
{
keyBindsData.actionKeyBinds.Add(item.Key, item.Value.ToString());
}
// If unknown actions were detected in this run, make sure we append them back to the settings file, so we won't break
// the newer builds potentially using them.
foreach (var item in unknownActions)
{
keyBindsData.actionKeyBinds.Add(item.Key, item.Value);
}
>>>>>>>
keyBindsData.axisActionKeyBinds = axisActionKeyDict;
keyBindsData.actionKeyBinds = new Dictionary<string, string>();
foreach (var item in actionKeyDict)
{
keyBindsData.actionKeyBinds.Add(GetKeyString(item.Key), item.Value.ToString());
}
// If unknown actions were detected in this run, make sure we append them back to the settings file, so we won't break
// the newer builds potentially using them.
foreach (var item in unknownActions)
{
keyBindsData.actionKeyBinds.Add(GetKeyString(item.Key), item.Value);
}
<<<<<<<
SetAxisBinding("Axis1", AxisActions.MovementHorizontal);
SetAxisBinding("Axis2", AxisActions.MovementVertical);
SetAxisBinding("Axis4", AxisActions.CameraHorizontal);
SetAxisBinding("Axis5", AxisActions.CameraVertical);
controllerUIDict[0] = KeyCode.JoystickButton0;
controllerUIDict[1] = KeyCode.JoystickButton1;
UpdateAxisBindingCache();
}
public bool GetMouseButtonDown(int button)
{
if (usingControllerCursor)
return GetKeyDown(controllerUIDict[button]);
return Input.GetMouseButtonDown(button);
}
public bool GetMouseButtonUp(int button)
{
if (usingControllerCursor)
return GetKeyUp(controllerUIDict[button]);
return Input.GetMouseButtonUp(button);
}
public bool GetMouseButton(int button)
{
if (usingControllerCursor)
return GetKey(controllerUIDict[button]);
return Input.GetMouseButton(button);
}
public bool GetKey(KeyCode key)
{
KeyCode conv = ConvertJoystickButtonKeyCode(key);
var k = (((int)conv) < startingAxisKeyCode && Input.GetKey(conv)) || GetAxisKey((int)conv);
if (k)
LastKeyDown = conv;
return k;
}
public bool GetKeyDown(KeyCode key)
{
KeyCode conv = ConvertJoystickButtonKeyCode(key);
var kd = (((int)conv) < startingAxisKeyCode && Input.GetKeyDown(conv)) || GetAxisKeyDown((int)conv);
if (kd)
LastKeyDown = conv;
return kd;
}
public bool GetKeyUp(KeyCode key)
{
KeyCode conv = ConvertJoystickButtonKeyCode(key);
return (((int)conv) < startingAxisKeyCode && Input.GetKeyUp(conv)) || GetAxisKeyUp((int)conv);
}
public bool AnyKeyDown
{
get
{
foreach (KeyCode k in KeyCodeList)
if (GetKeyDown(k)) return true;
return false;
}
}
public String GetKeyString(KeyCode key)
{
if (axisKeyCodeStrings.ContainsKey((int)key))
return axisKeyCodeStrings[(int)key];
else
return key.ToString();
}
public KeyCode ParseKeyCodeString(String s)
{
if (Enum.IsDefined(typeof(KeyCode), s))
{
return (KeyCode)Enum.Parse(typeof(KeyCode), s);
}
else
{
return (KeyCode)axisKeyCodeStrings.FirstOrDefault(x => x.Value == s).Key;
}
=======
SetBinding(KeyCode.F8, Actions.PrintScreen);
>>>>>>>
SetAxisBinding("Axis1", AxisActions.MovementHorizontal);
SetAxisBinding("Axis2", AxisActions.MovementVertical);
SetAxisBinding("Axis4", AxisActions.CameraHorizontal);
SetAxisBinding("Axis5", AxisActions.CameraVertical);
controllerUIDict[0] = KeyCode.JoystickButton0;
controllerUIDict[1] = KeyCode.JoystickButton1;
UpdateAxisBindingCache();
}
public bool GetMouseButtonDown(int button)
{
if (usingControllerCursor)
return GetKeyDown(controllerUIDict[button]);
return Input.GetMouseButtonDown(button);
}
public bool GetMouseButtonUp(int button)
{
if (usingControllerCursor)
return GetKeyUp(controllerUIDict[button]);
return Input.GetMouseButtonUp(button);
}
public bool GetMouseButton(int button)
{
if (usingControllerCursor)
return GetKey(controllerUIDict[button]);
return Input.GetMouseButton(button);
}
public bool GetKey(KeyCode key)
{
KeyCode conv = ConvertJoystickButtonKeyCode(key);
var k = (((int)conv) < startingAxisKeyCode && Input.GetKey(conv)) || GetAxisKey((int)conv);
if (k)
LastKeyDown = conv;
return k;
}
public bool GetKeyDown(KeyCode key)
{
KeyCode conv = ConvertJoystickButtonKeyCode(key);
var kd = (((int)conv) < startingAxisKeyCode && Input.GetKeyDown(conv)) || GetAxisKeyDown((int)conv);
if (kd)
LastKeyDown = conv;
return kd;
}
public bool GetKeyUp(KeyCode key)
{
KeyCode conv = ConvertJoystickButtonKeyCode(key);
return (((int)conv) < startingAxisKeyCode && Input.GetKeyUp(conv)) || GetAxisKeyUp((int)conv);
}
public bool AnyKeyDown
{
get
{
foreach (KeyCode k in KeyCodeList)
if (GetKeyDown(k)) return true;
return false;
}
}
public String GetKeyString(KeyCode key)
{
if (axisKeyCodeStrings.ContainsKey((int)key))
return axisKeyCodeStrings[(int)key];
else
return key.ToString();
}
public KeyCode ParseKeyCodeString(String s)
{
if (Enum.IsDefined(typeof(KeyCode), s))
{
return (KeyCode)Enum.Parse(typeof(KeyCode), s);
}
else
{
return (KeyCode)axisKeyCodeStrings.FirstOrDefault(x => x.Value == s).Key;
}
<<<<<<<
TestSetAxisBinding("Axis1", AxisActions.MovementHorizontal);
TestSetAxisBinding("Axis2", AxisActions.MovementVertical);
TestSetAxisBinding("Axis4", AxisActions.CameraHorizontal);
TestSetAxisBinding("Axis5", AxisActions.CameraVertical);
controllerUIDict[0] = KeyCode.JoystickButton0;
controllerUIDict[1] = KeyCode.JoystickButton1;
UpdateAxisBindingCache();
=======
TestSetBinding(KeyCode.F8, Actions.PrintScreen);
>>>>>>>
TestSetAxisBinding("Axis1", AxisActions.MovementHorizontal);
TestSetAxisBinding("Axis2", AxisActions.MovementVertical);
TestSetAxisBinding("Axis4", AxisActions.CameraHorizontal);
TestSetAxisBinding("Axis5", AxisActions.CameraVertical);
controllerUIDict[0] = KeyCode.JoystickButton0;
controllerUIDict[1] = KeyCode.JoystickButton1;
UpdateAxisBindingCache();
<<<<<<<
KeyCode key = ParseKeyCodeString(item.Key);
if (!actionKeyDict.ContainsKey(key))
actionKeyDict.Add(key, item.Value);
=======
var actionVal = ActionNameToEnum(item.Value);
if (!actionKeyDict.ContainsKey(item.Key) && actionVal != Actions.Unknown)
actionKeyDict.Add(item.Key, actionVal);
else
{
// This action is unknown in this game, make sure we still keep it so once we save the settings, we
// won't discard them.
unknownActions.Add(item.Key, item.Value);
}
>>>>>>>
KeyCode key = ParseKeyCodeString(item.Key);
var actionVal = ActionNameToEnum(item.Value);
if (!actionKeyDict.ContainsKey(key) && actionVal != Actions.Unknown)
actionKeyDict.Add(key, actionVal);
else
{
// This action is unknown in this game, make sure we still keep it so once we save the settings, we
// won't discard them.
unknownActions.Add(key, item.Value);
} |
<<<<<<<
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
=======
speedCautious = (sender == cautiousToggleButton);
Refresh();
}
public void ToggleSpeedButtonOnScrollHandler(BaseScreenComponent sender)
{
>>>>>>>
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
speedCautious = (sender == cautiousToggleButton);
Refresh();
}
public void ToggleSpeedButtonOnScrollHandler(BaseScreenComponent sender)
{
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
<<<<<<<
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
=======
travelShip = (sender == shipToggleButton);
Refresh();
}
public void ToggleTransportModeButtonOnScrollHandler(BaseScreenComponent sender)
{
>>>>>>>
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
travelShip = (sender == shipToggleButton);
Refresh();
}
public void ToggleTransportModeButtonOnScrollHandler(BaseScreenComponent sender)
{
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
<<<<<<<
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
=======
sleepModeInn = (sender == innToggleButton);
Refresh();
}
public void ToggleSleepModeButtonOnScrollHandler(BaseScreenComponent sender)
{
>>>>>>>
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick);
sleepModeInn = (sender == innToggleButton);
Refresh();
}
public void ToggleSleepModeButtonOnScrollHandler(BaseScreenComponent sender)
{
DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick); |
<<<<<<<
private PlayerHeightChanger heightChanger;
=======
private Croucher myCroucher;
private PlayerSpeedChanger speedChanger;
>>>>>>>
private PlayerHeightChanger heightChanger;
private PlayerSpeedChanger speedChanger; |
<<<<<<<
//mainCamera = GameManager.Instance.MainCamera;
climbingMotor = GetComponent<ClimbingMotor>();
=======
>>>>>>>
climbingMotor = GetComponent<ClimbingMotor>(); |
<<<<<<<
foreach(var item in keyBindsData.actionKeyBinds)
{
if (actionKeyDict.ContainsKey(item.Key))
actionKeyDict[item.Key] = item.Value;
else
actionKeyDict.Add(item.Key, item.Value);
}
//actionKeyDict = keyBindsData.actionKeyBinds;
=======
actionKeyDict = keyBindsData.actionKeyBinds;
RaiseLoadedKeyBindsEvent();
}
#endregion
#region Events
public delegate void OnLoadSaveKeyBinds();
public static event OnLoadSaveKeyBinds OnLoadedKeyBinds;
protected virtual void RaiseLoadedKeyBindsEvent()
{
if (OnLoadedKeyBinds != null)
OnLoadedKeyBinds();
}
public static event OnLoadSaveKeyBinds OnSavedKeyBinds;
protected virtual void RaiseSavedKeyBindsEvent()
{
if (OnSavedKeyBinds != null)
OnSavedKeyBinds();
}
public delegate void OnUpdateKeyBind(KeyCode code);
public static event OnUpdateKeyBind OnUpdatedKeyBind;
protected virtual void RaiseUpdatedKeyBindsEvent(KeyCode code)
{
if (OnUpdatedKeyBind != null)
OnUpdatedKeyBind(code);
>>>>>>>
foreach(var item in keyBindsData.actionKeyBinds)
{
if (actionKeyDict.ContainsKey(item.Key))
actionKeyDict[item.Key] = item.Value;
else
actionKeyDict.Add(item.Key, item.Value);
}
//actionKeyDict = keyBindsData.actionKeyBinds;
RaiseLoadedKeyBindsEvent();
}
#endregion
#region Events
public delegate void OnLoadSaveKeyBinds();
public static event OnLoadSaveKeyBinds OnLoadedKeyBinds;
protected virtual void RaiseLoadedKeyBindsEvent()
{
if (OnLoadedKeyBinds != null)
OnLoadedKeyBinds();
}
public static event OnLoadSaveKeyBinds OnSavedKeyBinds;
protected virtual void RaiseSavedKeyBindsEvent()
{
if (OnSavedKeyBinds != null)
OnSavedKeyBinds();
}
public delegate void OnUpdateKeyBind(KeyCode code);
public static event OnUpdateKeyBind OnUpdatedKeyBind;
protected virtual void RaiseUpdatedKeyBindsEvent(KeyCode code)
{
if (OnUpdatedKeyBind != null)
OnUpdatedKeyBind(code); |
<<<<<<<
using System.Collections.Immutable;
=======
using System.IO;
>>>>>>>
using System.IO;
using System.Collections.Immutable;
<<<<<<<
using Microsoft.CodeAnalysis.Text;
using Microsoft.DotNet.Try.Protocol;
using WorkspaceServer.LanguageServices;
using CompletionItem = Microsoft.DotNet.Try.Protocol.CompletionItem;
=======
using Microsoft.DotNet.Interactive.Rendering;
using Task = System.Threading.Tasks.Task;
>>>>>>>
using Microsoft.CodeAnalysis.Text;
using Microsoft.DotNet.Try.Protocol;
using WorkspaceServer.LanguageServices;
using CompletionItem = Microsoft.DotNet.Try.Protocol.CompletionItem; |
<<<<<<<
using Serilog;
=======
using System.Diagnostics;
using Serilog.Events;
>>>>>>>
using System.Diagnostics;
using Serilog;
using Serilog.Events;
<<<<<<<
}
=======
options.AddLogLevelOptions();
}
protected Options Options { get; } = new Options();
protected ILogger Log { get; }
>>>>>>>
options.AddLogLevelOptions();
}
protected ILogger Log { get; } |
<<<<<<<
.Where(t => t.AsType() != typeof(IOctopusSpaceAsyncRepository))
.Where(t => t.AsType() != typeof(IOctopusSystemAsyncRepository))
.Where(t => t.AsType() != typeof(IOctopusCommonAsyncRepository))
#if SYNC_CLIENT
=======
>>>>>>>
.Where(t => t.AsType() != typeof(IOctopusSpaceAsyncRepository))
.Where(t => t.AsType() != typeof(IOctopusSystemAsyncRepository))
.Where(t => t.AsType() != typeof(IOctopusCommonAsyncRepository))
<<<<<<<
.Where(t => t.AsType() != typeof(IOctopusSpaceRepository))
.Where(t => t.AsType() != typeof(IOctopusSystemRepository))
.Where(t => t.AsType() != typeof(IOctopusCommonRepository))
#endif
=======
>>>>>>>
.Where(t => t.AsType() != typeof(IOctopusSpaceRepository))
.Where(t => t.AsType() != typeof(IOctopusSystemRepository))
.Where(t => t.AsType() != typeof(IOctopusCommonRepository)) |
<<<<<<<
if (IsTenantedDeployment && !await Repository.SupportsTenants().ConfigureAwait(false))
throw new CommandException("Your Octopus server does not support tenants, which was introduced in Octopus 3.4. Please upgrade your Octopus server, enable the multi-tenancy feature or remove the --tenant and --tenanttag arguments.");
=======
if (IsTenantedDeployment && !Repository.SupportsTenants())
throw new CommandException("Your Octopus Server does not support tenants, which was introduced in Octopus 3.4. Please upgrade your Octopus Server, enable the multi-tenancy feature or remove the --tenant and --tenanttag arguments.");
>>>>>>>
if (IsTenantedDeployment && !await Repository.SupportsTenants().ConfigureAwait(false))
throw new CommandException("Your Octopus Server does not support tenants, which was introduced in Octopus 3.4. Please upgrade your Octopus Server, enable the multi-tenancy feature or remove the --tenant and --tenanttag arguments."); |
<<<<<<<
=======
public bool IsMultiTenancyEnabled { get; set; }
[Writeable]
public bool IsBuiltInWorkerEnabled { get; set; } = true;
[Writeable]
>>>>>>>
public bool IsBuiltInWorkerEnabled { get; set; } = true;
[Writeable] |
<<<<<<<
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, pathParameters);
return Client.Paginate(path ?? Client.RootDocument.Link(CollectionLinkName), parameters, getNextPage);
=======
return Client.Paginate(path ?? Client.Link(CollectionLinkName), pathParameters ?? new { }, getNextPage);
>>>>>>>
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, pathParameters);
return Client.Paginate(path ?? Client.Link(CollectionLinkName), parameters, getNextPage);
<<<<<<<
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, new { id = "all" });
return Client.Get<List<TResource>>(Client.RootDocument.Link(CollectionLinkName), parameters);
=======
return Client.Get<List<TResource>>(Client.Link(CollectionLinkName), new { id = "all" });
>>>>>>>
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, new { id = "all" });
return Client.Get<List<TResource>>(Client.Link(CollectionLinkName), parameters);
<<<<<<<
? Client.Get<TResource>(idOrHref, AdditionalQueryParameters)
: Client.Get<TResource>(Client.RootDocument.Link(CollectionLinkName), parameters);
=======
? Client.Get<TResource>(idOrHref)
: Client.Get<TResource>(Client.Link(CollectionLinkName), new { id = idOrHref });
>>>>>>>
? Client.Get<TResource>(idOrHref, AdditionalQueryParameters)
: Client.Get<TResource>(Client.Link(CollectionLinkName), parameters); |
<<<<<<<
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, pathParameters);
client.Paginate(path ?? client.RootDocument.Link(CollectionLinkName), parameters, getNextPage);
=======
client.Paginate(path ?? client.Link(CollectionLinkName), pathParameters ?? new { }, getNextPage);
>>>>>>>
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, pathParameters);
client.Paginate(path ?? client.Link(CollectionLinkName), parameters, getNextPage);
<<<<<<<
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, new { id = "all" });
return client.Get<List<TResource>>(client.RootDocument.Link(CollectionLinkName), parameters);
=======
return client.Get<List<TResource>>(client.Link(CollectionLinkName), new { id = "all" });
>>>>>>>
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, new { id = "all" });
return client.Get<List<TResource>>(client.Link(CollectionLinkName), parameters);
<<<<<<<
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, new { id = idOrHref });
return client.Get<TResource>(client.RootDocument.Link(CollectionLinkName), parameters);
=======
return client.Get<TResource>(client.Link(CollectionLinkName), new { id = idOrHref });
>>>>>>>
var parameters = ParameterHelper.CombineParameters(AdditionalQueryParameters, new { id = idOrHref });
return client.Get<TResource>(client.Link(CollectionLinkName), parameters); |
<<<<<<<
OctopusAsyncClient(OctopusServerEndpoint serverEndpoint, OctopusClientOptions options, bool addCertificateCallback, string requestingTool)
=======
// Use the Create method to instantiate
protected OctopusAsyncClient(OctopusServerEndpoint serverEndpoint, OctopusClientOptions options, bool addCertificateCallback, string requestingTool)
>>>>>>>
// Use the Create method to instantiate
protected OctopusAsyncClient(OctopusServerEndpoint serverEndpoint, OctopusClientOptions options, bool addCertificateCallback, string requestingTool)
<<<<<<<
=======
/// Gets a document that identifies the Octopus Server (from /api) and provides links to the resources available on the
/// server. Instead of hardcoding paths,
/// clients should use these link properties to traverse the resources on the server. This document is lazily loaded so
/// that it is only requested once for
/// the current <see cref="IOctopusAsyncClient" />.
/// </summary>
public RootResource RootDocument { get; protected set; }
/// <summary>
>>>>>>> |
<<<<<<<
public async Task Rerun(TaskResource resource)
=======
public Task<TaskTypeResource[]> GetTaskTypes()
{
return Client.Get<TaskTypeResource[]>(Client.RootDocument.Links["TaskTypes"]);
}
public Task Rerun(TaskResource resource)
>>>>>>>
public Task<TaskTypeResource[]> GetTaskTypes()
{
return Client.Get<TaskTypeResource[]>(Client.RootDocument.Links["TaskTypes"]);
}
public async Task Rerun(TaskResource resource) |
<<<<<<<
protected SpaceContext ExtendedSpaceContext { get; set; }
=======
protected SpaceQueryParameters CreateParameters(bool includeSystem, string[] spaceIds)
{
var newParameters = new SpaceQueryParameters(includeSystem, spaceIds);
ValidateSpaceParameters(newParameters);
return newParameters;
}
protected SpaceQueryParameters SpaceQueryParameters { get; set; }
>>>>>>>
protected SpaceContext ExtendedSpaceContext { get; set; }
<<<<<<<
["includeGlobal"] = ExtendedSpaceContext.IncludeSystem,
["spaces"] = ExtendedSpaceContext.SpaceIds
=======
["includeSystem"] = SpaceQueryParameters.IncludeSystem,
["spaces"] = SpaceQueryParameters.SpaceIds
>>>>>>>
["includeSystem"] = ExtendedSpaceContext.IncludeSystem,
["spaces"] = ExtendedSpaceContext.SpaceIds
<<<<<<<
=======
void ValidateSpaceParameters(SpaceQueryParameters newSpaceQueryParameters)
{
if (SpaceQueryParameters == null)
{
return;
}
if (newSpaceQueryParameters.IncludeSystem && !SpaceQueryParameters.IncludeSystem)
{
throw new InvalidIncludeSystemConfigurationException();
}
var previouslyDefinedSpaceIdsSet = new HashSet<string>(SpaceQueryParameters.SpaceIds);
if (!previouslyDefinedSpaceIdsSet.IsSupersetOf(newSpaceQueryParameters.SpaceIds))
{
throw new InvalidSpacesLimitationException();
}
}
>>>>>>> |
<<<<<<<
IScheduledProjectTriggerRepository ScheduledProjectTriggers { get; set; }
=======
ITagSetRepository TagSets { get; }
>>>>>>>
IScheduledProjectTriggerRepository ScheduledProjectTriggers { get; set; }
ITagSetRepository TagSets { get; } |
<<<<<<<
protected SpaceContext ExtendedSpaceContext { get; set; }
=======
protected SpaceQueryParameters CreateParameters(bool includeSystem, string[] spaceIds)
{
var newParameter = new SpaceQueryParameters(includeSystem, spaceIds);
ValidateSpaceParameters(newParameter);
return newParameter;
}
protected SpaceQueryParameters SpaceQueryParameters { get; set; }
>>>>>>>
protected SpaceContext ExtendedSpaceContext { get; set; }
<<<<<<<
// Server has not yet changed to includeSystem yet
["includeGlobal"] = ExtendedSpaceContext.IncludeSystem,
["spaces"] = ExtendedSpaceContext.SpaceIds
=======
["includeSystem"] = SpaceQueryParameters.IncludeSystem,
["spaces"] = SpaceQueryParameters.SpaceIds
>>>>>>>
["includeSystem"] = ExtendedSpaceContext.IncludeSystem,
["spaces"] = ExtendedSpaceContext.SpaceIds
<<<<<<<
=======
void ValidateSpaceParameters(SpaceQueryParameters newSpaceQueryParameters)
{
if (SpaceQueryParameters == null)
{
return;
}
if (newSpaceQueryParameters.IncludeSystem && !SpaceQueryParameters.IncludeSystem)
{
throw new InvalidIncludeSystemConfigurationException();
}
var previouslyDefinedSpaceIdsSet = new HashSet<string>(SpaceQueryParameters.SpaceIds);
if (!previouslyDefinedSpaceIdsSet.IsSupersetOf(newSpaceQueryParameters.SpaceIds))
{
throw new InvalidSpacesLimitationException();
}
}
>>>>>>> |
<<<<<<<
ThrowIfServerVersionIsNotCompatible().ConfigureAwait(false);
=======
>>>>>>>
<<<<<<<
ThrowIfServerVersionIsNotCompatible().ConfigureAwait(false);
=======
>>>>>>>
ThrowIfServerVersionIsNotCompatible().ConfigureAwait(false); |
<<<<<<<
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using OctopusTools.Client;
using OctopusTools.Infrastructure;
using OctopusTools.Model;
using log4net;
namespace OctopusTools.Commands
{
public class CreateReleaseCommand : ApiCommand
{
public CreateReleaseCommand(IOctopusSessionFactory sessionFactory, ILog log)
: base(sessionFactory, log)
{
DeployToEnvironmentNames = new List<string>();
}
public string ProjectName { get; set; }
public IList<string> DeployToEnvironmentNames { get; set; }
public string VersionNumber { get; set; }
public string PackageVersionNumber { get; set; }
public string ReleaseNotes { get; set; }
public bool Force { get; set; }
public override OptionSet Options
{
get
{
var options = base.Options;
options.Add("project=", "Name of the project", v => ProjectName = v);
options.Add("deployto=", "[Optional] Environment to automatically deploy to, e.g., Production", v => DeployToEnvironmentNames.Add(v));
options.Add("version=", "Version number to use for the new release.", v => VersionNumber = v);
options.Add("packageversion=", "Version number of the package to use for this release.", v => PackageVersionNumber = v);
options.Add("force", "Whether to force redeployment of already installed packages (flag, default false).", v => Force = true);
options.Add("releasenotes=", "Release Notes for the new release.", v => ReleaseNotes = v);
options.Add("releasenotesfile=", "Path to a file that contains Release Notes for the new release.", ReadReleaseNotesFromFile);
return options;
}
}
private void ReadReleaseNotesFromFile(string value)
{
try
{
ReleaseNotes = File.ReadAllText(value);
}
catch (IOException ex)
{
throw new CommandException(ex.Message);
}
}
public override void Execute()
{
if (string.IsNullOrWhiteSpace(ProjectName)) throw new CommandException("Please specify a project name using the parameter: --project=XYZ");
Log.Debug("Finding project: " + ProjectName);
var project = Session.GetProject(ProjectName);
Log.Debug("Finding environments...");
var environments = Session.FindEnvironments(DeployToEnvironmentNames);
Log.Debug("Finding steps for project...");
var steps = Session.FindStepsForProject(project);
Log.Debug("Getting package versions for each step...");
var selected = new List<SelectedPackage>();
foreach (var step in steps)
{
SelectedPackage version;
if (string.IsNullOrEmpty(PackageVersionNumber))
{
version = Session.GetLatestPackageForStep(step);
}
else
{
version = Session.GetPackageForStep(step, PackageVersionNumber);
}
Log.DebugFormat("{0} - latest: {1}", step.Description, version.NuGetPackageVersion);
selected.Add(version);
}
var versionNumber = VersionNumber;
if (string.IsNullOrWhiteSpace(versionNumber))
{
versionNumber = selected.Select(p => SemanticVersion.Parse(p.NuGetPackageVersion)).OrderByDescending(v => v).First().ToString();
Log.Warn("A --version parameter was not specified, so a version number was automatically selected based on the highest package version: " + versionNumber);
}
Log.Debug("Creating release: " + versionNumber);
var release = Session.CreateRelease(project, selected, versionNumber, ReleaseNotes);
Log.Info("Release created successfully!");
if (environments != null)
{
foreach (var environment in environments)
{
var deployment = Session.DeployRelease(release, environment, Force);
Log.InfoFormat("Successfully scheduled release '{0}' for deployment to environment '{1}'" + deployment.Name, release.Version, environment.Name);
}
}
}
}
}
=======
using System;
using System.Collections.Generic;
using System.Linq;
using OctopusTools.Client;
using OctopusTools.Infrastructure;
using OctopusTools.Model;
using log4net;
namespace OctopusTools.Commands
{
public class CreateReleaseCommand : ApiCommand
{
readonly IDeploymentWatcher deploymentWatcher;
public CreateReleaseCommand(IOctopusSession session, ILog log, IDeploymentWatcher deploymentWatcher): base(session, log)
{
this.deploymentWatcher = deploymentWatcher;
DeployToEnvironmentNames = new List<string>();
DeploymentStatusCheckSleepCycle = TimeSpan.FromSeconds(10);
DeploymentTimeout = TimeSpan.FromMinutes(4);
}
public string ProjectName { get; set; }
public IList<string> DeployToEnvironmentNames { get; set; }
public string VersionNumber { get; set; }
public string ReleaseNotes { get; set; }
public bool Force { get; set; }
public bool WaitForDeployment { get; set; }
public TimeSpan DeploymentTimeout { get; set; }
public TimeSpan DeploymentStatusCheckSleepCycle { get; set; }
public override OptionSet Options
{
get
{
var options = base.Options;
options.Add("project=", "Name of the project", v => ProjectName = v);
options.Add("deployto=", "[Optional] Environment to automatically deploy to, e.g., Production", v => DeployToEnvironmentNames.Add(v));
options.Add("version=", "Version number to use for the new release.", v => VersionNumber = v);
options.Add("force", "Whether to force redeployment of already installed packages (flag, default false).", v => Force = true);
options.Add("releasenotes=", "Release Notes for the new release.", v => ReleaseNotes = v);
options.Add("waitfordeployment", "Whether to wait synchronously for deployment to finish.", v => WaitForDeployment = true );
options.Add("deploymenttimeout=", "[Optional] Specifies maximum time that deployment can take", v => DeploymentTimeout = TimeSpan.Parse(v));
options.Add("deploymentchecksleepcycle=", "[Optional] Specifies how much time should elapse between deployment status checks", v => DeploymentStatusCheckSleepCycle = TimeSpan.Parse(v));
return options;
}
}
public override void Execute()
{
if (string.IsNullOrWhiteSpace(ProjectName)) throw new CommandException("Please specify a project name using the parameter: --project=XYZ");
Log.Debug("Finding project: " + ProjectName);
var project = Session.GetProject(ProjectName);
Log.Debug("Finding environments...");
var environments = Session.FindEnvironments(DeployToEnvironmentNames);
Log.Debug("Finding steps for project...");
var steps = Session.FindStepsForProject(project);
Log.Debug("Getting latest package versions for each step...");
var selected = new List<SelectedPackage>();
foreach (var step in steps)
{
var version = Session.GetLatestPackageForStep(step);
Log.DebugFormat("{0} - latest: {1}", step.Description, version.NuGetPackageVersion);
selected.Add(version);
}
var versionNumber = VersionNumber;
if (string.IsNullOrWhiteSpace(versionNumber))
{
versionNumber = selected.Select(p => SemanticVersion.Parse(p.NuGetPackageVersion)).OrderByDescending(v => v).First().ToString();
Log.Warn("A --version parameter was not specified, so a version number was automatically selected based on the highest package version: " + versionNumber);
}
Log.Debug("Creating release: " + versionNumber);
var release = Session.CreateRelease(project, selected, versionNumber, ReleaseNotes);
Log.Info("Release created successfully!");
if (environments != null)
{
var linksToDeploymentTasks = RequestDeployments(release, environments);
if (WaitForDeployment)
{
deploymentWatcher.WaitForDeploymentsToFinish(linksToDeploymentTasks, DeploymentTimeout, DeploymentStatusCheckSleepCycle);
}
}
}
IEnumerable<string> RequestDeployments(Release release, IEnumerable<DeploymentEnvironment> environments)
{
var linksToDeploymentTasks = new List<string>();
foreach (var environment in environments)
{
var deployment = Session.DeployRelease(release, environment, Force);
var linkToTask = deployment.Link("Task");
linksToDeploymentTasks.Add(linkToTask);
Log.InfoFormat("Successfully scheduled release '{0}' for deployment to environment '{1}'" + deployment.Name, release.Version, environment.Name);
}
return linksToDeploymentTasks;
}
}
}
>>>>>>>
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using OctopusTools.Client;
using OctopusTools.Infrastructure;
using OctopusTools.Model;
using log4net;
namespace OctopusTools.Commands
{
public class CreateReleaseCommand : ApiCommand
{
readonly IDeploymentWatcher deploymentWatcher;
public CreateReleaseCommand(IOctopusSession session, ILog log, IDeploymentWatcher deploymentWatcher): base(session, log)
{
this.deploymentWatcher = deploymentWatcher;
DeployToEnvironmentNames = new List<string>();
DeploymentStatusCheckSleepCycle = TimeSpan.FromSeconds(10);
DeploymentTimeout = TimeSpan.FromMinutes(4);
}
public string ProjectName { get; set; }
public IList<string> DeployToEnvironmentNames { get; set; }
public string VersionNumber { get; set; }
public string PackageVersionNumber { get; set; }
public string ReleaseNotes { get; set; }
public bool Force { get; set; }
public bool WaitForDeployment { get; set; }
public TimeSpan DeploymentTimeout { get; set; }
public TimeSpan DeploymentStatusCheckSleepCycle { get; set; }
public override OptionSet Options
{
get
{
var options = base.Options;
options.Add("project=", "Name of the project", v => ProjectName = v);
options.Add("deployto=", "[Optional] Environment to automatically deploy to, e.g., Production", v => DeployToEnvironmentNames.Add(v));
options.Add("version=", "Version number to use for the new release.", v => VersionNumber = v);
options.Add("packageversion=", "Version number of the package to use for this release.", v => PackageVersionNumber = v);
options.Add("force", "Whether to force redeployment of already installed packages (flag, default false).", v => Force = true);
options.Add("releasenotes=", "Release Notes for the new release.", v => ReleaseNotes = v);
options.Add("releasenotesfile=", "Path to a file that contains Release Notes for the new release.", ReadReleaseNotesFromFile);
options.Add("waitfordeployment", "Whether to wait synchronously for deployment to finish.", v => WaitForDeployment = true );
options.Add("deploymenttimeout=", "[Optional] Specifies maximum time that deployment can take", v => DeploymentTimeout = TimeSpan.Parse(v));
options.Add("deploymentchecksleepcycle=", "[Optional] Specifies how much time should elapse between deployment status checks", v => DeploymentStatusCheckSleepCycle = TimeSpan.Parse(v));
return options;
}
}
private void ReadReleaseNotesFromFile(string value)
{
try
{
ReleaseNotes = File.ReadAllText(value);
}
catch (IOException ex)
{
throw new CommandException(ex.Message);
}
}
public override void Execute()
{
if (string.IsNullOrWhiteSpace(ProjectName)) throw new CommandException("Please specify a project name using the parameter: --project=XYZ");
Log.Debug("Finding project: " + ProjectName);
var project = Session.GetProject(ProjectName);
Log.Debug("Finding environments...");
var environments = Session.FindEnvironments(DeployToEnvironmentNames);
Log.Debug("Finding steps for project...");
var steps = Session.FindStepsForProject(project);
Log.Debug("Getting package versions for each step...");
var selected = new List<SelectedPackage>();
foreach (var step in steps)
{
SelectedPackage version;
if (string.IsNullOrEmpty(PackageVersionNumber))
{
version = Session.GetLatestPackageForStep(step);
}
else
{
version = Session.GetPackageForStep(step, PackageVersionNumber);
}
Log.DebugFormat("{0} - latest: {1}", step.Description, version.NuGetPackageVersion);
selected.Add(version);
}
var versionNumber = VersionNumber;
if (string.IsNullOrWhiteSpace(versionNumber))
{
versionNumber = selected.Select(p => SemanticVersion.Parse(p.NuGetPackageVersion)).OrderByDescending(v => v).First().ToString();
Log.Warn("A --version parameter was not specified, so a version number was automatically selected based on the highest package version: " + versionNumber);
}
Log.Debug("Creating release: " + versionNumber);
var release = Session.CreateRelease(project, selected, versionNumber, ReleaseNotes);
Log.Info("Release created successfully!");
if (environments != null)
{
var linksToDeploymentTasks = RequestDeployments(release, environments);
if (WaitForDeployment)
{
deploymentWatcher.WaitForDeploymentsToFinish(linksToDeploymentTasks, DeploymentTimeout, DeploymentStatusCheckSleepCycle);
}
}
}
IEnumerable<string> RequestDeployments(Release release, IEnumerable<DeploymentEnvironment> environments)
{
var linksToDeploymentTasks = new List<string>();
foreach (var environment in environments)
{
var deployment = Session.DeployRelease(release, environment, Force);
var linkToTask = deployment.Link("Task");
linksToDeploymentTasks.Add(linkToTask);
Log.InfoFormat("Successfully scheduled release '{0}' for deployment to environment '{1}'" + deployment.Name, release.Version, environment.Name);
}
return linksToDeploymentTasks;
}
}
} |
<<<<<<<
public class FeedResource : Resource, INamedResource, IHaveSpaceResource
=======
/// <summary>
/// The FeedResource type has been deprecated on Octopus Deploy 3.5 servers. Use NuGetFeedResource instead")]
/// </summary>
public class FeedResource : Resource, INamedResource
>>>>>>>
/// <summary>
/// The FeedResource type has been deprecated on Octopus Deploy 3.5 servers. Use NuGetFeedResource instead")]
/// </summary>
public class FeedResource : Resource, INamedResource, IHaveSpaceResource
<<<<<<<
public string SpaceId { get; set; }
=======
/// <summary>
/// The package-acquisition locations supported by the feed.
/// The first is considered the default.
/// </summary>
public IList<PackageAcquisitionLocation> PackageAcquisitionLocationOptions { get; } = new List<PackageAcquisitionLocation>();
>>>>>>>
public string SpaceId { get; set; }
/// <summary>
/// The package-acquisition locations supported by the feed.
/// The first is considered the default.
/// </summary>
public IList<PackageAcquisitionLocation> PackageAcquisitionLocationOptions { get; } = new List<PackageAcquisitionLocation>(); |
<<<<<<<
if (!ROS.ok || shutting_down) return;
Publication p = lookupPublicationWithoutLock(topic);
=======
Publication p;
if ((p = lookupPublicationWithoutLock(topic)) == null || shutting_down) return;
>>>>>>>
if (!ROS.ok || shutting_down) return;
if ((p = lookupPublicationWithoutLock(topic)) == null || shutting_down) return; |
<<<<<<<
private const int back_cam = 1;
private const int front_cam = 0;
=======
//Stopwatch
Stopwatch sw = new Stopwatch();
>>>>>>>
private const int back_cam = 1;
private const int front_cam = 0;
//Stopwatch
Stopwatch sw = new Stopwatch();
<<<<<<<
_trans.Label = "Linear Max Vel";
_trans.Max = 2.0;
_trans.Min = 0.0;
_trans.Value = 0.5;
_rot.Label = "Angular Max Vel";
_rot.Max = 3.14;
_rot.Min = 0.0;
_rot.Value = 0.5;
=======
// ROS stuff
ROS.ROS_MASTER_URI = "http://10.0.3.88:11311";
ROS.Init(new string[0], "The_UI");
nh = new NodeHandle();
armGauge.startListening(nh);
battvolt.startListening(nh);
EStop.startListening(nh);
velPub = nh.advertise<gm.Twist>("/cmd_vel", 1);
multiplexPub = nh.advertise<m.Byte>("/cam_select", 1);
>>>>>>>
_trans.Label = "Linear Max Vel";
_trans.Max = 2.0;
_trans.Min = 0.0;
_trans.Value = 0.5;
_rot.Label = "Angular Max Vel";
_rot.Max = 3.14;
_rot.Min = 0.0;
_rot.Value = 0.5;
<<<<<<<
// run this ring stuff once when button is pressed
=======
>>>>>>>
<<<<<<<
=======
>>>>>>>
<<<<<<<
=======
>>>>>>> |
<<<<<<<
{
ROS.ROS_MASTER_URI = "http://10.0.2.182:11311";
=======
{
ROS.ROS_MASTER_URI = "http://10.0.2.42:11311";
>>>>>>>
{
ROS.ROS_MASTER_URI = "http://10.0.2.182:11311";
<<<<<<<
// ROS.ROS_HOSTNAME = "10.0.2.163";
=======
ROS.ROS_HOSTNAME = "10.0.2.82";
>>>>>>>
// ROS.ROS_HOSTNAME = "10.0.2.163";
<<<<<<<
Dispatcher.Invoke(new Action(() =>
{
lastt = new Touch();
scale = new ScaleTransform();
translate = new TranslateTransform();
TransformGroup group = new TransformGroup();
group.Children.Add(scale);
group.Children.Add(translate);
SubCanvas.RenderTransform = group;
n = DateTime.Now;
lastupdown = DateTime.Now;
}));
=======
lastt = new Touch();
scale = new ScaleTransform();
translate = new TranslateTransform();
dotscale = new ScaleTransform();
dottranslate = new TranslateTransform();
TransformGroup group = new TransformGroup();
TransformGroup dotgroup = new TransformGroup();
group.Children.Add(scale);
group.Children.Add(translate);
dotgroup.Children.Add(dotscale);
dotgroup.Children.Add(dottranslate);
SubCanvas.RenderTransform = group;
DotCanvas.RenderTransform = dotgroup;
n = DateTime.Now;
lastupdown = DateTime.Now;
AddRobot();
timers.StartTimer(ref YellowTimer, YellowTimer_Tick, 0, 10);
timers.StartTimer(ref GreenTimer, GreenTimer_Tick, 0, 5);
timers.MakeTimer(ref RM5Timer, RM5Timer_Tick, TimeDT, Timeout.Infinite);
numRobots = 1;
for (int i = 0; i < turboFingering.Length; i++)
timers.MakeTimer(ref turboFingering[i], fingerHandler, i, 600, Timeout.Infinite);
>>>>>>>
Dispatcher.Invoke(new Action(() =>
{
lastt = new Touch();
scale = new ScaleTransform();
translate = new TranslateTransform();
dotscale = new ScaleTransform();
dottranslate = new TranslateTransform();
TransformGroup group = new TransformGroup();
TransformGroup dotgroup = new TransformGroup();
group.Children.Add(scale);
group.Children.Add(translate);
dotgroup.Children.Add(dotscale);
dotgroup.Children.Add(dottranslate);
SubCanvas.RenderTransform = group;
DotCanvas.RenderTransform = dotgroup;
n = DateTime.Now;
lastupdown = DateTime.Now;
AddRobot();
timers.StartTimer(ref YellowTimer, YellowTimer_Tick, 0, 10);
timers.StartTimer(ref GreenTimer, GreenTimer_Tick, 0, 5);
timers.MakeTimer(ref RM5Timer, RM5Timer_Tick, TimeDT, Timeout.Infinite);
numRobots = 1;
for (int i = 0; i < turboFingering.Length; i++)
timers.MakeTimer(ref turboFingering[i], fingerHandler, i, 600, Timeout.Infinite);
}));
timers.StartTimer(ref YellowTimer, YellowTimer_Tick, 0, 10);
timers.StartTimer(ref GreenTimer, GreenTimer_Tick, 0, 5);
timers.MakeTimer(ref RM5Timer, RM5Timer_Tick, TimeDT, Timeout.Infinite);
numRobots = 1;
for (int i = 0; i < turboFingering.Length; i++)
timers.MakeTimer(ref turboFingering[i], fingerHandler, i, 600, Timeout.Infinite); |
<<<<<<<
toDebugInstead = false;
=======
>>>>>>>
toDebugInstead = false;
<<<<<<<
if (printit)
EDB.WriteLine(ROSOUT_FMAT, ROSOUT_PREFIX[level], o);
RosOutAppender.Instance.Append(o.ToString(), level);
=======
if (printit)
EDB.WriteLine(ROSOUT_FMAT, ROSOUT_PREFIX[level], o);
RosOutAppender.Instance.Append(o.ToString(), level);
>>>>>>>
if (printit)
EDB.WriteLine(ROSOUT_FMAT, ROSOUT_PREFIX[level], o);
RosOutAppender.Instance.Append(o.ToString(), level); |
<<<<<<<
using Serilog;
using System;
using System.Threading;
=======
using System;
using System.Threading;
>>>>>>>
using Serilog;
using System;
using System.Threading;
<<<<<<<
private IntPtr Wow;
private Random rand;
private int a_CastingDelay = 0;
private int a_LootingDelay = 0;
=======
private IntPtr Wow;
>>>>>>>
private IntPtr Wow;
private Random rand;
private int a_CastingDelay = 0;
private int a_LootingDelay = 0;
<<<<<<<
if (Properties.Settings.Default.RightClickCast) {
Win32.SendMouseDblRightClick(this.Wow);
} else {
Win32.SendKey(Properties.Settings.Default.FishKey);
Log.Information("Sent key: " + Properties.Settings.Default.FishKey);
}
Random rnd = new Random();
a_CastingDelay = rnd.Next(Properties.Settings.Default.CastingDelayLow, Properties.Settings.Default.CastingDelayHigh);
await Task.Delay(a_CastingDelay, token);
=======
Win32.ActivateWow(this.Wow);
if (Properties.Settings.Default.RightClickCast)
{
Win32.SendMouseDblRightClick(this.Wow);
}
else
{
Win32.SendKey(Properties.Settings.Default.FishKey);
}
await Task.Delay(Properties.Settings.Default.CastingDelay, token);
>>>>>>>
if (Properties.Settings.Default.RightClickCast) {
Win32.SendMouseDblRightClick(this.Wow);
} else {
Win32.SendKey(Properties.Settings.Default.FishKey);
Log.Information("Sent key: " + Properties.Settings.Default.FishKey);
}
Random rnd = new Random();
a_CastingDelay = rnd.Next(Properties.Settings.Default.CastingDelayLow, Properties.Settings.Default.CastingDelayHigh);
await Task.Delay(a_CastingDelay, token);
<<<<<<<
Log.Information("Send key start: " + actionKey);
Win32.ActivateWow(this.Wow);
await Task.Delay(1000, cancellationToken);
=======
Win32.ActivateWow(this.Wow);
>>>>>>>
Log.Information("Send key start: " + actionKey);
Win32.ActivateWow(this.Wow);
await Task.Delay(1000, cancellationToken); |
<<<<<<<
public bool Initialize { get; set; }
public System.Text.Encoding FileEncoding { get; set; }
}
=======
public string ConfigurationFile { get; set; }
}
>>>>>>>
public bool Initialize { get; set; }
public string ConfigurationFile { get; set; }
public System.Text.Encoding FileEncoding { get; set; }
} |
<<<<<<<
using migrators;
=======
using environments;
>>>>>>>
using migrators;
using environments; |
<<<<<<<
using System.Reflection;
using log4net.Repository;
using log4net.Core;
=======
using Newtonsoft.Json;
using System.Collections.Generic;
>>>>>>>
using System.Reflection;
using log4net.Repository;
using Newtonsoft.Json;
using System.Collections.Generic;
using log4net.Core;
<<<<<<<
.Add("isuptodate",
"This option prints whether there are any database updates or not, whithout actually running them. Other output except errors is disabled, to make it easy to use in scripts.",
option => { })
.Add("fileencoding=",
"File Encoding - Explicitly specify the file encoding of all files",
option =>
{
if(option != null)
{
configuration.FileEncoding = System.Text.Encoding.GetEncoding(option);
}
})
=======
//load configuration from file
.Add("cf=|configfile=|configurationfile=",
"Loads configuration options from a JSON file",
option => configuration.ConfigurationFile = option)
>>>>>>>
.Add("isuptodate",
"This option prints whether there are any database updates or not, whithout actually running them. Other output except errors is disabled, to make it easy to use in scripts.",
option => { })
.Add("fileencoding=",
"File Encoding - Explicitly specify the file encoding of all files",
option =>
{
if(option != null)
{
configuration.FileEncoding = System.Text.Encoding.GetEncoding(option);
}
})
//load configuration from file
.Add("cf=|configfile=|configurationfile=",
"Loads configuration options from a JSON file",
option => configuration.ConfigurationFile = option) |
<<<<<<<
namespace roundhouse.databases.mysql
=======
using roundhouse.consoles;
using roundhouse.infrastructure.logging;
namespace roundhouse.databases.mysql
>>>>>>>
using roundhouse.consoles;
namespace roundhouse.databases.mysql |
<<<<<<<
public static ExiledVersion Version = new ExiledVersion { Major = 1, Minor = 10, Patch = 0 };
=======
public bool TestingEnabled;
public bool AutoUpdateEnabled;
public static ExiledVersion Version = new ExiledVersion
{
Major = 2,
Minor = 0,
Patch = 0
};
>>>>>>>
public bool TestingEnabled;
public bool AutoUpdateEnabled;
public static ExiledVersion Version = new ExiledVersion
{
Major = 2,
Minor = 0,
Patch = 0
};
<<<<<<<
public static bool CmdSyncDataEventDisable;
public static bool GrenadeExplosionEventDisabled;
public static bool WarheadKeycardAccessEventDisable;
public static bool Scp079ExpGainEventDisable;
public static bool ElevatorInteractionEventDisable;
public static bool Scp106CreatedPortalEventDisable;
public static bool LockerInteractEventPatchDisable;
public static bool Scp106PocketDimensionDamageEventPatchDisable;
public static bool Scp106TeleportEventPatchDisable;
public static bool PocketDimensionEscapedEventPatchDisabled;
public static bool Scp914ActivationEventPatchDisabled;
public static bool Scp914KnobChangeEventPatchDisable;
public static bool WarheadStartEventPatchDisable;
public static bool LateShootEventPatchDisable;
public static bool GeneratorFinishedEventPatchDisable;
public static bool CancelMedicalEventPatchDisable;
public static bool PreAuthEventPatchDisable;
#endregion
private EventHandlers handlers;
//The below variable is used to increment the name of the harmony instance, otherwise harmony will not work upon a plugin reload.
private static int patchFixer;
=======
public static bool CmdSyncDataEventDisable;
public static bool GrenadeExplosionEventDisabled;
public static bool WarheadKeycardAccessEventDisable;
public static bool Scp079ExpGainEventDisable;
private EventHandlers handlers;
private CommandHandler commands;
//The below variable is used to incriment the name of the harmony instance, otherwise harmony will not work upon a plugin reload.
private static int _patchFixer;
>>>>>>>
public static bool CmdSyncDataEventDisable;
public static bool GrenadeExplosionEventDisabled;
public static bool WarheadKeycardAccessEventDisable;
public static bool Scp079ExpGainEventDisable;
public static bool ElevatorInteractionEventDisable;
public static bool Scp106CreatedPortalEventDisable;
public static bool LockerInteractEventPatchDisable;
public static bool Scp106PocketDimensionDamageEventPatchDisable;
public static bool Scp106TeleportEventPatchDisable;
public static bool PocketDimensionEscapedEventPatchDisabled;
public static bool Scp914ActivationEventPatchDisabled;
public static bool Scp914KnobChangeEventPatchDisable;
public static bool WarheadStartEventPatchDisable;
public static bool LateShootEventPatchDisable;
public static bool GeneratorFinishedEventPatchDisable;
public static bool CancelMedicalEventPatchDisable;
public static bool PreAuthEventPatchDisable;
#endregion
private EventHandlers handlers;
private CommandHandler commands;
//The below variable is used to incriment the name of the harmony instance, otherwise harmony will not work upon a plugin reload.
private static int _patchFixer;
<<<<<<<
Log.Info(Environment.CurrentDirectory);
Log.Info("Enabled.");
Log.Info($"Checking version status...");
ServerConsole.AddLog($"ServerMod - Version {Version.Major}.{Version.Minor}.{Version.Patch}-EXILED LOGTYPE-8");
if (Config.GetBool("exiled_auto_update", true))
=======
Log.Info($"Checking version status..");
Log.Info($"ServerMod - Version {Version.Major}.{Version.Minor}.{Version.Patch}-EXILED");
if (AutoUpdateEnabled)
>>>>>>>
Log.Info(Environment.CurrentDirectory);
Log.Info("Enabled.");
Log.Info($"Checking version status...");
ServerConsole.AddLog($"ServerMod - Version {Version.Major}.{Version.Minor}.{Version.Patch}-EXILED LOGTYPE-8");
if (Config.GetBool("exiled_auto_update", true))
<<<<<<<
ReloadConfigs();
Log.Debug("Adding Event Handlers...");
=======
Log.Debug("Adding Event Handlers..");
>>>>>>>
ReloadConfigs();
Log.Debug("Adding Event Handlers...");
<<<<<<<
=======
commands = new CommandHandler(this);
>>>>>>>
<<<<<<<
public static void ReloadConfigs()
{
Scp173Fix = Config.GetBool("exiled_tut_fix173", true);
Scp096Fix = Config.GetBool("exiled_tut_fix096", true);
NameTracking = Config.GetBool("exiled_name_tracking", true);
DropInventory = Config.GetBool("exiled_drop_inventory", true);
RemoveBloodPlacement = Config.GetBool("exiled_remove_blood_placement");
AntiFlyThreashold = Config.GetInt("exiled_antifly_threashold", 5);
}
=======
>>>>>>>
public static void ReloadConfigs()
{
Scp173Fix = Config.GetBool("exiled_tut_fix173", true);
Scp096Fix = Config.GetBool("exiled_tut_fix096", true);
NameTracking = Config.GetBool("exiled_name_tracking", true);
DropInventory = Config.GetBool("exiled_drop_inventory", true);
RemoveBloodPlacement = Config.GetBool("exiled_remove_blood_placement");
AntiFlyThreashold = Config.GetInt("exiled_antifly_threashold", 5);
}
<<<<<<<
public static void DeleteDirectory(string target_dir)
=======
public static void DeleteDirectory(string targetDir)
>>>>>>>
public static void DeleteDirectory(string targetDir)
<<<<<<<
Log.Debug("Unpatching...");
=======
commands = null;
Log.Debug("Unpatching..");
>>>>>>>
Log.Debug("Unpatching...");
<<<<<<<
public override void OnReload() => Log.Info("Reloading.");
public override string getName { get; }
=======
public override void OnReload() {}
public override void ReloadConfig()
{
TestingEnabled = Config.GetBool($"{ConfigPrefix}testing");
AutoUpdateEnabled = Config.GetBool("exiled_auto_update", true);
Scp173Fix = Config.GetBool("exiled_tut_fix173", true);
Scp096Fix = Config.GetBool("exiled_tut_fix096", true);
NameTracking = Config.GetBool("exiled_name_tracking", true);
}
>>>>>>>
public override void OnReload() => Log.Info("Reloading.");
public override string getName { get; }
<<<<<<<
try
=======
string url = "https://github.com/galaxy119/EXILED/releases/";
url += TestingEnabled ? "" : "latest/";
HttpWebRequest request = (HttpWebRequest) WebRequest.Create($"{url}");
HttpWebResponse response = (HttpWebResponse) request.GetResponse();
Stream stream = response.GetResponseStream();
if (stream == null)
{
throw new InvalidOperationException("No response from Github. This shouldn't happen, yell at Joker.");
}
StreamReader reader = new StreamReader(stream);
string read = reader.ReadToEnd();
string[] readArray = read.Split(new[] { Environment.NewLine }, StringSplitOptions.None);
string line = readArray.FirstOrDefault(s => s.Contains("EXILED.tar.gz"));
string version = Between(line, "/galaxy119/EXILED/releases/download/", "/EXILED.tar.gz");
string[] versionArray = version.Split('.');
if (!int.TryParse(versionArray[0], out int major))
>>>>>>>
try |
<<<<<<<
public class SCP914UpgradeEvent : EventArgs
{
public bool Allow;
public Scp914.Scp914Machine Machine;
public List<ReferenceHub> Players;
public List<Pickup> Items;
public Scp914.Scp914Knob KnobSetting;
}
=======
public class Scp914UpgradeEvent : EventArgs
{
public bool Allow { get; set; }
public Scp914Machine Machine { get; internal set; }
public List<ReferenceHub> Players { get; set; }
public List<Pickup> Items { get; set; }
public Scp914Knob KnobSetting { get; set; }
}
>>>>>>>
public class Scp914UpgradeEvent : EventArgs
{
public bool Allow { get; set; }
public Scp914Machine Machine { get; internal set; }
public List<ReferenceHub> Players { get; set; }
public List<Pickup> Items { get; set; }
public Scp914Knob KnobSetting { get; set; }
}
<<<<<<<
{
get => info;
=======
{
get => info;
>>>>>>>
{
get => info;
<<<<<<<
public ReferenceHub Player { get; set; }
public bool IsInHurtingRange { get; internal set; }
=======
public ReferenceHub Player { get; internal set; }
>>>>>>>
public ReferenceHub Player { get; internal set; }
public bool IsInHurtingRange { get; internal set; }
<<<<<<<
public ReferenceHub Player { get; set; }
public ItemType Item { get; set; }
public float Cooldown { get; set; }
=======
public ReferenceHub Player { get; internal set; }
public ItemType Item { get; internal set; }
>>>>>>>
public ReferenceHub Player { get; internal set; }
public ItemType Item { get; internal set; }
public float Cooldown { get; set; }
<<<<<<<
public readonly ReferenceHub Player;
public readonly Locker Locker;
public readonly int LockerId;
//Shoud be put as a properties and not in the constructor
public LockerInteractionEvent(ReferenceHub player, Locker locker, int lockerId)
{
Player = player;
Locker = locker;
LockerId = lockerId;
}
=======
public ReferenceHub Player { get; internal set; }
public Locker Locker { get; internal set; }
public int LockerId { get; internal set; }
>>>>>>>
public ReferenceHub Player { get; internal set; }
public Locker Locker { get; internal set; }
public int LockerId { get; internal set; }
<<<<<<<
public ConsoleCommandEvent(bool encrypted)
{
Encrypted = encrypted;
}
public ReferenceHub Player { get; set; }
public string Command { get; set; }
=======
public ConsoleCommandEvent(bool encrypted) => Encrypted = encrypted;
public ReferenceHub Player { get; internal set; }
public string Command { get; internal set; }
>>>>>>>
public ConsoleCommandEvent(bool encrypted) => Encrypted = encrypted;
public ReferenceHub Player { get; internal set; }
public string Command { get; internal set; }
<<<<<<<
get => bannedPlayer;
}
public ReferenceHub Issuer
{
set
{
if (value == null || issuer == value) return;
if (log)
LogBanChange(Assembly.GetCallingAssembly().GetName().Name
+ $" changed the ban issuer from user {issuer.nicknameSync.Network_myNickSync} ({issuer.characterClassManager.UserId}) to {value.nicknameSync.Network_myNickSync} ({value.characterClassManager.UserId})");
issuer = value;
}
get => issuer;
=======
get => bannedPlayer;
>>>>>>>
get => bannedPlayer;
}
public ReferenceHub Issuer
{
set
{
if (value == null || issuer == value) return;
if (log)
LogBanChange(Assembly.GetCallingAssembly().GetName().Name
+ $" changed the ban issuer from user {issuer.nicknameSync.Network_myNickSync} ({issuer.characterClassManager.UserId}) to {value.nicknameSync.Network_myNickSync} ({value.characterClassManager.UserId})");
issuer = value;
}
get => issuer;
<<<<<<<
ServerLogs._write = true;
=======
>>>>>>>
ServerLogs._write = true;
<<<<<<<
public class SyncDataEvent : EventArgs
{
public ReferenceHub Player;
public int State;
public Vector2 v2;
public bool Allow { get; set; }
}
public class WarheadKeycardAccessEvent : EventArgs
{
public ReferenceHub Player;
public bool Allow;
public string RequiredPerms;
}
public class Scp079ExpGainEvent : EventArgs
{
public ReferenceHub Player;
public bool Allow;
public ExpGainType GainType;
public float Amount;
}
public class Scp079LvlGainEvent : EventArgs
{
public ReferenceHub Player;
public bool Allow;
public int OldLvl;
public int NewLvl;
}
public class WarheadCancelEvent : EventArgs
{
public ReferenceHub Player;
public bool Allow;
}
public class WarheadStartEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow;
}
public class ItemChangedEvent : EventArgs
{
public ReferenceHub Player;
public Inventory.SyncItemInfo OldItem;
public Inventory.SyncItemInfo NewItem;
}
public class Scp106CreatedPortalEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public Vector3 PortalPosition { get; set; }
}
public class AnnounceNtfEntranceEvent : EventArgs
{
public int ScpsLeft { get; set; }
public int NtfNumber { get; set; }
public char NtfLetter { get; set; }
public bool Allow { get; set; }
}
public class AnnounceScpTerminationEvent : EventArgs
{
public ReferenceHub Killer { get; internal set; }
public Role Role { get; internal set; }
public PlayerStats.HitInfo HitInfo { get; set; }
public string TerminationCause { get; set; }
public bool Allow { get; set; }
}
public class AnnounceDecontaminationEvent : EventArgs
{
private int announcementId;
public int AnnouncementId
{
get => announcementId;
set => announcementId = Mathf.Clamp(value, 0, 5);
}
public bool IsAnnouncementGlobal { get; set; }
public bool Allow { get; set; }
}
public class SpawnRagdollEvent : EventArgs
{
private int ragdollPlayerId;
public ReferenceHub Killer { get; internal set; }
public ReferenceHub Player { get; internal set; }
public Vector3 Position { get; set; }
public Quaternion Rotation { get; set; }
public RoleType RoleType { get; set; }
public PlayerStats.HitInfo HitInfo { get; set; }
public bool AllowRecall { get; set; }
public string RagdollDissonanceId { get; set; }
public string RagdollPlayerName { get; set; }
public int RagdollPlayerId
{
get => ragdollPlayerId;
set
{
if (Extensions.Player.GetPlayer(value) == null)
return;
ragdollPlayerId = value;
}
}
public bool Allow { get; set; }
}
public class PlayerInteractEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
}
public class PlaceBloodEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public Vector3 Position { get; set; }
public int BloodType { get; set; }
public float Multiplier { get; set; }
public bool Allow { get; set; }
}
public class UsedMedicalItemEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public ItemType ItemType { get; internal set; }
}
public class PlaceDecalEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public Vector3 Position { get; set; }
public Quaternion Rotation { get; set; }
public int Type { get; set; }
public bool Allow { get; set; }
}
=======
public class SyncDataEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public int State { get; set; }
public Vector2 V2 { get; set; }
public bool Allow { get; set; }
}
public class WarheadKeycardAccessEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public string RequiredPerms { get; set; }
}
public class Scp079ExpGainEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public ExpGainType GainType { get; set; }
public float Amount { get; set; }
}
public class Scp079LvlGainEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public int OldLvl { get; internal set; }
public int NewLvl { get; set; }
}
public class WarheadCancelEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
}
public class WarheadStartEvent : EventArgs
{
public bool Allow { get; set; }
}
public class ItemChangedEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public Inventory.SyncItemInfo OldItem { get; internal set; }
public Inventory.SyncItemInfo NewItem { get; set; }
}
>>>>>>>
public class SyncDataEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public int CurrentAnimation { get; set; }
public Vector2 Speed { get; set; }
public bool Allow { get; set; }
}
public class WarheadKeycardAccessEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public List<string> RequiredPermissions { get; set; }
}
public class Scp079ExpGainEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public ExpGainType GainType { get; set; }
public float Amount { get; set; }
}
public class Scp079LvlGainEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public int OldLvl { get; internal set; }
public int NewLvl { get; set; }
}
public class WarheadCancelEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
}
public class WarheadStartEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; };
}
public class ItemChangedEvent : EventArgs
{
public ReferenceHub Player;
public Inventory.SyncItemInfo OldItem;
public Inventory.SyncItemInfo NewItem;
}
public class Scp106CreatedPortalEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public bool Allow { get; set; }
public Vector3 PortalPosition { get; set; }
}
public class AnnounceNtfEntranceEvent : EventArgs
{
public int ScpsLeft { get; set; }
public int NtfNumber { get; set; }
public char NtfLetter { get; set; }
public bool Allow { get; set; }
}
public class AnnounceScpTerminationEvent : EventArgs
{
public ReferenceHub Killer { get; internal set; }
public Role Role { get; internal set; }
public PlayerStats.HitInfo HitInfo { get; set; }
public string TerminationCause { get; set; }
public bool Allow { get; set; }
}
public class AnnounceDecontaminationEvent : EventArgs
{
private int announcementId;
public int AnnouncementId
{
get => announcementId;
set => announcementId = Mathf.Clamp(value, 0, 5);
}
public bool IsAnnouncementGlobal { get; set; }
public bool Allow { get; set; }
}
public class SpawnRagdollEvent : EventArgs
{
private int ragdollPlayerId;
public ReferenceHub Killer { get; internal set; }
public ReferenceHub Player { get; internal set; }
public Vector3 Position { get; set; }
public Quaternion Rotation { get; set; }
public RoleType RoleType { get; set; }
public PlayerStats.HitInfo HitInfo { get; set; }
public bool AllowRecall { get; set; }
public string RagdollDissonanceId { get; set; }
public string RagdollPlayerName { get; set; }
public int RagdollPlayerId
{
get => ragdollPlayerId;
set
{
if (Extensions.Player.GetPlayer(value) == null)
return;
ragdollPlayerId = value;
}
}
public bool Allow { get; set; }
}
public class PlayerInteractEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
}
public class PlaceBloodEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public Vector3 Position { get; set; }
public int BloodType { get; set; }
public float Multiplier { get; set; }
public bool Allow { get; set; }
}
public class UsedMedicalItemEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public ItemType ItemType { get; internal set; }
}
public class PlaceDecalEvent : EventArgs
{
public ReferenceHub Player { get; internal set; }
public Vector3 Position { get; set; }
public Quaternion Rotation { get; set; }
public int Type { get; set; }
public bool Allow { get; set; }
} |
<<<<<<<
/// Invoked before triggering a speaker with SCP-079.
/// </summary>
public static event CustomEventHandler<StartingSpeakerEventArgs> StartingSpeaker;
/// <summary>
/// Invoked before stopping a speaker with SCP-079.
/// </summary>
public static event CustomEventHandler<StoppingSpeakerEventArgs> StoppingSpeaker;
/// <summary>
=======
/// Invoked after Scp079 recontainment.
/// </summary>
public static event CustomEventHandler<RecontainedEventArgs> Recontained;
/// <summary>
>>>>>>>
/// Invoked before triggering a speaker with SCP-079.
/// </summary>
public static event CustomEventHandler<StartingSpeakerEventArgs> StartingSpeaker;
/// <summary>
/// Invoked before stopping a speaker with SCP-079.
/// </summary>
public static event CustomEventHandler<StoppingSpeakerEventArgs> StoppingSpeaker;
/// <summary>
/// Invoked after Scp079 recontainment.
/// </summary>
public static event CustomEventHandler<RecontainedEventArgs> Recontained;
/// <summary>
<<<<<<<
/// <summary>
/// Invoked before interacting with a speaker with SCP-079.
/// </summary>
/// <param name="ev">The <see cref="StartingSpeakerEventArgs"/> instance.</param>
public static void OnStartingSpeaker(StartingSpeakerEventArgs ev) => StartingSpeaker.InvokeSafely(ev);
/// <summary>
/// Invoked before stopping with a speaker with SCP-079.
/// </summary>
/// <param name="ev">The <see cref="StoppingEventArgs"/> instance.</param>
public static void OnStoppingSpeaker(StoppingSpeakerEventArgs ev) => StoppingSpeaker.InvokeSafely(ev);
=======
/// <summary>
/// Called after 079 recontainment.
/// </summary>
/// <param name="ev">The <see cref="RecontainedEventArgs"/> instance.</param>
public static void OnRecontained(RecontainedEventArgs ev) => Recontained.InvokeSafely(ev);
>>>>>>>
/// <summary>
/// Invoked before interacting with a speaker with SCP-079.
/// </summary>
/// <param name="ev">The <see cref="StartingSpeakerEventArgs"/> instance.</param>
public static void OnStartingSpeaker(StartingSpeakerEventArgs ev) => StartingSpeaker.InvokeSafely(ev);
/// <summary>
/// Invoked before stopping with a speaker with SCP-079.
/// </summary>
/// <param name="ev">The <see cref="StoppingEventArgs"/> instance.</param>
public static void OnStoppingSpeaker(StoppingSpeakerEventArgs ev) => StoppingSpeaker.InvokeSafely(ev);
/// <summary>
/// Called after 079 recontainment.
/// </summary>
/// <param name="ev">The <see cref="RecontainedEventArgs"/> instance.</param>
public static void OnRecontained(RecontainedEventArgs ev) => Recontained.InvokeSafely(ev); |
<<<<<<<
=======
>>>>>>>
<<<<<<<
/// <summary>
/// Gets the HintDisplay of the players ReferenceHub.
/// </summary>
/// <returns>Returns Hintdisplay of ReferenceHub.</returns>
public HintDisplay GetHintDisplay()
{
return ReferenceHub.hints;
}
/// <summary>
/// Simple way to show a hint to the player.
/// </summary>
/// <param name="message">The message to be shown.</param>
/// <param name="duration">The duration the text will be on screen.</param>
public void ShowHint(string message, float duration = 3f)
=======
/// <summary>
/// Gets the HintDisplay of the players ReferenceHub.
/// </summary>
public HintDisplay HintDisplay => ReferenceHub.hints;
/// <summary>
/// Simple way to show a hint to the player.
/// </summary>
/// <param name="message">The message to be shown.</param>
/// <param name="duration">The duration the text will be on screen.</param>
public void ShowHint(string message,float duration = 3f)
>>>>>>>
/// <summary>
/// Gets the HintDisplay of the players ReferenceHub.
/// </summary>
/// <returns>Returns the HintDisplay of ReferenceHub.</returns>
public HintDisplay GetHintDisplay()
{
return ReferenceHub.hints;
}
/// <summary>
/// Simple way to show a hint to the player.
/// </summary>
/// <param name="message">The message to be shown.</param>
/// <param name="duration">The duration the text will be on screen.</param>
public void ShowHint(string message, float duration = 3f) |
<<<<<<<
/// <summary>
/// Returns the list of players in this room.
/// </summary>
/// <returns>List of <see cref="ReferenceHub"/></returns>
public static List<ReferenceHub> GetHubs(this Room room) =>ReferenceHub.Hubs.Values.Where(h => !h.IsHost() && h.GetCurrentRoom().Name == room.Name).ToList();
=======
/// <summary>
/// Gets the number of activated generators.
/// </summary>
/// <returns></returns>
public static int ActivatedGenerators => Generator079.mainGenerator.totalVoltage;
/// <summary>
/// Turns off all lights of the facility (except for the entrance zone).
/// </summary>
/// <param name="duration"></param>
/// <param name="onlyHeavy"></param>
public static void TurnOffAllLights(float duration, bool onlyHeavy = false) => Generator079.generators[0].RpcCustomOverchargeForOurBeautifulModCreators(duration, onlyHeavy);
>>>>>>>
/// <summary>
/// Returns the list of players in this room.
/// </summary>
/// <returns>List of <see cref="ReferenceHub"/></returns>
public static List<ReferenceHub> GetHubs(this Room room) =>ReferenceHub.Hubs.Values.Where(h => !h.IsHost() && h.GetCurrentRoom().Name == room.Name).ToList();
/// Gets the number of activated generators.
/// </summary>
/// <returns></returns>
public static int ActivatedGenerators => Generator079.mainGenerator.totalVoltage;
/// <summary>
/// Turns off all lights of the facility (except for the entrance zone).
/// </summary>
/// <param name="duration"></param>
/// <param name="onlyHeavy"></param>
public static void TurnOffAllLights(float duration, bool onlyHeavy = false) => Generator079.generators[0].RpcCustomOverchargeForOurBeautifulModCreators(duration, onlyHeavy); |
<<<<<<<
var handlerInvokers = await ((Task<HandlerInvokers>)methodToInvoke.Invoke(this, new[] { body, transactionContext, message })).ConfigureAwait(false);
=======
var handlerInvokers = await ((Task<HandlerInvokers>)methodToInvoke.Invoke(this, new[] { messageId, body, transactionContext, message }));
>>>>>>>
var handlerInvokers = await ((Task<HandlerInvokers>)methodToInvoke.Invoke(this, new[] { body, transactionContext, message })); |
<<<<<<<
LogStartStop("Starting periodic task {taskDescription} with interval {timerInterval}", _description, Interval);
=======
LogStartStop("Starting periodic task '{0}' with interval {1}", _description, Interval);
#if NET45
>>>>>>>
LogStartStop("Starting periodic task {taskDescription} with interval {timerInterval}", _description, Interval);
#if NET45 |
<<<<<<<
/* Copyright (c) 2008-2014 Peter Palotas, Jeffrey Jangli, Normalex
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
namespace Alphaleonis.Win32.Filesystem
{
internal static partial class NativeMethods
{
/// <summary>
/// FINDEX_SEARCH_OPS Enumeration - Defines values that are used with the FindFirstFileEx function
/// <para>to specify the type of filtering to perform.</para>
/// </summary>
/// <remarks>
/// <para>Minimum supported client: Windows XP [desktop apps | Windows Store apps]</para>
/// <para>Minimum supported server: Windows Server 2003 [desktop apps | Windows Store apps]</para>
/// </remarks>
internal enum FindExSearchOps
{
/// <summary>The search for a file that matches a specified file name.
/// <para>The lpSearchFilter parameter of FindFirstFileEx must be NULL when this search operation is used.</para>
/// </summary>
SearchNameMatch = 0,
/// <summary>This is an advisory flag. If the file system supports directory filtering,
/// <para>the function searches for a file that matches the specified name and is also a directory.</para>
/// <para>If the file system does not support directory filtering, this flag is silently ignored.</para>
/// <para> </para>
/// <remarks>
/// <para>The lpSearchFilter parameter of the FindFirstFileEx function must be NULL when this search value is used.</para>
/// <para>If directory filtering is desired, this flag can be used on all file systems,</para>
/// <para>but because it is an advisory flag and only affects file systems that support it,</para>
/// <para>the application must examine the file attribute data stored in the lpFindFileData parameter</para>
/// <para>of the FindFirstFileEx function to determine whether the function has returned a handle to a directory.</para>
/// </remarks>
/// </summary>
SearchLimitToDirectories = 1,
/// <summary>This filtering type is not available.
/// </summary>
/// <remarks>For more information, see Device Interface Classes.</remarks>
SearchLimitToDevices = 2
}
}
=======
/* Copyright (c) 2008-2015 Peter Palotas, Jeffrey Jangli, Normalex
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
namespace Alphaleonis.Win32.Filesystem
{
internal static partial class NativeMethods
{
/// <summary>FINDEX_SEARCH_OPS Enumeration - Defines values that are used with the FindFirstFileEx function
/// <para>to specify the type of filtering to perform.</para>
/// <para> </para>
/// <remarks>
/// <para>Minimum supported client: Windows XP [desktop apps | Windows Store apps]</para>
/// <para>Minimum supported server: Windows Server 2003 [desktop apps | Windows Store apps]</para>
/// </remarks>
/// </summary>
internal enum FindExSearchOps
{
/// <summary>The search for a file that matches a specified file name.
/// <para>The lpSearchFilter parameter of FindFirstFileEx must be NULL when this search operation is used.</para>
/// </summary>
SearchNameMatch = 0,
/// <summary>This is an advisory flag. If the file system supports directory filtering,
/// <para>the function searches for a file that matches the specified name and is also a directory.</para>
/// <para>If the file system does not support directory filtering, this flag is silently ignored.</para>
/// <para> </para>
/// <remarks>
/// <para>The lpSearchFilter parameter of the FindFirstFileEx function must be NULL when this search value is used.</para>
/// <para>If directory filtering is desired, this flag can be used on all file systems,</para>
/// <para>but because it is an advisory flag and only affects file systems that support it,</para>
/// <para>the application must examine the file attribute data stored in the lpFindFileData parameter</para>
/// <para>of the FindFirstFileEx function to determine whether the function has returned a handle to a directory.</para>
/// </remarks>
/// </summary>
SearchLimitToDirectories = 1,
/// <summary>This filtering type is not available.
/// <para> </para>
/// <remarks>For more information, see Device Interface Classes.</remarks>
/// </summary>
SearchLimitToDevices = 2
}
}
>>>>>>>
/* Copyright (c) 2008-2015 Peter Palotas, Jeffrey Jangli, Normalex
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
namespace Alphaleonis.Win32.Filesystem
{
internal static partial class NativeMethods
{
/// <summary>
/// FINDEX_SEARCH_OPS Enumeration - Defines values that are used with the FindFirstFileEx function
/// <para>to specify the type of filtering to perform.</para>
/// </summary>
/// <remarks>
/// <para>Minimum supported client: Windows XP [desktop apps | Windows Store apps]</para>
/// <para>Minimum supported server: Windows Server 2003 [desktop apps | Windows Store apps]</para>
/// </remarks>
internal enum FindExSearchOps
{
/// <summary>The search for a file that matches a specified file name.
/// <para>The lpSearchFilter parameter of FindFirstFileEx must be NULL when this search operation is used.</para>
/// </summary>
SearchNameMatch = 0,
/// <summary>This is an advisory flag. If the file system supports directory filtering,
/// <para>the function searches for a file that matches the specified name and is also a directory.</para>
/// <para>If the file system does not support directory filtering, this flag is silently ignored.</para>
/// <para> </para>
/// <remarks>
/// <para>The lpSearchFilter parameter of the FindFirstFileEx function must be NULL when this search value is used.</para>
/// <para>If directory filtering is desired, this flag can be used on all file systems,</para>
/// <para>but because it is an advisory flag and only affects file systems that support it,</para>
/// <para>the application must examine the file attribute data stored in the lpFindFileData parameter</para>
/// <para>of the FindFirstFileEx function to determine whether the function has returned a handle to a directory.</para>
/// </remarks>
/// </summary>
SearchLimitToDirectories = 1,
/// <summary>This filtering type is not available.
/// </summary>
/// <remarks>For more information, see Device Interface Classes.</remarks>
SearchLimitToDevices = 2
}
} |
<<<<<<<
public static void WithModel(Action<IModel> modelCallback)
{
using (var connection = new ConnectionFactory {Uri = ConnectionString}.CreateConnection())
using (var model = connection.CreateModel())
{
modelCallback(model);
}
}
=======
public static bool DeclareExchange(string exchangeName, string type, bool passive=false)
{
using (var connection = new ConnectionFactory { Uri = ConnectionString }.CreateConnection())
using (var model = connection.CreateModel())
{
// just ignore if it fails...
try
{
if (passive)
{
model.ExchangeDeclarePassive(exchangeName);
}
else
{
model.ExchangeDeclare(exchangeName, type);
}
}
catch
{
return false;
}
return true;
}
}
public static void DeleteExchange(string exchangeName)
{
using (var connection = new ConnectionFactory { Uri = ConnectionString }.CreateConnection())
using (var model = connection.CreateModel())
{
// just ignore if it fails...
try
{
model.ExchangeDelete(exchangeName);
}
catch
{
}
}
}
public static bool DeclareQueue(string queueName, bool durable = true, bool exclusive = false, bool autoDelete = false, bool passive = false)
{
using (var connection = new ConnectionFactory { Uri = ConnectionString }.CreateConnection())
using (var model = connection.CreateModel())
{
// just ignore if it fails...
try
{
if (passive)
{
model.QueueDeclarePassive(queueName);
}
else
{
model.QueueDeclare(queueName, durable, exclusive, autoDelete, null);
}
}
catch
{
return false;
}
return true;
}
}
>>>>>>>
public static void WithModel(Action<IModel> modelCallback)
{
using (var connection = new ConnectionFactory {Uri = ConnectionString}.CreateConnection())
using (var model = connection.CreateModel())
{
modelCallback(model);
}
}
public static bool DeclareExchange(string exchangeName, string type, bool passive=false)
{
using (var connection = new ConnectionFactory { Uri = ConnectionString }.CreateConnection())
using (var model = connection.CreateModel())
{
// just ignore if it fails...
try
{
if (passive)
{
model.ExchangeDeclarePassive(exchangeName);
}
else
{
model.ExchangeDeclare(exchangeName, type);
}
}
catch
{
return false;
}
return true;
}
}
public static void DeleteExchange(string exchangeName)
{
using (var connection = new ConnectionFactory { Uri = ConnectionString }.CreateConnection())
using (var model = connection.CreateModel())
{
// just ignore if it fails...
try
{
model.ExchangeDelete(exchangeName);
}
catch
{
}
}
}
public static bool DeclareQueue(string queueName, bool durable = true, bool exclusive = false, bool autoDelete = false, bool passive = false)
{
using (var connection = new ConnectionFactory { Uri = ConnectionString }.CreateConnection())
using (var model = connection.CreateModel())
{
// just ignore if it fails...
try
{
if (passive)
{
model.QueueDeclarePassive(queueName);
}
else
{
model.QueueDeclare(queueName, durable, exclusive, autoDelete, null);
}
}
catch
{
return false;
}
return true;
}
} |
<<<<<<<
/// <summary>
/// Allows for specifying the ID for the saga requesting the timeout.
/// The ID will be returned with the <see cref="TimeoutReply"/>.
/// </summary>
public Guid SagaId { get; set; }
=======
/// <summary>
/// Allows for additional data to be passed along with the timeout. If you really really want,
/// you COULD use this field to pass a serialized object.
/// </summary>
public string CustomData { get; set; }
>>>>>>>
/// <summary>
/// Allows for additional data to be passed along with the timeout. If you really really want,
/// you COULD use this field to pass a serialized object.
/// </summary>
public string CustomData { get; set; }
/// <summary>
/// Allows for specifying the ID for the saga requesting the timeout.
/// The ID will be returned with the <see cref="TimeoutReply"/>.
/// </summary>
public Guid SagaId { get; set; } |
<<<<<<<
/* Copyright (c) 2008-2014 Peter Palotas, Jeffrey Jangli, Normalex
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
using System;
using System.Security;
using Microsoft.Win32.SafeHandles;
namespace Alphaleonis.Win32.Filesystem
{
/// <summary>Represents a wrapper class for a handle used by the FindFirstVolumeMountPoint/FindVolumeMountPointClose methods of the Win32 API.</summary>
[SecurityCritical]
internal sealed class SafeFindVolumeMountPointHandle : SafeHandleZeroOrMinusOneIsInvalid
{
/// <summary>Initializes a new instance of the <see cref="SafeFindVolumeMountPointHandle"/> class.</summary>
private SafeFindVolumeMountPointHandle()
: base(true)
{
}
/// <summary>Initializes a new instance of the <see cref="SafeFindVolumeHandle"/> class.</summary>
/// <param name="handle">The handle.</param>
/// <param name="callerHandle"><see langword="true"/> [owns handle].</param>
public SafeFindVolumeMountPointHandle(IntPtr handle, bool callerHandle) : base(callerHandle)
{
SetHandle(handle);
}
/// <summary>When overridden in a derived class, executes the code required to free the handle.</summary>
/// <returns><see langword="true"/> if the handle is released successfully; otherwise, in the event of a catastrophic failure, <see langword="false"/>.
/// </returns>
protected override bool ReleaseHandle()
{
return NativeMethods.FindVolumeMountPointClose(handle);
}
}
=======
/* Copyright (c) 2008-2015 Peter Palotas, Jeffrey Jangli, Normalex
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
using System;
using System.Security;
using Microsoft.Win32.SafeHandles;
namespace Alphaleonis.Win32.Filesystem
{
/// <summary>Represents a wrapper class for a handle used by the FindFirstVolumeMountPoint/FindVolumeMountPointClose methods of the Win32 API.</summary>
[SecurityCritical]
internal sealed class SafeFindVolumeMountPointHandle : SafeHandleZeroOrMinusOneIsInvalid
{
/// <summary>Initializes a new instance of the <see cref="SafeFindVolumeMountPointHandle"/> class.</summary>
private SafeFindVolumeMountPointHandle()
: base(true)
{
}
/// <summary>Initializes a new instance of the <see cref="SafeFindVolumeHandle"/> class.</summary>
/// <param name="handle">The handle.</param>
/// <param name="callerHandle"><c>true</c> [owns handle].</param>
public SafeFindVolumeMountPointHandle(IntPtr handle, bool callerHandle) : base(callerHandle)
{
SetHandle(handle);
}
/// <summary>When overridden in a derived class, executes the code required to free the handle.</summary>
/// <returns><c>true</c> if the handle is released successfully; otherwise, in the event of a catastrophic failure, <c>false</c>.
/// </returns>
protected override bool ReleaseHandle()
{
return NativeMethods.FindVolumeMountPointClose(handle);
}
}
>>>>>>>
/* Copyright (c) 2008-2015 Peter Palotas, Jeffrey Jangli, Normalex
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
using System;
using System.Security;
using Microsoft.Win32.SafeHandles;
namespace Alphaleonis.Win32.Filesystem
{
/// <summary>Represents a wrapper class for a handle used by the FindFirstVolumeMountPoint/FindVolumeMountPointClose methods of the Win32 API.</summary>
[SecurityCritical]
internal sealed class SafeFindVolumeMountPointHandle : SafeHandleZeroOrMinusOneIsInvalid
{
/// <summary>Initializes a new instance of the <see cref="SafeFindVolumeMountPointHandle"/> class.</summary>
private SafeFindVolumeMountPointHandle()
: base(true)
{
}
/// <summary>Initializes a new instance of the <see cref="SafeFindVolumeHandle"/> class.</summary>
/// <param name="handle">The handle.</param>
/// <param name="callerHandle"><see langword="true"/> [owns handle].</param>
public SafeFindVolumeMountPointHandle(IntPtr handle, bool callerHandle) : base(callerHandle)
{
SetHandle(handle);
}
/// <summary>When overridden in a derived class, executes the code required to free the handle.</summary>
/// <returns><see langword="true"/> if the handle is released successfully; otherwise, in the event of a catastrophic failure, <see langword="false"/>.
/// </returns>
protected override bool ReleaseHandle()
{
return NativeMethods.FindVolumeMountPointClose(handle);
}
} |
<<<<<<<
#endregion // State
#region Timeout
/// <summary>Specifies the time-out, in seconds, of the DFS root or link.</summary>
public long Timeout { get; internal set; }
=======
/// <summary>Specifies the time-out, in seconds, of the DFS root or link.</summary>
public ulong Timeout { get; internal set; }
>>>>>>>
/// <summary>Specifies the time-out, in seconds, of the DFS root or link.</summary>
public long Timeout { get; internal set; } |
<<<<<<<
UnitTestAssert.ThrowsException<System.IO.FileNotFoundException>(() => Alphaleonis.Win32.Filesystem.File.GetFileSystemEntryInfo(tempPath));
=======
ExceptionAssert.FileNotFoundException(() => Alphaleonis.Win32.Filesystem.File.GetFileSystemEntryInfo(folder.FullName));
}
>>>>>>>
UnitTestAssert.ThrowsException<System.IO.FileNotFoundException>(() => Alphaleonis.Win32.Filesystem.File.GetFileSystemEntryInfo(folder.FullName));
} |
<<<<<<<
if (inboundMessage == null) Task.FromResult(false);
=======
if (inboundMessage == null) return Task.FromResult(false);
>>>>>>>
if (inboundMessage == null) return Task.FromResult(false);
<<<<<<<
return Task.FromResult(false);
}
private Task HandleMessage(ChatMessage inboundMessage)
{
if (string.IsNullOrEmpty(inboundMessage.User)
|| (!string.IsNullOrEmpty(Self.Id) && inboundMessage.User == Self.Id))
return Task.FromResult(false);
=======
return Task.FromResult(false);
}
private Task HandleMessage(ChatMessage inboundMessage)
{
if (string.IsNullOrEmpty(inboundMessage.User))
return Task.FromResult(false);
if(!string.IsNullOrEmpty(Self.Id) && inboundMessage.User == Self.Id)
return Task.FromResult(false);
>>>>>>>
return Task.FromResult(false);
}
private Task HandleMessage(ChatMessage inboundMessage)
{
if (string.IsNullOrEmpty(inboundMessage.User))
return Task.FromResult(false);
if(!string.IsNullOrEmpty(Self.Id) && inboundMessage.User == Self.Id)
return Task.FromResult(false);
<<<<<<<
return RaiseMessageReceived(message);
}
private Task HandleGroupJoined(GroupJoinedMessage inboundMessage)
{
var channelId = inboundMessage?.Channel?.Id;
if (channelId == null) return Task.FromResult(false);
var hub = inboundMessage.Channel.ToChatHub();
_connectedHubs[channelId] = hub;
return RaiseChatHubJoined(hub);
}
private Task HandleChannelJoined(ChannelJoinedMessage inboundMessage)
{
var channelId = inboundMessage?.Channel?.Id;
if (channelId == null) return Task.FromResult(false);
var hub = inboundMessage.Channel.ToChatHub();
_connectedHubs[channelId] = hub;
return RaiseChatHubJoined(hub);
=======
return RaiseMessageReceived(message);
}
private Task HandleGroupJoined(GroupJoinedMessage inboundMessage)
{
string channelId = inboundMessage?.Channel?.Id;
if (channelId == null) return Task.FromResult(false);
var hub = inboundMessage.Channel.ToChatHub();
_connectedHubs[channelId] = hub;
return RaiseChatHubJoined(hub);
}
private Task HandleChannelJoined(ChannelJoinedMessage inboundMessage)
{
string channelId = inboundMessage?.Channel?.Id;
if (channelId == null) return Task.FromResult(false);
var hub = inboundMessage.Channel.ToChatHub();
_connectedHubs[channelId] = hub;
return RaiseChatHubJoined(hub);
>>>>>>>
return RaiseMessageReceived(message);
}
private Task HandleGroupJoined(GroupJoinedMessage inboundMessage)
{
string channelId = inboundMessage?.Channel?.Id;
if (channelId == null) return Task.FromResult(false);
var hub = inboundMessage.Channel.ToChatHub();
_connectedHubs[channelId] = hub;
return RaiseChatHubJoined(hub);
}
private Task HandleChannelJoined(ChannelJoinedMessage inboundMessage)
{
string channelId = inboundMessage?.Channel?.Id;
if (channelId == null) return Task.FromResult(false);
var hub = inboundMessage.Channel.ToChatHub();
_connectedHubs[channelId] = hub;
return RaiseChatHubJoined(hub);
<<<<<<<
return UserNameCache.ContainsKey(userId) ?
UserNameCache[userId] :
new SlackUser() { Id = userId, Name = string.Empty };
=======
return UserCache.ContainsKey(userId) ?
UserCache[userId] :
new SlackUser { Id = userId, Name = string.Empty };
>>>>>>>
return UserCache.ContainsKey(userId) ?
UserCache[userId] :
new SlackUser { Id = userId, Name = string.Empty };
<<<<<<<
public event ChatHubJoinedEventHandler OnChatHubJoined;
private async Task RaiseChatHubJoined(SlackChatHub hub)
{
var e = OnChatHubJoined;
if (e != null)
{
try
{
await e(hub);
}
catch
{
}
}
}
=======
public event ChatHubJoinedEventHandler OnChatHubJoined;
private async Task RaiseChatHubJoined(SlackChatHub hub)
{
var e = OnChatHubJoined;
if (e != null)
{
try
{
await e(hub);
}
catch
{
}
}
}
>>>>>>>
public event ChatHubJoinedEventHandler OnChatHubJoined;
private async Task RaiseChatHubJoined(SlackChatHub hub)
{
var e = OnChatHubJoined;
}
}
}
public event ChatHubJoinedEventHandler OnChatHubJoined;
private async Task RaiseChatHubJoined(SlackChatHub hub)
{
var e = OnChatHubJoined;
if (e != null)
{
try
{
await e(hub);
}
catch
{
}
}
} |
<<<<<<<
public void IIS_EXITED(object obj, EventArgs args)
{
RestartServer();
}
=======
>>>>>>>
public void IIS_EXITED(object obj, EventArgs args)
{
RestartServer();
} |
<<<<<<<
parseResult.Quality = new QualityModel{ Quality = episodeFile.Quality, Proper = episodeFile.Proper };
=======
parseResult.Quality = new Quality{ QualityType = episodeFile.Quality, Proper = episodeFile.Proper };
parseResult.Episodes = episodes;
>>>>>>>
parseResult.Quality = new QualityModel{ Quality = episodeFile.Quality, Proper = episodeFile.Proper };
parseResult.Episodes = episodes; |
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification);
<<<<<<<
var progressNotification = new ProgressNotification("Settings");
_notificationProvider.Register(progressNotification);
=======
>>>>>>>
_notificationProvider.Register(progressNotification); |
<<<<<<<
public virtual bool IsFolderLocked(string path)
{
var files = GetFileInfos(path, "*.*", SearchOption.AllDirectories);
foreach(var fileInfo in files)
{
if (IsFileLocked(fileInfo))
return true;
}
return false;
}
public virtual bool IsFileLocked(FileInfo file)
{
FileStream stream = null;
try
{
stream = file.Open(FileMode.Open, FileAccess.Read, FileShare.None);
}
catch (IOException)
{
return true;
}
finally
{
if (stream != null)
stream.Close();
}
//file is not locked
return false;
}
=======
public virtual bool IsChildOfPath(string child, string parent)
{
if (Path.GetFullPath(child).StartsWith(Path.GetFullPath(parent)))
return true;
return false;
}
>>>>>>>
public virtual bool IsFolderLocked(string path)
{
var files = GetFileInfos(path, "*.*", SearchOption.AllDirectories);
foreach(var fileInfo in files)
{
if (IsFileLocked(fileInfo))
return true;
}
return false;
}
public virtual bool IsFileLocked(FileInfo file)
{
FileStream stream = null;
try
{
stream = file.Open(FileMode.Open, FileAccess.Read, FileShare.None);
}
catch (IOException)
{
return true;
}
finally
{
if (stream != null)
stream.Close();
}
//file is not locked
return false;
}
public virtual bool IsChildOfPath(string child, string parent)
{
if (Path.GetFullPath(child).StartsWith(Path.GetFullPath(parent)))
return true;
return false;
} |
<<<<<<<
=======
using NzbDrone.Core.Providers.Jobs;
using NzbDrone.Core.Repository;
>>>>>>>
using NzbDrone.Core.Repository; |
<<<<<<<
parseResult.AirDate, parseResult.EpisodeTitle, parseResult.Quality.Quality);
=======
parseResult.AirDate, parseResult.Episodes.First().Title, parseResult.Quality.QualityType);
>>>>>>>
parseResult.AirDate, parseResult.Episodes.First().Title, parseResult.Quality.Quality);
<<<<<<<
var result = String.Format("{0} - {1} - {2} [{3}]", seriesTitle, epNumberString, parseResult.EpisodeTitle, parseResult.Quality.Quality);
=======
if (episodeNames.Distinct().Count() == 1)
episodeName = episodeNames.First();
else
episodeName = String.Join(" + ", episodeNames.Distinct());
var result = String.Format("{0} - {1} - {2} [{3}]", seriesTitle, epNumberString, episodeName, parseResult.Quality.QualityType);
>>>>>>>
if (episodeNames.Distinct().Count() == 1)
episodeName = episodeNames.First();
else
episodeName = String.Join(" + ", episodeNames.Distinct());
var result = String.Format("{0} - {1} - {2} [{3}]", seriesTitle, epNumberString, episodeName, parseResult.Quality.Quality); |
<<<<<<<
public class GBufferManager
{
public const int k_MaxGbuffer = 8;
public int gbufferCount { get; set; }
RenderTargetIdentifier[] m_ColorMRTs;
RenderTargetIdentifier[] m_RTIDs = new RenderTargetIdentifier[k_MaxGbuffer];
public void InitGBuffers(RenderTextureDescriptor rtDesc, RenderPipelineMaterial deferredMaterial, bool enableBakeShadowMask, CommandBuffer cmd)
{
// Init Gbuffer description
gbufferCount = deferredMaterial.GetMaterialGBufferCount();
RenderTextureFormat[] rtFormat;
RenderTextureReadWrite[] rtReadWrite;
deferredMaterial.GetMaterialGBufferDescription(out rtFormat, out rtReadWrite);
rtDesc.depthBufferBits = 0;
for (int gbufferIndex = 0; gbufferIndex < gbufferCount; ++gbufferIndex)
{
cmd.ReleaseTemporaryRT(HDShaderIDs._GBufferTexture[gbufferIndex]);
rtDesc.colorFormat = rtFormat[gbufferIndex];
rtDesc.sRGB = (rtReadWrite[gbufferIndex] != RenderTextureReadWrite.Linear);
cmd.GetTemporaryRT(HDShaderIDs._GBufferTexture[gbufferIndex], rtDesc, FilterMode.Point);
m_RTIDs[gbufferIndex] = new RenderTargetIdentifier(HDShaderIDs._GBufferTexture[gbufferIndex]);
}
if (enableBakeShadowMask)
{
cmd.ReleaseTemporaryRT(HDShaderIDs._ShadowMaskTexture);
rtDesc.colorFormat = Builtin.GetShadowMaskBufferFormat();
rtDesc.sRGB = (Builtin.GetShadowMaskBufferReadWrite() != RenderTextureReadWrite.Linear);
cmd.GetTemporaryRT(HDShaderIDs._ShadowMaskTexture, rtDesc, FilterMode.Point);
m_RTIDs[gbufferCount++] = new RenderTargetIdentifier(HDShaderIDs._ShadowMaskTexture);
}
}
public RenderTargetIdentifier[] GetGBuffers()
{
// TODO: check with THomas or Tim if wa can simply return m_ColorMRTs with null for extra RT
if (m_ColorMRTs == null || m_ColorMRTs.Length != gbufferCount)
m_ColorMRTs = new RenderTargetIdentifier[gbufferCount];
for (int index = 0; index < gbufferCount; index++)
{
m_ColorMRTs[index] = m_RTIDs[index];
}
return m_ColorMRTs;
}
}
public class DBufferManager
{
public const int k_MaxDbuffer = 4;
public int dbufferCount { get; set; }
public int vsibleDecalCount { get; set; }
RenderTargetIdentifier[] m_ColorMRTs;
RenderTargetIdentifier[] m_RTIDs = new RenderTargetIdentifier[k_MaxDbuffer];
RenderTexture m_HTile;
RenderTargetIdentifier m_HTileRT;
public void InitDBuffers(RenderTextureDescriptor rtDesc, CommandBuffer cmd)
{
dbufferCount = Decal.GetMaterialDBufferCount();
RenderTextureFormat[] rtFormat;
RenderTextureReadWrite[] rtReadWrite;
Decal.GetMaterialDBufferDescription(out rtFormat, out rtReadWrite);
rtDesc.depthBufferBits = 0;
for (int dbufferIndex = 0; dbufferIndex < dbufferCount; ++dbufferIndex)
{
cmd.ReleaseTemporaryRT(HDShaderIDs._DBufferTexture[dbufferIndex]);
rtDesc.colorFormat = rtFormat[dbufferIndex];
rtDesc.sRGB = (rtReadWrite[dbufferIndex] != RenderTextureReadWrite.Linear);
cmd.GetTemporaryRT(HDShaderIDs._DBufferTexture[dbufferIndex], rtDesc, FilterMode.Point);
m_RTIDs[dbufferIndex] = new RenderTargetIdentifier(HDShaderIDs._DBufferTexture[dbufferIndex]);
}
}
public RenderTargetIdentifier[] GetDBuffers()
{
if (m_ColorMRTs == null || m_ColorMRTs.Length != dbufferCount)
m_ColorMRTs = new RenderTargetIdentifier[dbufferCount];
for (int index = 0; index < dbufferCount; index++)
{
m_ColorMRTs[index] = m_RTIDs[index];
}
return m_ColorMRTs;
}
public void ClearNormalTargetAndHTile(Color clearColor, CommandBuffer cmd)
{
// index 1 is normals
CoreUtils.SetRenderTarget(cmd, m_ColorMRTs[1], ClearFlag.Color, clearColor);
CoreUtils.SetRenderTarget(cmd, m_HTileRT, ClearFlag.Color, CoreUtils.clearColorAllBlack);
}
public void SetHTile(int bindSlot, CommandBuffer cmd)
{
cmd.SetRandomWriteTarget(bindSlot, m_HTile);
}
public void UnSetHTile(CommandBuffer cmd)
{
cmd.ClearRandomWriteTargets();
}
public void SetHTileTexture(CommandBuffer cmd)
{
cmd.SetGlobalTexture(HDShaderIDs._DecalHTileTexture, m_HTileRT);
}
public void PushGlobalParams(CommandBuffer cmd)
{
cmd.SetGlobalInt(HDShaderIDs._EnableDBuffer, vsibleDecalCount > 0 ? 1 : 0);
}
public void Resize(HDCamera camera)
{
CoreUtils.ResizeHTile(ref m_HTile, ref m_HTileRT, camera.renderTextureDesc);
}
}
=======
>>>>>>>
<<<<<<<
m_LightLoop.UpdateDataBuffers();
RenderGBuffer(m_CullResults, hdCamera, renderContext, cmd);
=======
RenderGBuffer(m_CullResults, hdCamera, enableBakeShadowMask, renderContext, cmd);
>>>>>>>
m_LightLoop.UpdateDataBuffers();
RenderGBuffer(m_CullResults, hdCamera, renderContext, cmd);
<<<<<<<
CoreUtils.SetRenderTarget(cmd, m_GbufferManager.GetGBuffers(), m_CameraDepthStencilBufferRT);
=======
HDUtils.SetRenderTarget(cmd, hdCamera, m_GbufferManager.GetBuffersRTI(enableShadowMask), m_CameraDepthStencilBuffer);
>>>>>>>
HDUtils.SetRenderTarget(cmd, hdCamera, m_GbufferManager.GetBuffersRTI(enableShadowMask), m_CameraDepthStencilBuffer);
<<<<<<<
=======
m_GbufferManager.BindBufferAsTextures(cmd);
>>>>>>>
m_GbufferManager.BindBufferAsTextures(cmd);
<<<<<<<
CoreUtils.SetRenderTarget(cmd, m_DbufferManager.GetDBuffers(), m_CameraDepthStencilBufferRT); // do not clear anymore
m_DbufferManager.SetHTile(m_DbufferManager.dbufferCount, cmd);
DecalSystem.instance.Render(renderContext, camera, cmd, m_LightLoop);
=======
HDUtils.SetRenderTarget(cmd, camera, m_DbufferManager.GetBuffersRTI(), m_CameraDepthStencilBuffer); // do not clear anymore
m_DbufferManager.SetHTile(m_DbufferManager.bufferCount, cmd);
DecalSystem.instance.Render(renderContext, camera, cmd);
>>>>>>>
HDUtils.SetRenderTarget(cmd, camera, m_DbufferManager.GetBuffersRTI(), m_CameraDepthStencilBuffer); // do not clear anymore
m_DbufferManager.SetHTile(m_DbufferManager.bufferCount, cmd);
DecalSystem.instance.Render(renderContext, camera, cmd, m_LightLoop);
<<<<<<<
m_DbufferManager.SetHTileTexture(cmd);
DecalSystem.instance.SetAtlas(cmd);
=======
m_DbufferManager.SetHTileTexture(cmd);
>>>>>>>
m_DbufferManager.SetHTileTexture(cmd);
DecalSystem.instance.SetAtlas(cmd); |
<<<<<<<
var sourceValue = (string)valueContext.Value;
var targetType = valueContext.TargetType;
=======
var targetType = valueContext.Assignment.Member.MemberType;
var sourceValue = (string)valueContext.Assignment.Value;
>>>>>>>
var targetType = valueContext.Assignment.Member.MemberType;
var sourceValue = (string)valueContext.Assignment.Value;
<<<<<<<
Func<ConverterValueContext, object> converter;
=======
if (typeof(Delegate).GetTypeInfo().IsAssignableFrom(targetType.GetTypeInfo()))
{
var rootInstance = valueContext.BuildContext.AmbientRegistrator.Instances.First();
var callbackMethodInfo = rootInstance.GetType()
.GetRuntimeMethods().First(method => method.Name.Equals(sourceValue));
return callbackMethodInfo.CreateDelegate(valueContext.Assignment.Member.MemberType, rootInstance);
}
Func<ValueContext, object> converter;
>>>>>>>
if (typeof(Delegate).GetTypeInfo().IsAssignableFrom(targetType.GetTypeInfo()))
{
var rootInstance = valueContext.BuildContext.AmbientRegistrator.Instances.First();
var callbackMethodInfo = rootInstance.GetType()
.GetRuntimeMethods().First(method => method.Name.Equals(sourceValue));
return callbackMethodInfo.CreateDelegate(valueContext.Assignment.Member.MemberType, rootInstance);
}
Func<ConverterValueContext, object> converter; |
<<<<<<<
// Init Gbuffer description
m_GbufferManager.gbufferCount = m_DeferredMaterial.GetMaterialGBufferCount();
RenderTextureFormat[] rtFormat;
RenderTextureReadWrite[] rtReadWrite;
m_DeferredMaterial.GetMaterialGBufferDescription(out rtFormat, out rtReadWrite);
for (int gbufferIndex = 0; gbufferIndex < m_GbufferManager.gbufferCount; ++gbufferIndex)
{
m_GbufferManager.SetBufferDescription(gbufferIndex, "_GBufferTexture" + gbufferIndex, rtFormat[gbufferIndex], rtReadWrite[gbufferIndex]);
}
m_DbufferManager.gbufferCount = 2;
m_DbufferManager.SetBufferDescription(0, "_DBufferTexture0", RenderTextureFormat.ARGB32, RenderTextureReadWrite.sRGB);
m_DbufferManager.SetBufferDescription(1, "_DBufferTexture1", RenderTextureFormat.ARGB32, RenderTextureReadWrite.Default);
=======
>>>>>>> |
<<<<<<<
var compressImagesMessages = Substitute.For<ICollector<CompressImagesMessage>>();
=======
var settingsTable = Substitute.For<CloudTable>(new Uri("https://myaccount.table.core.windows.net/Tables/settings"));
>>>>>>>
var compressImagesMessages = Substitute.For<ICollector<CompressImagesMessage>>();
var settingsTable = Substitute.For<CloudTable>(new Uri("https://myaccount.table.core.windows.net/Tables/settings"));
<<<<<<<
compressImagesMessages,
=======
settingsTable,
>>>>>>>
compressImagesMessages,
settingsTable, |
<<<<<<<
=======
using DevExpress.LookAndFeel;
using DevExpress.Utils.Drawing.Helpers;
using DevExpress.XtraEditors;
>>>>>>>
using DevExpress.LookAndFeel;
using DevExpress.Utils.Drawing.Helpers;
using DevExpress.XtraEditors;
<<<<<<<
using System.Threading.Tasks;
=======
using System.Runtime.InteropServices;
>>>>>>>
using System.Runtime.InteropServices;
using System.Threading.Tasks; |
<<<<<<<
using (new EditorGUILayout.HorizontalScope())
{
=======
#region General Settings
using (new EditorGUILayout.HorizontalScope())
{
>>>>>>>
using (new EditorGUILayout.HorizontalScope())
{
<<<<<<<
InspectorUIUtility.RenderDocLinkButton(Interactable_URL);
}
=======
>>>>>>>
<<<<<<<
EditorGUILayout.PropertyField(statesProperty, new GUIContent("States", "The States this Interactable is based on"));
=======
EditorGUILayout.PropertyField(states, new GUIContent("States", "The States this Interactable is based on"));
>>>>>>>
EditorGUILayout.PropertyField(statesProperty, new GUIContent("States", "The States this Interactable is based on"));
<<<<<<<
EditorGUI.EndProperty();
GUI.enabled = true;
=======
>>>>>>>
EditorGUI.EndProperty();
GUI.enabled = true;
<<<<<<<
GUI.enabled = true;
=======
EditorGUILayout.EndVertical();
#endregion
EditorGUILayout.Space();
if (!ProfilesSetup && !showProfiles)
{
InspectorUIUtility.DrawWarning("Profiles (Optional) have not been set up or has errors.");
}
#region Profiles
bool isProfilesOpen = InspectorUIUtility.DrawSectionFoldout("Profiles", showProfiles, FontStyle.Bold, InspectorUIUtility.TitleFontSize);
>>>>>>>
GUI.enabled = true; |
<<<<<<<
=======
/// <inheritdoc />
public SpeechEventData(EventSystem eventSystem) : base(eventSystem) { }
>>>>>>>
<<<<<<<
/// <inheritdoc />
public SpeechEventData(EventSystem eventSystem) : base(eventSystem) { }
=======
/// <summary>
/// A semantic meaning of recognized phrase.
/// </summary>
public KeyValuePair<string, string[]>[] SemanticMeanings { get; private set; }
>>>>>>>
/// <inheritdoc />
public SpeechEventData(EventSystem eventSystem) : base(eventSystem) { }
<<<<<<<
public void Initialize(IMixedRealityInputSource inputSource, MixedRealityInputAction inputAction, RecognitionConfidenceLevel confidence, TimeSpan phraseDuration, DateTime phraseStartTime, string recognizedText)
=======
public void Initialize(IMixedRealityInputSource inputSource, MixedRealityInputAction inputAction, RecognitionConfidenceLevel confidence, TimeSpan phraseDuration, DateTime phraseStartTime, KeyValuePair<string, string[]>[] semanticMeanings, string recognizedText)
>>>>>>>
public void Initialize(IMixedRealityInputSource inputSource, MixedRealityInputAction inputAction, RecognitionConfidenceLevel confidence, TimeSpan phraseDuration, DateTime phraseStartTime, string recognizedText) |
<<<<<<<
type == typeof(IMixedRealityBoundarySystem) ||
type == typeof(IMixedRealityDiagnosticsManager);
=======
type == typeof(IMixedRealityTeleportSystem) ||
type == typeof(IMixedRealityBoundarySystem);
>>>>>>>
type == typeof(IMixedRealityTeleportSystem) ||
type == typeof(IMixedRealityBoundarySystem) ||
type == typeof(IMixedRealityDiagnosticsManager); |
<<<<<<<
private IMixedRealityController controller;
=======
[SerializeField]
[Tooltip("Should this GameObject clean itself up after source is lost?")]
private bool destroyOnSourceLost = true;
/// <summary>
/// Should this GameObject clean itself up after source is lost?
/// </summary>
public bool DestroyOnSourceLost
{
get { return destroyOnSourceLost; }
set { destroyOnSourceLost = value; }
}
/// <summary>
/// Is the controller this Synchronizer is registered to currently tracked?
/// </summary>
public bool IsTracked { get; protected set; } = false;
/// <summary>
/// The current tracking state of the assigned <see cref="IMixedRealityController"/>
/// </summary>
protected TrackingState TrackingState = TrackingState.NotTracked;
>>>>>>>
/// <summary>
/// Is the controller this Synchronizer is registered to currently tracked?
/// </summary>
public bool IsTracked { get; protected set; } = false;
/// <summary>
/// The current tracking state of the assigned <see cref="IMixedRealityController"/>
/// </summary>
protected TrackingState TrackingState = TrackingState.NotTracked;
private IMixedRealityController controller; |
<<<<<<<
#endregion Delete Tests
[AsyncTestMethod]
public async Task UndeleteAsync()
{
TestHttpHandler hijack = new TestHttpHandler();
hijack.SetResponseContent("{\"id\":\"an id\",\"String\":\"Hey\"}");
hijack.OnSendingRequest = req =>
{
Assert.AreEqual(req.Method, HttpMethod.Post);
Assert.AreEqual(req.RequestUri.Query, "?__systemproperties=__createdAt%2C__updatedAt%2C__version");
// only id and version should be sent
Assert.IsNull(req.Content);
Assert.AreEqual(req.Headers.IfMatch.First().Tag, "\"abc\"");
return Task.FromResult(req);
};
IMobileServiceClient service = new MobileServiceClient("http://www.test.com", "secret...", hijack);
IMobileServiceTable<ToDoWithSystemPropertiesType> table = service.GetTable<ToDoWithSystemPropertiesType>();
var obj = new ToDoWithSystemPropertiesType();
obj.Id = "an id";
obj.String = "new";
obj.Version = "abc";
await table.UndeleteAsync(obj, null);
Assert.AreEqual("an id", obj.Id);
Assert.AreEqual("Hey", obj.String);
}
#region Query Tests
=======
>>>>>>>
[AsyncTestMethod]
public async Task UndeleteAsync()
{
TestHttpHandler hijack = new TestHttpHandler();
hijack.SetResponseContent("{\"id\":\"an id\",\"String\":\"Hey\"}");
hijack.OnSendingRequest = req =>
{
Assert.AreEqual(req.Method, HttpMethod.Post);
Assert.AreEqual(req.RequestUri.Query, "?__systemproperties=__createdAt%2C__updatedAt%2C__version");
// only id and version should be sent
Assert.IsNull(req.Content);
Assert.AreEqual(req.Headers.IfMatch.First().Tag, "\"abc\"");
return Task.FromResult(req);
};
IMobileServiceClient service = new MobileServiceClient("http://www.test.com", "secret...", hijack);
IMobileServiceTable<ToDoWithSystemPropertiesType> table = service.GetTable<ToDoWithSystemPropertiesType>();
var obj = new ToDoWithSystemPropertiesType();
obj.Id = "an id";
obj.String = "new";
obj.Version = "abc";
await table.UndeleteAsync(obj, null);
Assert.AreEqual("an id", obj.Id);
Assert.AreEqual("Hey", obj.String);
} |
<<<<<<<
private SerializedProperty teleportDuration;
private SerializedProperty boundaryVisualizationProfile;
// Diagnostic system properties
private SerializedProperty enableDiagnosticsSystem;
private SerializedProperty diagnosticsSystemType;
private SerializedProperty diagnosticsSystemProfile;
=======
// Additional registered components profile
>>>>>>>
// Diagnostic system properties
private SerializedProperty enableDiagnosticsSystem;
private SerializedProperty diagnosticsSystemType;
private SerializedProperty diagnosticsSystemProfile;
// Additional registered components profile
<<<<<<<
teleportDuration = serializedObject.FindProperty("teleportDuration");
boundaryVisualizationProfile = serializedObject.FindProperty("boundaryVisualizationProfile");
// Diagnostics system configuration
enableDiagnosticsSystem = serializedObject.FindProperty("enableDiagnosticsSystem");
diagnosticsSystemType = serializedObject.FindProperty("diagnosticsSystemType");
diagnosticsSystemProfile = serializedObject.FindProperty("diagnosticsSystemProfile");
=======
// Additional registered components configuration
>>>>>>>
// Diagnostics system configuration
enableDiagnosticsSystem = serializedObject.FindProperty("enableDiagnosticsSystem");
diagnosticsSystemType = serializedObject.FindProperty("diagnosticsSystemType");
diagnosticsSystemProfile = serializedObject.FindProperty("diagnosticsSystemProfile");
// Additional registered components configuration |
<<<<<<<
base.OnEnable();
if (!CheckMixedRealityManager(false) ||
!MixedRealityManager.Instance.ActiveProfile.IsInputSystemEnabled ||
MixedRealityManager.Instance.ActiveProfile.InputSystemProfile.InputActionsProfile == null)
=======
if (!CheckMixedRealityConfigured(false) ||
!MixedRealityToolkit.Instance.ActiveProfile.IsInputSystemEnabled ||
MixedRealityToolkit.Instance.ActiveProfile.InputSystemProfile.InputActionsProfile == null)
>>>>>>>
base.OnEnable();
if (!CheckMixedRealityConfigured(false) ||
!MixedRealityToolkit.Instance.ActiveProfile.IsInputSystemEnabled ||
MixedRealityToolkit.Instance.ActiveProfile.InputSystemProfile.InputActionsProfile == null) |
<<<<<<<
Debug.LogError($"Unable to register the {concreteType.GetType()} service. It does not implement the IMixedRealityService interface.");
=======
Debug.LogError($"Unable to register the {concreteType} service. It does not implement the IMixedRealityToolkitService interface.");
>>>>>>>
Debug.LogError($"Unable to register the {concreteType} service. It does not implement the IMixedRealityService interface."); |
<<<<<<<
DebugUtilities.LogWarning($"There's already a {interfaceType.Name} registered.");
=======
Debug.LogError($"There's already a {type.Name} registered.");
>>>>>>>
Debug.LogError($"There's already a {interfaceType.Name} registered.");
<<<<<<<
DebugUtilities.LogError($"Unable to register {interfaceType}. Concrete type does not implement the IMixedRealityExtensionService implementation.");
=======
Debug.LogError($"Unable to register {type}. Concrete type does not implement the IMixedRealityExtensionService implementation.");
>>>>>>>
Debug.LogError($"Unable to register {interfaceType}. Concrete type does not implement the IMixedRealityExtensionService implementation."); |
<<<<<<<
base.OnEnable();
if (!CheckMixedRealityManager(false))
=======
if (!CheckMixedRealityConfigured(false))
>>>>>>>
base.OnEnable();
if (!CheckMixedRealityConfigured(false)) |
<<<<<<<
public void OnPointerUp(MixedRealityPointerEventData eventData)
=======
public void OnPointerDragged(MixedRealityPointerEventData eventData) { }
public void OnPointerUp(MixedRealityPointerEventData eventData)
{
if (manipulatorToDisable != null)
>>>>>>>
public void OnPointerDragged(MixedRealityPointerEventData eventData) { }
public void OnPointerUp(MixedRealityPointerEventData eventData) |
<<<<<<<
=======
#region Monobehaviour Implementation
protected virtual void OnValidate()
{
CheckInitialization();
}
protected override void OnEnable()
{
base.OnEnable();
CheckInitialization();
}
#endregion Monobehaviour Implementation
>>>>>>> |
<<<<<<<
private static bool[] providerFoldouts;
=======
private static bool showHandTrackingProperties = true;
private SerializedProperty handTrackingProfile;
>>>>>>>
private static bool showHandTrackingProperties = true;
private SerializedProperty handTrackingProfile;
private static bool[] providerFoldouts;
<<<<<<<
providerFoldouts = new bool[dataProviderConfigurations.arraySize];
=======
handTrackingProfile = serializedObject.FindProperty("handTrackingProfile");
>>>>>>>
handTrackingProfile = serializedObject.FindProperty("handTrackingProfile");
providerFoldouts = new bool[dataProviderConfigurations.arraySize]; |
<<<<<<<
=======
if (States == null)
{
States = States.GetDefaultInteractableStates();
}
>>>>>>>
if (States == null)
{
States = States.GetDefaultInteractableStates();
}
<<<<<<<
#region NearInteractionHandlers
/// <summary>
/// Is the eventData a grab action or near pointer?
/// </summary>
/// <param name="eventData"></param>
/// <returns></returns>
protected bool IsGrab(IMixedRealityPointer pointer, MixedRealityInputAction action)
{
if (pointer as IMixedRealityNearPointer != null)
{
return true;
}
return false;
}
protected bool IsControllerGrip(IMixedRealityPointer pointer)
{
bool hasGrip = false;
// TODO : detect a controll grip press or grip pose action
/*
if (pointer.Controller != null)
{
MixedRealityInteractionMapping[] mappings = pointer.Controller.Interactions;
for (int i = 0; i < mappings.Length; i++)
{
if ((mappings[i].AxisCodeX == ControllerMappingLibrary.AXIS_11 || mappings[i].AxisCodeX == ControllerMappingLibrary.AXIS_12) && mappings[i].BoolData || mappings[i].FloatData > 0.5f)
{
hasGrip = true;
}
}
}
*/
return hasGrip;
}
=======
#region IMixedRealityTouchHandler
>>>>>>>
#region NearInteractionHandlers
/// <summary>
/// Is the eventData a grab action or near pointer?
/// </summary>
/// <param name="eventData"></param>
/// <returns></returns>
protected bool IsGrab(IMixedRealityPointer pointer, MixedRealityInputAction action)
{
if (pointer as IMixedRealityNearPointer != null)
{
return true;
}
return false;
}
protected bool IsControllerGrip(IMixedRealityPointer pointer)
{
bool hasGrip = false;
// TODO : detect a controll grip press or grip pose action
/*
if (pointer.Controller != null)
{
MixedRealityInteractionMapping[] mappings = pointer.Controller.Interactions;
for (int i = 0; i < mappings.Length; i++)
{
if ((mappings[i].AxisCodeX == ControllerMappingLibrary.AXIS_11 || mappings[i].AxisCodeX == ControllerMappingLibrary.AXIS_12) && mappings[i].BoolData || mappings[i].FloatData > 0.5f)
{
hasGrip = true;
}
}
}
*/
return hasGrip;
}
<<<<<<<
void IMixedRealityTouchHandler.OnTouchUpdated(HandTrackingInputEventData eventData){}
#endregion NearInteractionHandlers
#region SourceHandlers
/// <summary>
/// Handle states related to vaailable sources and focus
/// </summary>
protected void SetSourceStates()
{
bool hasSource = sources.Count > 0;
bool targeted = HasFocus && hasSource;
bool interactive = !HasFocus && hasSource;
bool observationTargeted = HasFocus && !hasSource;
bool observation = !HasFocus && !hasSource;
SetTargeted(targeted);
SetInteractive(interactive);
SetObservationTargeted(observationTargeted);
SetObservation(observation);
}
/// <summary>
/// Capture information about sources, pointers.
/// Source Detected only works when global
/// Source Lost works when a hand is gestureing a leaves the sensor's view
/// </summary>
public void OnSourceDetected(SourceStateEventData eventData)
{
sources.Add(eventData);
SetSourceStates();
}
public void OnSourceLost(SourceStateEventData eventData)
{
sources.Remove(eventData);
SetSourceStates();
}
#endregion SourceHandlers
=======
void IMixedRealityTouchHandler.OnTouchUpdated(HandTrackingInputEventData eventData) { }
#endregion
>>>>>>>
void IMixedRealityTouchHandler.OnTouchUpdated(HandTrackingInputEventData eventData){}
#endregion NearInteractionHandlers
#region SourceHandlers
/// <summary>
/// Handle states related to vaailable sources and focus
/// </summary>
protected void SetSourceStates()
{
bool hasSource = sources.Count > 0;
bool targeted = HasFocus && hasSource;
bool interactive = !HasFocus && hasSource;
bool observationTargeted = HasFocus && !hasSource;
bool observation = !HasFocus && !hasSource;
SetTargeted(targeted);
SetInteractive(interactive);
SetObservationTargeted(observationTargeted);
SetObservation(observation);
}
/// <summary>
/// Capture information about sources, pointers.
/// Source Detected only works when global
/// Source Lost works when a hand is gestureing a leaves the sensor's view
/// </summary>
public void OnSourceDetected(SourceStateEventData eventData)
{
sources.Add(eventData);
SetSourceStates();
}
public void OnSourceLost(SourceStateEventData eventData)
{
sources.Remove(eventData);
SetSourceStates();
}
#endregion SourceHandlers |
<<<<<<<
Assert.AreEqual(0, MixedRealityServiceRegistry.GetAllServices().Count);
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.GetServices<IMixedRealityService>());
>>>>>>>
Assert.IsEmpty(MixedRealityToolkit.Instance.GetServices<IMixedRealityService>());
<<<<<<<
#region IMixedRealityDataprovider Tests
[Test]
public void Test_04_01_RegisterMixedRealityDataProvider()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Register
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test Data Provider 1", 10));
// Retrieve
var extensionService1 = MixedRealityToolkit.Instance.GetService<ITestDataProvider1>();
// Tests
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
Assert.IsNotNull(MixedRealityToolkit.Instance.GetDataProvider<ITestDataProvider1>());
// Tests
Assert.IsNotNull(extensionService1);
}
[Test]
public void Test_04_02_01_UnregisterMixedRealityDataProviderByType()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Register
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test Data Provider 1", 10));
// Retrieve
var extensionService1 = MixedRealityToolkit.Instance.GetService<ITestDataProvider1>();
// Tests
Assert.IsNotNull(extensionService1);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
Assert.IsNotNull(MixedRealityToolkit.Instance.GetDataProvider<ITestDataProvider1>());
var success = MixedRealityToolkit.Instance.UnregisterService<ITestDataProvider1>();
// Validate non-existent service
var isServiceRegistered = MixedRealityToolkit.Instance.IsServiceRegistered<ITestDataProvider1>();
// Tests
Assert.IsTrue(success);
Assert.IsFalse(isServiceRegistered);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
}
[Test]
public void Test_04_02_02_UnregisterMixedRealityDataProviderByTypeAndName()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Register
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test Data Provider 1", 10));
// Retrieve
var extensionService1 = MixedRealityToolkit.Instance.GetService<ITestDataProvider1>();
// Tests
Assert.IsNotNull(extensionService1);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
// Retrieve service
var dataProvider = MixedRealityToolkit.Instance.GetService<ITestDataProvider1>();
// Validate
Assert.IsNotNull(dataProvider);
var success = MixedRealityToolkit.Instance.UnregisterService<ITestDataProvider1>(dataProvider.Name);
// Validate non-existent service
var isServiceRegistered = MixedRealityToolkit.Instance.IsServiceRegistered<ITestDataProvider1>();
// Tests
Assert.IsTrue(success);
Assert.IsFalse(isServiceRegistered);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
}
[Test]
public void Test_04_03_RegisterMixedRealityDataProviders()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Add test ExtensionService
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test Data Provider 1", 10));
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, "Test Data Provider 2", 10));
// Retrieve all registered IMixedRealityExtensionServices
var extensionServices = MixedRealityToolkit.Instance.GetServices<IMixedRealityDataProvider>();
// Tests
Assert.IsNotNull(MixedRealityToolkit.Instance.ActiveProfile);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
Assert.AreEqual(2, extensionServices.Count);
Assert.IsNotNull(MixedRealityToolkit.Instance.GetDataProvider<TestDataProvider1>());
Assert.IsNotNull(MixedRealityToolkit.Instance.GetDataProvider<TestDataProvider2>());
}
[Test]
public void Test_04_04_UnregisterMixedRealityDataProvidersByType()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Add test ExtensionService
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test Data Provider 1", 10));
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, "Test Data Provider 2", 10));
// Retrieve all registered IMixedRealityExtensionServices
var extensionServices = MixedRealityToolkit.Instance.GetServices<IMixedRealityDataProvider>();
// Tests
Assert.IsNotNull(MixedRealityToolkit.Instance.ActiveProfile);
Assert.AreEqual(2, extensionServices.Count);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
// Retrieve services
var extensionService1 = MixedRealityToolkit.Instance.GetService<ITestDataProvider1>();
var extensionService2 = MixedRealityToolkit.Instance.GetService<ITestDataProvider2>();
// Validate
Assert.IsNotNull(extensionService1);
Assert.IsNotNull(extensionService2);
var success1 = MixedRealityToolkit.Instance.UnregisterService<ITestDataProvider1>();
var success2 = MixedRealityToolkit.Instance.UnregisterService<ITestDataProvider2>();
// Validate non-existent service
var isService1Registered = MixedRealityToolkit.Instance.IsServiceRegistered<ITestDataProvider1>();
var isService2Registered = MixedRealityToolkit.Instance.IsServiceRegistered<ITestDataProvider2>();
// Tests
Assert.IsTrue(success1);
Assert.IsTrue(success2);
Assert.IsFalse(isService1Registered);
Assert.IsFalse(isService2Registered);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
}
[Test]
public void Test_04_05_MixedRealityDataProviderDoesNotExist()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Add test data provider 1
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test Data Provider 1", 10));
// Validate non-existent data provider
Assert.IsFalse(MixedRealityToolkit.Instance.IsServiceRegistered<ITestDataProvider2>());
}
[Test]
public void Test_04_06_MixedRealityDataProviderDoesNotReturn()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
const string serviceName = "Test Data Provider";
// Add test data provider
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, serviceName, 10));
// Validate non-existent ExtensionService
MixedRealityToolkit.Instance.GetService<ITestExtensionService2>(serviceName);
// Tests
LogAssert.Expect(LogType.Error, $"Unable to find {serviceName} service.");
}
[Test]
public void Test_04_07_ValidateMixedRealityDataProviderName()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
var testName1 = "Test04-07-1";
var testName2 = "Test04-07-2";
// Add test data providers
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, testName1, 10));
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, testName2, 10));
// Retrieve
var dataProvider1 = (TestDataProvider1)MixedRealityToolkit.Instance.GetService<ITestDataProvider1>(testName1);
var dataProvider2 = (TestDataProvider2)MixedRealityToolkit.Instance.GetService<ITestDataProvider2>(testName2);
// Tests
Assert.AreEqual(testName1, dataProvider1.Name);
Assert.AreEqual(testName2, dataProvider2.Name);
}
[Test]
public void Test_04_08_GetMixedRealityDataProviderCollectionByInterface()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Add test data provider 1
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test04-08-1", 10));
// Add test data provider 2
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, "Test04-08-2.1", 10));
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, "Test04-08-2.2", 10));
// Retrieve all ITestDataProvider2 services
var test2DataProviderServices = MixedRealityToolkit.Instance.GetServices<ITestDataProvider2>();
// Tests
Assert.AreEqual(2, test2DataProviderServices.Count);
}
[Test]
public void Test_04_09_GetAllMixedRealityDataProviders()
{
TestUtilities.InitializeMixedRealityToolkitAndCreateScenes();
// Add test 1 services
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test16-1.1", 10));
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider1>(new TestDataProvider1(null, null, "Test16-1.2", 10));
// Add test 2 services
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, "Test16-2.1", 10));
MixedRealityToolkit.Instance.RegisterService<ITestDataProvider2>(new TestDataProvider2(null, null, "Test16-2.2", 10));
// Retrieve all extension services.
var allExtensionServices = MixedRealityToolkit.Instance.GetServices<IMixedRealityDataProvider>();
// Tests
Assert.AreEqual(4, allExtensionServices.Count);
}
#endregion IMixedRealityDataprovider Tests
=======
>>>>>>>
<<<<<<<
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
>>>>>>>
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
<<<<<<<
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
>>>>>>>
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
<<<<<<<
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
>>>>>>>
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
<<<<<<<
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
>>>>>>>
Assert.AreEqual(1, MixedRealityServiceRegistry.GetAllServices().Count);
<<<<<<<
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
>>>>>>>
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
<<<<<<<
Assert.AreEqual(2, extensionServices.Count);
Assert.AreEqual(2, MixedRealityServiceRegistry.GetAllServices().Count);
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.AreEqual(2, serviceCount);
Assert.AreEqual(extensionServices.Count, serviceCount);
>>>>>>>
Assert.AreEqual(2, serviceCount);
Assert.AreEqual(extensionServices.Count, serviceCount);
<<<<<<<
Assert.AreEqual(2, extensionServices.Count);
Assert.AreEqual(2, MixedRealityServiceRegistry.GetAllServices().Count);
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.AreEqual(2, serviceCount);
Assert.AreEqual(extensionServices.Count, serviceCount);
>>>>>>>
Assert.AreEqual(2, serviceCount);
Assert.AreEqual(extensionServices.Count, serviceCount);
<<<<<<<
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
=======
Assert.IsEmpty(MixedRealityToolkit.Instance.ActiveSystems);
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
>>>>>>>
Assert.IsEmpty(MixedRealityServiceRegistry.GetAllServices());
<<<<<<<
Assert.IsFalse(MixedRealityToolkit.Instance.IsServiceRegistered<ITestExtensionService2>());
=======
var isServiceRegistered = MixedRealityToolkit.Instance.IsServiceRegistered<ITestExtensionService2>();
// Tests
Assert.IsFalse(isServiceRegistered);
>>>>>>>
var isServiceRegistered = MixedRealityToolkit.Instance.IsServiceRegistered<ITestExtensionService2>();
// Tests
Assert.IsFalse(isServiceRegistered); |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.