content
stringlengths
5
1.04M
avg_line_length
float64
1.75
12.9k
max_line_length
int64
2
244k
alphanum_fraction
float64
0
0.98
licenses
list
repository_name
stringlengths
7
92
path
stringlengths
3
249
size
int64
5
1.04M
lang
stringclasses
2 values
using System; using System.Collections.Generic; using System.Text; namespace DeathStar.Core.Models.Equipments { public class EngineeringModule { public string Name { get; protected set; } public int KineticDamageEffectFactor { get; protected set; } public int ThermalDamageEffectFactor { get; protected set; } public int ExplosiveDamageEffectFactor { get; protected set; } public int ElectromagneticDamageEffectFactor { get; protected set; } public int RangeEffectFactor { get; protected set; } } }
33
76
0.71123
[ "MIT" ]
MizaN13/BattleEngine
ProjectDeathStar.Core/Models/Equipments/EngineeringModule.cs
563
C#
using System.Collections; using System.Collections.Generic; using UnityEngine; namespace ME.ECS.Pathfinding { public class AgentManager : MonoBehaviour { public Agent[] allAgents; [ContextMenu("Collect")] public void OnValidate() { this.allAgents = AgentManager.FindObjectsOfType<Agent>(); } public void Update() { this.Simulate(Time.deltaTime); } public void Simulate(float dt) { for (int i = 0, count = this.allAgents.Length; i < count; ++i) { this.allAgents[i].Simulate(dt); } } } }
17.722222
76
0.567398
[ "MIT" ]
Siridar-LLC/ecs-submodule
Essentials/Pathfinding/Pathfinding/MotionSolver/AgentManager.cs
640
C#
using OpenQA.Selenium; using OpenQA.Selenium.Support.UI; using System.Threading; namespace WcfRestExample.E2ETests.WebElements { public class Index { protected IWebDriver _driver; protected WebDriverWait _wait; public IWebElement LoadingBar { get { return _driver.FindElement(By.Id("loading")); } } public IWebElement HomeMenuButton { get { return _driver.FindElements(By.ClassName("mdl-navigation__link"))[0]; } } public IWebElement EmployeesMenuButton { get { return _driver.FindElements(By.ClassName("mdl-navigation__link"))[1]; } } public IWebElement ConfigurationMenuButton { get { return _driver.FindElements(By.ClassName("mdl-navigation__link"))[2]; } } public Index(IWebDriver driver, string url, WebDriverWait wait) { _driver = driver; _wait = wait; if (_driver.Url != url) _driver.Url = url; } public INavigation Open() { INavigation navigate = _driver.Navigate(); Loading(); return navigate; } public void Loading() { Thread.Sleep(250); _wait.Until(ExpectedConditions.InvisibilityOfElementLocated(By.Id("loading"))); Thread.Sleep(500); } public void GoToHome() { HomeMenuButton.Click(); Loading(); } public void GoToEmployees() { EmployeesMenuButton.Click(); Loading(); } public void GoToConfiguration() { ConfigurationMenuButton.Click(); Loading(); } } }
21.505495
91
0.499745
[ "MIT" ]
michalkowal/WcfRestExample
WcfRestExample.E2ETests/WebElements/Index.cs
1,959
C#
using Microsoft.Spatial; using Newtonsoft.Json; using Newtonsoft.Json.Converters; using System; using System.Collections.Generic; using System.Text; namespace CodeTest01.Data.Weather { public interface IWeatherDO { GeographyPoint Coordinate { get; } IDayLightRangeDO DayLightRange { get; } IEnumerable<IWeatherDescriptionDO> WeatherDescriptions { get; } string StationName { get; } IDetailDO Detail { get; } IWindDO Wind { get; } ICloudDO Cloud { get; } DateTime RecordedOnInUtc { get; } long CityId { get; } string Name { get; } } internal class WeatherDO : IWeatherDO { [JsonProperty("coord")] public GeographyPoint Coordinate { get; set; } [JsonProperty("sys")] public DayLightRangeDO DayLightRange { get; set; } [JsonProperty("weather")] public List<WeatherDescriptionDO> WeatherDescriptions { get; set; } [JsonProperty("base")] public string StationName { get; set; } [JsonProperty("main")] public DetailDO Detail { get; set; } [JsonProperty("wind")] public WindDO Wind { get; set; } [JsonProperty("clouds")] public CloudDO Clouds { get; set; } [JsonConverter(typeof(UnixDateTimeConverter))] [JsonProperty("dt")] public DateTime RecordedOnInUtc { get; set; } [JsonProperty("id")] public long CityId { get; set; } [JsonProperty("name")] public string Name { get; set; } IDayLightRangeDO IWeatherDO.DayLightRange => DayLightRange; IEnumerable<IWeatherDescriptionDO> IWeatherDO.WeatherDescriptions => WeatherDescriptions; IDetailDO IWeatherDO.Detail => Detail; IWindDO IWeatherDO.Wind => Wind; ICloudDO IWeatherDO.Cloud => Clouds; } }
23.350649
95
0.652948
[ "MIT" ]
ErikPhilips/CodeTest01
CodeTest01.Data.Weather.OpenWeatherMap/WeatherDO.cs
1,800
C#
namespace NPOI.SS.Formula.Functions { public class Fv : FinanceFunction { public override double Evaluate(double rate, double arg1, double arg2, double arg3, bool type) { return FinanceLib.fv(rate, arg1, arg2, arg3, type); } } }
21.909091
96
0.717842
[ "MIT" ]
iNeverSleeeeep/NPOI-For-Unity
NPOI.SS.Formula.Functions/Fv.cs
241
C#
using Toe.Scripting; namespace SpirVGraph.NodeFactories { public class OpIMulNodeFactory : AbstractNodeFactory { public static readonly OpIMulNodeFactory Instance = new OpIMulNodeFactory(); public OpIMulNodeFactory():base(new ScriptNode() { Name = "IMul", Category = NodeCategory.Function, Type = "OpIMul", InputPins = { new PinWithConnection("Operand1",null), new PinWithConnection("Operand2",null), }, OutputPins = { new Pin("out",null), } }, NodeFactoryVisibility.Visible) { } } }
25.962963
84
0.529244
[ "MIT" ]
gleblebedev/SpirVisualEditor
src/SpirVGraph/NodeFactories/OpIMulNodeFactory.cs
701
C#
using Luban.Job.Common.Defs; using Scriban; using System; namespace Luban.Job.Common.Utils { public static class RenderUtil { [ThreadStatic] private static Template t_constRender; public static string RenderCsConstClass(DefConst c) { var ctx = new TemplateContext(); var env = new TTypeTemplateCommonExtends { ["x"] = c }; ctx.PushGlobal(env); var template = t_constRender ??= Template.Parse(@" namespace {{x.namespace_with_top_module}} { public sealed class {{x.name}} { {{~ for item in x.items ~}} public const {{cs_define_type item.ctype}} {{item.name}} = {{cs_const_value item.ctype item.value}}; {{~end~}} } } "); var result = template.Render(ctx); return result; } [ThreadStatic] private static Template t_enumRender; public static string RenderCsEnumClass(DefEnum e) { var template = t_enumRender ??= Template.Parse(@" namespace {{namespace_with_top_module}} { {{~if is_flags~}} [System.Flags] {{~end~}} public enum {{name}} { {{~ for item in items ~}} {{item.name}} = {{item.value}}, {{~end~}} } } "); var result = template.Render(e); return result; } [ThreadStatic] private static Template t_javaConstRender; public static string RenderJavaConstClass(DefConst c) { var ctx = new TemplateContext(); var env = new TTypeTemplateCommonExtends { ["x"] = c }; ctx.PushGlobal(env); var template = t_javaConstRender ??= Template.Parse(@" package {{x.namespace_with_top_module}}; public final class {{x.name}} { {{~ for item in x.items ~}} public static final {{java_define_type item.ctype}} {{item.name}} = {{java_const_value item.ctype item.value}}; {{~end~}} } "); var result = template.Render(ctx); return result; } [ThreadStatic] private static Template t_javaEnumRender; public static string RenderJavaEnumClass(DefEnum e) { var template = t_javaEnumRender ??= Template.Parse(@" package {{namespace_with_top_module}}; public enum {{name}} { {{~ for item in items ~}} {{item.name}}({{item.value}}), {{~end~}} ; private final int value; public int getValue() { return value; } {{name}}(int value) { this.value = value; } public static {{name}} valueOf(int value) { {{~ for item in items ~}} if (value == {{item.value}}) return {{item.name}}; {{~end~}} throw new IllegalArgumentException(""""); } } "); var result = template.Render(e); return result; } [ThreadStatic] private static Template t_cppConstRender; public static string RenderCppConstClass(DefConst c) { var ctx = new TemplateContext(); var env = new TTypeTemplateCommonExtends { ["x"] = c }; ctx.PushGlobal(env); var template = t_cppConstRender ??= Template.Parse(@" {{x.cpp_namespace_begin}} struct {{x.name}} { {{~ for item in x.items ~}} static constexpr {{cpp_define_type item.ctype}} {{item.name}} = {{cpp_const_value item.ctype item.value}}; {{~end~}} }; {{x.cpp_namespace_end}} "); var result = template.Render(ctx); return result; } [ThreadStatic] private static Template t_cppEnumRender; public static string RenderCppEnumClass(DefEnum e) { var template = t_cppEnumRender ??= Template.Parse(@" {{cpp_namespace_begin}} enum class {{name}} { {{~ for item in items ~}} {{item.name}} = {{item.value}}, {{~end~}} }; {{cpp_namespace_end}} "); var result = template.Render(e); return result; } [ThreadStatic] private static Template t_tsConstRender; public static string RenderTypescriptConstClass(DefConst c) { var ctx = new TemplateContext(); var env = new TTypeTemplateCommonExtends { ["x"] = c }; ctx.PushGlobal(env); var template = t_tsConstRender ??= Template.Parse(@" {{x.typescript_namespace_begin}} export class {{x.name}} { {{~ for item in x.items ~}} static {{item.name}} = {{ts_const_value item.ctype item.value}}; {{~end~}} } {{x.typescript_namespace_end}} "); var result = template.Render(ctx); return result; } [ThreadStatic] private static Template t_tsEnumRender; public static string RenderTypescriptEnumClass(DefEnum e) { var template = t_tsEnumRender ??= Template.Parse(@" {{typescript_namespace_begin}} export enum {{name}} { {{~for item in items ~}} {{item.name}} = {{item.value}}, {{~end~}} } {{typescript_namespace_end}} "); var result = template.Render(e); return result; } } }
23.105263
115
0.551632
[ "MIT" ]
Lorkta/luban
src/Luban.Job.Common/Source/Utils/RenderUtil.cs
5,268
C#
namespace P07_PredicateForNames { using System; using System.Linq; public class PredicateForNames { public static void Main() { int length = int.Parse(Console.ReadLine()); Func<string, bool> checkLength = n => n.Length <= length; Action<string> printName = n => Console.WriteLine(n); Console.ReadLine() .Split() .Where(checkLength) .ToList() .ForEach(printName); } } }
24
69
0.515152
[ "MIT" ]
MertYumer/C-Fundamentals---January-2019
C# Advanced - January 2019/05. Functional Programming - Exercises/P07-PredicateForNames/PredicateForNames.cs
530
C#
// Copyright 1998-2014 Epic Games, Inc. All Rights Reserved. using UnrealBuildTool; using System.Collections.Generic; public class GAEditorTarget : TargetRules { public GAEditorTarget(TargetInfo Target) { Type = TargetType.Editor; } // // TargetRules interface. // public override void SetupBinaries( TargetInfo Target, ref List<UEBuildBinaryConfiguration> OutBuildBinaryConfigurations, ref List<string> OutExtraModuleNames ) { OutExtraModuleNames.Add("GA"); } }
19.730769
69
0.723197
[ "Apache-2.0" ]
JackHarb89/ga2014
Source/GAEditor.Target.cs
513
C#
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; using System.Linq; using Microsoft.Build.Framework; using Microsoft.Build.Logging.Query.Graph; using Microsoft.Build.Logging.Query.Utility; namespace Microsoft.Build.Logging.Query.Result { public class Project : Component, IEquatable<Project>, IResultWithId, IResultWithName, IResultWithPath { public int Id { get; } public string ProjectFile { get; } public Build ParentBuild { get; } public ItemManager Items { get; } public PropertyManager Properties { get; } public PropertyManager GlobalProperties { get; } public ProjectNode_BeforeThis Node_BeforeThis { get; } public IReadOnlyDictionary<int, Target> TargetsById => _targetsById; public IReadOnlyDictionary<string, Target> TargetsByName => _targetsByName; public IReadOnlyList<Target> OrderedTargets => _orderedTargets; // TODO: A single project instance can be built concurrently with // distinct EntryPointTargets. Those should be tracked as part of // the overall Project. public IReadOnlyList<Target> EntryPointTargets => _entryPointTargets; public override Component Parent => ParentBuild; public string Name => System.IO.Path.GetFileNameWithoutExtension(ProjectFile); public string Path => ProjectFile; private readonly Dictionary<int, Target> _targetsById; private readonly Dictionary<string, Target> _targetsByName; private readonly List<Target> _orderedTargets; private readonly List<Target> _entryPointTargets; public Project( int id, string projectFile, IEnumerable items, IEnumerable properties, IDictionary<string, string> globalProperties, Build parentBuild) : base() { Id = id; ProjectFile = projectFile; ParentBuild = parentBuild; Items = new ItemManager(); Properties = new PropertyManager(); GlobalProperties = new PropertyManager(); Node_BeforeThis = new ProjectNode_BeforeThis(this); _targetsById = new Dictionary<int, Target>(); _targetsByName = new Dictionary<string, Target>(); _orderedTargets = new List<Target>(); _entryPointTargets = new List<Target>(); CopyItems(items); CopyProperties(properties); CopyGlobalProperties(globalProperties); } public Target AddTarget(int id, string name, bool isEntryPointTarget) { var target = new Target(id, name, this); _targetsByName[name] = target; _orderedTargets.Add(target); if (id != BuildEventContext.InvalidTargetId) { _targetsById[id] = target; } if (isEntryPointTarget) { _entryPointTargets.Add(target); } return target; } private void CopyItems(IEnumerable items) { if (items == null) { return; } foreach (var item in items.Cast<DictionaryEntry>()) { Items.Add(item.Key as string, item.Value as ITaskItem); } } private void CopyProperties(IEnumerable properties) { if (properties == null) { return; } foreach (var property in properties.Cast<DictionaryEntry>()) { Properties.Set(property.Key as string, property.Value as string); } } private void CopyGlobalProperties(IDictionary<string, string> globalProperties) { if (globalProperties == null) { return; } foreach (var globalProperty in globalProperties) { GlobalProperties.Set(globalProperty.Key, globalProperty.Value); } } public bool Equals([AllowNull] Project other) { return other != null && Id == other.Id; } public override int GetHashCode() { return HashCode.Combine(Id); } } }
32.637037
106
0.588516
[ "MIT" ]
Lpallett4/cli-lab
src/MSBuildBinLogQuery/Result/Project.cs
4,408
C#
using UnityEditor; using UnityEngine; namespace Lunari.Tsuki.Editor { public static class GUIStyles { public static GUIStyle Get(string key, EditorSkin skin = EditorSkin.Inspector) { return EditorGUIUtility.GetBuiltinSkin(skin).FindStyle(key); } public const string box = "box"; public const string button = "button"; public const string toggle = "toggle"; public const string label = "label"; public const string window = "window"; public const string textfield = "textfield"; public const string textarea = "textarea"; public const string horizontalslider = "horizontalslider"; public const string horizontalsliderthumb = "horizontalsliderthumb"; public const string verticalslider = "verticalslider"; public const string verticalsliderthumb = "verticalsliderthumb"; public const string horizontalscrollbar = "horizontalscrollbar"; public const string horizontalscrollbarthumb = "horizontalscrollbarthumb"; public const string horizontalscrollbarleftbutton = "horizontalscrollbarleftbutton"; public const string horizontalscrollbarrightbutton = "horizontalscrollbarrightbutton"; public const string verticalscrollbar = "verticalscrollbar"; public const string verticalscrollbarthumb = "verticalscrollbarthumb"; public const string verticalscrollbarupbutton = "verticalscrollbarupbutton"; public const string verticalscrollbardownbutton = "verticalscrollbardownbutton"; public const string scrollview = "scrollview"; public const string AboutWIndowLicenseLabel = "AboutWIndowLicenseLabel"; public const string ACButton = "AC Button"; public const string ACLeftArrow = "AC LeftArrow"; public const string ACRightArrow = "AC RightArrow"; public const string AnimationEventBackground = "AnimationEventBackground"; public const string AnimationEventTooltip = "AnimationEventTooltip"; public const string AnimationEventTooltipArrow = "AnimationEventTooltipArrow"; public const string AnimationKeyframeBackground = "AnimationKeyframeBackground"; public const string AnimationPlayHead = "AnimationPlayHead"; public const string AnimationRowEven = "AnimationRowEven"; public const string AnimationRowOdd = "AnimationRowOdd"; public const string AnimationSelectionTextField = "AnimationSelectionTextField"; public const string AnimationSequencerLinkButton = "AnimationSequencerLinkButton"; public const string AnimationTimelineTick = "AnimationTimelineTick"; public const string AnimPropDropdown = "AnimPropDropdown"; public const string AppToolbar = "AppToolbar"; public const string AssetLabel = "AssetLabel"; public const string AssetLabelIcon = "AssetLabel Icon"; public const string AssetLabelPartial = "AssetLabel Partial"; public const string AudioKnobOverlay = "AudioKnobOverlay"; public const string BoldLabel = "BoldLabel"; public const string BoldToggle = "BoldToggle"; public const string ButtonLeft = "ButtonLeft"; public const string ButtonMid = "ButtonMid"; public const string ButtonRight = "ButtonRight"; public const string BypassToggle = "BypassToggle"; public const string CapsuleButton = "CapsuleButton"; public const string ChannelStripAttenuationBar = "ChannelStripAttenuationBar"; public const string ChannelStripAttenuationMarkerSquare = "ChannelStripAttenuationMarkerSquare"; public const string ChannelStripBg = "ChannelStripBg"; public const string ChannelStripDuckingMarker = "ChannelStripDuckingMarker"; public const string ChannelStripEffectBar = "ChannelStripEffectBar"; public const string ChannelStripSendReturnBar = "ChannelStripSendReturnBar"; public const string ChannelStripVUMeterBg = "ChannelStripVUMeterBg"; public const string CircularToggle = "CircularToggle"; public const string CNBox = "CN Box"; public const string CNCountBadge = "CN CountBadge"; public const string CNEntryBackEven = "CN EntryBackEven"; public const string CNEntryBackOdd = "CN EntryBackOdd"; public const string CNEntryError = "CN EntryError"; public const string CNEntryErrorIcon = "CN EntryErrorIcon"; public const string CNEntryErrorIconSmall = "CN EntryErrorIconSmall"; public const string CNEntryErrorSmall = "CN EntryErrorSmall"; public const string CNEntryInfo = "CN EntryInfo"; public const string CNEntryInfoIcon = "CN EntryInfoIcon"; public const string CNEntryInfoIconSmall = "CN EntryInfoIconSmall"; public const string CNEntryInfoSmall = "CN EntryInfoSmall"; public const string CNEntryWarn = "CN EntryWarn"; public const string CNEntryWarnIcon = "CN EntryWarnIcon"; public const string CNEntryWarnIconSmall = "CN EntryWarnIconSmall"; public const string CNEntryWarnSmall = "CN EntryWarnSmall"; public const string CNMessage = "CN Message"; public const string CNStatusError = "CN StatusError"; public const string CNStatusInfo = "CN StatusInfo"; public const string CNStatusWarn = "CN StatusWarn"; public const string ColorField = "ColorField"; public const string ColorPicker2DThumb = "ColorPicker2DThumb"; public const string ColorPickerBackground = "ColorPickerBackground"; public const string ColorPickerBox = "ColorPickerBox"; public const string ColorPickerCurrentColor = "ColorPickerCurrentColor"; public const string ColorPickerCurrentExposureSwatchBorder = "ColorPickerCurrentExposureSwatchBorder"; public const string ColorPickerExposureSwatch = "ColorPickerExposureSwatch"; public const string ColorPickerHorizThumb = "ColorPickerHorizThumb"; public const string ColorPickerHueRing = "ColorPickerHueRing"; public const string ColorPickerHueRingThumb = "ColorPickerHueRingThumb"; public const string ColorPickerOriginalColor = "ColorPickerOriginalColor"; public const string ColorPickerSliderBackground = "ColorPickerSliderBackground"; public const string ColorPickerVertThumb = "ColorPickerVertThumb"; public const string Command = "Command"; public const string CommandLeft = "CommandLeft"; public const string CommandMid = "CommandMid"; public const string CommandRight = "CommandRight"; public const string ControlHighlight = "ControlHighlight"; public const string ControlLabel = "ControlLabel"; public const string CurveEditorBackground = "CurveEditorBackground"; public const string CurveEditorLabelTickmarks = "CurveEditorLabelTickmarks"; public const string debug_layout_box = "debug_layout_box"; public const string dockarea = "dockarea"; public const string dockareaOverlay = "dockareaOverlay"; public const string dockareaStandalone = "dockareaStandalone"; public const string DopesheetBackground = "DopesheetBackground"; public const string Dopesheetkeyframe = "Dopesheetkeyframe"; public const string DopesheetScaleLeft = "DopesheetScaleLeft"; public const string DopesheetScaleRight = "DopesheetScaleRight"; public const string dragtab = "dragtab"; public const string dragtabdropwindow = "dragtabdropwindow"; public const string DropDown = "DropDown"; public const string DropDownButton = "DropDownButton"; public const string EditModeToolbar = "EditModeToolbar"; public const string EditModeToolbarLeft = "EditModeToolbarLeft"; public const string EditModeToolbarMid = "EditModeToolbarMid"; public const string EditModeToolbarRight = "EditModeToolbarRight"; public const string ErrorLabel = "ErrorLabel"; public const string ExposablePopupItem = "ExposablePopupItem"; public const string ExposablePopupMenu = "ExposablePopupMenu"; public const string EyeDropperHorizontalLine = "EyeDropperHorizontalLine"; public const string EyeDropperPickedPixel = "EyeDropperPickedPixel"; public const string EyeDropperVerticalLine = "EyeDropperVerticalLine"; public const string flowbackground = "flow background"; public const string flownavbarback = "flow navbar back"; public const string flownavbarbutton = "flow navbar button"; public const string flownavbarseparator = "flow navbar separator"; public const string flownode0 = "flow node 0"; public const string flownode0on = "flow node 0 on"; public const string flownode1 = "flow node 1"; public const string flownode1on = "flow node 1 on"; public const string flownode2 = "flow node 2"; public const string flownode2on = "flow node 2 on"; public const string flownode3 = "flow node 3"; public const string flownode3on = "flow node 3 on"; public const string flownode4 = "flow node 4"; public const string flownode4on = "flow node 4 on"; public const string flownode5 = "flow node 5"; public const string flownode5on = "flow node 5 on"; public const string flownode6 = "flow node 6"; public const string flownode6on = "flow node 6 on"; public const string flownodehex0 = "flow node hex 0"; public const string flownodehex0on = "flow node hex 0 on"; public const string flownodehex1 = "flow node hex 1"; public const string flownodehex1on = "flow node hex 1 on"; public const string flownodehex2 = "flow node hex 2"; public const string flownodehex2on = "flow node hex 2 on"; public const string flownodehex3 = "flow node hex 3"; public const string flownodehex3on = "flow node hex 3 on"; public const string flownodehex4 = "flow node hex 4"; public const string flownodehex4on = "flow node hex 4 on"; public const string flownodehex5 = "flow node hex 5"; public const string flownodehex5on = "flow node hex 5 on"; public const string flownodehex6 = "flow node hex 6"; public const string flownodehex6on = "flow node hex 6 on"; public const string flownodetitlebar = "flow node titlebar"; public const string flowoverlayarealeft = "flow overlay area left"; public const string flowoverlayarearight = "flow overlay area right"; public const string flowoverlaybox = "flow overlay box"; public const string flowoverlayfoldout = "flow overlay foldout"; public const string flowoverlayheaderlowerleft = "flow overlay header lower left"; public const string flowoverlayheaderlowerright = "flow overlay header lower right"; public const string flowoverlayheaderupperleft = "flow overlay header upper left"; public const string flowoverlayheaderupperright = "flow overlay header upper right"; public const string flowshaderin0 = "flow shader in 0"; public const string flowshaderin1 = "flow shader in 1"; public const string flowshaderin2 = "flow shader in 2"; public const string flowshaderin3 = "flow shader in 3"; public const string flowshaderin4 = "flow shader in 4"; public const string flowshaderin5 = "flow shader in 5"; public const string flowshadernode0 = "flow shader node 0"; public const string flowshadernode0on = "flow shader node 0 on"; public const string flowshaderout0 = "flow shader out 0"; public const string flowshaderout1 = "flow shader out 1"; public const string flowshaderout2 = "flow shader out 2"; public const string flowshaderout3 = "flow shader out 3"; public const string flowshaderout4 = "flow shader out 4"; public const string flowshaderout5 = "flow shader out 5"; public const string flowtargetin = "flow target in"; public const string flowtriggerPinin = "flow triggerPin in"; public const string flowtriggerPinout = "flow triggerPin out"; public const string flowvar0 = "flow var 0"; public const string flowvar0on = "flow var 0 on"; public const string flowvar1 = "flow var 1"; public const string flowvar1on = "flow var 1 on"; public const string flowvar2 = "flow var 2"; public const string flowvar2on = "flow var 2 on"; public const string flowvar3 = "flow var 3"; public const string flowvar3on = "flow var 3 on"; public const string flowvar4 = "flow var 4"; public const string flowvar4on = "flow var 4 on"; public const string flowvar5 = "flow var 5"; public const string flowvar5on = "flow var 5 on"; public const string flowvar6 = "flow var 6"; public const string flowvar6on = "flow var 6 on"; public const string flowvarPinin = "flow varPin in"; public const string flowvarPinout = "flow varPin out"; public const string flowvarPintooltip = "flow varPin tooltip"; public const string Foldout = "Foldout"; public const string FoldOutPreDrop = "FoldOutPreDrop"; public const string GameViewBackground = "GameViewBackground"; public const string GradDownSwatch = "Grad Down Swatch"; public const string GradDownSwatchOverlay = "Grad Down Swatch Overlay"; public const string GradUpSwatch = "Grad Up Swatch"; public const string GradUpSwatchOverlay = "Grad Up Swatch Overlay"; public const string grey_border = "grey_border"; public const string GridList = "GridList"; public const string GridListText = "GridListText"; public const string GridToggle = "GridToggle"; public const string groupBackground = "groupBackground"; public const string GroupBox = "GroupBox"; public const string GVGizmoDropDown = "GV Gizmo DropDown"; public const string HeaderLabel = "HeaderLabel"; public const string HelpBox = "HelpBox"; public const string HiLabel = "Hi Label"; public const string HorizontalMinMaxScrollbarThumb = "HorizontalMinMaxScrollbarThumb"; public const string hostview = "hostview"; public const string IconButton = "IconButton"; public const string INBigTitle = "IN BigTitle"; public const string INBigTitleInner = "IN BigTitle Inner"; public const string INColorField = "IN ColorField"; public const string INDropDown = "IN DropDown"; public const string INFoldout = "IN Foldout"; public const string INFoldoutStatic = "IN FoldoutStatic"; public const string INGameObjectHeader = "IN GameObjectHeader"; public const string INLabel = "IN Label"; public const string INLockButton = "IN LockButton"; public const string INObjectField = "IN ObjectField"; public const string INPopup = "IN Popup"; public const string INRenderLayer = "IN RenderLayer"; public const string INSelectedLine = "IN SelectedLine"; public const string INTextField = "IN TextField"; public const string INThumbnailSelection = "IN ThumbnailSelection"; public const string INThumbnailShadow = "IN ThumbnailShadow"; public const string INTitle = "IN Title"; public const string INTitleText = "IN TitleText"; public const string INToggle = "IN Toggle"; public const string InnerShadowBg = "InnerShadowBg"; public const string InsertionMarker = "InsertionMarker"; public const string InvisibleButton = "InvisibleButton"; public const string LargeButton = "LargeButton"; public const string LargeButtonLeft = "LargeButtonLeft"; public const string LargeButtonMid = "LargeButtonMid"; public const string LargeButtonRight = "LargeButtonRight"; public const string LargeDropDown = "LargeDropDown"; public const string LargeLabel = "LargeLabel"; public const string LargePopup = "LargePopup"; public const string LargeTextField = "LargeTextField"; public const string LightmapEditorSelectedHighlight = "LightmapEditorSelectedHighlight"; public const string ListToggle = "ListToggle"; public const string LockedHeaderBackground = "LockedHeaderBackground"; public const string LockedHeaderButton = "LockedHeaderButton"; public const string LockedHeaderLabel = "LockedHeaderLabel"; public const string LODBlackBox = "LODBlackBox"; public const string LODCameraLine = "LODCameraLine"; public const string LODLevelNotifyText = "LODLevelNotifyText"; public const string LODRendererAddButton = "LODRendererAddButton"; public const string LODRendererButton = "LODRendererButton"; public const string LODRendererRemove = "LODRendererRemove"; public const string LODRenderersText = "LODRenderersText"; public const string LODSceneText = "LODSceneText"; public const string LODSliderBG = "LODSliderBG"; public const string LODSliderRange = "LODSliderRange"; public const string LODSliderRangeSelected = "LODSliderRangeSelected"; public const string LODSliderText = "LODSliderText"; public const string LODSliderTextSelected = "LODSliderTextSelected"; public const string MeBlendBackground = "MeBlendBackground"; public const string MeBlendPosition = "MeBlendPosition"; public const string MeBlendTriangleLeft = "MeBlendTriangleLeft"; public const string MeBlendTriangleRight = "MeBlendTriangleRight"; public const string MeLivePlayBackground = "MeLivePlayBackground"; public const string MeLivePlayBar = "MeLivePlayBar"; public const string MenuItem = "MenuItem"; public const string MenuItemMixed = "MenuItemMixed"; public const string MeTimeLabel = "MeTimeLabel"; public const string MeTransBGOver = "MeTransBGOver"; public const string MeTransitionBack = "MeTransitionBack"; public const string MeTransitionBlock = "MeTransitionBlock"; public const string MeTransitionHandleLeft = "MeTransitionHandleLeft"; public const string MeTransitionHandleLeftPrev = "MeTransitionHandleLeftPrev"; public const string MeTransitionHandleRight = "MeTransitionHandleRight"; public const string MeTransitionHead = "MeTransitionHead"; public const string MeTransitionSelect = "MeTransitionSelect"; public const string MeTransitionSelectHead = "MeTransitionSelectHead"; public const string MeTransOff2On = "MeTransOff2On"; public const string MeTransOffLeft = "MeTransOffLeft"; public const string MeTransOffRight = "MeTransOffRight"; public const string MeTransOn2Off = "MeTransOn2Off"; public const string MeTransOnLeft = "MeTransOnLeft"; public const string MeTransOnRight = "MeTransOnRight"; public const string MeTransPlayhead = "MeTransPlayhead"; public const string MiniBoldLabel = "MiniBoldLabel"; public const string minibutton = "minibutton"; public const string minibuttonleft = "minibuttonleft"; public const string minibuttonmid = "minibuttonmid"; public const string minibuttonright = "minibuttonright"; public const string MiniLabel = "MiniLabel"; public const string MiniLabelRight = "MiniLabelRight"; public const string MiniMinMaxSliderHorizontal = "MiniMinMaxSliderHorizontal"; public const string MiniMinMaxSliderVertical = "MiniMinMaxSliderVertical"; public const string MiniPopup = "MiniPopup"; public const string MiniPullDown = "MiniPullDown"; public const string MiniPullDownLeft = "MiniPullDownLeft"; public const string MiniSliderHorizontal = "MiniSliderHorizontal"; public const string MiniSliderVertical = "MiniSliderVertical"; public const string MiniTextField = "MiniTextField"; public const string MiniToolbarButton = "MiniToolbarButton"; public const string MiniToolbarButtonLeft = "MiniToolbarButtonLeft"; public const string MiniToolbarPopup = "MiniToolbarPopup"; public const string MinMaxHorizontalSliderThumb = "MinMaxHorizontalSliderThumb"; public const string MuteToggle = "MuteToggle"; public const string NotificationBackground = "NotificationBackground"; public const string NotificationText = "NotificationText"; public const string ObjectField = "ObjectField"; public const string ObjectFieldMiniThumb = "ObjectFieldMiniThumb"; public const string ObjectFieldThumb = "ObjectFieldThumb"; public const string ObjectFieldThumbOverlay = "ObjectFieldThumbOverlay"; public const string ObjectFieldThumbOverlay2 = "ObjectFieldThumbOverlay2"; public const string ObjectPickerBackground = "ObjectPickerBackground"; public const string ObjectPickerGroupHeader = "ObjectPickerGroupHeader"; public const string ObjectPickerLargeStatus = "ObjectPickerLargeStatus"; public const string ObjectPickerPreviewBackground = "ObjectPickerPreviewBackground"; public const string ObjectPickerResultsEven = "ObjectPickerResultsEven"; public const string ObjectPickerResultsGrid = "ObjectPickerResultsGrid"; public const string ObjectPickerResultsGridLabel = "ObjectPickerResultsGridLabel"; public const string ObjectPickerResultsOdd = "ObjectPickerResultsOdd"; public const string ObjectPickerSmallStatus = "ObjectPickerSmallStatus"; public const string ObjectPickerTab = "ObjectPickerTab"; public const string ObjectPickerToolbar = "ObjectPickerToolbar"; public const string OLbox = "OL box"; public const string OLboxNoExpand = "OL box NoExpand"; public const string OLElem = "OL Elem"; public const string OLEntryBackEven = "OL EntryBackEven"; public const string OLEntryBackOdd = "OL EntryBackOdd"; public const string OLheader = "OL header"; public const string OLLabel = "OL Label"; public const string OLMinus = "OL Minus"; public const string OLPlus = "OL Plus"; public const string OLSelectedRow = "OL SelectedRow"; public const string OLTextField = "OL TextField"; public const string OLTitle = "OL Title"; public const string OLTitleTextRight = "OL Title TextRight"; public const string OLTitleleft = "OL Titleleft"; public const string OLTitlemid = "OL Titlemid"; public const string OLTitleright = "OL Titleright"; public const string OLToggle = "OL Toggle"; public const string OLToggleWhite = "OL ToggleWhite"; public const string PaneOptions = "PaneOptions"; public const string PlayerSettingsLevel = "PlayerSettingsLevel"; public const string PlayerSettingsPlatform = "PlayerSettingsPlatform"; public const string Popup = "Popup"; public const string PopupBackground = "PopupBackground"; public const string PopupCurveDropdown = "PopupCurveDropdown"; public const string PopupCurveEditorBackground = "PopupCurveEditorBackground"; public const string PopupCurveEditorSwatch = "PopupCurveEditorSwatch"; public const string PopupCurveSwatchBackground = "PopupCurveSwatchBackground"; public const string PRBrokenPrefabLabel = "PR BrokenPrefabLabel"; public const string PRDigDownArrow = "PR DigDownArrow"; public const string PRDisabledBrokenPrefabLabel = "PR DisabledBrokenPrefabLabel"; public const string PRDisabledLabel = "PR DisabledLabel"; public const string PRDisabledPrefabLabel = "PR DisabledPrefabLabel"; public const string PRInsertion = "PR Insertion"; public const string PRInsertionAbove = "PR Insertion Above"; public const string PRLabel = "PR Label"; public const string PRPing = "PR Ping"; public const string PRPrefabLabel = "PR PrefabLabel"; public const string PRTextField = "PR TextField"; public const string PreBackground = "PreBackground"; public const string PreButton = "PreButton"; public const string PreDropDown = "PreDropDown"; public const string PreferencesKeysElement = "PreferencesKeysElement"; public const string PreferencesSection = "PreferencesSection"; public const string PreferencesSectionBox = "PreferencesSectionBox"; public const string PreHorizontalScrollbar = "PreHorizontalScrollbar"; public const string PreHorizontalScrollbarThumb = "PreHorizontalScrollbarThumb"; public const string PreLabel = "PreLabel"; public const string PreOverlayLabel = "PreOverlayLabel"; public const string PreSlider = "PreSlider"; public const string PreSliderThumb = "PreSliderThumb"; public const string PreToolbar = "PreToolbar"; public const string PreToolbar2 = "PreToolbar2"; public const string PreVerticalScrollbar = "PreVerticalScrollbar"; public const string PreVerticalScrollbarThumb = "PreVerticalScrollbarThumb"; public const string ProfilerBadge = "ProfilerBadge"; public const string ProfilerLeftPane = "ProfilerLeftPane"; public const string ProfilerLeftPaneOverlay = "ProfilerLeftPaneOverlay"; public const string ProfilerPaneLeftBackground = "ProfilerPaneLeftBackground"; public const string ProfilerPaneSubLabel = "ProfilerPaneSubLabel"; public const string ProfilerRightPane = "ProfilerRightPane"; public const string ProfilerScrollviewBackground = "ProfilerScrollviewBackground"; public const string ProfilerSelectedLabel = "ProfilerSelectedLabel"; public const string ProfilerTimelineBar = "ProfilerTimelineBar"; public const string ProfilerTimelineFoldout = "ProfilerTimelineFoldout"; public const string ProfilerTimelineLeftPane = "ProfilerTimelineLeftPane"; public const string ProgressBarBack = "ProgressBarBack"; public const string ProgressBarBar = "ProgressBarBar"; public const string ProgressBarText = "ProgressBarText"; public const string ProjectBrowserBottomBarBg = "ProjectBrowserBottomBarBg"; public const string ProjectBrowserGridLabel = "ProjectBrowserGridLabel"; public const string ProjectBrowserHeaderBgMiddle = "ProjectBrowserHeaderBgMiddle"; public const string ProjectBrowserHeaderBgTop = "ProjectBrowserHeaderBgTop"; public const string ProjectBrowserIconAreaBg = "ProjectBrowserIconAreaBg"; public const string ProjectBrowserIconDropShadow = "ProjectBrowserIconDropShadow"; public const string ProjectBrowserPreviewBg = "ProjectBrowserPreviewBg"; public const string ProjectBrowserSubAssetBg = "ProjectBrowserSubAssetBg"; public const string ProjectBrowserSubAssetBgCloseEnded = "ProjectBrowserSubAssetBgCloseEnded"; public const string ProjectBrowserSubAssetBgDivider = "ProjectBrowserSubAssetBgDivider"; public const string ProjectBrowserSubAssetBgMiddle = "ProjectBrowserSubAssetBgMiddle"; public const string ProjectBrowserSubAssetBgOpenEnded = "ProjectBrowserSubAssetBgOpenEnded"; public const string ProjectBrowserSubAssetExpandBtn = "ProjectBrowserSubAssetExpandBtn"; public const string ProjectBrowserTextureIconDropShadow = "ProjectBrowserTextureIconDropShadow"; public const string ProjectBrowserTopBarBg = "ProjectBrowserTopBarBg"; public const string QualitySettingsDefault = "QualitySettingsDefault"; public const string Radio = "Radio"; public const string RectangleToolHBar = "RectangleToolHBar"; public const string RectangleToolHBarLeft = "RectangleToolHBarLeft"; public const string RectangleToolHBarRight = "RectangleToolHBarRight"; public const string RectangleToolHighlight = "RectangleToolHighlight"; public const string RectangleToolScaleBottom = "RectangleToolScaleBottom"; public const string RectangleToolScaleLeft = "RectangleToolScaleLeft"; public const string RectangleToolScaleRight = "RectangleToolScaleRight"; public const string RectangleToolScaleTop = "RectangleToolScaleTop"; public const string RectangleToolSelection = "RectangleToolSelection"; public const string RectangleToolVBar = "RectangleToolVBar"; public const string RectangleToolVBarBottom = "RectangleToolVBarBottom"; public const string RectangleToolVBarTop = "RectangleToolVBarTop"; public const string RegionBg = "RegionBg"; public const string RightLabel = "RightLabel"; public const string RLBackground = "RL Background"; public const string RLDragHandle = "RL DragHandle"; public const string RLElement = "RL Element"; public const string RLFooter = "RL Footer"; public const string RLFooterButton = "RL FooterButton"; public const string RLHeader = "RL Header"; public const string SCViewAxisLabel = "SC ViewAxisLabel"; public const string SCViewLabel = "SC ViewLabel"; public const string SceneViewOverlayTransparentBackground = "SceneViewOverlayTransparentBackground"; public const string ScriptText = "ScriptText"; public const string SearchCancelButton = "SearchCancelButton"; public const string SearchCancelButtonEmpty = "SearchCancelButtonEmpty"; public const string SearchModeFilter = "SearchModeFilter"; public const string SearchTextField = "SearchTextField"; public const string SelectionRect = "SelectionRect"; public const string sequenceClip = "sequenceClip"; public const string sequenceGroupFont = "sequenceGroupFont"; public const string sequenceTrackHeaderFont = "sequenceTrackHeaderFont"; public const string ShurikenCheckMark = "ShurikenCheckMark"; public const string ShurikenCheckMarkMixed = "ShurikenCheckMarkMixed"; public const string ShurikenDropdown = "ShurikenDropdown"; public const string ShurikenEditableLabel = "ShurikenEditableLabel"; public const string ShurikenEffectBg = "ShurikenEffectBg"; public const string ShurikenEmitterTitle = "ShurikenEmitterTitle"; public const string ShurikenLabel = "ShurikenLabel"; public const string ShurikenMinus = "ShurikenMinus"; public const string ShurikenModuleBg = "ShurikenModuleBg"; public const string ShurikenModuleTitle = "ShurikenModuleTitle"; public const string ShurikenObjectField = "ShurikenObjectField"; public const string ShurikenPlus = "ShurikenPlus"; public const string ShurikenPopup = "ShurikenPopup"; public const string ShurikenToggle = "ShurikenToggle"; public const string ShurikenToggleMixed = "ShurikenToggleMixed"; public const string ShurikenValue = "ShurikenValue"; public const string SimplePopup = "SimplePopup"; public const string SliderMixed = "SliderMixed"; public const string SoloToggle = "SoloToggle"; public const string StaticDropdown = "StaticDropdown"; public const string sv_iconselector_back = "sv_iconselector_back"; public const string sv_iconselector_button = "sv_iconselector_button"; public const string sv_iconselector_labelselection = "sv_iconselector_labelselection"; public const string sv_iconselector_selection = "sv_iconselector_selection"; public const string sv_iconselector_sep = "sv_iconselector_sep"; public const string sv_label_0 = "sv_label_0"; public const string sv_label_1 = "sv_label_1"; public const string sv_label_2 = "sv_label_2"; public const string sv_label_3 = "sv_label_3"; public const string sv_label_4 = "sv_label_4"; public const string sv_label_5 = "sv_label_5"; public const string sv_label_6 = "sv_label_6"; public const string sv_label_7 = "sv_label_7"; public const string TabWindowBackground = "TabWindowBackground"; public const string TagMenuItem = "Tag MenuItem"; public const string TagTextField = "Tag TextField"; public const string TagTextFieldButton = "Tag TextField Button"; public const string TagTextFieldEmpty = "Tag TextField Empty"; public const string TENodeBackground = "TE NodeBackground"; public const string TENodeBox = "TE NodeBox"; public const string TENodeBoxSelected = "TE NodeBoxSelected"; public const string TENodeLabelBot = "TE NodeLabelBot"; public const string TENodeLabelTop = "TE NodeLabelTop"; public const string TEPinLabel = "TE PinLabel"; public const string TEToolbar = "TE Toolbar"; public const string TEtoolbarbutton = "TE toolbarbutton"; public const string TEToolbarDropDown = "TE ToolbarDropDown"; public const string TextFieldDropDown = "TextFieldDropDown"; public const string TextFieldDropDownText = "TextFieldDropDownText"; public const string TimeScrubber = "TimeScrubber"; public const string TimeScrubberButton = "TimeScrubberButton"; public const string tinyFont = "tinyFont"; public const string TLBaseStateLogicBarOverlay = "TL BaseStateLogicBarOverlay"; public const string TLEndPoint = "TL EndPoint"; public const string TLInPoint = "TL InPoint"; public const string TLItemTitle = "TL ItemTitle"; public const string TLLeftColumn = "TL LeftColumn"; public const string TLLeftItem = "TL LeftItem"; public const string TLLogicBar0 = "TL LogicBar 0"; public const string TLLogicBar1 = "TL LogicBar 1"; public const string TLLogicBarparentgrey = "TL LogicBar parentgrey"; public const string TLLoopSection = "TL LoopSection"; public const string TLOutPoint = "TL OutPoint"; public const string TLPlayhead = "TL Playhead"; public const string TLRangeOverlay = "TL Range Overlay"; public const string TLRightLine = "TL RightLine"; public const string TLSelectionH1 = "TL Selection H1"; public const string TLSelectionH2 = "TL Selection H2"; public const string TLSelectionBarCloseButton = "TL SelectionBarCloseButton"; public const string TLSelectionBarPreview = "TL SelectionBarPreview"; public const string TLSelectionBarText = "TL SelectionBarText"; public const string TLSelectionButton = "TL SelectionButton"; public const string TLSelectionButtonPreDropGlow = "TL SelectionButton PreDropGlow"; public const string TLSelectionButtonName = "TL SelectionButtonName"; public const string TLSelectionButtonNew = "TL SelectionButtonNew"; public const string TLtableft = "TL tab left"; public const string TLtabmid = "TL tab mid"; public const string TLtabplusleft = "TL tab plus left"; public const string TLtabplusright = "TL tab plus right"; public const string TLtabright = "TL tab right"; public const string ToggleMixed = "ToggleMixed"; public const string Toolbar = "Toolbar"; public const string toolbarbutton = "toolbarbutton"; public const string ToolbarDropDown = "ToolbarDropDown"; public const string ToolbarPopup = "ToolbarPopup"; public const string ToolbarSeachCancelButton = "ToolbarSeachCancelButton"; public const string ToolbarSeachCancelButtonEmpty = "ToolbarSeachCancelButtonEmpty"; public const string ToolbarSeachTextField = "ToolbarSeachTextField"; public const string ToolbarSeachTextFieldPopup = "ToolbarSeachTextFieldPopup"; public const string ToolbarSearchField = "ToolbarSearchField"; public const string ToolbarTextField = "ToolbarTextField"; public const string Tooltip = "Tooltip"; public const string VCS_StickyNote = "VCS_StickyNote"; public const string VCS_StickyNoteArrow = "VCS_StickyNoteArrow"; public const string VCS_StickyNoteLabel = "VCS_StickyNoteLabel"; public const string VCS_StickyNoteP4 = "VCS_StickyNoteP4"; public const string VerticalMinMaxScrollbarThumb = "VerticalMinMaxScrollbarThumb"; public const string VisibilityToggle = "VisibilityToggle"; public const string WarningOverlay = "WarningOverlay"; public const string WhiteBoldLabel = "WhiteBoldLabel"; public const string WhiteLabel = "WhiteLabel"; public const string WhiteLargeLabel = "WhiteLargeLabel"; public const string WhiteMiniLabel = "WhiteMiniLabel"; public const string WinBtnClose = "WinBtnClose"; public const string WinBtnCloseActiveMac = "WinBtnCloseActiveMac"; public const string WinBtnCloseMac = "WinBtnCloseMac"; public const string WinBtnInactiveMac = "WinBtnInactiveMac"; public const string WinBtnMax = "WinBtnMax"; public const string WinBtnMaxActiveMac = "WinBtnMaxActiveMac"; public const string WinBtnMaxMac = "WinBtnMaxMac"; public const string WinBtnMin = "WinBtnMin"; public const string WinBtnMinActiveMac = "WinBtnMinActiveMac"; public const string WinBtnMinMac = "WinBtnMinMac"; public const string WindowBackground = "WindowBackground"; public const string WindowBottomResize = "WindowBottomResize"; public const string WizardBox = "Wizard Box"; public const string WizardError = "Wizard Error"; public const string WordWrapLabel = "WordWrapLabel"; public const string WordWrappedLabel = "WordWrappedLabel"; public const string WordWrappedMiniLabel = "WordWrappedMiniLabel"; public const string WrappedLabel = "WrappedLabel"; } }
66.328098
110
0.721702
[ "MIT" ]
JuniorSidnei/TsukiSuite
Assets/Editor/GUIStyles.cs
38,008
C#
/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the iot1click-projects-2018-05-14.normal.json service model. */ using System; using System.Collections.Generic; using System.Globalization; using System.IO; using System.Net; using System.Text; using System.Xml.Serialization; using Amazon.IoT1ClickProjects.Model; using Amazon.Runtime; using Amazon.Runtime.Internal; using Amazon.Runtime.Internal.Transform; using Amazon.Runtime.Internal.Util; using ThirdParty.Json.LitJson; namespace Amazon.IoT1ClickProjects.Model.Internal.MarshallTransformations { /// <summary> /// Response Unmarshaller for ListTagsForResource operation /// </summary> public class ListTagsForResourceResponseUnmarshaller : JsonResponseUnmarshaller { /// <summary> /// Unmarshaller the response from the service to the response class. /// </summary> /// <param name="context"></param> /// <returns></returns> public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context) { ListTagsForResourceResponse response = new ListTagsForResourceResponse(); context.Read(); int targetDepth = context.CurrentDepth; while (context.ReadAtDepth(targetDepth)) { if (context.TestExpression("tags", targetDepth)) { var unmarshaller = new DictionaryUnmarshaller<string, string, StringUnmarshaller, StringUnmarshaller>(StringUnmarshaller.Instance, StringUnmarshaller.Instance); response.Tags = unmarshaller.Unmarshall(context); continue; } } return response; } /// <summary> /// Unmarshaller error response to exception. /// </summary> /// <param name="context"></param> /// <param name="innerException"></param> /// <param name="statusCode"></param> /// <returns></returns> public override AmazonServiceException UnmarshallException(JsonUnmarshallerContext context, Exception innerException, HttpStatusCode statusCode) { var errorResponse = JsonErrorResponseUnmarshaller.GetInstance().Unmarshall(context); errorResponse.InnerException = innerException; errorResponse.StatusCode = statusCode; var responseBodyBytes = context.GetResponseBodyBytes(); using (var streamCopy = new MemoryStream(responseBodyBytes)) using (var contextCopy = new JsonUnmarshallerContext(streamCopy, false, null)) { if (errorResponse.Code != null && errorResponse.Code.Equals("InternalFailureException")) { return InternalFailureExceptionUnmarshaller.Instance.Unmarshall(contextCopy, errorResponse); } if (errorResponse.Code != null && errorResponse.Code.Equals("InvalidRequestException")) { return InvalidRequestExceptionUnmarshaller.Instance.Unmarshall(contextCopy, errorResponse); } if (errorResponse.Code != null && errorResponse.Code.Equals("ResourceNotFoundException")) { return ResourceNotFoundExceptionUnmarshaller.Instance.Unmarshall(contextCopy, errorResponse); } } return new AmazonIoT1ClickProjectsException(errorResponse.Message, errorResponse.InnerException, errorResponse.Type, errorResponse.Code, errorResponse.RequestId, errorResponse.StatusCode); } private static ListTagsForResourceResponseUnmarshaller _instance = new ListTagsForResourceResponseUnmarshaller(); internal static ListTagsForResourceResponseUnmarshaller GetInstance() { return _instance; } /// <summary> /// Gets the singleton. /// </summary> public static ListTagsForResourceResponseUnmarshaller Instance { get { return _instance; } } } }
39.855932
200
0.655326
[ "Apache-2.0" ]
ChristopherButtars/aws-sdk-net
sdk/src/Services/IoT1ClickProjects/Generated/Model/Internal/MarshallTransformations/ListTagsForResourceResponseUnmarshaller.cs
4,703
C#
using System.Reflection; using System.Runtime.InteropServices; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("ESFA.DC.ILR1819.DataStore.Stateless.Test")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("ESFA.DC.ILR1819.DataStore.Stateless.Test")] [assembly: AssemblyCopyright("Copyright © 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] // Setting ComVisible to false makes the types in this assembly not visible // to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] // The following GUID is for the ID of the typelib if this project is exposed to COM [assembly: Guid("09e114fa-2b1a-4a64-9268-5ae0f741ebff")] // Version information for an assembly consists of the following four values: // // Major Version // Minor Version // Build Number // Revision // // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
39.138889
84
0.747339
[ "MIT" ]
SkillsFundingAgency/DC-ILR-1819-DataStore
src/ESFA.DC.ILR1819.DataStore.Stateless.Test/Properties/AssemblyInfo.cs
1,412
C#
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; namespace WebFrontend.Controllers { public class HomeController : Controller { public ActionResult Index() { return View(); } public ActionResult About() { ViewBag.Message = "Your application description page."; return View(); } public ActionResult Contact() { ViewBag.Message = "Your contact page."; return View(); } } }
19.266667
67
0.564014
[ "Apache-2.0" ]
mihail-morosan/OCAPE
WebFrontend/WebFrontend/Controllers/HomeController.cs
580
C#
//___________________________________________________________________________________ // // Copyright (C) 2019, Mariusz Postol LODZ POLAND. // // To be in touch join the community at GITTER: https://gitter.im/mpostol/OPC-UA-OOI //___________________________________________________________________________________ namespace UAOOI.Networking.Core { /// <summary> /// Interface IMessageHandlerFactory - creates objects supporting the Data Transfer Graph messages handling over the wire. /// </summary> public interface IMessageHandlerFactory { /// <summary> /// Gets an instance implementing <see cref="IBinaryDataTransferGraphReceiver" /> interface. /// </summary> /// <param name="name">The name to be used for identification of the underlying DTG transport channel.</param> /// <param name="configuration">The configuration of the object implementing the <see cref="IBinaryDataTransferGraphReceiver" />.</param> /// <returns>An object implementing <see cref="IBinaryDataTransferGraphReceiver" /> that provides functionality supporting reading the messages from the wire.</returns> IBinaryDataTransferGraphReceiver GetBinaryDTGReceiver(string name, string configuration); /// <summary> /// Gets an instance implementing <see cref="IBinaryDataTransferGraphSender" /> interface. /// </summary> /// <param name="name">The name to be used for identification of the underlying DTG transport channel.</param> /// <param name="configuration">The configuration of the object implementing the <see cref="IBinaryDataTransferGraphSender" />.</param> /// <returns>An object implementing <see cref="IBinaryDataTransferGraphSender" /> that provides functionality supporting sending the messages over the wire.</returns> IBinaryDataTransferGraphSender GetBinaryDTGSender(string name, string configuration); } }
55.029412
172
0.765901
[ "MIT" ]
BiancoRoyal/OPC-UA-OOI
Networking/Core/IMessageHandlerFactory.cs
1,873
C#
using GatewayServer.AsyncProxyConfig; using GatewayServer.AsyncProxyConfig.ConfigHelper; using Yarp.ReverseProxy.Configuration; namespace GatewayServer.AsyncProxyConfig.ProxyAsyncProvider { public class AsyncProxyConfigProvider : IProxyConfigProvider { private volatile AsyncProxyConfig _config; private readonly IAsyncProxyConfigHelper proxyConfigProvider; public AsyncProxyConfigProvider(IAsyncProxyConfigHelper proxyConfigProvider) { this.proxyConfigProvider = proxyConfigProvider; _config = new AsyncProxyConfig(new List<RouteConfig>(), new List<ClusterConfig>()); } public IProxyConfig GetConfig() { return _config; } /// <summary> /// 初始化代理配置 /// </summary> /// <returns></returns> public async Task<bool> InitProxyConfig() { return await this.Reload(); } /// <summary> /// 重新加载配置 /// </summary> /// <param name="routes"></param> /// <param name="clusters"></param> /// <returns></returns> public async Task<bool> Reload() { return await this.LoadConfigFromDb(); } private async Task<bool> LoadConfigFromDb() { // 1. 拉取配置数据 var proxyConfig = await proxyConfigProvider.GetConfig(); // 2. 启动更新 var oldConfig = _config; // 加载新配置 _config = new AsyncProxyConfig(proxyConfig.routes, proxyConfig.clusters); // 释放老配置 oldConfig.SignalChange(); return true; } } }
28.220339
95
0.586787
[ "MIT" ]
hstarorg/bizgw
GatewayServer.AsyncProxyConfig/ProxyAsyncProvider/AsyncProxyConfigProvider.cs
1,733
C#
/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the macie2-2020-01-01.normal.json service model. */ using System; using System.Collections.Generic; using System.Xml.Serialization; using System.Text; using System.IO; using System.Net; using Amazon.Runtime; using Amazon.Runtime.Internal; namespace Amazon.Macie2.Model { /// <summary> /// Specifies a property- or tag-based condition that defines criteria for including or /// excluding S3 buckets from a classification job. /// </summary> public partial class CriteriaForJob { private SimpleCriterionForJob _simpleCriterion; private TagCriterionForJob _tagCriterion; /// <summary> /// Gets and sets the property SimpleCriterion. /// <para> /// A property-based condition that defines a property, operator, and one or more values /// for including or excluding buckets from the job. /// </para> /// </summary> public SimpleCriterionForJob SimpleCriterion { get { return this._simpleCriterion; } set { this._simpleCriterion = value; } } // Check to see if SimpleCriterion property is set internal bool IsSetSimpleCriterion() { return this._simpleCriterion != null; } /// <summary> /// Gets and sets the property TagCriterion. /// <para> /// A tag-based condition that defines an operator and tag keys, tag values, or tag key /// and value pairs for including or excluding buckets from the job. /// </para> /// </summary> public TagCriterionForJob TagCriterion { get { return this._tagCriterion; } set { this._tagCriterion = value; } } // Check to see if TagCriterion property is set internal bool IsSetTagCriterion() { return this._tagCriterion != null; } } }
32.227848
104
0.645326
[ "Apache-2.0" ]
ChristopherButtars/aws-sdk-net
sdk/src/Services/Macie2/Generated/Model/CriteriaForJob.cs
2,546
C#
using System; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Text; using System.Threading.Tasks; namespace KeyHelperForms { class CharacterHandler { public List<Character> Characters { get; private set; } public CharacterHandler() { Characters = new List<Character>(); } public void AddCharacter(Process characterProcess) { if (FindCharacter(characterProcess.Id) == null) { Characters.Add(new Character(characterProcess)); //Also fill with initial delay values. } else { //Means the character is already on the list, we don't want any duplicates. } } public void RemoveCharacter(int processId) { Character currentCharacterObject = FindCharacter(processId); //It will return null at non existant pid. if (currentCharacterObject == null) { //Means we are trying to delete a non-existant object, don't do anything. } else { Characters.Remove(currentCharacterObject); } } public void RemoveCharacter(Character objectToRemove) { try { Characters.Remove(objectToRemove); } catch (ArgumentNullException) { //Maybe raise an error, no need for now. Just don't remove null object. } } public bool RenewAndCheckForChange(List<Process> newProcesses) { //TODO : I didn't like the name of the method, you could change it. bool didSomethingChange = false; //Check the status of every process and remove dead ones, also add the new ones. for(int currentIndex = Characters.Count-1; currentIndex >= 0; currentIndex--) //There may be some dead processes. We must find them... AND DESTROY THEM ! { try { Characters[currentIndex].RefreshCharacterValues(); //If user logs to different char, this method will handle it. if (Characters[currentIndex].ClientProcess.HasExited || Characters[currentIndex].CharacterName.Equals(String.Empty)) { //Means if we exited or restarted the client without logging in again. RemoveCharacter(Characters[currentIndex]); //Delete exited process. Garbage collector will handle the rest. didSomethingChange = true; } } catch (IndexOutOfRangeException) { break; //Wisest approach i think is to stop this madness. } } if(newProcesses.Count == Characters.Count && didSomethingChange == false) { //Means no character has been removed and no new process has arrived. It is safe to end here. return false; } foreach (Process thisNewProcess in newProcesses) //After destructon, construction always comes. { AddCharacter(thisNewProcess); //Remember that this method handles duplicate process, so don't worry. didSomethingChange = true; } return didSomethingChange; } public void StartCharacterPress(int index) { Characters[index].StartPressing(); } public void StopCharacterPress(int index) { Characters[index].StopPressing(); } public Character FindCharacter(int processId) //MAY RETURN NULL, BE WARY. { foreach (Character currentChar in Characters) { if (currentChar.ClientProcess.Id == processId) { return currentChar; } } return null; } public void ResetCharacters() { Characters.Clear(); } public int GetCharacterCount() { return Characters.Count; } public void ShowEveryClient() { foreach(Character currentChar in Characters) { currentChar.ShowClient(); } } } }
35.814516
165
0.545373
[ "MIT" ]
furkanarabaci/KeyHelperForms
KeyHelperForms/CharacterHandler.cs
4,443
C#
using System; namespace Project { public abstract class CalculatorAdapter { protected Calculator _calculator; public CalculatorAdapter(Calculator calculator) { _calculator = calculator; } public abstract int Sum(); public abstract int Sub(); } }
17.833333
55
0.613707
[ "MIT" ]
danieldeveloper001/csharp_design_patterns
src/structural/adapter/002_concrete_internal_services/Adapter/CalculatorAdapter.cs
321
C#
using System; using System.Diagnostics; using System.Threading.Tasks; using DeviceCheck; using Foundation; using NDB.Covid19.Models.UserDefinedExceptions; using NDB.Covid19.OAuth2; using NDB.Covid19.ViewModels; using NDB.Covid19.iOS.Utils; using NDB.Covid19.Utils; using UIKit; using NDB.Covid19.Enums; using System.Collections.Generic; using static NDB.Covid19.PersistedData.LocalPreferencesHelper; namespace NDB.Covid19.iOS.Views.AuthenticationFlow { public partial class InformationAndConsentViewController : BaseViewController, IUIAccessibilityContainer { public InformationAndConsentViewController (IntPtr handle) : base (handle) { } public static InformationAndConsentViewController GetInformationAndConsentViewController() { UIStoryboard storyboard = UIStoryboard.FromName("InformationAndConsent", null); InformationAndConsentViewController vc = storyboard.InstantiateInitialViewController() as InformationAndConsentViewController; vc.ModalPresentationStyle = UIModalPresentationStyle.FullScreen; return vc; } InformationAndConsentViewModel _viewModel; UIViewController _authViewController; public override void ViewDidLoad() { base.ViewDidLoad(); _viewModel = new InformationAndConsentViewModel(OnAuthSuccess, OnAuthError); _viewModel.Init(); SetTexts(); SetupStyling(); SetupAccessibility(); AddObservers(); } public override void ViewWillAppear(bool animated) { base.ViewWillAppear(animated); LogUtils.LogMessage(LogSeverity.INFO, "The user is seeing Information and Consent page", null); } public override void ViewWillDisappear(bool animated) { base.ViewWillDisappear(animated); LogInWithIDPortenBtn.HideSpinner(); MessagingCenter.Unsubscribe<object>(this, MessagingCenterKeys.KEY_APP_BECAME_ACTIVE); MessagingCenter.Unsubscribe<object>(this, MessagingCenterKeys.KEY_APP_RESIGN_ACTIVE); } void AddObservers() { MessagingCenter.Subscribe<object>(this, MessagingCenterKeys.KEY_APP_BECAME_ACTIVE, (object _) => { LogUtils.LogMessage(LogSeverity.INFO, "The user is seeing Information and Consent page", null); }); MessagingCenter.Subscribe<object>(this, MessagingCenterKeys.KEY_APP_RESIGN_ACTIVE, (object _) => { LogUtils.LogMessage(LogSeverity.INFO, "The user left Information and Consent page", null); }); } private void SetTexts() { HeaderLabel.SetAttributedText(InformationAndConsentViewModel.INFORMATION_CONSENT_HEADER_TEXT); DescriptionLabel.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_DESCRIPTION); LookUp_Header.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_LOOKUP_HEADER, StyleUtil.FontType.FontBold); LookUp_Text.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_LOOKUP_TEXT); Notification_Header.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_NOTIFICATION_HEADER, StyleUtil.FontType.FontBold); Notification_Text.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_NOTIFICATION_TEXT); Consent_BeAware_Text.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_CONSENT_BEAWARE_TEXT); Consent_Explanation_Text.SetAttributedText(InformationAndConsentViewModel.INFOCONSENT_CONSENT_EXPLANATION_TEXT, StyleUtil.FontType.FontItalic); } public void SetupStyling() { HeaderLabel.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; DescriptionLabel.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; LookUp_Header.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; LookUp_Text.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; Notification_Header.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; Notification_Text.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; Consent_BeAware_Text.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; Consent_Explanation_Text.TextColor = ColorHelper.TEXT_COLOR_ON_BACKGROUND; StyleUtil.InitButtonStyling(LogInWithIDPortenBtn, InformationAndConsentViewModel.INFORMATION_CONSENT_ID_PORTEN_BUTTON_TEXT); } private void SetupAccessibility() { HeaderLabel.AccessibilityTraits = UIAccessibilityTrait.Header; LookUp_Header.AccessibilityTraits = UIAccessibilityTrait.Header; Notification_Header.AccessibilityTraits = UIAccessibilityTrait.Header; CloseBtn.AccessibilityLabel = InformationAndConsentViewModel.CLOSE_BUTTON_ACCESSIBILITY_LABEL; if (UIAccessibility.IsVoiceOverRunning) { this.SetAccessibilityElements(NSArray.FromNSObjects(ScrollView, CloseBtn)); PostAccessibilityNotificationAndReenableElement(CloseBtn, HeaderLabel); } } void OnAuthError(object sender, AuthErrorType authErrorType) { _viewModel.Cleanup(); Debug.Print("OnAuthError"); LogUtils.LogMessage(LogSeverity.INFO, "Authentication failed."); LogInWithIDPortenBtn.HideSpinner(); Utils.AuthErrorUtils.GoToErrorPageForAuthErrorType(this, authErrorType); _authViewController.DismissViewController(true, null); } void OnAuthSuccess(object sender, EventArgs e) { Debug.Print("OnAuthSuccess"); LogUtils.LogMessage(LogSeverity.INFO, $"Successfully authenticated and verifeid user. Navigating to {nameof(QuestionnaireViewController)}"); LogInWithIDPortenBtn.HideSpinner(); GoToQuestionnairePage(); _authViewController.DismissViewController(true, null); } partial void OnLoginBtnTapped(CustomSubclasses.DefaultBorderButton sender) { InvokeOnMainThread(() => { LogInWithIDPortenBtn.ShowSpinner(View, UIActivityIndicatorViewStyle.White); }); LogUtils.LogMessage(Enums.LogSeverity.INFO, "Startet login with ID porten"); _authViewController = AuthenticationState.Authenticator.GetUI(); PresentViewController(_authViewController, true, null); } //After calling this method you cannot return to this page. //The entire Navigationcontroller has to be dismissed, and this controller must be reloaded and call ViewDidLoad() void GoToQuestionnairePage() { _viewModel.Cleanup(); NavigationController?.PushViewController(QuestionnaireViewController.Create(), true); } partial void OnCloseBtnTapped(UIButton sender) { _viewModel.Cleanup(); NavigationHelper.GoToResultPageFromAuthFlow(NavigationController); MessagingCenter.Send<object>(this, MessagingCenterKeys.KEY_CONSENT_MODAL_IS_CLOSED); } } }
44.539877
155
0.704545
[ "MIT" ]
folkehelseinstituttet/Fhi.Smittestopp.App
NDB.Covid19/NDB.Covid19.iOS/Views/AuthenticationFlow/InformationAndConsentViewController.cs
7,260
C#
using Bost.Proto.Enum; using Bost.Proto.Model; using Bost.Proto.Types; using System; namespace Bost.Proto.Packet.Play.Serverbound { public class PlayerBlockPlacementPacket : BasePacket { public override int PacketId => 0x2E; public HandType Hand; //Varint Enum public Position Location; public int Face; //Varint Enum public float CursorPositionX; public float CursorPositionY; public float CursorPositionZ; public bool InsideBlock; public override void Read(byte[] array) { if (McVarint.TryParse(ref array, out var hand)) Hand = (HandType)hand; Location = new Position(); Location.Read(ref array); _ = McVarint.TryParse(ref array, out Face); _ = McFloat.TryParse(ref array, out CursorPositionX); _ = McFloat.TryParse(ref array, out CursorPositionY); _ = McFloat.TryParse(ref array, out CursorPositionZ); _ = McBoolean.TryParse(ref array, out InsideBlock); } public override byte[] Write() { throw new NotImplementedException(); } public override string ToString() { return $"[PlayerBlockPlacement] Hand:{Hand} Location:{Location} Face:{Face} " + $"CursorPositionX:{CursorPositionX} CursorPositionY:{CursorPositionY} " + $"CursorPositionZ:{CursorPositionZ} InsideBlock:{InsideBlock}"; } } }
28.266667
82
0.727987
[ "MIT" ]
SlenderEmpire/CraftAI
gate/Bost.Proto/Packet/Play/Serverbound/PlayerBlockPlacementPacket.cs
1,274
C#
using Impatient.Tests.Northwind; using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Impatient.Tests { [TestClass] public class EFCoreTests { [TestMethod] public void TestEfCore_Basic() { EfCoreTestCase((context, log) => { var result = (from o in context.Set<Order>() select new { o, o.Customer }).FirstOrDefault(); Assert.IsNotNull(result); Assert.IsNotNull(result.o); Assert.IsNotNull(result.Customer); Assert.AreEqual(@" SELECT TOP (1) [o].[OrderID] AS [o.OrderID], [o].[CustomerID] AS [o.CustomerID], [o].[EmployeeID] AS [o.EmployeeID], [o].[Freight] AS [o.Freight], [o].[OrderDate] AS [o.OrderDate], [o].[RequiredDate] AS [o.RequiredDate], [o].[ShipAddress] AS [o.ShipAddress], [o].[ShipCity] AS [o.ShipCity], [o].[ShipCountry] AS [o.ShipCountry], [o].[ShipName] AS [o.ShipName], [o].[ShipPostalCode] AS [o.ShipPostalCode], [o].[ShipRegion] AS [o.ShipRegion], [o].[ShipVia] AS [o.ShipVia], [o].[ShippedDate] AS [o.ShippedDate], [c].[CustomerID] AS [Customer.CustomerID], [c].[Address] AS [Customer.Address], [c].[City] AS [Customer.City], [c].[CompanyName] AS [Customer.CompanyName], [c].[ContactName] AS [Customer.ContactName], [c].[ContactTitle] AS [Customer.ContactTitle], [c].[Country] AS [Customer.Country], [c].[Fax] AS [Customer.Fax], [c].[Phone] AS [Customer.Phone], [c].[PostalCode] AS [Customer.PostalCode], [c].[Region] AS [Customer.Region] FROM [dbo].[Orders] AS [o] INNER JOIN [dbo].[Customers] AS [c] ON [o].[CustomerID] = [c].[CustomerID] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Tracking_Basic() { EfCoreTestCase((context, log) => { var order1 = context.Set<Order>().FirstOrDefault(); var order2 = context.Set<Order>().FirstOrDefault(); var entries = context.ChangeTracker.Entries(); Assert.AreEqual(1, entries.Count()); Assert.IsNotNull(order1); Assert.IsNotNull(order2); Assert.AreEqual(order1, order2); }); } [TestMethod] public async Task FirstOrDefaultAsync() { await EfCoreTestCaseAsync(async (context, log) => { var order = await context.Set<Order>().FirstOrDefaultAsync(); Assert.IsNotNull(order); Assert.AreEqual(1, context.ChangeTracker.Entries().Count()); Assert.AreEqual(@" SELECT TOP (1) [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate] FROM [dbo].[Orders] AS [o] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public async Task FirstOrDefaultAsync_Predicate() { await EfCoreTestCaseAsync(async (context, log) => { var order = await context.Set<Order>().FirstOrDefaultAsync(o => o.OrderID == 10252); Assert.IsNotNull(order); Assert.AreEqual(1, context.ChangeTracker.Entries().Count()); Assert.AreEqual(@" SELECT TOP (1) [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate] FROM [dbo].[Orders] AS [o] WHERE [o].[OrderID] = 10252 ".Trim(), log.ToString().Trim()); }); } [TestMethod] public async Task ToListAsync() { await EfCoreTestCaseAsync(async (context, log) => { var orders = await context.Set<Order>().Where(o => o.OrderID == 10252).ToListAsync(); Assert.AreEqual(1, orders.Count); Assert.AreEqual(1, context.ChangeTracker.Entries().Count()); Assert.AreEqual(@" SELECT [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate] FROM [dbo].[Orders] AS [o] WHERE [o].[OrderID] = 10252 ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Tracking_Nested_Complex() { EfCoreTestCase((context, log) => { var results = (from o in context.Set<Order>() let cs = context.Set<Customer>().Where(c => c.CustomerID.StartsWith("A")).Take(1).ToArray() select new { o, cs }).Take(2).ToArray(); Assert.AreEqual(3, context.ChangeTracker.Entries().Count()); Assert.AreEqual(results[0].cs.Single(), results[1].cs.Single()); }); } [TestMethod] public void Tracking_Basic_AsNoTracking() { EfCoreTestCase((context, log) => { var details = (from d in context.Set<OrderDetail>().AsNoTracking() where d.OrderID == 10252 from d2 in d.Order.OrderDetails select d2).ToList(); Assert.AreEqual(0, context.ChangeTracker.Entries().Count()); Assert.AreNotEqual(details.Count, details.Distinct().Count()); Assert.AreEqual(@" SELECT [d2].[OrderID] AS [OrderID], [d2].[ProductID] AS [ProductID], [d2].[Discount] AS [Discount], [d2].[Quantity] AS [Quantity], [d2].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d] INNER JOIN [dbo].[Orders] AS [o] ON [d].[OrderID] = [o].[OrderID] INNER JOIN ( SELECT [d_0].[OrderID] AS [OrderID], [d_0].[ProductID] AS [ProductID], [d_0].[Discount] AS [Discount], [d_0].[Quantity] AS [Quantity], [d_0].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d_0] WHERE [d_0].[UnitPrice] >= 5.0 ) AS [d2] ON [o].[OrderID] = [d2].[OrderID] WHERE ([d].[UnitPrice] >= 5.0) AND ([d].[OrderID] = 10252) ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Include_ManyToOne() { EfCoreTestCase((context, log) => { var result = context.Set<Order>().Include(o => o.Customer).FirstOrDefault(); Assert.IsNotNull(result); Assert.IsNotNull(result.Customer); Assert.AreEqual(@" SELECT TOP (1) [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate], [c].[CustomerID] AS [Customer.CustomerID], [c].[Address] AS [Customer.Address], [c].[City] AS [Customer.City], [c].[CompanyName] AS [Customer.CompanyName], [c].[ContactName] AS [Customer.ContactName], [c].[ContactTitle] AS [Customer.ContactTitle], [c].[Country] AS [Customer.Country], [c].[Fax] AS [Customer.Fax], [c].[Phone] AS [Customer.Phone], [c].[PostalCode] AS [Customer.PostalCode], [c].[Region] AS [Customer.Region] FROM [dbo].[Orders] AS [o] INNER JOIN [dbo].[Customers] AS [c] ON [o].[CustomerID] = [c].[CustomerID] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Include_ManyToOne_ThenInclude_ManyToOne() { EfCoreTestCase((context, log) => { var result = context.Set<OrderDetail>().Include(d => d.Order).ThenInclude(o => o.Customer).FirstOrDefault(); Assert.IsNotNull(result); Assert.IsNotNull(result.Order?.Customer); Assert.AreEqual(@" SELECT TOP (1) [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice], [o].[OrderID] AS [Order.OrderID], [o].[CustomerID] AS [Order.CustomerID], [o].[EmployeeID] AS [Order.EmployeeID], [o].[Freight] AS [Order.Freight], [o].[OrderDate] AS [Order.OrderDate], [o].[RequiredDate] AS [Order.RequiredDate], [o].[ShipAddress] AS [Order.ShipAddress], [o].[ShipCity] AS [Order.ShipCity], [o].[ShipCountry] AS [Order.ShipCountry], [o].[ShipName] AS [Order.ShipName], [o].[ShipPostalCode] AS [Order.ShipPostalCode], [o].[ShipRegion] AS [Order.ShipRegion], [o].[ShipVia] AS [Order.ShipVia], [o].[ShippedDate] AS [Order.ShippedDate], [c].[CustomerID] AS [Order.Customer.CustomerID], [c].[Address] AS [Order.Customer.Address], [c].[City] AS [Order.Customer.City], [c].[CompanyName] AS [Order.Customer.CompanyName], [c].[ContactName] AS [Order.Customer.ContactName], [c].[ContactTitle] AS [Order.Customer.ContactTitle], [c].[Country] AS [Order.Customer.Country], [c].[Fax] AS [Order.Customer.Fax], [c].[Phone] AS [Order.Customer.Phone], [c].[PostalCode] AS [Order.Customer.PostalCode], [c].[Region] AS [Order.Customer.Region] FROM [dbo].[Order Details] AS [d] INNER JOIN [dbo].[Orders] AS [o] ON [d].[OrderID] = [o].[OrderID] INNER JOIN [dbo].[Customers] AS [c] ON [o].[CustomerID] = [c].[CustomerID] WHERE [d].[UnitPrice] >= 5.0 ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Include_ManyToOne_Include_ManyToOne() { EfCoreTestCase((context, log) => { var result = context.Set<OrderDetail>().Include(d => d.Order).Include(d => d.Product).FirstOrDefault(); Assert.IsNotNull(result); Assert.IsNotNull(result.Order); Assert.IsNotNull(result.Product); Assert.AreEqual(@" SELECT TOP (1) [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice], [o].[OrderID] AS [Order.OrderID], [o].[CustomerID] AS [Order.CustomerID], [o].[EmployeeID] AS [Order.EmployeeID], [o].[Freight] AS [Order.Freight], [o].[OrderDate] AS [Order.OrderDate], [o].[RequiredDate] AS [Order.RequiredDate], [o].[ShipAddress] AS [Order.ShipAddress], [o].[ShipCity] AS [Order.ShipCity], [o].[ShipCountry] AS [Order.ShipCountry], [o].[ShipName] AS [Order.ShipName], [o].[ShipPostalCode] AS [Order.ShipPostalCode], [o].[ShipRegion] AS [Order.ShipRegion], [o].[ShipVia] AS [Order.ShipVia], [o].[ShippedDate] AS [Order.ShippedDate], [p].[Item1] AS [Product.Item1], [p].[Item2] AS [Product.Item2], [p].[Item3] AS [Product.Item3], [p].[Item4] AS [Product.Item4], [p].[Item5] AS [Product.Item5], [p].[Item6] AS [Product.Item6], [p].[Item7] AS [Product.Item7], [p].[Rest.Item1] AS [Product.Rest.Item1], [p].[Rest.Item2] AS [Product.Rest.Item2], [p].[Rest.Item3] AS [Product.Rest.Item3] FROM [dbo].[Order Details] AS [d] INNER JOIN [dbo].[Orders] AS [o] ON [d].[OrderID] = [o].[OrderID] INNER JOIN ( SELECT [p_0].[ProductID] AS [Item1], [p_0].[CategoryID] AS [Item2], [p_0].[Discontinued] AS [Item3], [p_0].[ProductName] AS [Item4], [p_0].[SupplierID] AS [Item5], [p_0].[QuantityPerUnit] AS [Item6], [p_0].[ReorderLevel] AS [Item7], [p_0].[UnitPrice] AS [Rest.Item1], [p_0].[UnitsInStock] AS [Rest.Item2], [p_0].[UnitsOnOrder] AS [Rest.Item3] FROM [dbo].[Products] AS [p_0] WHERE [p_0].[Discontinued] IN (0, 1) ) AS [p] ON [d].[ProductID] = [p].[Item1] WHERE [d].[UnitPrice] >= 5.0 ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Include_OneToMany() { EfCoreTestCase((context, log) => { var result = context.Set<Customer>().Include(c => c.Orders).FirstOrDefault(); Assert.IsNotNull(result); Assert.IsTrue(result.Orders.Any()); Assert.AreEqual(@" SELECT TOP (1) [c].[CustomerID] AS [CustomerID], [c].[Address] AS [Address], [c].[City] AS [City], [c].[CompanyName] AS [CompanyName], [c].[ContactName] AS [ContactName], [c].[ContactTitle] AS [ContactTitle], [c].[Country] AS [Country], [c].[Fax] AS [Fax], [c].[Phone] AS [Phone], [c].[PostalCode] AS [PostalCode], [c].[Region] AS [Region], ( SELECT [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate] FROM [dbo].[Orders] AS [o] WHERE [c].[CustomerID] = [o].[CustomerID] FOR JSON PATH ) AS [Orders] FROM [dbo].[Customers] AS [c] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Include_OneToMany_ThenInclude_OneToMany() { EfCoreTestCase((context, log) => { var result = context.Set<Customer>().Include(c => c.Orders).ThenInclude(o => o.OrderDetails).FirstOrDefault(); Assert.IsNotNull(result); Assert.IsTrue(result.Orders.Any()); Assert.AreEqual(@" SELECT TOP (1) [c].[CustomerID] AS [CustomerID], [c].[Address] AS [Address], [c].[City] AS [City], [c].[CompanyName] AS [CompanyName], [c].[ContactName] AS [ContactName], [c].[ContactTitle] AS [ContactTitle], [c].[Country] AS [Country], [c].[Fax] AS [Fax], [c].[Phone] AS [Phone], [c].[PostalCode] AS [PostalCode], [c].[Region] AS [Region], ( SELECT [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate], ( SELECT [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d] WHERE ([d].[UnitPrice] >= 5.0) AND ([o].[OrderID] = [d].[OrderID]) FOR JSON PATH ) AS [OrderDetails] FROM [dbo].[Orders] AS [o] WHERE [c].[CustomerID] = [o].[CustomerID] FOR JSON PATH ) AS [Orders] FROM [dbo].[Customers] AS [c] ".Trim(), log.ToString().Trim()); }); } private static Customer ForceNonTranslatable(NorthwindDbContext context, Order order) { return context.Set<Customer>().Single(c => c.CustomerID == order.CustomerID); } [TestMethod] public void QueryFilter_Via_TopLevel() { EfCoreTestCase((context, log) => { var results = context.Set<OrderDetail>().Where(d => d.OrderID == 10252).ToList(); Assert.IsFalse(results.Any(r => r.UnitPrice < 5.00m)); Assert.AreEqual(2, results.Count); Assert.AreEqual(@" SELECT [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d] WHERE ([d].[UnitPrice] >= 5.0) AND ([d].[OrderID] = 10252) ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void QueryFilter_Via_Navigation() { EfCoreTestCase((context, log) => { var results = (from o in context.Set<Order>() where o.OrderID == 10252 from d in o.OrderDetails select d).ToList(); Assert.AreEqual(@" SELECT [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice] FROM [dbo].[Orders] AS [o] INNER JOIN ( SELECT [d_0].[OrderID] AS [OrderID], [d_0].[ProductID] AS [ProductID], [d_0].[Discount] AS [Discount], [d_0].[Quantity] AS [Quantity], [d_0].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d_0] WHERE [d_0].[UnitPrice] >= 5.0 ) AS [d] ON [o].[OrderID] = [d].[OrderID] WHERE [o].[OrderID] = 10252 ".Trim(), log.ToString().Trim()); Assert.IsFalse(results.Any(r => r.UnitPrice < 5.00m)); Assert.AreEqual(2, results.Count); }); } [TestMethod] public void QueryFilter_Via_TopLevel_IgnoreQueryFilters() { EfCoreTestCase((context, log) => { var results = context.Set<OrderDetail>().IgnoreQueryFilters().Where(d => d.OrderID == 10252).ToList(); Assert.IsTrue(results.Any(r => r.UnitPrice < 5.00m)); Assert.AreEqual(3, results.Count); Assert.AreEqual(@" SELECT [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d] WHERE [d].[OrderID] = 10252 ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void QueryFilter_Via_Navigation_IgnoreQueryFilters() { EfCoreTestCase((context, log) => { var results = (from o in context.Set<Order>() where o.OrderID == 10252 from d in o.OrderDetails select d).IgnoreQueryFilters().ToList(); Assert.IsTrue(results.Any(r => r.UnitPrice < 5.00m)); Assert.AreEqual(3, results.Count); Assert.AreEqual(@" SELECT [d].[OrderID] AS [OrderID], [d].[ProductID] AS [ProductID], [d].[Discount] AS [Discount], [d].[Quantity] AS [Quantity], [d].[UnitPrice] AS [UnitPrice] FROM [dbo].[Orders] AS [o] INNER JOIN [dbo].[Order Details] AS [d] ON [o].[OrderID] = [d].[OrderID] WHERE [o].[OrderID] = 10252 ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Inheritance_TPH_Simple() { EfCoreTestCase((context, log) => { var results = context.Set<Product>().ToList(); Assert.IsTrue(results.Where(r => !r.Discontinued).All(r => r is Product && !(r is DiscontinuedProduct))); Assert.IsTrue(results.Where(r => r.Discontinued).All(r => r is DiscontinuedProduct)); Assert.AreEqual(@" SELECT [p].[ProductID] AS [Item1], [p].[CategoryID] AS [Item2], [p].[Discontinued] AS [Item3], [p].[ProductName] AS [Item4], [p].[SupplierID] AS [Item5], [p].[QuantityPerUnit] AS [Item6], [p].[ReorderLevel] AS [Item7], [p].[UnitPrice] AS [Rest.Item1], [p].[UnitsInStock] AS [Rest.Item2], [p].[UnitsOnOrder] AS [Rest.Item3] FROM [dbo].[Products] AS [p] WHERE [p].[Discontinued] IN (0, 1) ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void Inheritance_TPH_OfType() { EfCoreTestCase((context, log) => { var results = context.Set<Product>().OfType<DiscontinuedProduct>().ToList(); Assert.IsTrue(results.All(r => r is DiscontinuedProduct && r.Discontinued)); Assert.AreEqual(@" SELECT [p].[ProductID] AS [Item1], [p].[CategoryID] AS [Item2], [p].[Discontinued] AS [Item3], [p].[ProductName] AS [Item4], [p].[SupplierID] AS [Item5], [p].[QuantityPerUnit] AS [Item6], [p].[ReorderLevel] AS [Item7], [p].[UnitPrice] AS [Rest.Item1], [p].[UnitsInStock] AS [Rest.Item2], [p].[UnitsOnOrder] AS [Rest.Item3] FROM [dbo].[Products] AS [p] WHERE [p].[Discontinued] IN (0, 1) AND ([p].[Discontinued] = 1) ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void OwnedEntity_OneLevelDeep() { EfCoreTestCase((context, log) => { var product = context.Set<Product>().First(); Assert.IsNotNull(product.ProductStats); Assert.AreEqual(@" SELECT TOP (1) [p].[ProductID] AS [Item1], [p].[CategoryID] AS [Item2], [p].[Discontinued] AS [Item3], [p].[ProductName] AS [Item4], [p].[SupplierID] AS [Item5], [p].[QuantityPerUnit] AS [Item6], [p].[ReorderLevel] AS [Item7], [p].[UnitPrice] AS [Rest.Item1], [p].[UnitsInStock] AS [Rest.Item2], [p].[UnitsOnOrder] AS [Rest.Item3] FROM [dbo].[Products] AS [p] WHERE [p].[Discontinued] IN (0, 1) ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void EFProperty_translated() { EfCoreTestCase((context, log) => { var result = (from p in context.Set<Product>() select EF.Property<short?>(p.ProductStats, "ReorderLevel")).FirstOrDefault(); Assert.AreEqual(@" SELECT TOP (1) [p].[ReorderLevel] FROM [dbo].[Products] AS [p] WHERE [p].[Discontinued] IN (0, 1) ".Trim(), log.ToString().Trim()); }); } private static bool ClientPredicate<TArg>(TArg arg) { return true; } [TestMethod] public void EFProperty_at_client() { EfCoreTestCase((context, log) => { var result = (from p in context.Set<Product>() where ClientPredicate(p) select EF.Property<short?>(p.ProductStats, "ReorderLevel")).FirstOrDefault(); Assert.AreEqual(@" SELECT [p].[ProductID] AS [Item1], [p].[CategoryID] AS [Item2], [p].[Discontinued] AS [Item3], [p].[ProductName] AS [Item4], [p].[SupplierID] AS [Item5], [p].[QuantityPerUnit] AS [Item6], [p].[ReorderLevel] AS [Item7], [p].[UnitPrice] AS [Rest.Item1], [p].[UnitsInStock] AS [Rest.Item2], [p].[UnitsOnOrder] AS [Rest.Item3] FROM [dbo].[Products] AS [p] WHERE [p].[Discontinued] IN (0, 1) ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void NestedReaders() { var services = new ServiceCollection(); var loggerProvider = new TestConnectionLoggerProvider(); services.AddLogging(log => { log .AddProvider(loggerProvider) .SetMinimumLevel(LogLevel.Debug) .AddFilter((category, level) => category.StartsWith(DbLoggerCategory.Database.Name)); }); services.AddDbContext<NorthwindDbContext>(options => { options .UseSqlServer(@"Server=.\sqlexpress; Database=NORTHWND; Trusted_Connection=true") .UseImpatient(); }); var provider = services.BuildServiceProvider(); using (var scope = provider.CreateScope()) using (var context = scope.ServiceProvider.GetRequiredService<NorthwindDbContext>()) { var result = (from o in context.Set<Order>() select new { o, Customer = context.Set<Customer>().Where(ClientPredicate).FirstOrDefault() }).Take(5).ToArray(); Assert.AreEqual(@"Opening connection t Opened connection to Executing DbCommand Executed DbCommand ( Executing DbCommand Executed DbCommand ( Executing DbCommand Executed DbCommand ( Executing DbCommand Executed DbCommand ( Executing DbCommand Executed DbCommand ( Executing DbCommand Executed DbCommand ( Closing connection t Closed connection to ", loggerProvider.LoggerInstance.StringBuilder.ToString()); } } [TestMethod] public void TrickyJson_ProperChangeTracking() { EfCoreTestCase((context, log) => { var customers = context.Set<Customer>(); var orders = context.Set<Order>(); var details = context.Set<OrderDetail>(); var query = from t in (from c in customers from t in (from o in orders where o.CustomerID == c.CustomerID let d = from d in details where d.OrderID == o.OrderID select d select new { o, d }).Where(x => x.o.Freight == null) select new { c, t.o, t.d }).Take(10) from d in t.d select new { t.c, t.o, d }; var results = query.ToList(); Assert.IsTrue(results.All(r => r.c == r.o.Customer)); Assert.IsTrue(results.All(r => r.o == r.d.Order)); Assert.AreEqual(@" SELECT [t].[c.CustomerID] AS [c.CustomerID], [t].[c.Address] AS [c.Address], [t].[c.City] AS [c.City], [t].[c.CompanyName] AS [c.CompanyName], [t].[c.ContactName] AS [c.ContactName], [t].[c.ContactTitle] AS [c.ContactTitle], [t].[c.Country] AS [c.Country], [t].[c.Fax] AS [c.Fax], [t].[c.Phone] AS [c.Phone], [t].[c.PostalCode] AS [c.PostalCode], [t].[c.Region] AS [c.Region], [t].[o.OrderID] AS [o.OrderID], [t].[o.CustomerID] AS [o.CustomerID], [t].[o.EmployeeID] AS [o.EmployeeID], [t].[o.Freight] AS [o.Freight], [t].[o.OrderDate] AS [o.OrderDate], [t].[o.RequiredDate] AS [o.RequiredDate], [t].[o.ShipAddress] AS [o.ShipAddress], [t].[o.ShipCity] AS [o.ShipCity], [t].[o.ShipCountry] AS [o.ShipCountry], [t].[o.ShipName] AS [o.ShipName], [t].[o.ShipPostalCode] AS [o.ShipPostalCode], [t].[o.ShipRegion] AS [o.ShipRegion], [t].[o.ShipVia] AS [o.ShipVia], [t].[o.ShippedDate] AS [o.ShippedDate], [d].[value] AS [d] FROM ( SELECT TOP (10) [c].[CustomerID] AS [c.CustomerID], [c].[Address] AS [c.Address], [c].[City] AS [c.City], [c].[CompanyName] AS [c.CompanyName], [c].[ContactName] AS [c.ContactName], [c].[ContactTitle] AS [c.ContactTitle], [c].[Country] AS [c.Country], [c].[Fax] AS [c.Fax], [c].[Phone] AS [c.Phone], [c].[PostalCode] AS [c.PostalCode], [c].[Region] AS [c.Region], [t_0].[o.OrderID] AS [o.OrderID], [t_0].[o.CustomerID] AS [o.CustomerID], [t_0].[o.EmployeeID] AS [o.EmployeeID], [t_0].[o.Freight] AS [o.Freight], [t_0].[o.OrderDate] AS [o.OrderDate], [t_0].[o.RequiredDate] AS [o.RequiredDate], [t_0].[o.ShipAddress] AS [o.ShipAddress], [t_0].[o.ShipCity] AS [o.ShipCity], [t_0].[o.ShipCountry] AS [o.ShipCountry], [t_0].[o.ShipName] AS [o.ShipName], [t_0].[o.ShipPostalCode] AS [o.ShipPostalCode], [t_0].[o.ShipRegion] AS [o.ShipRegion], [t_0].[o.ShipVia] AS [o.ShipVia], [t_0].[o.ShippedDate] AS [o.ShippedDate], [t_0].[d] AS [d] FROM [dbo].[Customers] AS [c] CROSS APPLY ( SELECT [o].[OrderID] AS [o.OrderID], [o].[CustomerID] AS [o.CustomerID], [o].[EmployeeID] AS [o.EmployeeID], [o].[Freight] AS [o.Freight], [o].[OrderDate] AS [o.OrderDate], [o].[RequiredDate] AS [o.RequiredDate], [o].[ShipAddress] AS [o.ShipAddress], [o].[ShipCity] AS [o.ShipCity], [o].[ShipCountry] AS [o.ShipCountry], [o].[ShipName] AS [o.ShipName], [o].[ShipPostalCode] AS [o.ShipPostalCode], [o].[ShipRegion] AS [o.ShipRegion], [o].[ShipVia] AS [o.ShipVia], [o].[ShippedDate] AS [o.ShippedDate], ( SELECT [d_0].[OrderID] AS [OrderID], [d_0].[ProductID] AS [ProductID], [d_0].[Discount] AS [Discount], [d_0].[Quantity] AS [Quantity], [d_0].[UnitPrice] AS [UnitPrice] FROM [dbo].[Order Details] AS [d_0] WHERE ([d_0].[UnitPrice] >= 5.0) AND ([d_0].[OrderID] = [o].[OrderID]) FOR JSON PATH ) AS [d] FROM [dbo].[Orders] AS [o] WHERE ([o].[CustomerID] = [c].[CustomerID]) AND ([o].[Freight] IS NULL) ) AS [t_0] ) AS [t] CROSS APPLY ( SELECT [j].[value] FROM OPENJSON([t].[d]) AS [j] ) AS [d] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void QueryType_AsTracking() { EfCoreTestCase((context, log) => { // Load the customers first context.Set<Customer>().AsTracking().ToList(); // Load the query type with the navigation to customers var qos = context .Query<QuarterlyOrders>() .AsTracking() .ToList(); }); } [TestMethod] public void OrderedQueryable_LetClause() { // The issue was that having an IOrderedQueryable in // a Select, that has an expanded navigation property, // will get rewritten into an IQueryable by the navigation // composing visitor, when it needs to stay an IOrderedQueryable // to satisfy things like anonymous type ctor sigs. EfCoreTestCase((context, log) => { var query = from c in context.Set<Customer>() let os = (from o in context.Set<Order>() where o.Customer == c orderby o.OrderDate select o) select new { c, os }; query.ToList(); Assert.AreEqual(@" SELECT [c].[CustomerID] AS [c.CustomerID], [c].[Address] AS [c.Address], [c].[City] AS [c.City], [c].[CompanyName] AS [c.CompanyName], [c].[ContactName] AS [c.ContactName], [c].[ContactTitle] AS [c.ContactTitle], [c].[Country] AS [c.Country], [c].[Fax] AS [c.Fax], [c].[Phone] AS [c.Phone], [c].[PostalCode] AS [c.PostalCode], [c].[Region] AS [c.Region], ( SELECT [o].[OrderID] AS [OrderID], [o].[CustomerID] AS [CustomerID], [o].[EmployeeID] AS [EmployeeID], [o].[Freight] AS [Freight], [o].[OrderDate] AS [OrderDate], [o].[RequiredDate] AS [RequiredDate], [o].[ShipAddress] AS [ShipAddress], [o].[ShipCity] AS [ShipCity], [o].[ShipCountry] AS [ShipCountry], [o].[ShipName] AS [ShipName], [o].[ShipPostalCode] AS [ShipPostalCode], [o].[ShipRegion] AS [ShipRegion], [o].[ShipVia] AS [ShipVia], [o].[ShippedDate] AS [ShippedDate] FROM [dbo].[Orders] AS [o] INNER JOIN [dbo].[Customers] AS [c_0] ON [o].[CustomerID] = [c_0].[CustomerID] WHERE [c_0].[CustomerID] = [c].[CustomerID] ORDER BY [o].[OrderDate] ASC FOR JSON PATH ) AS [os] FROM [dbo].[Customers] AS [c] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void DefaultIfEmpty_NoArg_Max_NoArg() { EfCoreTestCase((context, log) => { var query = from c in context.Set<Customer>() select new { c, o = c.Orders.Select(o => o.OrderDate).DefaultIfEmpty().Max() }; query.ToList(); Assert.AreEqual(@" SELECT [c].[CustomerID] AS [c.CustomerID], [c].[Address] AS [c.Address], [c].[City] AS [c.City], [c].[CompanyName] AS [c.CompanyName], [c].[ContactName] AS [c.ContactName], [c].[ContactTitle] AS [c.ContactTitle], [c].[Country] AS [c.Country], [c].[Fax] AS [c.Fax], [c].[Phone] AS [c.Phone], [c].[PostalCode] AS [c.PostalCode], [c].[Region] AS [c.Region], ( SELECT MAX((CASE WHEN [t].[$empty] IS NULL THEN [t].[OrderDate] ELSE NULL END)) FROM ( SELECT NULL AS [$empty] ) AS [t_0] LEFT JOIN ( SELECT 0 AS [$empty], [o].[OrderDate] FROM [dbo].[Orders] AS [o] WHERE [c].[CustomerID] = [o].[CustomerID] ) AS [t] ON 1 = 1 ) AS [o] FROM [dbo].[Customers] AS [c] ".Trim(), log.ToString().Trim()); }); } [TestMethod] public void GroupBy_Aggregate_Subquery() { EfCoreTestCase((context, log) => { var query = from c in context.Set<Customer>() let agg = c.Orders.Where(e => e.Freight != null).Max(o => o.Freight) group new { c, agg } by c.CustomerID into g select new { g.Key, agg = g.Sum(e => e.agg) }; query.ToList(); Assert.AreEqual(@" SELECT [c].[CustomerID] AS [Key], ( SELECT [c_0].[CustomerID] AS [c.CustomerID], [c_0].[Address] AS [c.Address], [c_0].[City] AS [c.City], [c_0].[CompanyName] AS [c.CompanyName], [c_0].[ContactName] AS [c.ContactName], [c_0].[ContactTitle] AS [c.ContactTitle], [c_0].[Country] AS [c.Country], [c_0].[Fax] AS [c.Fax], [c_0].[Phone] AS [c.Phone], [c_0].[PostalCode] AS [c.PostalCode], [c_0].[Region] AS [c.Region], ( SELECT MAX([o].[Freight]) FROM [dbo].[Orders] AS [o] WHERE ([c_0].[CustomerID] = [o].[CustomerID]) AND ([o].[Freight] IS NOT NULL) ) AS [agg] FROM [dbo].[Customers] AS [c_0] WHERE [c].[CustomerID] = [c_0].[CustomerID] FOR JSON PATH ) AS [Elements] FROM [dbo].[Customers] AS [c] GROUP BY [c].[CustomerID] ".Trim(), log.ToString().Trim()); }); } private void EfCoreTestCase(Action<NorthwindDbContext, StringBuilder> action) { var services = new ServiceCollection(); var loggerProvider = new TestLoggerProvider(); services.AddLogging(log => { log.AddProvider(loggerProvider); }); services.AddDbContext<NorthwindDbContext>(options => { options .UseSqlServer(@"Server=.\sqlexpress; Database=NORTHWND; Trusted_Connection=true; MultipleActiveResultSets=True") .UseImpatient(); }); var provider = services.BuildServiceProvider(); using (var scope = provider.CreateScope()) using (var context = scope.ServiceProvider.GetRequiredService<NorthwindDbContext>()) { action(context, loggerProvider.LoggerInstance.StringBuilder); } } private async Task EfCoreTestCaseAsync(Func<NorthwindDbContext, StringBuilder, Task> action) { var services = new ServiceCollection(); var loggerProvider = new TestLoggerProvider(); services.AddLogging(log => { log.AddProvider(loggerProvider); }); services.AddDbContext<NorthwindDbContext>(options => { options .UseSqlServer(@"Server=.\sqlexpress; Database=NORTHWND; Trusted_Connection=true; MultipleActiveResultSets=True") .UseImpatient(); }); var provider = services.BuildServiceProvider(); using (var scope = provider.CreateScope()) using (var context = scope.ServiceProvider.GetRequiredService<NorthwindDbContext>()) { await action(context, loggerProvider.LoggerInstance.StringBuilder); } } public class TestLoggerProvider : ILoggerProvider { public TestSqlLogger LoggerInstance { get; } = new TestSqlLogger(); public ILogger CreateLogger(string categoryName) { return LoggerInstance; } public void Dispose() { } } public class TestConnectionLoggerProvider : ILoggerProvider { public TestConnectionLogger LoggerInstance { get; } = new TestConnectionLogger(); public ILogger CreateLogger(string categoryName) { return LoggerInstance; } public void Dispose() { } } public class TestSqlLogger : ILogger { public StringBuilder StringBuilder { get; } = new StringBuilder(); public IDisposable BeginScope<TState>(TState state) => null; public bool IsEnabled(LogLevel logLevel) => true; public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func<TState, Exception, string> formatter) { if (state is IReadOnlyList<KeyValuePair<string, object>> dict) { var commandText = dict.FirstOrDefault(i => i.Key == "commandText").Value; if (commandText != null) { if (StringBuilder.Length > 0) { StringBuilder.AppendLine().AppendLine(); } StringBuilder.Append(commandText); } } } } public class TestConnectionLogger : ILogger { public StringBuilder StringBuilder { get; } = new StringBuilder(); public IDisposable BeginScope<TState>(TState state) => null; public bool IsEnabled(LogLevel logLevel) => true; public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func<TState, Exception, string> formatter) { var message = formatter(state, exception); StringBuilder.AppendLine(message.Substring(0, 20)); } } } internal class NorthwindDbContext : DbContext { public NorthwindDbContext(DbContextOptions options) : base(options) { } protected override void OnModelCreating(ModelBuilder modelBuilder) { modelBuilder.Entity<Customer>(e => { e.HasKey(d => d.CustomerID); }); modelBuilder.Entity<Order>(e => { e.HasKey(d => d.OrderID); e.HasOne(o => o.Customer).WithMany(c => c.Orders).IsRequired(); }); modelBuilder.Entity<OrderDetail>(e => { e.HasKey(d => new { d.OrderID, d.ProductID }); e.HasOne(d => d.Product).WithMany().HasForeignKey(d => d.ProductID); e.HasQueryFilter(d => d.UnitPrice >= 5.00m); }); modelBuilder.Entity<Product>(e => { e.HasKey(d => d.ProductID); e.OwnsOne(d => d.ProductStats, d => { d.Property(f => f.QuantityPerUnit).HasColumnName(nameof(ProductStats.QuantityPerUnit)); d.Property(f => f.UnitPrice).HasColumnName(nameof(ProductStats.UnitPrice)); d.Property(f => f.UnitsInStock).HasColumnName(nameof(ProductStats.UnitsInStock)); d.Property(f => f.UnitsOnOrder).HasColumnName(nameof(ProductStats.UnitsOnOrder)); d.Property<short?>("ReorderLevel").HasColumnName("ReorderLevel"); }); e.HasDiscriminator(p => p.Discontinued).HasValue(false); }); modelBuilder.Entity<DiscontinuedProduct>(e => { e.HasDiscriminator(p => p.Discontinued).HasValue(true); }); modelBuilder.Query<QuarterlyOrders>(q => { q.ToView("Quarterly Orders", "dbo"); q.Property(o => o.Id).HasColumnName("CustomerID"); q.HasOne(o => o.Customer).WithMany().HasForeignKey(o => o.Id); }); } } }
48.943981
1,206
0.56222
[ "MIT" ]
JTOne123/Impatient
test/Impatient.Tests/EFCoreTests.cs
41,066
C#
using Microsoft.Extensions.Caching.Memory; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Logging; using Newtonsoft.Json; using System; using System.Net; using Walter.BOM.Geo; using Walter.Net; using Walter.Net.Networking; using Walter.Web.FireWall.Geo.IP2Loaction.Models; namespace Walter.Web.FireWall.Geo.IP2Loaction.Infrastructure { public class IP2LocationGeoFactory : IGeoFactory { //update this with your key or provide the key via const string countryCode = "https://api.ip2location.com/v2/?ip={0}&key={1}"; //not used as returns a random number //const string creditsCheck = "https://api.ip2location.com/v2/?key=demo&check=1"; const GeoLocation _home = GeoLocation.Luxembourg; int _creditsUsed = -1; int _creditsLeft = -1; string _key; private readonly IFireWallConfig _config; private readonly IMemoryCache _memory; private readonly ILogger _logger; private readonly MemoryCacheEntryOptions _memoryCacheEntryOptions; private readonly JsonSerializerSettings _settings; private readonly WafWebClient _client; private readonly bool _debugLoggingOn; public IP2LocationGeoFactory(IFireWallConfig config, IMemoryCache memory, IConfiguration configuration = null, ILoggerFactory loggerFactory = null) { _settings = new JsonSerializerSettings() { ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor }; _config = config; _memory = memory; _logger = loggerFactory?.CreateLogger<IP2LocationGeoFactory>(); _memoryCacheEntryOptions = config.Cashing.GeoLocation; _client = new Walter.Net.WafWebClient(); //make it easy to test when no configuration then use demo _key = configuration?.GetValue<string>("IP2LocationKey") ?? "demo"; //only generate debug logs if enabled making log processing more streamlined _debugLoggingOn = _logger?.IsEnabled(LogLevel.Debug) ?? false; } public bool IsBlocked(GeoLocation? geo) { if ( geo is null || geo.HasValue==false) return false; var blocked = _config.Geography.IsBlocked(geo.Value); if (_debugLoggingOn) { _logger?.Lazy().LogDebug(new EventId(-1, "IP2Location") , "Request if Geography {geo} is blocked returned \"{flag}\"" , geo , (blocked ? "block":"No issues") ); } return blocked; } public bool IsGeoBlocked(IPAddress address) { if (address is null) { throw new ArgumentNullException(nameof(address)); } var result = !IsGeoWhiteListed(address) && IsBlocked(QueryLocation(address)); if (_debugLoggingOn) { _logger?.Lazy().LogDebug(new EventId(-1, "IP2Location") , "Request if Geography {geo} is blocked returned {flag}" , address , (result ? "ok" : "block") ); } return result; } public bool IsGeoWhiteListed(IPAddress address) { if (address is null) { throw new ArgumentNullException(nameof(address)); } var found = _config.Geography.IsWhiteListed(address); if (_debugLoggingOn) { _logger?.Lazy().LogDebug(new EventId(-1, "IP2Location") , "Request Is GeoWhiteListed {address} returned {flag}" , address , (found ? "ok" : "block") ); } return found; } /// <summary> /// Query the location of an IP /// </summary> /// <param name="address">The IP to query</param> /// <returns> /// the location if found and the API is valid /// </returns> public GeoLocation QueryLocation(IPAddress address) { var location = GeoLocation.UnKnown; //there are several ways to avoid making redundant call when detecting on your network configuration and topography if (address.IsLocalIpAddress() || address.IsInLocalSubnet() || address.Scope() != CommunicationScopes.WAN) { return _home; } var key = string.Concat("Ip2L", address.ToString()); if (_memory.TryGetValue<Ip2LocationCoutyRequest>(key, out var data)) { if (_debugLoggingOn) { _logger?.Lazy().LogDebug(new EventId(-1, "IP2Location"), "Request for the location of {address} answered from memory with {location}" , address , data.Location ); } return data.Location; } if (_creditsLeft == 0) { _logger?.Lazy().LogWarning(eventId: new EventId(ERROR_CODES.NoMoreRequestsInIp2LocationAccount, "IP2Location"), "No more available request for GEO location with IP2Locations account for this 24 hour period, credits used:{creditsUsed}, Credits Left:{creditsLeft}", _creditsUsed, _creditsLeft); } //the web client keeps a audit log of all requests and request status string json = _client.Get(MakeUri(address)); //get the last entry from the log, may not be the correct one var entry = _client.Requests[0]; try { if (_client.IsSuccessStatusCode && json.IsValidJson<Ip2LocationCoutyRequest>(_settings, out data) && data.Location != GeoLocation.UnKnown) { _memory.Set<Ip2LocationCoutyRequest>(key, data, options: _memoryCacheEntryOptions); location = data.Location; } return location; } finally { if (entry.Status == HttpStatusCode.OK) { if (_debugLoggingOn) { _logger?.Lazy().LogDebug(new EventId(-1, "IP2Location") , message: "Request for the location of {address} to IP2Location using {method} on {url} returns {status} after {roundTrip} Json returned:{json}" , address , entry.Method , entry.Url.AbsoluteUri , _client.StatusCode , _client.RoundTrip , json ); } } else { _logger?.Lazy().LogCritical(new EventId(ERROR_CODES.API_FAILED, "IP2Location") , exception: _client.Exception , message: "Request for the location of {address} to IP2Location using {method} on {url} returns {status} after {roundTrip} Json returned:{json}" , address , entry.Method , entry.Url.AbsoluteUri , _client.StatusCode , _client.RoundTrip , json ); } } } private Uri MakeUri(IPAddress address) { return new Uri(string.Format(countryCode, address.ToString(), _key) , UriKind.Absolute); } public GeoLocation QueryProxy(IPAddress address) { _logger?.Lazy().LogInformation("Query proxy is not implemented"); return GeoLocation.UnKnown; } public bool TryGetLocation(IPAddress remoteAddress, out GeoLocation location) { location = GeoLocation.UnKnown; try { location = QueryLocation(remoteAddress); } catch (Exception e) { _logger?.Lazy().LogError(eventId: new EventId(ERROR_CODES.EXCEPTION, "TryGetLocation"), e, "A {exception} exception was generated with message:{message}", e.GetType().Name, e.Message); } return location != GeoLocation.UnKnown; } public void SetOptions() { } public Walter.BOM.Geo.GeoLocation MapLocation2Country(string sampleJson) { if (string.IsNullOrEmpty(sampleJson)) { throw new ArgumentException($"'{nameof(sampleJson)}' cannot be null or empty", nameof(sampleJson)); } var data = JsonConvert.DeserializeObject<Ip2LocationCoutyRequest>(sampleJson); //up date accurate count of requests done lock (this) { if (_creditsUsed < data.CreditsUsed) { _creditsUsed = data.CreditsUsed; _creditsLeft = data.CreditsLeft; } } return data.Location; } } }
37.373541
308
0.52556
[ "MIT" ]
ASP-WAF/FireWall
Samples/IGeoFactory implementation/Walter.Web.FireWall.Geo.IP2Loaction/Infrastructure/IP2LocationGeoFactory.cs
9,607
C#
#if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR) namespace Org.BouncyCastle.Crypto.Tls { /// <summary> /// RFC 4492 5.4 /// </summary> public abstract class ECCurveType { /** * Indicates the elliptic curve domain parameters are conveyed verbosely, and the * underlying finite field is a prime field. */ public const byte explicit_prime = 1; /** * Indicates the elliptic curve domain parameters are conveyed verbosely, and the * underlying finite field is a characteristic-2 field. */ public const byte explicit_char2 = 2; /** * Indicates that a named curve is used. This option SHOULD be used when applicable. */ public const byte named_curve = 3; /* * Values 248 through 255 are reserved for private use. */ } } #endif
26.941176
92
0.604803
[ "MIT" ]
Manolomon/space-checkers
client/Assets/Libs/Best HTTP (Pro)/Best HTTP (Pro)/BestHTTP/SecureProtocol/crypto/tls/ECCurveType.cs
916
C#
using System; using System.Collections.Generic; using System.Text; namespace Kooboo.Sites.Render.Renderers.ExternalCache { public class CacheObject { public CacheObject() { } public CacheObject(string fullurl, string name, string contenttype, int interval) { this.FullFileUrl = fullurl; this.name = name; this.ContentType = contenttype; this.interval = interval; if (this.interval <= 0) { this.interval = 60 * 60; // default one hour. } // this.Expiration = DateTime.Now.AddSeconds(this.interval); } // seconds. public int interval { get; set; } public DateTime Expiration { get; set; } private string _contenttype; public string ContentType { get; set; } private Guid _id; public Guid Id { get { if (_id == default(Guid)) { if (FullFileUrl != null) { _id = Lib.Security.Hash.ComputeGuidIgnoreCase(FullFileUrl); } } return _id; } } public string FullFileUrl { get; set; } private string _name; public string name { get { if (_name == null && FullFileUrl != null) { return Lib.Helper.UrlHelper.GetNameFromUrl(FullFileUrl); } return _name; } set { _name = value; } } } }
21.9375
89
0.445584
[ "MIT" ]
Kooboo/Kooboo
Kooboo.Sites/Render/Renderers/ExternalCache/CacheObject.cs
1,757
C#
// Copyright (c) Microsoft. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. using Xunit; namespace System.Reflection.Tests { public class ConstructorInfoConstructorName { //Positive Test 1: Ensure ConstructorInfo.ContructorName is correct [Fact] public void PosTest1() { Assert.Equal(".ctor", ConstructorInfo.ConstructorName); } } }
26.333333
101
0.679325
[ "MIT" ]
690486439/corefx
src/System.Reflection.TypeExtensions/tests/ConstructorInfo/ConstructorInfoConstructorName.cs
474
C#
using System; using System.Collections.Generic; using System.Linq; namespace _10.SoftUniExamResults { class Program { static void Main(string[] args) { string input = Console.ReadLine(); Dictionary<string, int> students = new Dictionary<string, int>(); Dictionary<string, int> submissions = new Dictionary<string, int>(); while (input != "exam finished") { string[] command = input .Split('-', StringSplitOptions.RemoveEmptyEntries) .ToArray(); string username = command[0]; if (command.Length > 2) { string language = command[1]; int points = int.Parse(command[2]); if (!students.ContainsKey(username)) { students.Add(username, points); } else { if(students[username] < points) { students[username] = points; } } if(!submissions.ContainsKey(language)) { submissions.Add(language, 0); } submissions[language]++; } else { students.Remove(username); } input = Console.ReadLine(); } Console.WriteLine("Results:"); foreach (var item in students.OrderByDescending(x=>x.Value).ThenBy(x=>x.Key)) { Console.WriteLine($"{item.Key} | {item.Value}"); } Console.WriteLine("Submissions:"); foreach (var item in submissions.OrderByDescending(x=>x.Value).ThenBy(x=>x.Key)) { Console.WriteLine($"{item.Key} - {item.Value}"); } } } }
31.569231
92
0.42885
[ "MIT" ]
HNochev/SoftUni-CSharp-Software-Engineering
Programming Fundamentals/Exercise 7 - Associative Arrays/10.SoftUniExamResults/Program.cs
2,054
C#
using RedsysTPV.Enums; using RedsysTPV.Models; using System.Configuration; using System.Security.Policy; using Microsoft.AspNetCore.Mvc; using System; using Microsoft.Extensions.Configuration; namespace RedsysTPV.WebSample.Controllers { public class RequestController : Controller { private IConfiguration _configuration; public RequestController(IConfiguration configuration) { _configuration = configuration; } // GET: Request public ActionResult Index(string merchantCode, string merchantOrder, decimal amount) { var paymentRequestService = new PaymentRequestService(); var paymentRequest = new PaymentRequest( Ds_Merchant_ConsumerLanguage: Language.Spanish, Ds_Merchant_MerchantCode: merchantCode, Ds_Merchant_Terminal: "1", Ds_Merchant_TransactionType: TransactionType.Authorization, Ds_Merchant_Amount: amount, Ds_Merchant_Currency: Currency.EUR, Ds_Merchant_Order: merchantOrder, Ds_Merchant_MerchantURL: Url.Action("Index", "Response", null, Request.Scheme), Ds_Merchant_UrlOK: Url.Action("OK", "Result", null, Request.Scheme), Ds_Merchant_UrlKO: Url.Action("KO", "Result", null, Request.Scheme) ); paymentRequest.Ds_Merchant_Paymethods = PaymentMethod.CreditCard; paymentRequest.Ds_Merchant_Titular = "TITULAR"; paymentRequest.Ds_Merchant_MerchantName = "MY COMMERCE"; paymentRequest.Ds_Merchant_ProductDescription = "PRODUCT DESCRIPTION"; paymentRequest.Ds_Merchant_Identifier = "REQUIRED"; var secrets = _configuration.GetSection("Secrets"); var formData = paymentRequestService.GetPaymentRequestFormData( paymentRequest: paymentRequest, merchantKey: secrets["key"]); ViewBag.ConnectionURL = secrets["url"]; return View(formData); } } }
39.301887
95
0.656745
[ "MIT" ]
CrahunGit/RedsysTPV
src/RedsysTPV.WebSample/Controllers/RequestController.cs
2,085
C#
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Xml; using System.Xml.Serialization; namespace MockServer.Common { public class XmlSerializeHelper { public static string ObjectToXML(object o) { XmlSerializer ser = new XmlSerializer(o.GetType()); MemoryStream mem = new MemoryStream(); XmlTextWriter writer = new XmlTextWriter(mem, Encoding.UTF8); ser.Serialize(writer, o); writer.Close(); return Encoding.UTF8.GetString(mem.ToArray()); } public static object XMLToObject(string s, Type t) { XmlSerializer mySerializer = new XmlSerializer(t); StreamReader mem2 = new StreamReader(new MemoryStream(System.Text.Encoding.Default.GetBytes(s)), System.Text.Encoding.UTF8); return mySerializer.Deserialize(mem2); } /// <summary> /// 将object对象序列化成XML /// </summary> /// <param name="o"></param> /// <returns></returns> public static string ObjectToXML<T>(T t) { return ClearSpecialCharForXml(ObjectToXML<T>(t, Encoding.UTF8)); } /// <summary> /// 将object对象序列化成XML /// </summary> /// <param name="o"></param> /// <returns></returns> public static string ObjectToXML<T>(T t, Encoding encoding) { XmlSerializer ser = new XmlSerializer(t.GetType()); using (MemoryStream mem = new MemoryStream()) { using (XmlTextWriter writer = new XmlTextWriter(mem, encoding)) { XmlSerializerNamespaces ns = new XmlSerializerNamespaces(); ns.Add("", ""); ser.Serialize(writer, t, ns); return ClearSpecialCharForXml(encoding.GetString(mem.ToArray())); } } } /// <summary> /// 将XML反序列化成对象 /// </summary> /// <param name="s"></param> /// <param name="t"></param> /// <returns></returns> public static T XMLToObject<T>(string source) { return XMLToObject<T>(source, Encoding.UTF8); } /// <summary> /// 将XML反序列化成对象 /// </summary> /// <param name="s"></param> /// <param name="t"></param> /// <returns></returns> public static T XMLToObject<T>(string source, Encoding encoding) { XmlSerializer mySerializer = new XmlSerializer(typeof(T)); using (MemoryStream stream = new MemoryStream(encoding.GetBytes(source))) { return (T)mySerializer.Deserialize(stream); } } /// <summary> /// 清理XML字符串左尖括号前面的多余字符 /// </summary> /// <param name="xml">待处理的XML字符串</param> /// <returns></returns> /// <remarks> add by grs at 2012-10-16 </remarks> private static string ClearSpecialCharForXml(string xml) { if (string.IsNullOrEmpty(xml)) { return string.Empty; } return System.Text.RegularExpressions.Regex.Replace(xml, "^[^<]*", ""); } } }
31.809524
136
0.541018
[ "MIT" ]
WalleStudio/Walle.Mocker
MockSercer.Common/XmlSerializeHelper.cs
3,448
C#
using System; using System.ComponentModel.DataAnnotations; using Newtonsoft.Json; namespace TropicalBears.API.Models { // Models used as parameters to AccountController actions. public class AddExternalLoginBindingModel { [Required] [Display(Name = "External access token")] public string ExternalAccessToken { get; set; } } public class ChangePasswordBindingModel { [Required] [DataType(DataType.Password)] [Display(Name = "Current password")] public string OldPassword { get; set; } [Required] [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] [DataType(DataType.Password)] [Display(Name = "New password")] public string NewPassword { get; set; } [DataType(DataType.Password)] [Display(Name = "Confirm new password")] [Compare("NewPassword", ErrorMessage = "The new password and confirmation password do not match.")] public string ConfirmPassword { get; set; } } public class RegisterBindingModel { [Required] [Display(Name = "Email")] public string Email { get; set; } [Required] [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] [DataType(DataType.Password)] [Display(Name = "Password")] public string Password { get; set; } [DataType(DataType.Password)] [Display(Name = "Confirm password")] [Compare("Password", ErrorMessage = "The password and confirmation password do not match.")] public string ConfirmPassword { get; set; } } public class RegisterExternalBindingModel { [Required] [Display(Name = "Email")] public string Email { get; set; } } public class RemoveLoginBindingModel { [Required] [Display(Name = "Login provider")] public string LoginProvider { get; set; } [Required] [Display(Name = "Provider key")] public string ProviderKey { get; set; } } public class SetPasswordBindingModel { [Required] [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] [DataType(DataType.Password)] [Display(Name = "New password")] public string NewPassword { get; set; } [DataType(DataType.Password)] [Display(Name = "Confirm new password")] [Compare("NewPassword", ErrorMessage = "The new password and confirmation password do not match.")] public string ConfirmPassword { get; set; } } }
31.823529
110
0.622181
[ "MIT" ]
spiovezana/eadComercio
TropicalBears.API/Models/AccountBindingModels.cs
2,707
C#
namespace LyARev { partial class Frmtripleta { /// <summary> /// Required designer variable. /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// Clean up any resources being used. /// </summary> /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); } #region Windows Form Designer generated code /// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { this.dgvtripleta = new System.Windows.Forms.DataGridView(); this.DatoObjeto = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.DatoFuente = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Operador = new System.Windows.Forms.DataGridViewTextBoxColumn(); ((System.ComponentModel.ISupportInitialize)(this.dgvtripleta)).BeginInit(); this.SuspendLayout(); // // dgvtripleta // this.dgvtripleta.AllowUserToDeleteRows = false; this.dgvtripleta.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill; this.dgvtripleta.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.dgvtripleta.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.DatoObjeto, this.DatoFuente, this.Operador}); this.dgvtripleta.Location = new System.Drawing.Point(12, 12); this.dgvtripleta.Name = "dgvtripleta"; this.dgvtripleta.ReadOnly = true; this.dgvtripleta.Size = new System.Drawing.Size(418, 384); this.dgvtripleta.TabIndex = 0; // // DatoObjeto // this.DatoObjeto.HeaderText = "Dato Objeto"; this.DatoObjeto.Name = "DatoObjeto"; this.DatoObjeto.ReadOnly = true; // // DatoFuente // this.DatoFuente.HeaderText = "Dato Fuente"; this.DatoFuente.Name = "DatoFuente"; this.DatoFuente.ReadOnly = true; // // Operador // this.Operador.HeaderText = "Operador"; this.Operador.Name = "Operador"; this.Operador.ReadOnly = true; // // Frmtripleta // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(442, 408); this.Controls.Add(this.dgvtripleta); this.Name = "Frmtripleta"; this.Text = "TRIPLETA"; this.Load += new System.EventHandler(this.Frmtripleta_Load); ((System.ComponentModel.ISupportInitialize)(this.dgvtripleta)).EndInit(); this.ResumeLayout(false); } #endregion private System.Windows.Forms.DataGridView dgvtripleta; private System.Windows.Forms.DataGridViewTextBoxColumn DatoObjeto; private System.Windows.Forms.DataGridViewTextBoxColumn DatoFuente; private System.Windows.Forms.DataGridViewTextBoxColumn Operador; } }
40.413043
129
0.594406
[ "MIT" ]
AriAlanPR/SaphireCompiler
LyARev/LyARev/Frmtripleta.Designer.cs
3,720
C#
using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; // 有关程序集的常规信息通过下列特性集 // 控制。更改这些特性值可修改 // 与程序集关联的信息。 [assembly: AssemblyTitle("WorkingWithRazor")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("WorkingWithRazor")] [assembly: AssemblyCopyright("Copyright © 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] // 将 ComVisible 设置为 false 会使此程序集中的类型 // 对 COM 组件不可见。如果需要 // 从 COM 访问此程序集中的某个类型,请针对该类型将 ComVisible 特性设置为 true。 [assembly: ComVisible(false)] // 如果此项目向 COM 公开,则下列 GUID 用于 typelib 的 ID [assembly: Guid("1d1ac69e-f54f-45c2-9d44-02f62747f0fc")] // 程序集的版本信息由下列四个值组成: // // 主版本 // 次版本 // 内部版本号 // 修订版本 // // 可以指定所有值,也可以使用“修订号”和“内部版本号”的默认值, // 方法是按如下所示使用 "*": [assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
25.805556
56
0.723358
[ "Apache-2.0" ]
nandehutuzn/SportsStore
WorkingWithRazor/Properties/AssemblyInfo.cs
1,290
C#
using System; using System.IO; using System.Xml; using Umbraco.Core.IO; namespace Umbraco.Web.UI.Install.Steps { public partial class Renaming : StepUserControl { private readonly string _oldAccessFilePath = IOHelper.MapPath(SystemDirectories.Data + "/access.xml"); private readonly string _newAccessFilePath = IOHelper.MapPath(SystemDirectories.Data + "/access.config"); private bool _changesNeeded = false; protected void Page_Load(object sender, EventArgs e) { // check access.xml file identifyResult.Text += CheckAccessFile(); if (_changesNeeded) { changesNeeded.Visible = true; } else { noChangedNeeded.Visible = true; changesNeeded.Visible = false; } } private string CheckAccessFile() { if (!NewAccessFileExist() && OldAccessFileExist()) { _changesNeeded = true; return "<li>Access.xml found. Needs to be renamed to access.config</li>"; } return "<li>Public Access file is all good. No changes needed</li>"; } private bool OldAccessFileExist() { return File.Exists(_oldAccessFilePath); } private bool NewAccessFileExist() { return File.Exists(_newAccessFilePath); } protected void UpdateChangesClick(object sender, EventArgs e) { bool succes = true; string progressText = ""; // rename access file if (OldAccessFileExist()) { try { File.Move(_oldAccessFilePath, IOHelper.MapPath(SystemFiles.AccessXml)); progressText += String.Format("<li>Public Access file renamed</li>"); } catch (Exception ee) { progressText += String.Format("<li>Error renaming access file: {0}</li>", ee.ToString()); succes = false; } } string resultClass = succes ? "success" : "error"; resultText.Text = String.Format("<div class=\"{0}\"><p>{1}</p></div>", resultClass, progressText); result.Visible = true; init.Visible = false; } } }
32.518987
114
0.502919
[ "MIT" ]
ConnectionMaster/Umbraco-CMS
src/Umbraco.Web.UI/install/steps/Renaming.ascx.cs
2,571
C#
// <auto-generated /> using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; using WebAppClientes.Infra.Data; namespace WebAppClientes.Infra.Data.Migrations { [DbContext(typeof(DatabaseContext))] [Migration("20200403191302_InitialCreate")] partial class InitialCreate { protected override void BuildTargetModel(ModelBuilder modelBuilder) { #pragma warning disable 612, 618 modelBuilder .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn) .HasAnnotation("ProductVersion", "3.1.3") .HasAnnotation("Relational:MaxIdentifierLength", 63); modelBuilder.Entity("WebAppClientes.Domain.Cliente", b => { b.Property<int>("Id") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn); b.Property<string>("Bairro") .HasColumnType("character varying(100)") .HasMaxLength(100); b.Property<string>("Cidade") .HasColumnType("character varying(100)") .HasMaxLength(100); b.Property<string>("Cpf") .IsRequired() .HasColumnType("character varying(14)") .HasMaxLength(14); b.Property<string>("Nome") .IsRequired() .HasColumnType("character varying(100)") .HasMaxLength(100); b.Property<string>("Observacoes") .HasColumnType("character varying(1000)") .HasMaxLength(1000); b.Property<string>("Rua") .HasColumnType("character varying(200)") .HasMaxLength(200); b.HasKey("Id"); b.ToTable("Clientes"); }); #pragma warning restore 612, 618 } } }
37.703125
128
0.554082
[ "MIT" ]
rafaeldalsenter/web-app-clientes
WebAppClientes.Infra.Data/Migrations/20200403191302_InitialCreate.Designer.cs
2,415
C#
using System; using System.Collections.Generic; using UnityEngine; namespace Mirror { /// <summary> /// A High level network connection. This is used for connections from client-to-server and for connection from server-to-client. /// </summary> /// <remarks> /// <para>A NetworkConnection corresponds to a specific connection for a host in the transport layer. It has a connectionId that is assigned by the transport layer and passed to the Initialize function.</para> /// <para>A NetworkClient has one NetworkConnection. A NetworkServerSimple manages multiple NetworkConnections. The NetworkServer has multiple "remote" connections and a "local" connection for the local client.</para> /// <para>The NetworkConnection class provides message sending and handling facilities. For sending data over a network, there are methods to send message objects, byte arrays, and NetworkWriter objects. To handle data arriving from the network, handler functions can be registered for message Ids, byte arrays can be processed by HandleBytes(), and NetworkReader object can be processed by HandleReader().</para> /// <para>NetworkConnection objects also act as observers for networked objects. When a connection is an observer of a networked object with a NetworkIdentity, then the object will be visible to corresponding client for the connection, and incremental state changes will be sent to the client.</para> /// <para>There are many virtual functions on NetworkConnection that allow its behaviour to be customized. NetworkClient and NetworkServer can both be made to instantiate custom classes derived from NetworkConnection by setting their networkConnectionClass member variable.</para> /// </remarks> public abstract class NetworkConnection : IDisposable { static readonly ILogger logger = LogFactory.GetLogger<NetworkConnection>(); // internal so it can be tested internal readonly HashSet<NetworkIdentity> visList = new HashSet<NetworkIdentity>(); Dictionary<int, NetworkMessageDelegate> messageHandlers; /// <summary> /// Unique identifier for this connection that is assigned by the transport layer. /// </summary> /// <remarks> /// <para>On a server, this Id is unique for every connection on the server. On a client this Id is local to the client, it is not the same as the Id on the server for this connection.</para> /// <para>Transport layers connections begin at one. So on a client with a single connection to a server, the connectionId of that connection will be one. In NetworkServer, the connectionId of the local connection is zero.</para> /// <para>Clients do not know their connectionId on the server, and do not know the connectionId of other clients on the server.</para> /// </remarks> public readonly int connectionId; /// <summary> /// Flag that indicates the client has been authenticated. /// </summary> public bool isAuthenticated; /// <summary> /// General purpose object to hold authentication data, character selection, tokens, etc. /// associated with the connection for reference after Authentication completes. /// </summary> public object authenticationData; /// <summary> /// Flag that tells if the connection has been marked as "ready" by a client calling ClientScene.Ready(). /// <para>This property is read-only. It is set by the system on the client when ClientScene.Ready() is called, and set by the system on the server when a ready message is received from a client.</para> /// <para>A client that is ready is sent spawned objects by the server and updates to the state of spawned objects. A client that is not ready is not sent spawned objects.</para> /// </summary> public bool isReady; /// <summary> /// The IP address / URL / FQDN associated with the connection. /// Can be useful for a game master to do IP Bans etc. /// </summary> public abstract string address { get; } /// <summary> /// The last time that a message was received on this connection. /// <para>This includes internal system messages (such as Commands and ClientRpc calls) and user messages.</para> /// </summary> public float lastMessageTime; /// <summary> /// The NetworkIdentity for this connection. /// </summary> public NetworkIdentity identity { get; internal set; } /// <summary> /// A list of the NetworkIdentity objects owned by this connection. This list is read-only. /// <para>This includes the player object for the connection - if it has localPlayerAutority set, and any objects spawned with local authority or set with AssignLocalAuthority.</para> /// <para>This list can be used to validate messages from clients, to ensure that clients are only trying to control objects that they own.</para> /// </summary> // IMPORTANT: this needs to be <NetworkIdentity>, not <uint netId>. fixes a bug where DestroyOwnedObjects wouldn't find // the netId anymore: https://github.com/vis2k/Mirror/issues/1380 . Works fine with NetworkIdentity pointers though. public readonly HashSet<NetworkIdentity> clientOwnedObjects = new HashSet<NetworkIdentity>(); /// <summary> /// Setting this to true will log the contents of network message to the console. /// </summary> /// <remarks> /// <para>Warning: this can be a lot of data and can be very slow. Both incoming and outgoing messages are logged. The format of the logs is:</para> /// <para>ConnectionSend con:1 bytes:11 msgId:5 FB59D743FD120000000000 ConnectionRecv con:1 bytes:27 msgId:8 14F21000000000016800AC3FE090C240437846403CDDC0BD3B0000</para> /// <para>Note that these are application-level network messages, not protocol-level packets. There will typically be multiple network messages combined in a single protocol packet.</para> /// </remarks> [Obsolete("Set logger to Log level instead")] public bool logNetworkMessages; /// <summary> /// Creates a new NetworkConnection /// </summary> internal NetworkConnection() { } /// <summary> /// Creates a new NetworkConnection with the specified connectionId /// </summary> /// <param name="networkConnectionId"></param> internal NetworkConnection(int networkConnectionId) { connectionId = networkConnectionId; } ~NetworkConnection() { Dispose(false); } /// <summary> /// Disposes of this connection, releasing channel buffers that it holds. /// </summary> public void Dispose() { Dispose(true); // Take yourself off the Finalization queue // to prevent finalization code for this object // from executing a second time. GC.SuppressFinalize(this); } protected virtual void Dispose(bool disposing) { clientOwnedObjects.Clear(); } /// <summary> /// Disconnects this connection. /// </summary> public abstract void Disconnect(); internal void SetHandlers(Dictionary<int, NetworkMessageDelegate> handlers) { messageHandlers = handlers; } /// <summary> /// This sends a network message with a message ID on the connection. This message is sent on channel zero, which by default is the reliable channel. /// </summary> /// <typeparam name="T">The message type to unregister.</typeparam> /// <param name="msg">The message to send.</param> /// <param name="channelId">The transport layer channel to send on.</param> /// <returns></returns> public bool Send<T>(T msg, int channelId = Channels.DefaultReliable) where T : IMessageBase { using (PooledNetworkWriter writer = NetworkWriterPool.GetWriter()) { // pack message and send allocation free MessagePacker.Pack(msg, writer); NetworkDiagnostics.OnSend(msg, channelId, writer.Position, 1); return Send(writer.ToArraySegment(), channelId); } } // validate packet size before sending. show errors if too big/small. // => it's best to check this here, we can't assume that all transports // would check max size and show errors internally. best to do it // in one place in hlapi. // => it's important to log errors, so the user knows what went wrong. protected internal static bool ValidatePacketSize(ArraySegment<byte> segment, int channelId) { if (segment.Count > Transport.activeTransport.GetMaxPacketSize(channelId)) { logger.LogError("NetworkConnection.ValidatePacketSize: cannot send packet larger than " + Transport.activeTransport.GetMaxPacketSize(channelId) + " bytes"); return false; } if (segment.Count == 0) { // zero length packets getting into the packet queues are bad. logger.LogError("NetworkConnection.ValidatePacketSize: cannot send zero bytes"); return false; } // good size return true; } // internal because no one except Mirror should send bytes directly to // the client. they would be detected as a message. send messages instead. internal abstract bool Send(ArraySegment<byte> segment, int channelId = Channels.DefaultReliable); public override string ToString() { return $"connection({connectionId})"; } internal void AddToVisList(NetworkIdentity identity) { visList.Add(identity); // spawn identity for this conn NetworkServer.ShowForConnection(identity, this); } internal void RemoveFromVisList(NetworkIdentity identity, bool isDestroyed) { visList.Remove(identity); if (!isDestroyed) { // hide identity for this conn NetworkServer.HideForConnection(identity, this); } } internal void RemoveObservers() { foreach (NetworkIdentity identity in visList) { identity.RemoveObserverInternal(this); } visList.Clear(); } internal bool InvokeHandler(int msgType, NetworkReader reader, int channelId) { if (messageHandlers.TryGetValue(msgType, out NetworkMessageDelegate msgDelegate)) { msgDelegate(this, reader, channelId); return true; } if (logger.LogEnabled()) logger.Log("Unknown message ID " + msgType + " " + this + ". May be due to no existing RegisterHandler for this message."); return false; } /// <summary> /// This function invokes the registered handler function for a message. /// <para>Network connections used by the NetworkClient and NetworkServer use this function for handling network messages.</para> /// </summary> /// <typeparam name="T">The message type to unregister.</typeparam> /// <param name="msg">The message object to process.</param> /// <returns></returns> public bool InvokeHandler<T>(T msg, int channelId) where T : IMessageBase { // get writer from pool using (PooledNetworkWriter writer = NetworkWriterPool.GetWriter()) { // if it is a value type, just use typeof(T) to avoid boxing // this works because value types cannot be derived // if it is a reference type (for example IMessageBase), // ask the message for the real type int msgType = MessagePacker.GetId(default(T) != null ? typeof(T) : msg.GetType()); MessagePacker.Pack(msg, writer); ArraySegment<byte> segment = writer.ToArraySegment(); using (PooledNetworkReader networkReader = NetworkReaderPool.GetReader(segment)) return InvokeHandler(msgType, networkReader, channelId); } } // note: original HLAPI HandleBytes function handled >1 message in a while loop, but this wasn't necessary // anymore because NetworkServer/NetworkClient Update both use while loops to handle >1 data events per // frame already. // -> in other words, we always receive 1 message per Receive call, never two. // -> can be tested easily with a 1000ms send delay and then logging amount received in while loops here // and in NetworkServer/Client Update. HandleBytes already takes exactly one. /// <summary> /// This function allows custom network connection classes to process data from the network before it is passed to the application. /// </summary> /// <param name="buffer">The data received.</param> internal void TransportReceive(ArraySegment<byte> buffer, int channelId) { // unpack message using (PooledNetworkReader networkReader = NetworkReaderPool.GetReader(buffer)) { if (MessagePacker.UnpackMessage(networkReader, out int msgType)) { // logging if (logger.LogEnabled()) logger.Log("ConnectionRecv " + this + " msgType:" + msgType + " content:" + BitConverter.ToString(buffer.Array, buffer.Offset, buffer.Count)); // try to invoke the handler for that message if (InvokeHandler(msgType, networkReader, channelId)) { lastMessageTime = Time.time; } } else { logger.LogError("Closed connection: " + this + ". Invalid message header."); Disconnect(); } } } // Failsafe to kick clients that have stopped sending anything to the server. // Clients Ping the server every 2 seconds but transports are unreliable // when it comes to properly generating Disconnect messages to the server. // This cannot be abstract because then NetworkConnectionToServer // would require and override that would never be called // This is overriden in NetworkConnectionToClient. internal virtual bool IsClientAlive() { return true; } internal void AddOwnedObject(NetworkIdentity obj) { clientOwnedObjects.Add(obj); } internal void RemoveOwnedObject(NetworkIdentity obj) { clientOwnedObjects.Remove(obj); } internal void DestroyOwnedObjects() { // create a copy because the list might be modified when destroying HashSet<NetworkIdentity> tmp = new HashSet<NetworkIdentity>(clientOwnedObjects); foreach (NetworkIdentity netIdentity in tmp) { if (netIdentity != null) { NetworkServer.Destroy(netIdentity.gameObject); } } // clear the hashset because we destroyed them all clientOwnedObjects.Clear(); } } }
49.75
418
0.617656
[ "Apache-2.0" ]
Tierra-Exodus-Entertainmet/Gunslingers
Assets/Mirror/Runtime/NetworkConnection.cs
16,119
C#
//------------------------------------------------------------------------------ // <auto-generated> // This code was generated by a tool. // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // </auto-generated> //------------------------------------------------------------------------------ namespace AspWebApplication.Pages { public partial class WebTools { /// <summary> /// TextBox1 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.TextBox TextBox1; /// <summary> /// Button1 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.Button Button1; /// <summary> /// Label1 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.Label Label1; /// <summary> /// TextBox2 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.TextBox TextBox2; /// <summary> /// Button2 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.Button Button2; /// <summary> /// Label2 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.Label Label2; /// <summary> /// TextBox3 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.TextBox TextBox3; /// <summary> /// Button3 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.Button Button3; /// <summary> /// Label3 control. /// </summary> /// <remarks> /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// </remarks> protected global::System.Web.UI.WebControls.Label Label3; } }
33.865979
84
0.522679
[ "Apache-2.0" ]
Mehdi-Naseri/Classic-ASP-Portal
AspWebApplication/Pages/WebTools.aspx.designer.cs
3,287
C#
using System; using MikhailKhalizev.Processor.x86.BinToCSharp; namespace MikhailKhalizev.Max.Program { public partial class RawProgram { [MethodInfo("0x1018_ede8-123fe8")] public void /* sys_mve */ Method_1018_ede8() { ii(0x1018_ede8, 3); mov(ax, bp); /* mov ax, bp */ } } }
24.8
88
0.548387
[ "Apache-2.0" ]
mikhail-khalizev/max
source/MikhailKhalizev.Max/source/Program/Auto/z-1018-ede8-sys-mve.cs
372
C#
// Copyright (c) Six Labors and contributors. // Licensed under the Apache License, Version 2.0. using System; using System.Numerics; using SixLabors.ImageSharp.PixelFormats; using SixLabors.ImageSharp.Processing; using SixLabors.ImageSharp.Processing.Processors.Transforms; using SixLabors.ImageSharp.Tests.TestUtilities.ImageComparison; using SixLabors.Primitives; using Xunit; namespace SixLabors.ImageSharp.Tests { [GroupOutput("Drawing")] public class DrawImageTest : FileTestBase { private const PixelTypes PixelTypes = Tests.PixelTypes.Rgba32; public static readonly string[] TestFiles = { TestImages.Jpeg.Baseline.Calliphora, TestImages.Bmp.Car, TestImages.Png.Splash, TestImages.Gif.Rings }; [Theory] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Normal)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Multiply)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Add)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Subtract)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Screen)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Darken)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Lighten)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Overlay)] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.HardLight)] public void ImageShouldApplyDrawImage<TPixel>(TestImageProvider<TPixel> provider, PixelColorBlendingMode mode) where TPixel : struct, IPixel<TPixel> { using (Image<TPixel> image = provider.GetImage()) using (var blend = Image.Load<TPixel>(TestFile.Create(TestImages.Bmp.Car).Bytes)) { blend.Mutate(x => x.Resize(image.Width / 2, image.Height / 2)); image.Mutate(x => x.DrawImage(blend, new Point(image.Width / 4, image.Height / 4), mode, .75f)); image.DebugSave(provider, new { mode }); } } [Theory] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Normal)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Multiply)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Add)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Subtract)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Screen)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Darken)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Lighten)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.Overlay)] [WithFile(TestImages.Png.Rainbow, PixelTypes, PixelColorBlendingMode.HardLight)] public void ImageBlendingMatchesSvgSpecExamples<TPixel>(TestImageProvider<TPixel> provider, PixelColorBlendingMode mode) where TPixel : struct, IPixel<TPixel> { using (Image<TPixel> background = provider.GetImage()) using (var source = Image.Load<TPixel>(TestFile.Create(TestImages.Png.Ducky).Bytes)) { background.Mutate(x => x.DrawImage(source, mode, 1F)); VerifyImage(provider, mode, background); } } [Theory] [WithFileCollection(nameof(TestFiles), PixelTypes, PixelColorBlendingMode.Normal)] public void ImageShouldDrawTransformedImage<TPixel>(TestImageProvider<TPixel> provider, PixelColorBlendingMode mode) where TPixel : struct, IPixel<TPixel> { using (Image<TPixel> image = provider.GetImage()) using (var blend = Image.Load<TPixel>(TestFile.Create(TestImages.Bmp.Car).Bytes)) { Matrix3x2 rotate = Matrix3x2Extensions.CreateRotationDegrees(45F); Matrix3x2 scale = Matrix3x2Extensions.CreateScale(new SizeF(.25F, .25F)); Matrix3x2 matrix = rotate * scale; // Lets center the matrix so we can tell whether any cut-off issues we may have belong to the drawing processor Rectangle srcBounds = blend.Bounds(); Rectangle destBounds = TransformHelpers.GetTransformedBoundingRectangle(srcBounds, matrix); Matrix3x2 centeredMatrix = TransformHelpers.GetCenteredTransformMatrix(srcBounds, destBounds, matrix); // We pass a new rectangle here based on the dest bounds since we've offset the matrix blend.Mutate(x => x.Transform( centeredMatrix, KnownResamplers.Bicubic, new Rectangle(0, 0, destBounds.Width, destBounds.Height))); var position = new Point((image.Width - blend.Width) / 2, (image.Height - blend.Height) / 2); image.Mutate(x => x.DrawImage(blend, position, mode, .75F)); image.DebugSave(provider, new[] { "Transformed" }); } } [Theory] [WithSolidFilledImages(100, 100, 255, 255, 255, PixelTypes.Rgba32)] public void ImageShouldHandleNegativeLocation(TestImageProvider<Rgba32> provider) { using (Image<Rgba32> background = provider.GetImage()) using (var overlay = new Image<Rgba32>(50, 50)) { overlay.Mutate(x => x.Fill(Rgba32.Black)); const int xy = -25; Rgba32 backgroundPixel = background[0, 0]; Rgba32 overlayPixel = overlay[Math.Abs(xy) + 1, Math.Abs(xy) + 1]; background.Mutate(x => x.DrawImage(overlay, new Point(xy, xy), PixelColorBlendingMode.Normal, 1F)); Assert.Equal(Rgba32.White, backgroundPixel); Assert.Equal(overlayPixel, background[0, 0]); background.DebugSave(provider, testOutputDetails: "Negative"); } } [Theory] [WithSolidFilledImages(100, 100, 255, 255, 255, PixelTypes.Rgba32)] public void ImageShouldHandlePositiveLocation(TestImageProvider<Rgba32> provider) { using (Image<Rgba32> background = provider.GetImage()) using (var overlay = new Image<Rgba32>(50, 50)) { overlay.Mutate(x => x.Fill(Rgba32.Black)); const int xy = 25; Rgba32 backgroundPixel = background[xy - 1, xy - 1]; Rgba32 overlayPixel = overlay[0, 0]; background.Mutate(x => x.DrawImage(overlay, new Point(xy, xy), PixelColorBlendingMode.Normal, 1F)); Assert.Equal(Rgba32.White, backgroundPixel); Assert.Equal(overlayPixel, background[xy, xy]); background.DebugSave(provider, testOutputDetails: "Positive"); } } private static void VerifyImage<TPixel>( TestImageProvider<TPixel> provider, PixelColorBlendingMode mode, Image<TPixel> img) where TPixel : struct, IPixel<TPixel> { img.DebugSave( provider, new { mode }, appendPixelTypeToFileName: false, appendSourceFileOrDescription: false); var comparer = ImageComparer.TolerantPercentage(0.01F, 3); img.CompareFirstFrameToReferenceOutput(comparer, provider, new { mode }, appendPixelTypeToFileName: false, appendSourceFileOrDescription: false); } } }
47.97546
128
0.63977
[ "Apache-2.0" ]
Davidsv/ImageSharp
tests/ImageSharp.Tests/Drawing/DrawImageTest.cs
7,822
C#
namespace MassTransit.Containers.Tests.SimpleInjector_Tests { using System.Threading.Tasks; using Common_Tests; using NUnit.Framework; using SimpleInjector; using TestFramework.Sagas; [TestFixture] public class SimpleInjector_SagaStateMachine : Common_SagaStateMachine { [Test] public void Should_be_a_valid_container() { _container.Verify(); } readonly Container _container; public SimpleInjector_SagaStateMachine() { _container = new Container(); _container.SetMassTransitContainerOptions(); _container.AddMassTransit(ConfigureRegistration); _container.Register<PublishTestStartedActivity>(); } [OneTimeTearDown] public async Task Close_container() { await _container.DisposeAsync(); } protected override IBusRegistrationContext Registration => _container.GetInstance<IBusRegistrationContext>(); } }
25.121951
117
0.654369
[ "ECL-2.0", "Apache-2.0" ]
Aerodynamite/MassTrans
tests/MassTransit.Containers.Tests/SimpleInjector_Tests/SimpleInjector_SagaStateMachine.cs
1,030
C#
using System; using System.IO; using System.Windows.Forms; namespace DirectoryToJson { public partial class frmMain : Form { public frmMain() { InitializeComponent(); } private void label1_Click(object sender, EventArgs e) { } private void btnProcess_Click(object sender, EventArgs e) { Cursor.Current = Cursors.WaitCursor; try { string fullPath = Path.GetFullPath(txtPath.Text); Directories d = new Directories(fullPath, txtFilters.Text, rdbSuppressEmpty.Checked, rdbWriteChildren.Checked ); txtJSON.Text = d.GetJsonPretty(); File.WriteAllText(Path.Combine(fullPath, "directory.json"), d.GetJson()); } finally { Cursor.Current = Cursors.Default; } } private void btnBrowse_Click(object sender, EventArgs e) { if (folderBrowser.ShowDialog() == DialogResult.OK) { txtPath.Text = folderBrowser.SelectedPath; } } } }
25.434783
128
0.539316
[ "MIT" ]
CedartownOnline/DirToJSON
DirectoryToJson/frmMain.cs
1,172
C#
using NHapi.Base.Parser; using NHapi.Base; using NHapi.Base.Log; using System; using System.Collections.Generic; using NHapi.Model.V25.Segment; using NHapi.Model.V25.Datatype; using NHapi.Base.Model; namespace NHapi.Model.V25.Group { ///<summary> ///Represents the MFN_M05_MF_LOCATION Group. A Group is an ordered collection of message /// segments that can repeat together or be optionally in/excluded together. /// This Group contains the following elements: ///<ol> ///<li>0: MFE (Master File Entry) </li> ///<li>1: LOC (Location Identification) </li> ///<li>2: LCH (Location Characteristic) optional repeating</li> ///<li>3: LRL (Location Relationship) optional repeating</li> ///<li>4: MFN_M05_MF_LOC_DEPT (a Group object) repeating</li> ///</ol> ///</summary> [Serializable] public class MFN_M05_MF_LOCATION : AbstractGroup { ///<summary> /// Creates a new MFN_M05_MF_LOCATION Group. ///</summary> public MFN_M05_MF_LOCATION(IGroup parent, IModelClassFactory factory) : base(parent, factory){ try { this.add(typeof(MFE), true, false); this.add(typeof(LOC), true, false); this.add(typeof(LCH), false, true); this.add(typeof(LRL), false, true); this.add(typeof(MFN_M05_MF_LOC_DEPT), true, true); } catch(HL7Exception e) { HapiLogFactory.GetHapiLog(GetType()).Error("Unexpected error creating MFN_M05_MF_LOCATION - this is probably a bug in the source code generator.", e); } } ///<summary> /// Returns MFE (Master File Entry) - creates it if necessary ///</summary> public MFE MFE { get{ MFE ret = null; try { ret = (MFE)this.GetStructure("MFE"); } catch(HL7Exception e) { HapiLogFactory.GetHapiLog(GetType()).Error("Unexpected error accessing data - this is probably a bug in the source code generator.", e); throw new System.Exception("An unexpected error ocurred",e); } return ret; } } ///<summary> /// Returns LOC (Location Identification) - creates it if necessary ///</summary> public LOC LOC { get{ LOC ret = null; try { ret = (LOC)this.GetStructure("LOC"); } catch(HL7Exception e) { HapiLogFactory.GetHapiLog(GetType()).Error("Unexpected error accessing data - this is probably a bug in the source code generator.", e); throw new System.Exception("An unexpected error ocurred",e); } return ret; } } ///<summary> /// Returns first repetition of LCH (Location Characteristic) - creates it if necessary ///</summary> public LCH GetLCH() { LCH ret = null; try { ret = (LCH)this.GetStructure("LCH"); } catch(HL7Exception e) { HapiLogFactory.GetHapiLog(GetType()).Error("Unexpected error accessing data - this is probably a bug in the source code generator.", e); throw new System.Exception("An unexpected error ocurred",e); } return ret; } ///<summary> ///Returns a specific repetition of LCH /// * (Location Characteristic) - creates it if necessary /// throws HL7Exception if the repetition requested is more than one /// greater than the number of existing repetitions. ///</summary> public LCH GetLCH(int rep) { return (LCH)this.GetStructure("LCH", rep); } /** * Returns the number of existing repetitions of LCH */ public int LCHRepetitionsUsed { get{ int reps = -1; try { reps = this.GetAll("LCH").Length; } catch (HL7Exception e) { string message = "Unexpected error accessing data - this is probably a bug in the source code generator."; HapiLogFactory.GetHapiLog(GetType()).Error(message, e); throw new System.Exception(message); } return reps; } } /** * Enumerate over the LCH results */ public IEnumerable<LCH> LCHs { get { for (int rep = 0; rep < LCHRepetitionsUsed; rep++) { yield return (LCH)this.GetStructure("LCH", rep); } } } ///<summary> ///Adds a new LCH ///</summary> public LCH AddLCH() { return this.AddStructure("LCH") as LCH; } ///<summary> ///Removes the given LCH ///</summary> public void RemoveLCH(LCH toRemove) { this.RemoveStructure("LCH", toRemove); } ///<summary> ///Removes the LCH at the given index ///</summary> public void RemoveLCHAt(int index) { this.RemoveRepetition("LCH", index); } ///<summary> /// Returns first repetition of LRL (Location Relationship) - creates it if necessary ///</summary> public LRL GetLRL() { LRL ret = null; try { ret = (LRL)this.GetStructure("LRL"); } catch(HL7Exception e) { HapiLogFactory.GetHapiLog(GetType()).Error("Unexpected error accessing data - this is probably a bug in the source code generator.", e); throw new System.Exception("An unexpected error ocurred",e); } return ret; } ///<summary> ///Returns a specific repetition of LRL /// * (Location Relationship) - creates it if necessary /// throws HL7Exception if the repetition requested is more than one /// greater than the number of existing repetitions. ///</summary> public LRL GetLRL(int rep) { return (LRL)this.GetStructure("LRL", rep); } /** * Returns the number of existing repetitions of LRL */ public int LRLRepetitionsUsed { get{ int reps = -1; try { reps = this.GetAll("LRL").Length; } catch (HL7Exception e) { string message = "Unexpected error accessing data - this is probably a bug in the source code generator."; HapiLogFactory.GetHapiLog(GetType()).Error(message, e); throw new System.Exception(message); } return reps; } } /** * Enumerate over the LRL results */ public IEnumerable<LRL> LRLs { get { for (int rep = 0; rep < LRLRepetitionsUsed; rep++) { yield return (LRL)this.GetStructure("LRL", rep); } } } ///<summary> ///Adds a new LRL ///</summary> public LRL AddLRL() { return this.AddStructure("LRL") as LRL; } ///<summary> ///Removes the given LRL ///</summary> public void RemoveLRL(LRL toRemove) { this.RemoveStructure("LRL", toRemove); } ///<summary> ///Removes the LRL at the given index ///</summary> public void RemoveLRLAt(int index) { this.RemoveRepetition("LRL", index); } ///<summary> /// Returns first repetition of MFN_M05_MF_LOC_DEPT (a Group object) - creates it if necessary ///</summary> public MFN_M05_MF_LOC_DEPT GetMF_LOC_DEPT() { MFN_M05_MF_LOC_DEPT ret = null; try { ret = (MFN_M05_MF_LOC_DEPT)this.GetStructure("MF_LOC_DEPT"); } catch(HL7Exception e) { HapiLogFactory.GetHapiLog(GetType()).Error("Unexpected error accessing data - this is probably a bug in the source code generator.", e); throw new System.Exception("An unexpected error ocurred",e); } return ret; } ///<summary> ///Returns a specific repetition of MFN_M05_MF_LOC_DEPT /// * (a Group object) - creates it if necessary /// throws HL7Exception if the repetition requested is more than one /// greater than the number of existing repetitions. ///</summary> public MFN_M05_MF_LOC_DEPT GetMF_LOC_DEPT(int rep) { return (MFN_M05_MF_LOC_DEPT)this.GetStructure("MF_LOC_DEPT", rep); } /** * Returns the number of existing repetitions of MFN_M05_MF_LOC_DEPT */ public int MF_LOC_DEPTRepetitionsUsed { get{ int reps = -1; try { reps = this.GetAll("MF_LOC_DEPT").Length; } catch (HL7Exception e) { string message = "Unexpected error accessing data - this is probably a bug in the source code generator."; HapiLogFactory.GetHapiLog(GetType()).Error(message, e); throw new System.Exception(message); } return reps; } } /** * Enumerate over the MFN_M05_MF_LOC_DEPT results */ public IEnumerable<MFN_M05_MF_LOC_DEPT> MF_LOC_DEPTs { get { for (int rep = 0; rep < MF_LOC_DEPTRepetitionsUsed; rep++) { yield return (MFN_M05_MF_LOC_DEPT)this.GetStructure("MF_LOC_DEPT", rep); } } } ///<summary> ///Adds a new MFN_M05_MF_LOC_DEPT ///</summary> public MFN_M05_MF_LOC_DEPT AddMF_LOC_DEPT() { return this.AddStructure("MF_LOC_DEPT") as MFN_M05_MF_LOC_DEPT; } ///<summary> ///Removes the given MFN_M05_MF_LOC_DEPT ///</summary> public void RemoveMF_LOC_DEPT(MFN_M05_MF_LOC_DEPT toRemove) { this.RemoveStructure("MF_LOC_DEPT", toRemove); } ///<summary> ///Removes the MFN_M05_MF_LOC_DEPT at the given index ///</summary> public void RemoveMF_LOC_DEPTAt(int index) { this.RemoveRepetition("MF_LOC_DEPT", index); } } }
28.27476
158
0.641695
[ "MPL-2.0", "MPL-2.0-no-copyleft-exception" ]
afaonline/nHapi
src/NHapi.Model.V25/Group/MFN_M05_MF_LOCATION.cs
8,850
C#
// Copyright © Tanner Gooding and Contributors. Licensed under the MIT License (MIT). See License.md in the repository root for more information. // Ported from um/codecapi.h in the Windows SDK for Windows 10.0.20348.0 // Original source is Copyright © Microsoft. All rights reserved. using NUnit.Framework; using System; using System.Runtime.InteropServices; using static TerraFX.Interop.Windows; namespace TerraFX.Interop.UnitTests { /// <summary>Provides validation of the <see cref="CODECAPI_GUID_AVEncSDDS" /> struct.</summary> public static unsafe class CODECAPI_GUID_AVEncSDDSTests { /// <summary>Validates that the <see cref="Guid" /> of the <see cref="CODECAPI_GUID_AVEncSDDS" /> struct is correct.</summary> [Test] public static void GuidOfTest() { Assert.That(typeof(CODECAPI_GUID_AVEncSDDS).GUID, Is.EqualTo(STATIC_CODECAPI_GUID_AVEncSDDS)); } /// <summary>Validates that the <see cref="CODECAPI_GUID_AVEncSDDS" /> struct is blittable.</summary> [Test] public static void IsBlittableTest() { Assert.That(Marshal.SizeOf<CODECAPI_GUID_AVEncSDDS>(), Is.EqualTo(sizeof(CODECAPI_GUID_AVEncSDDS))); } /// <summary>Validates that the <see cref="CODECAPI_GUID_AVEncSDDS" /> struct has the right <see cref="LayoutKind" />.</summary> [Test] public static void IsLayoutSequentialTest() { Assert.That(typeof(CODECAPI_GUID_AVEncSDDS).IsLayoutSequential, Is.True); } /// <summary>Validates that the <see cref="CODECAPI_GUID_AVEncSDDS" /> struct has the correct size.</summary> [Test] public static void SizeOfTest() { Assert.That(sizeof(CODECAPI_GUID_AVEncSDDS), Is.EqualTo(1)); } } }
40.288889
145
0.679537
[ "MIT" ]
phizch/terrafx.interop.windows
tests/Interop/Windows/um/codecapi/CODECAPI_GUID_AVEncSDDSTests.cs
1,815
C#
using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Mvc; using OnlineShopping.Business.Abstract; using OnlineShopping.Entities.Concrete; using OnlineShopping.WebApi.Models; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace OnlineShopping.WebApi.Controllers { [Route("api/[controller]")] [ApiController] public class UserController : ControllerBase { private readonly IUserService userService; public UserController(IUserService userService) { this.userService = userService; } [HttpGet("{userID:int}")] public IActionResult GetUser(int userID) { Customer customer = userService.GetCustomer(userID); if (customer == null) return BadRequest(); if (!customer.IsEmailVerified) return Ok("Please verify mail address!"); return Ok(new UserModel { UserID = customer.UserID, Name = customer.Name, Surname = customer.Surname, Email = customer.Email }); } [HttpGet("Verify/{guid}")] public IActionResult VerifyUserEmail(Guid guid) { if (userService.VerifyUserEmail(guid)) return Ok(); return NotFound(); } [HttpPost] public IActionResult CreateUser(UserModel model) { Customer customer = userService.CreateCustomer(new() { Email = model.Email, Name = model.Name, Surname = model.Surname, Password = model.Password, IsEmailVerified = false, IsPasswordChange = false }); model.UserID = customer.UserID; return CreatedAtAction(nameof(GetUser), new { userID = customer.UserID }, model); } [HttpPut] public IActionResult UpdateUser(UserModel model) { userService.UpdateCustomer(new() { UserID = model.UserID, Name = model.Name, Surname = model.Surname, Password = model.Password }); return Ok(model); } [HttpGet("Employee/{userID:int}")] public IActionResult GetEmployee(int userID) { Employee employee = userService.GetEmployee(userID); if (employee == null) return BadRequest(); if (employee.IsPasswordChange) return Ok(new UserModel { UserID = employee.UserID, IsPasswordChange = true }); return Ok(new EmployeeModel { UserID = employee.UserID, Name = employee.Name, Surname = employee.Surname, Email = employee.Email, EmployeeType = employee.EmployeeType.ToString(), IsWorking = employee.EmployeeStatus == Entities.EmployeeStatus.Working }); } [HttpPost("Employee")] public IActionResult CreateEmployee(EmployeeModel model) { Employee employee = userService.CreateEmployee(new() { Email = model.Email, Name = model.Name, Surname = model.Surname, Password =model.Password, IsEmailVerified = true, IsPasswordChange = true, EmployeeStatus = Entities.EmployeeStatus.Working, EmployeeType = Enum.Parse<Entities.EmployeeType>(model.EmployeeType) }); return CreatedAtAction(nameof(GetEmployee), new { userID = employee.UserID }, model); } [HttpPut("Employee")] public IActionResult UpdateEmployee(EmployeeModel model) { userService.UpdateEmployee(new() { UserID = model.UserID, Name = model.Name, Surname = model.Surname, Password = model.Password, EmployeeStatus = model.IsWorking ? Entities.EmployeeStatus.Working : Entities.EmployeeStatus.Leave }); return Ok(model); } } }
31.855072
114
0.541174
[ "MIT" ]
danego61/Asp.Net-Core-Online-Shopping-Api
OnlineShopping.WebApi/Controllers/UserController.cs
4,398
C#
using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.Collections.Immutable; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; using Vostok.Commons.Time; using Vostok.Logging.Abstractions; using WhiteAlbum.Entities; using WhiteAlbum.Entities.Users; using WhiteAlbum.Helpers; using WhiteAlbum.Requests; using WhiteAlbum.Settings; using Single = WhiteAlbum.Entities.Single; namespace WhiteAlbum.Stores { public class SingleStore { private readonly ConcurrentDictionary<SingleId, Single> singles = new(); private readonly ConcurrentDictionary<UserId, ImmutableArray<Single>> singlesByUser = new(); private readonly ConcurrentDictionary<Date, ConcurrentBag<SingleId>> singlesByDate = new(); private readonly Func<WhiteAlbumSettings> getSettings; private readonly PeriodicalAction action; public SingleStore(Func<WhiteAlbumSettings> getSettings, ILog log) { this.getSettings = getSettings; action = new PeriodicalAction(() => Dump(), e => log.Error(e), () => 1.Seconds()); } public void Start() { action.Start(); } public void Stop() { action.Stop(); } public void Dump() { if (!File.Exists(getSettings().SinglesDumpPath)) File.Create(getSettings().SinglesDumpPath).Dispose(); var content = singles.Select(x => x.Value).ToJson(); if (content.Length < 3) return; var tmpFileName = $"{getSettings().SinglesDumpPath}_tmp_{Guid.NewGuid()}"; using (var tmpFile = new FileStream(tmpFileName, FileMode.Create)) { tmpFile.Write(Encoding.UTF8.GetBytes(content)); } File.Replace(tmpFileName, getSettings().SinglesDumpPath, null); } public void Initialize(IEnumerable<Single>? signles) { if (signles == null) return; foreach (var single in signles) { CreateInternal(single); } } public async Task<Single> Create(CreateSingleRequest request) { var now = Date.Now(); var single = new Single(request.Id, request.Name, request.Meta, request.Track, Context.User?.Id ?? throw new Exception("User is empty"), now) ; return CreateInternal(single); } private Single CreateInternal(Single single) { var result = singles.GetOrAdd(single.Id, single); try { if (!ReferenceEquals(result, single)) throw new Exception("Single already exists."); return result; } finally { while (true) { var usersAlbum= singlesByUser.GetOrAdd(result.Owner, _ => ImmutableArray<Single>.Empty); if (usersAlbum.Contains(single)) break; if (singlesByUser.TryUpdate(result.Owner, usersAlbum.Add(single), usersAlbum)) break; } singlesByDate.GetOrAdd(single.CreatedAt, _ => new()).Add(single.Id); } } public async Task<Single> Get(SingleId singleId) { return singles[singleId]; } public async Task<SingleEntry[]> GetByDate(Date date) { if (!singlesByDate.TryGetValue(date, out var singleIds)) return Array.Empty<SingleEntry>(); return singleIds.Select(x => singles[x]).Select(x => new SingleEntry(x.Id, x.Name, date)).ToArray(); } public async Task<ImmutableArray<Single>> Get(UserId userId) { if (singlesByUser.TryGetValue(userId, out var result)) return result; return ImmutableArray<Single>.Empty; } } }
31.864662
155
0.551439
[ "MIT" ]
HackerDom/ructf-2021
services/white_album/src/WhiteAlbum/Stores/SingleStore.cs
4,240
C#
// <auto-generated> // Code generated by Microsoft (R) AutoRest Code Generator. // Changes may cause incorrect behavior and will be lost if the code is // regenerated. // </auto-generated> namespace Zell.UiPathAutomation.Orchestrator.Models { using Newtonsoft.Json; using System.Linq; public partial class LicenseStatsModel { /// <summary> /// Initializes a new instance of the LicenseStatsModel class. /// </summary> public LicenseStatsModel() { CustomInit(); } /// <summary> /// Initializes a new instance of the LicenseStatsModel class. /// </summary> /// <param name="robotType">Possible values include: 'NonProduction', /// 'Attended', 'Unattended', 'Studio', 'Development', 'StudioX', /// 'Headless', 'StudioPro', 'TestAutomation'</param> public LicenseStatsModel(LicenseStatsModelRobotType? robotType = default(LicenseStatsModelRobotType?), long? count = default(long?), System.DateTime? timestamp = default(System.DateTime?)) { RobotType = robotType; Count = count; Timestamp = timestamp; CustomInit(); } /// <summary> /// An initialization method that performs custom operations like setting defaults /// </summary> partial void CustomInit(); /// <summary> /// Gets or sets possible values include: 'NonProduction', 'Attended', /// 'Unattended', 'Studio', 'Development', 'StudioX', 'Headless', /// 'StudioPro', 'TestAutomation' /// </summary> [JsonProperty(PropertyName = "robotType")] public LicenseStatsModelRobotType? RobotType { get; set; } /// <summary> /// </summary> [JsonProperty(PropertyName = "count")] public long? Count { get; set; } /// <summary> /// </summary> [JsonProperty(PropertyName = "timestamp")] public System.DateTime? Timestamp { get; set; } } }
33.42623
196
0.597352
[ "MIT" ]
zell12/MondayAppOne
Zell.UiPathAutomation/Orchestrator/Models/LicenseStatsModel.cs
2,039
C#
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Common; using System.Windows.Controls; using System.Windows.Ink; using System.Windows.Data; using System.Windows.Media; namespace DesktopAnnotator { /// <summary> /// 描画モードの種類 /// </summary> public enum DrawingMode { None = 0, Pen, Marker, Eraser, EraseByStroke } public class MainWindowViewModel : BindableBase { public DrawingAttributes PenAttributes { get { return new DrawingAttributes() { Color = Properties.Settings.Default.PenColor, Width = Properties.Settings.Default.PenThickness, Height = Properties.Settings.Default.PenThickness }; } } public DrawingAttributes MarkerAttributes { get { return new DrawingAttributes() { Color = Properties.Settings.Default.MarkerColor, Height = Properties.Settings.Default.MarkerThickness, IsHighlighter = true, IgnorePressure = true, }; } } public DrawingAttributes EraserAttributes { get { return new DrawingAttributes() {}; } } private DrawingMode currentMode; /// <summary> /// 現在の描画モードを取得または設定します。 /// </summary> public DrawingMode CurrentMode { get { return currentMode; } set { // プロパティ値を変更 this.SetProperty(ref this.currentMode, value); // 設定されたモードに合わせて、他のプロパティも設定 switch (currentMode) { case DrawingMode.None: break; case DrawingMode.Pen: EditingMode = InkCanvasEditingMode.Ink; DrawingAttribute = PenAttributes; break; case DrawingMode.Marker: EditingMode = InkCanvasEditingMode.Ink; DrawingAttribute = MarkerAttributes; break; case DrawingMode.Eraser: EditingMode = InkCanvasEditingMode.EraseByPoint; DrawingAttribute = EraserAttributes; break; case DrawingMode.EraseByStroke: EditingMode = InkCanvasEditingMode.EraseByStroke; DrawingAttribute = EraserAttributes; break; default: break; } } } private InkCanvasEditingMode editingMode; /// <summary> /// InkCanvasの編集モードを取得または設定します。 /// </summary> public InkCanvasEditingMode EditingMode { get { return editingMode; } set { this.SetProperty(ref this.editingMode, value); } } private DrawingAttributes drawingAttribute; /// <summary> /// 描画に使用する属性を取得または設定します。 /// </summary> public DrawingAttributes DrawingAttribute { get { return drawingAttribute; } set { this.SetProperty(ref this.drawingAttribute, value); } } private StrokeCollection strokes; /// <summary> /// InkCanvasの描画内容を取得または設定します。 /// </summary> public StrokeCollection Strokes { get { return strokes; } set { this.SetProperty(ref this.strokes, value); } } public MainWindowViewModel() { CurrentMode = DrawingMode.Pen; Strokes = new StrokeCollection(); } #region 各種コマンドの実装 private DelegateCommand clearCommand; public DelegateCommand ClearCommand { get { return clearCommand = clearCommand ?? new DelegateCommand(ClearCanvas); } } private void ClearCanvas(object param) { Strokes.Clear(); } private DelegateCommand selectDrawingModeCommand; public DelegateCommand SelectDrawingModeCommand { get { return selectDrawingModeCommand = selectDrawingModeCommand ?? new DelegateCommand(SelectDrawingMode); } } private void SelectDrawingMode(object param) { var mode = (DrawingMode)param; CurrentMode = mode; } #endregion } /// <summary> /// 現在の描画モードと指定されたパラメータからbool値に変換するコンバーター /// </summary> /// <remarks> /// ContextMenu内のチェック表示に使用 /// </remarks> public class CurrentModeToBooleanConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { var p = (DrawingMode)parameter; var v = (DrawingMode)value; return p == v; } public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { throw new NotImplementedException(); } } }
28.647368
124
0.528569
[ "MIT" ]
sourcechord/DesktopAnnotator
DesktopAnnotator/MainWindowViewModel.cs
5,785
C#
namespace Eventures.Data.Migrations { using Microsoft.EntityFrameworkCore.Metadata; using Microsoft.EntityFrameworkCore.Migrations; using System; public partial class CreateIdentitySchema : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( name: "AspNetRoles", columns: table => new { Id = table.Column<string>(nullable: false), Name = table.Column<string>(maxLength: 256, nullable: true), NormalizedName = table.Column<string>(maxLength: 256, nullable: true), ConcurrencyStamp = table.Column<string>(nullable: true) }, constraints: table => { table.PrimaryKey("PK_AspNetRoles", x => x.Id); }); migrationBuilder.CreateTable( name: "AspNetUsers", columns: table => new { Id = table.Column<string>(nullable: false), UserName = table.Column<string>(maxLength: 256, nullable: true), NormalizedUserName = table.Column<string>(maxLength: 256, nullable: true), Email = table.Column<string>(maxLength: 256, nullable: true), NormalizedEmail = table.Column<string>(maxLength: 256, nullable: true), EmailConfirmed = table.Column<bool>(nullable: false), PasswordHash = table.Column<string>(nullable: true), SecurityStamp = table.Column<string>(nullable: true), ConcurrencyStamp = table.Column<string>(nullable: true), PhoneNumber = table.Column<string>(nullable: true), PhoneNumberConfirmed = table.Column<bool>(nullable: false), TwoFactorEnabled = table.Column<bool>(nullable: false), LockoutEnd = table.Column<DateTimeOffset>(nullable: true), LockoutEnabled = table.Column<bool>(nullable: false), AccessFailedCount = table.Column<int>(nullable: false) }, constraints: table => { table.PrimaryKey("PK_AspNetUsers", x => x.Id); }); migrationBuilder.CreateTable( name: "AspNetRoleClaims", columns: table => new { Id = table.Column<int>(nullable: false) .Annotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn), RoleId = table.Column<string>(nullable: false), ClaimType = table.Column<string>(nullable: true), ClaimValue = table.Column<string>(nullable: true) }, constraints: table => { table.PrimaryKey("PK_AspNetRoleClaims", x => x.Id); table.ForeignKey( name: "FK_AspNetRoleClaims_AspNetRoles_RoleId", column: x => x.RoleId, principalTable: "AspNetRoles", principalColumn: "Id", onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateTable( name: "AspNetUserClaims", columns: table => new { Id = table.Column<int>(nullable: false) .Annotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn), UserId = table.Column<string>(nullable: false), ClaimType = table.Column<string>(nullable: true), ClaimValue = table.Column<string>(nullable: true) }, constraints: table => { table.PrimaryKey("PK_AspNetUserClaims", x => x.Id); table.ForeignKey( name: "FK_AspNetUserClaims_AspNetUsers_UserId", column: x => x.UserId, principalTable: "AspNetUsers", principalColumn: "Id", onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateTable( name: "AspNetUserLogins", columns: table => new { LoginProvider = table.Column<string>(maxLength: 128, nullable: false), ProviderKey = table.Column<string>(maxLength: 128, nullable: false), ProviderDisplayName = table.Column<string>(nullable: true), UserId = table.Column<string>(nullable: false) }, constraints: table => { table.PrimaryKey("PK_AspNetUserLogins", x => new { x.LoginProvider, x.ProviderKey }); table.ForeignKey( name: "FK_AspNetUserLogins_AspNetUsers_UserId", column: x => x.UserId, principalTable: "AspNetUsers", principalColumn: "Id", onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateTable( name: "AspNetUserRoles", columns: table => new { UserId = table.Column<string>(nullable: false), RoleId = table.Column<string>(nullable: false) }, constraints: table => { table.PrimaryKey("PK_AspNetUserRoles", x => new { x.UserId, x.RoleId }); table.ForeignKey( name: "FK_AspNetUserRoles_AspNetRoles_RoleId", column: x => x.RoleId, principalTable: "AspNetRoles", principalColumn: "Id", onDelete: ReferentialAction.Cascade); table.ForeignKey( name: "FK_AspNetUserRoles_AspNetUsers_UserId", column: x => x.UserId, principalTable: "AspNetUsers", principalColumn: "Id", onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateTable( name: "AspNetUserTokens", columns: table => new { UserId = table.Column<string>(nullable: false), LoginProvider = table.Column<string>(maxLength: 128, nullable: false), Name = table.Column<string>(maxLength: 128, nullable: false), Value = table.Column<string>(nullable: true) }, constraints: table => { table.PrimaryKey("PK_AspNetUserTokens", x => new { x.UserId, x.LoginProvider, x.Name }); table.ForeignKey( name: "FK_AspNetUserTokens_AspNetUsers_UserId", column: x => x.UserId, principalTable: "AspNetUsers", principalColumn: "Id", onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateIndex( name: "IX_AspNetRoleClaims_RoleId", table: "AspNetRoleClaims", column: "RoleId"); migrationBuilder.CreateIndex( name: "RoleNameIndex", table: "AspNetRoles", column: "NormalizedName", unique: true, filter: "[NormalizedName] IS NOT NULL"); migrationBuilder.CreateIndex( name: "IX_AspNetUserClaims_UserId", table: "AspNetUserClaims", column: "UserId"); migrationBuilder.CreateIndex( name: "IX_AspNetUserLogins_UserId", table: "AspNetUserLogins", column: "UserId"); migrationBuilder.CreateIndex( name: "IX_AspNetUserRoles_RoleId", table: "AspNetUserRoles", column: "RoleId"); migrationBuilder.CreateIndex( name: "EmailIndex", table: "AspNetUsers", column: "NormalizedEmail"); migrationBuilder.CreateIndex( name: "UserNameIndex", table: "AspNetUsers", column: "NormalizedUserName", unique: true, filter: "[NormalizedUserName] IS NOT NULL"); } protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "AspNetRoleClaims"); migrationBuilder.DropTable( name: "AspNetUserClaims"); migrationBuilder.DropTable( name: "AspNetUserLogins"); migrationBuilder.DropTable( name: "AspNetUserRoles"); migrationBuilder.DropTable( name: "AspNetUserTokens"); migrationBuilder.DropTable( name: "AspNetRoles"); migrationBuilder.DropTable( name: "AspNetUsers"); } } }
43.322727
122
0.497849
[ "MIT" ]
thelad43/CSharp-MVC-Frameworks-ASP.NET-Core-SoftUni
03. Eventures Inc/Eventures.Data/Migrations/00000000000000_CreateIdentitySchema.cs
9,533
C#
//------------------------------------------------------------------------------ // <auto-generated> // This code was generated by a tool. // Runtime Version:4.0.30319.1 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // </auto-generated> //------------------------------------------------------------------------------ namespace HiddenTear_Decrypt.Properties { [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")] internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); public static Settings Default { get { return defaultInstance; } } } }
35.451613
152
0.566879
[ "MIT" ]
Harot5001/HiddenTear
HiddenTear-Decrypt/Properties/Settings.Designer.cs
1,101
C#
using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.Net; using System.Web.Http; using System.Web.Http.Controllers; using System.Web.Http.ModelBinding; using System.Web.Security; using AutoMapper; using Umbraco.Core; using Umbraco.Core.Models; using Umbraco.Core.Security; using Umbraco.Core.Services; using Umbraco.Web.Models.ContentEditing; using Umbraco.Web.WebApi.Filters; using System.Linq; using Umbraco.Core.Models.Membership; using Umbraco.Web; namespace Umbraco.Web.WebApi.Binders { internal class MemberBinder : ContentItemBaseBinder<IMember, MemberSave> { public MemberBinder(ApplicationContext applicationContext) : base(applicationContext) { } /// <summary> /// Constructor /// </summary> public MemberBinder() : this(ApplicationContext.Current) { } protected override ContentItemValidationHelper<IMember, MemberSave> GetValidationHelper() { return new MemberValidationHelper(); } /// <summary> /// Returns an IMember instance used to bind values to and save (depending on the membership scenario) /// </summary> /// <param name="model"></param> /// <returns></returns> protected override IMember GetExisting(MemberSave model) { var scenario = ApplicationContext.Services.MemberService.GetMembershipScenario(); var provider = Core.Security.MembershipProviderExtensions.GetMembersMembershipProvider(); switch (scenario) { case MembershipScenario.NativeUmbraco: return GetExisting(model.Key); case MembershipScenario.CustomProviderWithUmbracoLink: case MembershipScenario.StandaloneCustomProvider: default: var membershipUser = provider.GetUser(model.Key, false); if (membershipUser == null) { throw new InvalidOperationException("Could not find member with key " + model.Key); } //TODO: Support this scenario! //if (scenario == MembershipScenario.CustomProviderWithUmbracoLink) //{ // //if there's a 'Member' type then we should be able to just go get it from the db since it was created with a link // // to our data. // var memberType = ApplicationContext.Services.MemberTypeService.GetMemberType(Constants.Conventions.MemberTypes.Member); // if (memberType != null) // { // var existing = GetExisting(model.Key); // FilterContentTypeProperties(existing.ContentType, existing.ContentType.PropertyTypes.Select(x => x.Alias).ToArray()); // } //} //generate a member for a generic membership provider //NOTE: We don't care about the password here, so just generate something //var member = MemberService.CreateGenericMembershipProviderMember(model.Name, model.Email, model.Username, Guid.NewGuid().ToString("N")); //var convertResult = membershipUser.ProviderUserKey.TryConvertTo<Guid>(); //if (convertResult.Success == false) //{ // throw new InvalidOperationException("Only membership providers that store a GUID as their ProviderUserKey are supported" + model.Key); //} //member.Key = convertResult.Result; var member = Mapper.Map<MembershipUser, IMember>(membershipUser); return member; } } private IMember GetExisting(Guid key) { var member = ApplicationContext.Services.MemberService.GetByKey(key); if (member == null) { throw new InvalidOperationException("Could not find member with key " + key); } var standardProps = Constants.Conventions.Member.GetStandardPropertyTypeStubs(); //remove all membership properties, these values are set with the membership provider. var exclude = standardProps.Select(x => x.Value.Alias).ToArray(); foreach (var remove in exclude) { member.Properties.Remove(remove); } return member; } /// <summary> /// Gets an instance of IMember used when creating a member /// </summary> /// <param name="model"></param> /// <returns></returns> /// <remarks> /// Depending on whether a custom membership provider is configured this will return different results. /// </remarks> protected override IMember CreateNew(MemberSave model) { var provider = Core.Security.MembershipProviderExtensions.GetMembersMembershipProvider(); if (provider.IsUmbracoMembershipProvider()) { var contentType = ApplicationContext.Services.MemberTypeService.Get(model.ContentTypeAlias); if (contentType == null) { throw new InvalidOperationException("No member type found wth alias " + model.ContentTypeAlias); } //remove all membership properties, these values are set with the membership provider. FilterMembershipProviderProperties(contentType); //return the new member with the details filled in return new Member(model.Name, model.Email, model.Username, model.Password.NewPassword, contentType); } else { //A custom membership provider is configured //NOTE: Below we are assigning the password to just a new GUID because we are not actually storing the password, however that // field is mandatory in the database so we need to put something there. //If the default Member type exists, we'll use that to create the IMember - that way we can associate the custom membership // provider to our data - eventually we can support editing custom properties with a custom provider. var memberType = ApplicationContext.Services.MemberTypeService.Get(Constants.Conventions.MemberTypes.DefaultAlias); if (memberType != null) { FilterContentTypeProperties(memberType, memberType.PropertyTypes.Select(x => x.Alias).ToArray()); return new Member(model.Name, model.Email, model.Username, Guid.NewGuid().ToString("N"), memberType); } //generate a member for a generic membership provider var member = MemberService.CreateGenericMembershipProviderMember(model.Name, model.Email, model.Username, Guid.NewGuid().ToString("N")); //we'll just remove all properties here otherwise we'll end up with validation errors, we don't want to persist any property data anyways // in this case. FilterContentTypeProperties(member.ContentType, member.ContentType.PropertyTypes.Select(x => x.Alias).ToArray()); return member; } } /// <summary> /// This will remove all of the special membership provider properties which were required to display the property editors /// for editing - but the values have been mapped back ot the MemberSave object directly - we don't want to keep these properties /// on the IMember because they will attempt to be persisted which we don't want since they might not even exist. /// </summary> /// <param name="contentType"></param> private void FilterMembershipProviderProperties(IContentTypeBase contentType) { var defaultProps = Constants.Conventions.Member.GetStandardPropertyTypeStubs(); //remove all membership properties, these values are set with the membership provider. var exclude = defaultProps.Select(x => x.Value.Alias).ToArray(); FilterContentTypeProperties(contentType, exclude); } private void FilterContentTypeProperties(IContentTypeBase contentType, IEnumerable<string> exclude) { //remove all properties based on the exclusion list foreach (var remove in exclude) { if (contentType.PropertyTypeExists(remove)) { contentType.RemovePropertyType(remove); } } } protected override ContentItemDto<IMember> MapFromPersisted(MemberSave model) { return Mapper.Map<IMember, ContentItemDto<IMember>>(model.PersistedContent); } /// <summary> /// Custom validation helper so that we can exclude the Member.StandardPropertyTypeStubs from being validating for existence /// </summary> internal class MemberValidationHelper : ContentItemValidationHelper<IMember, MemberSave> { /// <summary> /// We need to manually validate a few things here like email and login to make sure they are valid and aren't duplicates /// </summary> /// <param name="postedItem"></param> /// <param name="actionContext"></param> /// <returns></returns> protected override bool ValidatePropertyData(ContentItemBasic<ContentPropertyBasic, IMember> postedItem, HttpActionContext actionContext) { var memberSave = (MemberSave)postedItem; if (memberSave.Username.IsNullOrWhiteSpace()) { actionContext.ModelState.AddPropertyError( new ValidationResult("Invalid user name", new[] { "value" }), string.Format("{0}login", Constants.PropertyEditors.InternalGenericPropertiesPrefix)); } if (memberSave.Email.IsNullOrWhiteSpace() || new EmailAddressAttribute().IsValid(memberSave.Email) == false) { actionContext.ModelState.AddPropertyError( new ValidationResult("Invalid email", new[] { "value" }), string.Format("{0}email", Constants.PropertyEditors.InternalGenericPropertiesPrefix)); } //default provider! var membershipProvider = Core.Security.MembershipProviderExtensions.GetMembersMembershipProvider(); var validEmail = ValidateUniqueEmail(memberSave, membershipProvider, actionContext); if (validEmail == false) { actionContext.ModelState.AddPropertyError( new ValidationResult("Email address is already in use", new[] { "value" }), string.Format("{0}email", Constants.PropertyEditors.InternalGenericPropertiesPrefix)); } var validLogin = ValidateUniqueLogin(memberSave, membershipProvider, actionContext); if (validLogin == false) { actionContext.ModelState.AddPropertyError( new ValidationResult("Username is already in use", new[] { "value" }), string.Format("{0}login", Constants.PropertyEditors.InternalGenericPropertiesPrefix)); } return base.ValidatePropertyData(postedItem, actionContext); } protected override bool ValidateProperties(ContentItemBasic<ContentPropertyBasic, IMember> postedItem, HttpActionContext actionContext) { var propertiesToValidate = postedItem.Properties.ToList(); var defaultProps = Constants.Conventions.Member.GetStandardPropertyTypeStubs(); var exclude = defaultProps.Select(x => x.Value.Alias).ToArray(); foreach (var remove in exclude) { propertiesToValidate.RemoveAll(property => property.Alias == remove); } return ValidateProperties(propertiesToValidate.ToArray(), postedItem.PersistedContent.Properties.ToArray(), actionContext); } internal bool ValidateUniqueLogin(MemberSave contentItem, MembershipProvider membershipProvider, HttpActionContext actionContext) { if (contentItem == null) throw new ArgumentNullException("contentItem"); if (membershipProvider == null) throw new ArgumentNullException("membershipProvider"); int totalRecs; var existingByName = membershipProvider.FindUsersByName(contentItem.Username.Trim(), 0, int.MaxValue, out totalRecs); switch (contentItem.Action) { case ContentSaveAction.Save: //ok, we're updating the member, we need to check if they are changing their login and if so, does it exist already ? if (contentItem.PersistedContent.Username.InvariantEquals(contentItem.Username.Trim()) == false) { //they are changing their login name if (existingByName.Cast<MembershipUser>().Select(x => x.UserName) .Any(x => x == contentItem.Username.Trim())) { //the user cannot use this login return false; } } break; case ContentSaveAction.SaveNew: //check if the user's login already exists if (existingByName.Cast<MembershipUser>().Select(x => x.UserName) .Any(x => x == contentItem.Username.Trim())) { //the user cannot use this login return false; } break; default: //we don't support this for members throw new HttpResponseException(HttpStatusCode.NotFound); } return true; } internal bool ValidateUniqueEmail(MemberSave contentItem, MembershipProvider membershipProvider, HttpActionContext actionContext) { if (contentItem == null) throw new ArgumentNullException("contentItem"); if (membershipProvider == null) throw new ArgumentNullException("membershipProvider"); if (membershipProvider.RequiresUniqueEmail == false) { return true; } int totalRecs; var existingByEmail = membershipProvider.FindUsersByEmail(contentItem.Email.Trim(), 0, int.MaxValue, out totalRecs); switch (contentItem.Action) { case ContentSaveAction.Save: //ok, we're updating the member, we need to check if they are changing their email and if so, does it exist already ? if (contentItem.PersistedContent.Email.InvariantEquals(contentItem.Email.Trim()) == false) { //they are changing their email if (existingByEmail.Cast<MembershipUser>().Select(x => x.Email) .Any(x => x.InvariantEquals(contentItem.Email.Trim()))) { //the user cannot use this email return false; } } break; case ContentSaveAction.SaveNew: //check if the user's email already exists if (existingByEmail.Cast<MembershipUser>().Select(x => x.Email) .Any(x => x.InvariantEquals(contentItem.Email.Trim()))) { //the user cannot use this email return false; } break; default: //we don't support this for members throw new HttpResponseException(HttpStatusCode.NotFound); } return true; } } } }
50.211594
179
0.559891
[ "MIT" ]
ClaytonWang/Umbraco-CMS
src/Umbraco.Web/WebApi/Binders/MemberBinder.cs
17,325
C#
using System.Collections.Generic; namespace SeprrAPI.Contract { public class SlackRequest { public string text { get; set; } } public class SlackResponse { public string text { get; set; } public List<Attachments> attachments { get; set; } } public class Attachments { public string title { get; set; } public string text { get; set; } public string color { get; set; } public string[] mrkdwn_in { get; set; } = { "text", "fields" }; public List<Fields> fields { get; set; } public string ts { get; set; } public string footer { get; set; } } public class Fields { public string title { get; set; } public string value { get; set; } } public class ApiResponse { public string orig_train { get; set; } public string orig_departure_time { get; set; } public string orig_line { get; set; } public string orig_arrival_time { get; set; } public string orig_delay { get; set; } public string isdirect { get; set; } } }
26.714286
71
0.57754
[ "MIT" ]
NavneetHegde/SeprrAPI
SeprrAPI/Contract/SlackPayload.cs
1,124
C#
// Copyright (c) Microsoft. All rights reserved. namespace Microsoft.Azure.Devices.Edge.Util { using System.Threading.Tasks; /// <summary> /// Signature provider. /// </summary> public interface ISignatureProvider { Task<string> SignAsync(string data); } }
21
48
0.653061
[ "MIT" ]
ArchanaMSFT/iotedge
edge-util/src/Microsoft.Azure.Devices.Edge.Util/ISignatureProvider.cs
294
C#
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0 // Changes may cause incorrect behavior and will be lost if the code is // regenerated. namespace AutorestClient.Models { using Newtonsoft.Json; using System.Collections; using System.Collections.Generic; using System.Linq; /// <summary> /// ResponseError /// </summary> /// <remarks> /// ResponseError /// </remarks> public partial class ResponseError { /// <summary> /// Initializes a new instance of the ResponseError class. /// </summary> public ResponseError() { CustomInit(); } /// <summary> /// Initializes a new instance of the ResponseError class. /// </summary> public ResponseError(string errorCode = default(string), string fieldName = default(string), string message = default(string), IDictionary<string, string> meta = default(IDictionary<string, string>)) { ErrorCode = errorCode; FieldName = fieldName; Message = message; Meta = meta; CustomInit(); } /// <summary> /// An initialization method that performs custom operations like setting defaults /// </summary> partial void CustomInit(); /// <summary> /// </summary> [JsonProperty(PropertyName = "ErrorCode")] public string ErrorCode { get; set; } /// <summary> /// </summary> [JsonProperty(PropertyName = "FieldName")] public string FieldName { get; set; } /// <summary> /// </summary> [JsonProperty(PropertyName = "Message")] public string Message { get; set; } /// <summary> /// </summary> [JsonProperty(PropertyName = "Meta")] public IDictionary<string, string> Meta { get; set; } } }
29.522388
208
0.553084
[ "Apache-2.0" ]
BruceCowan-AI/ServiceStack
tests/ServiceStack.OpenApi.Tests/GeneratedClient/Models/ResponseError.cs
1,912
C#
// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.md in the project root for license information. using System; using System.Collections.Generic; using System.Data.SqlClient; using System.Diagnostics; using System.Diagnostics.CodeAnalysis; using System.Globalization; using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.SignalR.Messaging; using Microsoft.AspNet.SignalR.Tracing; namespace Microsoft.AspNet.SignalR.SqlServer { /// <summary> /// Uses SQL Server tables to scale-out SignalR applications in web farms. /// </summary> public class SqlMessageBus : ScaleoutMessageBus { internal const string SchemaName = "SignalR"; private const string _tableNamePrefix = "Messages"; private readonly string _connectionString; private readonly SqlScaleoutConfiguration _configuration; // This is the specific TraceSource for the SqlMessageBus. The Trace property from the base type traces from ScaleoutMessageBus // so we generally don't want to use that from here. private readonly TraceSource _trace; private readonly IDbProviderFactory _dbProviderFactory; private readonly List<SqlStream> _streams = new List<SqlStream>(); /// <summary> /// Creates a new instance of the SqlMessageBus class. /// </summary> /// <param name="resolver">The resolver to use.</param> /// <param name="configuration">The SQL scale-out configuration options.</param> public SqlMessageBus(IDependencyResolver resolver, SqlScaleoutConfiguration configuration) : this(resolver, configuration, SqlClientFactory.Instance.AsIDbProviderFactory()) { } internal SqlMessageBus(IDependencyResolver resolver, SqlScaleoutConfiguration configuration, IDbProviderFactory dbProviderFactory) : base(resolver, configuration) { if (configuration == null) { throw new ArgumentNullException("configuration"); } _connectionString = configuration.ConnectionString; _configuration = configuration; _dbProviderFactory = dbProviderFactory; var traceManager = resolver.Resolve<ITraceManager>(); _trace = traceManager["SignalR." + typeof(SqlMessageBus).Name]; ThreadPool.QueueUserWorkItem(Initialize); } protected override int StreamCount { get { return _configuration.TableCount; } } protected override Task Send(int streamIndex, IList<Message> messages) { return _streams[streamIndex].Send(messages); } protected override void Dispose(bool disposing) { _trace.TraceInformation("SQL message bus disposing, disposing streams"); for (var i = 0; i < _streams.Count; i++) { _streams[i].Dispose(); } base.Dispose(disposing); } [SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope", Justification = "They're stored in a List and disposed in the Dispose method"), SuppressMessage("Microsoft.Design", "CA1031:DoNotCatchGeneralExceptionTypes", Justification = "On a background thread and we report exceptions asynchronously")] private void Initialize(object state) { // NOTE: Called from a ThreadPool thread _trace.TraceInformation("SQL message bus initializing, TableCount={0}", _configuration.TableCount); while (true) { try { var installer = new SqlInstaller(_connectionString, _tableNamePrefix, _configuration.TableCount, _trace); installer.Install(); break; } catch (Exception ex) { // Exception while installing for (var i = 0; i < _configuration.TableCount; i++) { OnError(i, ex); } _trace.TraceError("Error trying to install SQL server objects, trying again in 2 seconds: {0}", ex); // Try again in a little bit Thread.Sleep(2000); } } for (var i = 0; i < _configuration.TableCount; i++) { var streamIndex = i; var tableName = String.Format(CultureInfo.InvariantCulture, "{0}_{1}", _tableNamePrefix, streamIndex); var stream = new SqlStream(streamIndex, _connectionString, tableName, _trace, _dbProviderFactory); stream.Queried += () => Open(streamIndex); stream.Faulted += (ex) => OnError(streamIndex, ex); stream.Received += (id, messages) => OnReceived(streamIndex, id, messages); _streams.Add(stream); StartReceiving(streamIndex); } } private void StartReceiving(int streamIndex) { var stream = _streams[streamIndex]; stream.StartReceiving() // Open the stream once receiving has started .Then(() => Open(streamIndex)) // Starting the receive loop failed .Catch(ex => { OnError(streamIndex, ex); // Try again in a little bit Thread.Sleep(2000); StartReceiving(streamIndex); }, _trace); } } }
37.769737
175
0.592057
[ "Apache-2.0" ]
AndreasBieber/SignalR
src/Microsoft.AspNet.SignalR.SqlServer/SqlMessageBus.cs
5,743
C#
#if UNITY_ANDROID && ! UNITY_EDITOR //------------------------------------------------------------------------------ // <auto-generated /> // // This file was automatically generated by SWIG (http://www.swig.org). // Version 3.0.12 // // Do not make changes to this file unless you know what you are doing--modify // the SWIG interface file instead. //------------------------------------------------------------------------------ class AkSoundEnginePINVOKE { static AkSoundEnginePINVOKE() { } [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_SOUNDBANK_VERSION_get")] public static extern uint CSharp_AK_SOUNDBANK_VERSION_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioSettings_uNumSamplesPerFrame_set")] public static extern void CSharp_AkAudioSettings_uNumSamplesPerFrame_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioSettings_uNumSamplesPerFrame_get")] public static extern uint CSharp_AkAudioSettings_uNumSamplesPerFrame_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioSettings_uNumSamplesPerSecond_set")] public static extern void CSharp_AkAudioSettings_uNumSamplesPerSecond_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioSettings_uNumSamplesPerSecond_get")] public static extern uint CSharp_AkAudioSettings_uNumSamplesPerSecond_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkAudioSettings")] public static extern global::System.IntPtr CSharp_new_AkAudioSettings(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkAudioSettings")] public static extern void CSharp_delete_AkAudioSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_idDevice_set")] public static extern void CSharp_AkDeviceDescription_idDevice_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_idDevice_get")] public static extern uint CSharp_AkDeviceDescription_idDevice_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_deviceName_set")] public static extern void CSharp_AkDeviceDescription_deviceName_set(global::System.IntPtr jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_deviceName_get")] public static extern global::System.IntPtr CSharp_AkDeviceDescription_deviceName_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_deviceStateMask_set")] public static extern void CSharp_AkDeviceDescription_deviceStateMask_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_deviceStateMask_get")] public static extern int CSharp_AkDeviceDescription_deviceStateMask_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_isDefaultDevice_set")] public static extern void CSharp_AkDeviceDescription_isDefaultDevice_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_isDefaultDevice_get")] public static extern bool CSharp_AkDeviceDescription_isDefaultDevice_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_Clear")] public static extern void CSharp_AkDeviceDescription_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_GetSizeOf")] public static extern int CSharp_AkDeviceDescription_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceDescription_Clone")] public static extern void CSharp_AkDeviceDescription_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkDeviceDescription")] public static extern global::System.IntPtr CSharp_new_AkDeviceDescription(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkDeviceDescription")] public static extern void CSharp_delete_AkDeviceDescription(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_Position")] public static extern UnityEngine.Vector3 CSharp_AkTransform_Position(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_OrientationFront")] public static extern UnityEngine.Vector3 CSharp_AkTransform_OrientationFront(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_OrientationTop")] public static extern UnityEngine.Vector3 CSharp_AkTransform_OrientationTop(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_Set__SWIG_0")] public static extern void CSharp_AkTransform_Set__SWIG_0(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2, UnityEngine.Vector3 jarg3, UnityEngine.Vector3 jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_Set__SWIG_1")] public static extern void CSharp_AkTransform_Set__SWIG_1(global::System.IntPtr jarg1, float jarg2, float jarg3, float jarg4, float jarg5, float jarg6, float jarg7, float jarg8, float jarg9, float jarg10); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_SetPosition__SWIG_0")] public static extern void CSharp_AkTransform_SetPosition__SWIG_0(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_SetPosition__SWIG_1")] public static extern void CSharp_AkTransform_SetPosition__SWIG_1(global::System.IntPtr jarg1, float jarg2, float jarg3, float jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_SetOrientation__SWIG_0")] public static extern void CSharp_AkTransform_SetOrientation__SWIG_0(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2, UnityEngine.Vector3 jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTransform_SetOrientation__SWIG_1")] public static extern void CSharp_AkTransform_SetOrientation__SWIG_1(global::System.IntPtr jarg1, float jarg2, float jarg3, float jarg4, float jarg5, float jarg6, float jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkTransform")] public static extern global::System.IntPtr CSharp_new_AkTransform(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkTransform")] public static extern void CSharp_delete_AkTransform(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_occlusion_set")] public static extern void CSharp_AkObstructionOcclusionValues_occlusion_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_occlusion_get")] public static extern float CSharp_AkObstructionOcclusionValues_occlusion_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_obstruction_set")] public static extern void CSharp_AkObstructionOcclusionValues_obstruction_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_obstruction_get")] public static extern float CSharp_AkObstructionOcclusionValues_obstruction_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_Clear")] public static extern void CSharp_AkObstructionOcclusionValues_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_GetSizeOf")] public static extern int CSharp_AkObstructionOcclusionValues_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObstructionOcclusionValues_Clone")] public static extern void CSharp_AkObstructionOcclusionValues_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkObstructionOcclusionValues")] public static extern global::System.IntPtr CSharp_new_AkObstructionOcclusionValues(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkObstructionOcclusionValues")] public static extern void CSharp_delete_AkObstructionOcclusionValues(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelEmitter_position_set")] public static extern void CSharp_AkChannelEmitter_position_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelEmitter_position_get")] public static extern global::System.IntPtr CSharp_AkChannelEmitter_position_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelEmitter_uInputChannels_set")] public static extern void CSharp_AkChannelEmitter_uInputChannels_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelEmitter_uInputChannels_get")] public static extern uint CSharp_AkChannelEmitter_uInputChannels_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkChannelEmitter")] public static extern void CSharp_delete_AkChannelEmitter(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_listenerID_set")] public static extern void CSharp_AkAuxSendValue_listenerID_set(global::System.IntPtr jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_listenerID_get")] public static extern ulong CSharp_AkAuxSendValue_listenerID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_auxBusID_set")] public static extern void CSharp_AkAuxSendValue_auxBusID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_auxBusID_get")] public static extern uint CSharp_AkAuxSendValue_auxBusID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_fControlValue_set")] public static extern void CSharp_AkAuxSendValue_fControlValue_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_fControlValue_get")] public static extern float CSharp_AkAuxSendValue_fControlValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_Set")] public static extern void CSharp_AkAuxSendValue_Set(global::System.IntPtr jarg1, ulong jarg2, uint jarg3, float jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_IsSame")] public static extern bool CSharp_AkAuxSendValue_IsSame(global::System.IntPtr jarg1, ulong jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAuxSendValue_GetSizeOf")] public static extern int CSharp_AkAuxSendValue_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkAuxSendValue")] public static extern void CSharp_delete_AkAuxSendValue(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkRamp__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkRamp__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkRamp__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkRamp__SWIG_1(float jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRamp_fPrev_set")] public static extern void CSharp_AkRamp_fPrev_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRamp_fPrev_get")] public static extern float CSharp_AkRamp_fPrev_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRamp_fNext_set")] public static extern void CSharp_AkRamp_fNext_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRamp_fNext_get")] public static extern float CSharp_AkRamp_fNext_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkRamp")] public static extern void CSharp_delete_AkRamp(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_INT_get")] public static extern ushort CSharp_AK_INT_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_FLOAT_get")] public static extern ushort CSharp_AK_FLOAT_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_INTERLEAVED_get")] public static extern byte CSharp_AK_INTERLEAVED_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_NONINTERLEAVED_get")] public static extern byte CSharp_AK_NONINTERLEAVED_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_LE_NATIVE_BITSPERSAMPLE_get")] public static extern uint CSharp_AK_LE_NATIVE_BITSPERSAMPLE_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_LE_NATIVE_SAMPLETYPE_get")] public static extern uint CSharp_AK_LE_NATIVE_SAMPLETYPE_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_LE_NATIVE_INTERLEAVE_get")] public static extern uint CSharp_AK_LE_NATIVE_INTERLEAVE_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uSampleRate_set")] public static extern void CSharp_AkAudioFormat_uSampleRate_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uSampleRate_get")] public static extern uint CSharp_AkAudioFormat_uSampleRate_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_channelConfig_set")] public static extern void CSharp_AkAudioFormat_channelConfig_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_channelConfig_get")] public static extern global::System.IntPtr CSharp_AkAudioFormat_channelConfig_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uBitsPerSample_set")] public static extern void CSharp_AkAudioFormat_uBitsPerSample_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uBitsPerSample_get")] public static extern uint CSharp_AkAudioFormat_uBitsPerSample_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uBlockAlign_set")] public static extern void CSharp_AkAudioFormat_uBlockAlign_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uBlockAlign_get")] public static extern uint CSharp_AkAudioFormat_uBlockAlign_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uTypeID_set")] public static extern void CSharp_AkAudioFormat_uTypeID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uTypeID_get")] public static extern uint CSharp_AkAudioFormat_uTypeID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uInterleaveID_set")] public static extern void CSharp_AkAudioFormat_uInterleaveID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_uInterleaveID_get")] public static extern uint CSharp_AkAudioFormat_uInterleaveID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_GetNumChannels")] public static extern uint CSharp_AkAudioFormat_GetNumChannels(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_GetBitsPerSample")] public static extern uint CSharp_AkAudioFormat_GetBitsPerSample(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_GetBlockAlign")] public static extern uint CSharp_AkAudioFormat_GetBlockAlign(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_GetTypeID")] public static extern uint CSharp_AkAudioFormat_GetTypeID(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_GetInterleaveID")] public static extern uint CSharp_AkAudioFormat_GetInterleaveID(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_SetAll")] public static extern void CSharp_AkAudioFormat_SetAll(global::System.IntPtr jarg1, uint jarg2, global::System.IntPtr jarg3, uint jarg4, uint jarg5, uint jarg6, uint jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioFormat_IsChannelConfigSupported")] public static extern bool CSharp_AkAudioFormat_IsChannelConfigSupported(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkAudioFormat")] public static extern global::System.IntPtr CSharp_new_AkAudioFormat(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkAudioFormat")] public static extern void CSharp_delete_AkAudioFormat(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_pItem_set")] public static extern void CSharp_AkIterator_pItem_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_pItem_get")] public static extern global::System.IntPtr CSharp_AkIterator_pItem_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_NextIter")] public static extern global::System.IntPtr CSharp_AkIterator_NextIter(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_PrevIter")] public static extern global::System.IntPtr CSharp_AkIterator_PrevIter(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_GetItem")] public static extern global::System.IntPtr CSharp_AkIterator_GetItem(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_IsEqualTo")] public static extern bool CSharp_AkIterator_IsEqualTo(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkIterator_IsDifferentFrom")] public static extern bool CSharp_AkIterator_IsDifferentFrom(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkIterator")] public static extern global::System.IntPtr CSharp_new_AkIterator(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkIterator")] public static extern void CSharp_delete_AkIterator(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkPlaylistItem__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkPlaylistItem__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkPlaylistItem__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkPlaylistItem__SWIG_1(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkPlaylistItem")] public static extern void CSharp_delete_AkPlaylistItem(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_Assign")] public static extern global::System.IntPtr CSharp_AkPlaylistItem_Assign(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_IsEqualTo")] public static extern bool CSharp_AkPlaylistItem_IsEqualTo(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_SetExternalSources")] public static extern int CSharp_AkPlaylistItem_SetExternalSources(global::System.IntPtr jarg1, uint jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_audioNodeID_set")] public static extern void CSharp_AkPlaylistItem_audioNodeID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_audioNodeID_get")] public static extern uint CSharp_AkPlaylistItem_audioNodeID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_msDelay_set")] public static extern void CSharp_AkPlaylistItem_msDelay_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_msDelay_get")] public static extern int CSharp_AkPlaylistItem_msDelay_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_pCustomInfo_set")] public static extern void CSharp_AkPlaylistItem_pCustomInfo_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistItem_pCustomInfo_get")] public static extern global::System.IntPtr CSharp_AkPlaylistItem_pCustomInfo_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkPlaylistArray")] public static extern global::System.IntPtr CSharp_new_AkPlaylistArray(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkPlaylistArray")] public static extern void CSharp_delete_AkPlaylistArray(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Begin")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_Begin(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_End")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_End(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_FindEx")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_FindEx(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Erase__SWIG_0")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_Erase__SWIG_0(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Erase__SWIG_1")] public static extern void CSharp_AkPlaylistArray_Erase__SWIG_1(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_EraseSwap")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_EraseSwap(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_IsGrowingAllowed")] public static extern bool CSharp_AkPlaylistArray_IsGrowingAllowed(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Reserve")] public static extern int CSharp_AkPlaylistArray_Reserve(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Reserved")] public static extern uint CSharp_AkPlaylistArray_Reserved(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Term")] public static extern void CSharp_AkPlaylistArray_Term(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Length")] public static extern uint CSharp_AkPlaylistArray_Length(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Data")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_Data(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_IsEmpty")] public static extern bool CSharp_AkPlaylistArray_IsEmpty(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Exists")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_Exists(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_AddLast__SWIG_0")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_AddLast__SWIG_0(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_AddLast__SWIG_1")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_AddLast__SWIG_1(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Last")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_Last(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_RemoveLast")] public static extern void CSharp_AkPlaylistArray_RemoveLast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Remove")] public static extern int CSharp_AkPlaylistArray_Remove(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_RemoveSwap")] public static extern int CSharp_AkPlaylistArray_RemoveSwap(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_RemoveAll")] public static extern void CSharp_AkPlaylistArray_RemoveAll(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_ItemAtIndex")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_ItemAtIndex(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Insert")] public static extern global::System.IntPtr CSharp_AkPlaylistArray_Insert(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_GrowArray__SWIG_0")] public static extern bool CSharp_AkPlaylistArray_GrowArray__SWIG_0(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_GrowArray__SWIG_1")] public static extern bool CSharp_AkPlaylistArray_GrowArray__SWIG_1(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Resize")] public static extern bool CSharp_AkPlaylistArray_Resize(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Transfer")] public static extern void CSharp_AkPlaylistArray_Transfer(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylistArray_Copy")] public static extern int CSharp_AkPlaylistArray_Copy(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylist_Enqueue__SWIG_0")] public static extern int CSharp_AkPlaylist_Enqueue__SWIG_0(global::System.IntPtr jarg1, uint jarg2, int jarg3, global::System.IntPtr jarg4, uint jarg5, global::System.IntPtr jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylist_Enqueue__SWIG_1")] public static extern int CSharp_AkPlaylist_Enqueue__SWIG_1(global::System.IntPtr jarg1, uint jarg2, int jarg3, global::System.IntPtr jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylist_Enqueue__SWIG_2")] public static extern int CSharp_AkPlaylist_Enqueue__SWIG_2(global::System.IntPtr jarg1, uint jarg2, int jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylist_Enqueue__SWIG_3")] public static extern int CSharp_AkPlaylist_Enqueue__SWIG_3(global::System.IntPtr jarg1, uint jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylist_Enqueue__SWIG_4")] public static extern int CSharp_AkPlaylist_Enqueue__SWIG_4(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkPlaylist")] public static extern global::System.IntPtr CSharp_new_AkPlaylist(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkPlaylist")] public static extern void CSharp_delete_AkPlaylist(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceOpen__SWIG_0")] public static extern uint CSharp_DynamicSequenceOpen__SWIG_0(ulong jarg1, uint jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceOpen__SWIG_1")] public static extern uint CSharp_DynamicSequenceOpen__SWIG_1(ulong jarg1, uint jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceOpen__SWIG_2")] public static extern uint CSharp_DynamicSequenceOpen__SWIG_2(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceClose")] public static extern int CSharp_DynamicSequenceClose(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequencePlay__SWIG_0")] public static extern int CSharp_DynamicSequencePlay__SWIG_0(uint jarg1, int jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequencePlay__SWIG_1")] public static extern int CSharp_DynamicSequencePlay__SWIG_1(uint jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequencePlay__SWIG_2")] public static extern int CSharp_DynamicSequencePlay__SWIG_2(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequencePause__SWIG_0")] public static extern int CSharp_DynamicSequencePause__SWIG_0(uint jarg1, int jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequencePause__SWIG_1")] public static extern int CSharp_DynamicSequencePause__SWIG_1(uint jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequencePause__SWIG_2")] public static extern int CSharp_DynamicSequencePause__SWIG_2(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceResume__SWIG_0")] public static extern int CSharp_DynamicSequenceResume__SWIG_0(uint jarg1, int jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceResume__SWIG_1")] public static extern int CSharp_DynamicSequenceResume__SWIG_1(uint jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceResume__SWIG_2")] public static extern int CSharp_DynamicSequenceResume__SWIG_2(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceStop__SWIG_0")] public static extern int CSharp_DynamicSequenceStop__SWIG_0(uint jarg1, int jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceStop__SWIG_1")] public static extern int CSharp_DynamicSequenceStop__SWIG_1(uint jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceStop__SWIG_2")] public static extern int CSharp_DynamicSequenceStop__SWIG_2(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceBreak")] public static extern int CSharp_DynamicSequenceBreak(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_Seek__SWIG_0")] public static extern int CSharp_Seek__SWIG_0(uint jarg1, int jarg2, bool jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_Seek__SWIG_1")] public static extern int CSharp_Seek__SWIG_1(uint jarg1, float jarg2, bool jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceGetPauseTimes")] public static extern int CSharp_DynamicSequenceGetPauseTimes(uint jarg1, out uint jarg2, out uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceLockPlaylist")] public static extern global::System.IntPtr CSharp_DynamicSequenceLockPlaylist(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_DynamicSequenceUnlockPlaylist")] public static extern int CSharp_DynamicSequenceUnlockPlaylist(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkOutputSettings__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkOutputSettings__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkOutputSettings__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkOutputSettings__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2, global::System.IntPtr jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkOutputSettings__SWIG_2")] public static extern global::System.IntPtr CSharp_new_AkOutputSettings__SWIG_2([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkOutputSettings__SWIG_3")] public static extern global::System.IntPtr CSharp_new_AkOutputSettings__SWIG_3([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkOutputSettings__SWIG_4")] public static extern global::System.IntPtr CSharp_new_AkOutputSettings__SWIG_4([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_audioDeviceShareset_set")] public static extern void CSharp_AkOutputSettings_audioDeviceShareset_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_audioDeviceShareset_get")] public static extern uint CSharp_AkOutputSettings_audioDeviceShareset_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_idDevice_set")] public static extern void CSharp_AkOutputSettings_idDevice_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_idDevice_get")] public static extern uint CSharp_AkOutputSettings_idDevice_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_ePanningRule_set")] public static extern void CSharp_AkOutputSettings_ePanningRule_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_ePanningRule_get")] public static extern int CSharp_AkOutputSettings_ePanningRule_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_channelConfig_set")] public static extern void CSharp_AkOutputSettings_channelConfig_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkOutputSettings_channelConfig_get")] public static extern global::System.IntPtr CSharp_AkOutputSettings_channelConfig_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkOutputSettings")] public static extern void CSharp_delete_AkOutputSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTaskContext_uIdxThread_set")] public static extern void CSharp_AkTaskContext_uIdxThread_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTaskContext_uIdxThread_get")] public static extern uint CSharp_AkTaskContext_uIdxThread_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkTaskContext")] public static extern global::System.IntPtr CSharp_new_AkTaskContext(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkTaskContext")] public static extern void CSharp_delete_AkTaskContext(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uMaxNumPaths_set")] public static extern void CSharp_AkInitSettings_uMaxNumPaths_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uMaxNumPaths_get")] public static extern uint CSharp_AkInitSettings_uMaxNumPaths_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uCommandQueueSize_set")] public static extern void CSharp_AkInitSettings_uCommandQueueSize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uCommandQueueSize_get")] public static extern uint CSharp_AkInitSettings_uCommandQueueSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bEnableGameSyncPreparation_set")] public static extern void CSharp_AkInitSettings_bEnableGameSyncPreparation_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bEnableGameSyncPreparation_get")] public static extern bool CSharp_AkInitSettings_bEnableGameSyncPreparation_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uContinuousPlaybackLookAhead_set")] public static extern void CSharp_AkInitSettings_uContinuousPlaybackLookAhead_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uContinuousPlaybackLookAhead_get")] public static extern uint CSharp_AkInitSettings_uContinuousPlaybackLookAhead_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uNumSamplesPerFrame_set")] public static extern void CSharp_AkInitSettings_uNumSamplesPerFrame_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uNumSamplesPerFrame_get")] public static extern uint CSharp_AkInitSettings_uNumSamplesPerFrame_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uMonitorQueuePoolSize_set")] public static extern void CSharp_AkInitSettings_uMonitorQueuePoolSize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uMonitorQueuePoolSize_get")] public static extern uint CSharp_AkInitSettings_uMonitorQueuePoolSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_settingsMainOutput_set")] public static extern void CSharp_AkInitSettings_settingsMainOutput_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_settingsMainOutput_get")] public static extern global::System.IntPtr CSharp_AkInitSettings_settingsMainOutput_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uMaxHardwareTimeoutMs_set")] public static extern void CSharp_AkInitSettings_uMaxHardwareTimeoutMs_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uMaxHardwareTimeoutMs_get")] public static extern uint CSharp_AkInitSettings_uMaxHardwareTimeoutMs_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bUseSoundBankMgrThread_set")] public static extern void CSharp_AkInitSettings_bUseSoundBankMgrThread_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bUseSoundBankMgrThread_get")] public static extern bool CSharp_AkInitSettings_bUseSoundBankMgrThread_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bUseLEngineThread_set")] public static extern void CSharp_AkInitSettings_bUseLEngineThread_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bUseLEngineThread_get")] public static extern bool CSharp_AkInitSettings_bUseLEngineThread_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_szPluginDLLPath_set")] public static extern void CSharp_AkInitSettings_szPluginDLLPath_set(global::System.IntPtr jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_szPluginDLLPath_get")] public static extern global::System.IntPtr CSharp_AkInitSettings_szPluginDLLPath_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_eFloorPlane_set")] public static extern void CSharp_AkInitSettings_eFloorPlane_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_eFloorPlane_get")] public static extern int CSharp_AkInitSettings_eFloorPlane_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uBankReadBufferSize_set")] public static extern void CSharp_AkInitSettings_uBankReadBufferSize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_uBankReadBufferSize_get")] public static extern uint CSharp_AkInitSettings_uBankReadBufferSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_fDebugOutOfRangeLimit_set")] public static extern void CSharp_AkInitSettings_fDebugOutOfRangeLimit_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_fDebugOutOfRangeLimit_get")] public static extern float CSharp_AkInitSettings_fDebugOutOfRangeLimit_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bDebugOutOfRangeCheckEnabled_set")] public static extern void CSharp_AkInitSettings_bDebugOutOfRangeCheckEnabled_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitSettings_bDebugOutOfRangeCheckEnabled_get")] public static extern bool CSharp_AkInitSettings_bDebugOutOfRangeCheckEnabled_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkInitSettings")] public static extern void CSharp_delete_AkInitSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_sourceID_set")] public static extern void CSharp_AkSourceSettings_sourceID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_sourceID_get")] public static extern uint CSharp_AkSourceSettings_sourceID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_pMediaMemory_set")] public static extern void CSharp_AkSourceSettings_pMediaMemory_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_pMediaMemory_get")] public static extern global::System.IntPtr CSharp_AkSourceSettings_pMediaMemory_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_uMediaSize_set")] public static extern void CSharp_AkSourceSettings_uMediaSize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_uMediaSize_get")] public static extern uint CSharp_AkSourceSettings_uMediaSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_Clear")] public static extern void CSharp_AkSourceSettings_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_GetSizeOf")] public static extern int CSharp_AkSourceSettings_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSourceSettings_Clone")] public static extern void CSharp_AkSourceSettings_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkSourceSettings")] public static extern global::System.IntPtr CSharp_new_AkSourceSettings(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkSourceSettings")] public static extern void CSharp_delete_AkSourceSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_IsInitialized")] public static extern bool CSharp_IsInitialized(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetAudioSettings")] public static extern int CSharp_GetAudioSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSpeakerConfiguration__SWIG_0")] public static extern global::System.IntPtr CSharp_GetSpeakerConfiguration__SWIG_0(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSpeakerConfiguration__SWIG_1")] public static extern global::System.IntPtr CSharp_GetSpeakerConfiguration__SWIG_1(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPanningRule__SWIG_0")] public static extern int CSharp_GetPanningRule__SWIG_0(out int jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPanningRule__SWIG_1")] public static extern int CSharp_GetPanningRule__SWIG_1(out int jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetPanningRule__SWIG_0")] public static extern int CSharp_SetPanningRule__SWIG_0(int jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetPanningRule__SWIG_1")] public static extern int CSharp_SetPanningRule__SWIG_1(int jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSpeakerAngles__SWIG_0")] public static extern int CSharp_GetSpeakerAngles__SWIG_0([global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]float[] jarg1, ref uint jarg2, out float jarg3, ulong jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSpeakerAngles__SWIG_1")] public static extern int CSharp_GetSpeakerAngles__SWIG_1([global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]float[] jarg1, ref uint jarg2, out float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetSpeakerAngles__SWIG_0")] public static extern int CSharp_SetSpeakerAngles__SWIG_0([global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]float[] jarg1, uint jarg2, float jarg3, ulong jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetSpeakerAngles__SWIG_1")] public static extern int CSharp_SetSpeakerAngles__SWIG_1([global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]float[] jarg1, uint jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetVolumeThreshold")] public static extern int CSharp_SetVolumeThreshold(float jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMaxNumVoicesLimit")] public static extern int CSharp_SetMaxNumVoicesLimit(ushort jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RenderAudio__SWIG_0")] public static extern int CSharp_RenderAudio__SWIG_0(bool jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RenderAudio__SWIG_1")] public static extern int CSharp_RenderAudio__SWIG_1(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RegisterPluginDLL__SWIG_0")] public static extern int CSharp_RegisterPluginDLL__SWIG_0([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RegisterPluginDLL__SWIG_1")] public static extern int CSharp_RegisterPluginDLL__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetIDFromString")] public static extern uint CSharp_GetIDFromString([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_0")] public static extern uint CSharp_PostEvent__SWIG_0(uint jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7, uint jarg8); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_1")] public static extern uint CSharp_PostEvent__SWIG_1(uint jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_2")] public static extern uint CSharp_PostEvent__SWIG_2(uint jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_3")] public static extern uint CSharp_PostEvent__SWIG_3(uint jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_4")] public static extern uint CSharp_PostEvent__SWIG_4([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7, uint jarg8); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_5")] public static extern uint CSharp_PostEvent__SWIG_5([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_6")] public static extern uint CSharp_PostEvent__SWIG_6([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEvent__SWIG_7")] public static extern uint CSharp_PostEvent__SWIG_7([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_0")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_0(uint jarg1, int jarg2, ulong jarg3, int jarg4, int jarg5, uint jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_1")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_1(uint jarg1, int jarg2, ulong jarg3, int jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_2")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_2(uint jarg1, int jarg2, ulong jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_3")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_3(uint jarg1, int jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_4")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_4(uint jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_5")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_5([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, ulong jarg3, int jarg4, int jarg5, uint jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_6")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_6([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, ulong jarg3, int jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_7")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_7([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, ulong jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_8")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_8([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnEvent__SWIG_9")] public static extern int CSharp_ExecuteActionOnEvent__SWIG_9([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostMIDIOnEvent")] public static extern int CSharp_PostMIDIOnEvent(uint jarg1, ulong jarg2, global::System.IntPtr jarg3, ushort jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopMIDIOnEvent__SWIG_0")] public static extern int CSharp_StopMIDIOnEvent__SWIG_0(uint jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopMIDIOnEvent__SWIG_1")] public static extern int CSharp_StopMIDIOnEvent__SWIG_1(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopMIDIOnEvent__SWIG_2")] public static extern int CSharp_StopMIDIOnEvent__SWIG_2(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PinEventInStreamCache__SWIG_0")] public static extern int CSharp_PinEventInStreamCache__SWIG_0(uint jarg1, sbyte jarg2, sbyte jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PinEventInStreamCache__SWIG_1")] public static extern int CSharp_PinEventInStreamCache__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, sbyte jarg2, sbyte jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnpinEventInStreamCache__SWIG_0")] public static extern int CSharp_UnpinEventInStreamCache__SWIG_0(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnpinEventInStreamCache__SWIG_1")] public static extern int CSharp_UnpinEventInStreamCache__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetBufferStatusForPinnedEvent__SWIG_0")] public static extern int CSharp_GetBufferStatusForPinnedEvent__SWIG_0(uint jarg1, out float jarg2, out int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetBufferStatusForPinnedEvent__SWIG_1")] public static extern int CSharp_GetBufferStatusForPinnedEvent__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, out float jarg2, out int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_0")] public static extern int CSharp_SeekOnEvent__SWIG_0(uint jarg1, ulong jarg2, int jarg3, bool jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_1")] public static extern int CSharp_SeekOnEvent__SWIG_1(uint jarg1, ulong jarg2, int jarg3, bool jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_2")] public static extern int CSharp_SeekOnEvent__SWIG_2(uint jarg1, ulong jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_3")] public static extern int CSharp_SeekOnEvent__SWIG_3([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, int jarg3, bool jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_4")] public static extern int CSharp_SeekOnEvent__SWIG_4([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, int jarg3, bool jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_5")] public static extern int CSharp_SeekOnEvent__SWIG_5([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_6")] public static extern int CSharp_SeekOnEvent__SWIG_6(uint jarg1, ulong jarg2, float jarg3, bool jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_7")] public static extern int CSharp_SeekOnEvent__SWIG_7(uint jarg1, ulong jarg2, float jarg3, bool jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_8")] public static extern int CSharp_SeekOnEvent__SWIG_8(uint jarg1, ulong jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_9")] public static extern int CSharp_SeekOnEvent__SWIG_9([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, float jarg3, bool jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_10")] public static extern int CSharp_SeekOnEvent__SWIG_10([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, float jarg3, bool jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SeekOnEvent__SWIG_11")] public static extern int CSharp_SeekOnEvent__SWIG_11([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_CancelEventCallbackCookie")] public static extern void CSharp_CancelEventCallbackCookie(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_CancelEventCallbackGameObject")] public static extern void CSharp_CancelEventCallbackGameObject(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_CancelEventCallback")] public static extern void CSharp_CancelEventCallback(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSourcePlayPosition__SWIG_0")] public static extern int CSharp_GetSourcePlayPosition__SWIG_0(uint jarg1, out int jarg2, bool jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSourcePlayPosition__SWIG_1")] public static extern int CSharp_GetSourcePlayPosition__SWIG_1(uint jarg1, out int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSourceStreamBuffering")] public static extern int CSharp_GetSourceStreamBuffering(uint jarg1, out int jarg2, out int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopAll__SWIG_0")] public static extern void CSharp_StopAll__SWIG_0(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopAll__SWIG_1")] public static extern void CSharp_StopAll__SWIG_1(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopPlayingID__SWIG_0")] public static extern void CSharp_StopPlayingID__SWIG_0(uint jarg1, int jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopPlayingID__SWIG_1")] public static extern void CSharp_StopPlayingID__SWIG_1(uint jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopPlayingID__SWIG_2")] public static extern void CSharp_StopPlayingID__SWIG_2(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnPlayingID__SWIG_0")] public static extern void CSharp_ExecuteActionOnPlayingID__SWIG_0(int jarg1, uint jarg2, int jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnPlayingID__SWIG_1")] public static extern void CSharp_ExecuteActionOnPlayingID__SWIG_1(int jarg1, uint jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ExecuteActionOnPlayingID__SWIG_2")] public static extern void CSharp_ExecuteActionOnPlayingID__SWIG_2(int jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRandomSeed")] public static extern void CSharp_SetRandomSeed(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_MuteBackgroundMusic")] public static extern void CSharp_MuteBackgroundMusic(bool jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetBackgroundMusicMute")] public static extern bool CSharp_GetBackgroundMusicMute(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SendPluginCustomGameData")] public static extern int CSharp_SendPluginCustomGameData(uint jarg1, ulong jarg2, int jarg3, uint jarg4, uint jarg5, global::System.IntPtr jarg6, uint jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnregisterAllGameObj")] public static extern int CSharp_UnregisterAllGameObj(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMultiplePositions__SWIG_0")] public static extern int CSharp_SetMultiplePositions__SWIG_0(ulong jarg1, global::System.IntPtr jarg2, ushort jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMultiplePositions__SWIG_1")] public static extern int CSharp_SetMultiplePositions__SWIG_1(ulong jarg1, global::System.IntPtr jarg2, ushort jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMultiplePositions__SWIG_2")] public static extern int CSharp_SetMultiplePositions__SWIG_2(ulong jarg1, global::System.IntPtr jarg2, ushort jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMultiplePositions__SWIG_3")] public static extern int CSharp_SetMultiplePositions__SWIG_3(ulong jarg1, global::System.IntPtr jarg2, ushort jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetScalingFactor")] public static extern int CSharp_SetScalingFactor(ulong jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ClearBanks")] public static extern int CSharp_ClearBanks(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBankLoadIOSettings")] public static extern int CSharp_SetBankLoadIOSettings(float jarg1, sbyte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBank__SWIG_0")] public static extern int CSharp_LoadBank__SWIG_0([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, out uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBank__SWIG_1")] public static extern int CSharp_LoadBank__SWIG_1(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBankMemoryView__SWIG_0")] public static extern int CSharp_LoadBankMemoryView__SWIG_0(global::System.IntPtr jarg1, uint jarg2, out uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBankMemoryCopy__SWIG_0")] public static extern int CSharp_LoadBankMemoryCopy__SWIG_0(global::System.IntPtr jarg1, uint jarg2, out uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBank__SWIG_2")] public static extern int CSharp_LoadBank__SWIG_2([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, global::System.IntPtr jarg2, global::System.IntPtr jarg3, out uint jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBank__SWIG_3")] public static extern int CSharp_LoadBank__SWIG_3(uint jarg1, global::System.IntPtr jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBankMemoryView__SWIG_1")] public static extern int CSharp_LoadBankMemoryView__SWIG_1(global::System.IntPtr jarg1, uint jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4, out uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadBankMemoryCopy__SWIG_1")] public static extern int CSharp_LoadBankMemoryCopy__SWIG_1(global::System.IntPtr jarg1, uint jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4, out uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnloadBank__SWIG_0")] public static extern int CSharp_UnloadBank__SWIG_0([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnloadBank__SWIG_1")] public static extern int CSharp_UnloadBank__SWIG_1(uint jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnloadBank__SWIG_2")] public static extern int CSharp_UnloadBank__SWIG_2([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, global::System.IntPtr jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnloadBank__SWIG_3")] public static extern int CSharp_UnloadBank__SWIG_3(uint jarg1, global::System.IntPtr jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_CancelBankCallbackCookie")] public static extern void CSharp_CancelBankCallbackCookie(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_0")] public static extern int CSharp_PrepareBank__SWIG_0(int jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_1")] public static extern int CSharp_PrepareBank__SWIG_1(int jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_2")] public static extern int CSharp_PrepareBank__SWIG_2(int jarg1, uint jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_3")] public static extern int CSharp_PrepareBank__SWIG_3(int jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_4")] public static extern int CSharp_PrepareBank__SWIG_4(int jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_5")] public static extern int CSharp_PrepareBank__SWIG_5(int jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_6")] public static extern int CSharp_PrepareBank__SWIG_6(int jarg1, uint jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareBank__SWIG_7")] public static extern int CSharp_PrepareBank__SWIG_7(int jarg1, uint jarg2, global::System.IntPtr jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ClearPreparedEvents")] public static extern int CSharp_ClearPreparedEvents(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareEvent__SWIG_0")] public static extern int CSharp_PrepareEvent__SWIG_0(int jarg1, global::System.IntPtr jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareEvent__SWIG_1")] public static extern int CSharp_PrepareEvent__SWIG_1(int jarg1, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareEvent__SWIG_2")] public static extern int CSharp_PrepareEvent__SWIG_2(int jarg1, global::System.IntPtr jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareEvent__SWIG_3")] public static extern int CSharp_PrepareEvent__SWIG_3(int jarg1, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMedia")] public static extern int CSharp_SetMedia(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnsetMedia")] public static extern int CSharp_UnsetMedia(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareGameSyncs__SWIG_0")] public static extern int CSharp_PrepareGameSyncs__SWIG_0(int jarg1, int jarg2, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg3, global::System.IntPtr jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareGameSyncs__SWIG_1")] public static extern int CSharp_PrepareGameSyncs__SWIG_1(int jarg1, int jarg2, uint jarg3, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareGameSyncs__SWIG_2")] public static extern int CSharp_PrepareGameSyncs__SWIG_2(int jarg1, int jarg2, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg3, global::System.IntPtr jarg4, uint jarg5, global::System.IntPtr jarg6, global::System.IntPtr jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PrepareGameSyncs__SWIG_3")] public static extern int CSharp_PrepareGameSyncs__SWIG_3(int jarg1, int jarg2, uint jarg3, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg4, uint jarg5, global::System.IntPtr jarg6, global::System.IntPtr jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddListener")] public static extern int CSharp_AddListener(ulong jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemoveListener")] public static extern int CSharp_RemoveListener(ulong jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddDefaultListener")] public static extern int CSharp_AddDefaultListener(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemoveDefaultListener")] public static extern int CSharp_RemoveDefaultListener(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetListenersToDefault")] public static extern int CSharp_ResetListenersToDefault(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetListenerSpatialization__SWIG_0")] public static extern int CSharp_SetListenerSpatialization__SWIG_0(ulong jarg1, bool jarg2, global::System.IntPtr jarg3, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]float[] jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetListenerSpatialization__SWIG_1")] public static extern int CSharp_SetListenerSpatialization__SWIG_1(ulong jarg1, bool jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_0")] public static extern int CSharp_SetRTPCValue__SWIG_0(uint jarg1, float jarg2, ulong jarg3, int jarg4, int jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_1")] public static extern int CSharp_SetRTPCValue__SWIG_1(uint jarg1, float jarg2, ulong jarg3, int jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_2")] public static extern int CSharp_SetRTPCValue__SWIG_2(uint jarg1, float jarg2, ulong jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_3")] public static extern int CSharp_SetRTPCValue__SWIG_3(uint jarg1, float jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_4")] public static extern int CSharp_SetRTPCValue__SWIG_4(uint jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_5")] public static extern int CSharp_SetRTPCValue__SWIG_5([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, ulong jarg3, int jarg4, int jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_6")] public static extern int CSharp_SetRTPCValue__SWIG_6([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, ulong jarg3, int jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_7")] public static extern int CSharp_SetRTPCValue__SWIG_7([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, ulong jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_8")] public static extern int CSharp_SetRTPCValue__SWIG_8([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValue__SWIG_9")] public static extern int CSharp_SetRTPCValue__SWIG_9([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_0")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_0(uint jarg1, float jarg2, uint jarg3, int jarg4, int jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_1")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_1(uint jarg1, float jarg2, uint jarg3, int jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_2")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_2(uint jarg1, float jarg2, uint jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_3")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_3(uint jarg1, float jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_4")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_4([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, uint jarg3, int jarg4, int jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_5")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_5([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, uint jarg3, int jarg4, int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_6")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_6([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, uint jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRTPCValueByPlayingID__SWIG_7")] public static extern int CSharp_SetRTPCValueByPlayingID__SWIG_7([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, float jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_0")] public static extern int CSharp_ResetRTPCValue__SWIG_0(uint jarg1, ulong jarg2, int jarg3, int jarg4, bool jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_1")] public static extern int CSharp_ResetRTPCValue__SWIG_1(uint jarg1, ulong jarg2, int jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_2")] public static extern int CSharp_ResetRTPCValue__SWIG_2(uint jarg1, ulong jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_3")] public static extern int CSharp_ResetRTPCValue__SWIG_3(uint jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_4")] public static extern int CSharp_ResetRTPCValue__SWIG_4(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_5")] public static extern int CSharp_ResetRTPCValue__SWIG_5([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, int jarg3, int jarg4, bool jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_6")] public static extern int CSharp_ResetRTPCValue__SWIG_6([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, int jarg3, int jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_7")] public static extern int CSharp_ResetRTPCValue__SWIG_7([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_8")] public static extern int CSharp_ResetRTPCValue__SWIG_8([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResetRTPCValue__SWIG_9")] public static extern int CSharp_ResetRTPCValue__SWIG_9([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetSwitch__SWIG_0")] public static extern int CSharp_SetSwitch__SWIG_0(uint jarg1, uint jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetSwitch__SWIG_1")] public static extern int CSharp_SetSwitch__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostTrigger__SWIG_0")] public static extern int CSharp_PostTrigger__SWIG_0(uint jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostTrigger__SWIG_1")] public static extern int CSharp_PostTrigger__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetState__SWIG_0")] public static extern int CSharp_SetState__SWIG_0(uint jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetState__SWIG_1")] public static extern int CSharp_SetState__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetGameObjectAuxSendValues")] public static extern int CSharp_SetGameObjectAuxSendValues(ulong jarg1, global::System.IntPtr jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetGameObjectOutputBusVolume")] public static extern int CSharp_SetGameObjectOutputBusVolume(ulong jarg1, ulong jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetActorMixerEffect")] public static extern int CSharp_SetActorMixerEffect(uint jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBusEffect__SWIG_0")] public static extern int CSharp_SetBusEffect__SWIG_0(uint jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBusEffect__SWIG_1")] public static extern int CSharp_SetBusEffect__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMixer__SWIG_0")] public static extern int CSharp_SetMixer__SWIG_0(uint jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMixer__SWIG_1")] public static extern int CSharp_SetMixer__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBusConfig__SWIG_0")] public static extern int CSharp_SetBusConfig__SWIG_0(uint jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBusConfig__SWIG_1")] public static extern int CSharp_SetBusConfig__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetObjectObstructionAndOcclusion")] public static extern int CSharp_SetObjectObstructionAndOcclusion(ulong jarg1, ulong jarg2, float jarg3, float jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetMultipleObstructionAndOcclusion")] public static extern int CSharp_SetMultipleObstructionAndOcclusion(ulong jarg1, ulong jarg2, global::System.IntPtr jarg3, uint jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StartOutputCapture")] public static extern int CSharp_StartOutputCapture([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopOutputCapture")] public static extern int CSharp_StopOutputCapture(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddOutputCaptureMarker")] public static extern int CSharp_AddOutputCaptureMarker([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StartProfilerCapture")] public static extern int CSharp_StartProfilerCapture([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopProfilerCapture")] public static extern int CSharp_StopProfilerCapture(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemoveOutput")] public static extern int CSharp_RemoveOutput(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ReplaceOutput__SWIG_0")] public static extern int CSharp_ReplaceOutput__SWIG_0(global::System.IntPtr jarg1, ulong jarg2, out ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ReplaceOutput__SWIG_1")] public static extern int CSharp_ReplaceOutput__SWIG_1(global::System.IntPtr jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetOutputID__SWIG_0")] public static extern ulong CSharp_GetOutputID__SWIG_0(uint jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetOutputID__SWIG_1")] public static extern ulong CSharp_GetOutputID__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBusDevice__SWIG_0")] public static extern int CSharp_SetBusDevice__SWIG_0(uint jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBusDevice__SWIG_1")] public static extern int CSharp_SetBusDevice__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDeviceList__SWIG_0")] public static extern int CSharp_GetDeviceList__SWIG_0(uint jarg1, uint jarg2, out uint jarg3, global::System.IntPtr jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDeviceList__SWIG_1")] public static extern int CSharp_GetDeviceList__SWIG_1(uint jarg1, out uint jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetOutputVolume")] public static extern int CSharp_SetOutputVolume(ulong jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDeviceSpatialAudioSupport")] public static extern int CSharp_GetDeviceSpatialAudioSupport(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_Suspend__SWIG_0")] public static extern int CSharp_Suspend__SWIG_0(bool jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_Suspend__SWIG_1")] public static extern int CSharp_Suspend__SWIG_1(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_WakeupFromSuspend")] public static extern int CSharp_WakeupFromSuspend(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetBufferTick")] public static extern uint CSharp_GetBufferTick(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iCurrentPosition_set")] public static extern void CSharp_AkSegmentInfo_iCurrentPosition_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iCurrentPosition_get")] public static extern int CSharp_AkSegmentInfo_iCurrentPosition_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iPreEntryDuration_set")] public static extern void CSharp_AkSegmentInfo_iPreEntryDuration_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iPreEntryDuration_get")] public static extern int CSharp_AkSegmentInfo_iPreEntryDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iActiveDuration_set")] public static extern void CSharp_AkSegmentInfo_iActiveDuration_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iActiveDuration_get")] public static extern int CSharp_AkSegmentInfo_iActiveDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iPostExitDuration_set")] public static extern void CSharp_AkSegmentInfo_iPostExitDuration_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iPostExitDuration_get")] public static extern int CSharp_AkSegmentInfo_iPostExitDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iRemainingLookAheadTime_set")] public static extern void CSharp_AkSegmentInfo_iRemainingLookAheadTime_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_iRemainingLookAheadTime_get")] public static extern int CSharp_AkSegmentInfo_iRemainingLookAheadTime_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fBeatDuration_set")] public static extern void CSharp_AkSegmentInfo_fBeatDuration_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fBeatDuration_get")] public static extern float CSharp_AkSegmentInfo_fBeatDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fBarDuration_set")] public static extern void CSharp_AkSegmentInfo_fBarDuration_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fBarDuration_get")] public static extern float CSharp_AkSegmentInfo_fBarDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fGridDuration_set")] public static extern void CSharp_AkSegmentInfo_fGridDuration_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fGridDuration_get")] public static extern float CSharp_AkSegmentInfo_fGridDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fGridOffset_set")] public static extern void CSharp_AkSegmentInfo_fGridOffset_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSegmentInfo_fGridOffset_get")] public static extern float CSharp_AkSegmentInfo_fGridOffset_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkSegmentInfo")] public static extern global::System.IntPtr CSharp_new_AkSegmentInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkSegmentInfo")] public static extern void CSharp_delete_AkSegmentInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_totalCPU_set")] public static extern void CSharp_AkResourceMonitorDataSummary_totalCPU_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_totalCPU_get")] public static extern float CSharp_AkResourceMonitorDataSummary_totalCPU_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_pluginCPU_set")] public static extern void CSharp_AkResourceMonitorDataSummary_pluginCPU_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_pluginCPU_get")] public static extern float CSharp_AkResourceMonitorDataSummary_pluginCPU_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_physicalVoices_set")] public static extern void CSharp_AkResourceMonitorDataSummary_physicalVoices_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_physicalVoices_get")] public static extern uint CSharp_AkResourceMonitorDataSummary_physicalVoices_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_virtualVoices_set")] public static extern void CSharp_AkResourceMonitorDataSummary_virtualVoices_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_virtualVoices_get")] public static extern uint CSharp_AkResourceMonitorDataSummary_virtualVoices_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_totalVoices_set")] public static extern void CSharp_AkResourceMonitorDataSummary_totalVoices_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_totalVoices_get")] public static extern uint CSharp_AkResourceMonitorDataSummary_totalVoices_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_nbActiveEvents_set")] public static extern void CSharp_AkResourceMonitorDataSummary_nbActiveEvents_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkResourceMonitorDataSummary_nbActiveEvents_get")] public static extern uint CSharp_AkResourceMonitorDataSummary_nbActiveEvents_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkResourceMonitorDataSummary")] public static extern global::System.IntPtr CSharp_new_AkResourceMonitorDataSummary(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkResourceMonitorDataSummary")] public static extern void CSharp_delete_AkResourceMonitorDataSummary(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_INVALID_MIDI_CHANNEL_get")] public static extern byte CSharp_AK_INVALID_MIDI_CHANNEL_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_INVALID_MIDI_NOTE_get")] public static extern byte CSharp_AK_INVALID_MIDI_NOTE_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byChan_set")] public static extern void CSharp_AkMIDIEvent_byChan_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byChan_get")] public static extern byte CSharp_AkMIDIEvent_byChan_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tGen_byParam1_set")] public static extern void CSharp_AkMIDIEvent_tGen_byParam1_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tGen_byParam1_get")] public static extern byte CSharp_AkMIDIEvent_tGen_byParam1_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tGen_byParam2_set")] public static extern void CSharp_AkMIDIEvent_tGen_byParam2_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tGen_byParam2_get")] public static extern byte CSharp_AkMIDIEvent_tGen_byParam2_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tGen")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tGen(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tGen")] public static extern void CSharp_delete_AkMIDIEvent_tGen(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteOnOff_byNote_set")] public static extern void CSharp_AkMIDIEvent_tNoteOnOff_byNote_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteOnOff_byNote_get")] public static extern byte CSharp_AkMIDIEvent_tNoteOnOff_byNote_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteOnOff_byVelocity_set")] public static extern void CSharp_AkMIDIEvent_tNoteOnOff_byVelocity_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteOnOff_byVelocity_get")] public static extern byte CSharp_AkMIDIEvent_tNoteOnOff_byVelocity_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tNoteOnOff")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tNoteOnOff(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tNoteOnOff")] public static extern void CSharp_delete_AkMIDIEvent_tNoteOnOff(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tCc_byCc_set")] public static extern void CSharp_AkMIDIEvent_tCc_byCc_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tCc_byCc_get")] public static extern byte CSharp_AkMIDIEvent_tCc_byCc_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tCc_byValue_set")] public static extern void CSharp_AkMIDIEvent_tCc_byValue_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tCc_byValue_get")] public static extern byte CSharp_AkMIDIEvent_tCc_byValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tCc")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tCc(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tCc")] public static extern void CSharp_delete_AkMIDIEvent_tCc(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tPitchBend_byValueLsb_set")] public static extern void CSharp_AkMIDIEvent_tPitchBend_byValueLsb_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tPitchBend_byValueLsb_get")] public static extern byte CSharp_AkMIDIEvent_tPitchBend_byValueLsb_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tPitchBend_byValueMsb_set")] public static extern void CSharp_AkMIDIEvent_tPitchBend_byValueMsb_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tPitchBend_byValueMsb_get")] public static extern byte CSharp_AkMIDIEvent_tPitchBend_byValueMsb_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tPitchBend")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tPitchBend(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tPitchBend")] public static extern void CSharp_delete_AkMIDIEvent_tPitchBend(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteAftertouch_byNote_set")] public static extern void CSharp_AkMIDIEvent_tNoteAftertouch_byNote_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteAftertouch_byNote_get")] public static extern byte CSharp_AkMIDIEvent_tNoteAftertouch_byNote_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteAftertouch_byValue_set")] public static extern void CSharp_AkMIDIEvent_tNoteAftertouch_byValue_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tNoteAftertouch_byValue_get")] public static extern byte CSharp_AkMIDIEvent_tNoteAftertouch_byValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tNoteAftertouch")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tNoteAftertouch(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tNoteAftertouch")] public static extern void CSharp_delete_AkMIDIEvent_tNoteAftertouch(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tChanAftertouch_byValue_set")] public static extern void CSharp_AkMIDIEvent_tChanAftertouch_byValue_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tChanAftertouch_byValue_get")] public static extern byte CSharp_AkMIDIEvent_tChanAftertouch_byValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tChanAftertouch")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tChanAftertouch(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tChanAftertouch")] public static extern void CSharp_delete_AkMIDIEvent_tChanAftertouch(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tProgramChange_byProgramNum_set")] public static extern void CSharp_AkMIDIEvent_tProgramChange_byProgramNum_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_tProgramChange_byProgramNum_get")] public static extern byte CSharp_AkMIDIEvent_tProgramChange_byProgramNum_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent_tProgramChange")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent_tProgramChange(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent_tProgramChange")] public static extern void CSharp_delete_AkMIDIEvent_tProgramChange(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_Gen_set")] public static extern void CSharp_AkMIDIEvent_Gen_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_Gen_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_Gen_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_Cc_set")] public static extern void CSharp_AkMIDIEvent_Cc_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_Cc_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_Cc_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_NoteOnOff_set")] public static extern void CSharp_AkMIDIEvent_NoteOnOff_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_NoteOnOff_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_NoteOnOff_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_PitchBend_set")] public static extern void CSharp_AkMIDIEvent_PitchBend_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_PitchBend_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_PitchBend_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_NoteAftertouch_set")] public static extern void CSharp_AkMIDIEvent_NoteAftertouch_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_NoteAftertouch_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_NoteAftertouch_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_ChanAftertouch_set")] public static extern void CSharp_AkMIDIEvent_ChanAftertouch_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_ChanAftertouch_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_ChanAftertouch_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_ProgramChange_set")] public static extern void CSharp_AkMIDIEvent_ProgramChange_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_ProgramChange_get")] public static extern global::System.IntPtr CSharp_AkMIDIEvent_ProgramChange_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byType_set")] public static extern void CSharp_AkMIDIEvent_byType_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byType_get")] public static extern int CSharp_AkMIDIEvent_byType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byOnOffNote_set")] public static extern void CSharp_AkMIDIEvent_byOnOffNote_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byOnOffNote_get")] public static extern byte CSharp_AkMIDIEvent_byOnOffNote_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byVelocity_set")] public static extern void CSharp_AkMIDIEvent_byVelocity_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byVelocity_get")] public static extern byte CSharp_AkMIDIEvent_byVelocity_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byCc_set")] public static extern void CSharp_AkMIDIEvent_byCc_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byCc_get")] public static extern int CSharp_AkMIDIEvent_byCc_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byCcValue_set")] public static extern void CSharp_AkMIDIEvent_byCcValue_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byCcValue_get")] public static extern byte CSharp_AkMIDIEvent_byCcValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byValueLsb_set")] public static extern void CSharp_AkMIDIEvent_byValueLsb_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byValueLsb_get")] public static extern byte CSharp_AkMIDIEvent_byValueLsb_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byValueMsb_set")] public static extern void CSharp_AkMIDIEvent_byValueMsb_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byValueMsb_get")] public static extern byte CSharp_AkMIDIEvent_byValueMsb_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byAftertouchNote_set")] public static extern void CSharp_AkMIDIEvent_byAftertouchNote_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byAftertouchNote_get")] public static extern byte CSharp_AkMIDIEvent_byAftertouchNote_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byNoteAftertouchValue_set")] public static extern void CSharp_AkMIDIEvent_byNoteAftertouchValue_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byNoteAftertouchValue_get")] public static extern byte CSharp_AkMIDIEvent_byNoteAftertouchValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byChanAftertouchValue_set")] public static extern void CSharp_AkMIDIEvent_byChanAftertouchValue_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byChanAftertouchValue_get")] public static extern byte CSharp_AkMIDIEvent_byChanAftertouchValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byProgramNum_set")] public static extern void CSharp_AkMIDIEvent_byProgramNum_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEvent_byProgramNum_get")] public static extern byte CSharp_AkMIDIEvent_byProgramNum_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEvent")] public static extern global::System.IntPtr CSharp_new_AkMIDIEvent(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEvent")] public static extern void CSharp_delete_AkMIDIEvent(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIPost_uOffset_set")] public static extern void CSharp_AkMIDIPost_uOffset_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIPost_uOffset_get")] public static extern uint CSharp_AkMIDIPost_uOffset_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIPost_PostOnEvent")] public static extern int CSharp_AkMIDIPost_PostOnEvent(global::System.IntPtr jarg1, uint jarg2, ulong jarg3, uint jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIPost_Clone")] public static extern void CSharp_AkMIDIPost_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIPost_GetSizeOf")] public static extern int CSharp_AkMIDIPost_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIPost")] public static extern global::System.IntPtr CSharp_new_AkMIDIPost(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIPost")] public static extern void CSharp_delete_AkMIDIPost(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSettings_fStreamingLookAheadRatio_set")] public static extern void CSharp_AkMusicSettings_fStreamingLookAheadRatio_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSettings_fStreamingLookAheadRatio_get")] public static extern float CSharp_AkMusicSettings_fStreamingLookAheadRatio_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMusicSettings")] public static extern void CSharp_delete_AkMusicSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPlayingSegmentInfo__SWIG_0")] public static extern int CSharp_GetPlayingSegmentInfo__SWIG_0(uint jarg1, global::System.IntPtr jarg2, bool jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPlayingSegmentInfo__SWIG_1")] public static extern int CSharp_GetPlayingSegmentInfo__SWIG_1(uint jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSerializedCallbackHeader_pPackage_get")] public static extern global::System.IntPtr CSharp_AkSerializedCallbackHeader_pPackage_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSerializedCallbackHeader_pNext_get")] public static extern global::System.IntPtr CSharp_AkSerializedCallbackHeader_pNext_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSerializedCallbackHeader_eType_get")] public static extern int CSharp_AkSerializedCallbackHeader_eType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSerializedCallbackHeader_GetData")] public static extern global::System.IntPtr CSharp_AkSerializedCallbackHeader_GetData(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkSerializedCallbackHeader")] public static extern global::System.IntPtr CSharp_new_AkSerializedCallbackHeader(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkSerializedCallbackHeader")] public static extern void CSharp_delete_AkSerializedCallbackHeader(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackInfo_pCookie_get")] public static extern global::System.IntPtr CSharp_AkCallbackInfo_pCookie_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackInfo_gameObjID_get")] public static extern ulong CSharp_AkCallbackInfo_gameObjID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkCallbackInfo")] public static extern void CSharp_delete_AkCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkEventCallbackInfo_playingID_get")] public static extern uint CSharp_AkEventCallbackInfo_playingID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkEventCallbackInfo_eventID_get")] public static extern uint CSharp_AkEventCallbackInfo_eventID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkEventCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkEventCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkEventCallbackInfo")] public static extern void CSharp_delete_AkEventCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byChan_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byChan_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byParam1_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byParam1_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byParam2_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byParam2_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byType_get")] public static extern int CSharp_AkMIDIEventCallbackInfo_byType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byOnOffNote_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byOnOffNote_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byVelocity_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byVelocity_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byCc_get")] public static extern int CSharp_AkMIDIEventCallbackInfo_byCc_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byCcValue_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byCcValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byValueLsb_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byValueLsb_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byValueMsb_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byValueMsb_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byAftertouchNote_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byAftertouchNote_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byNoteAftertouchValue_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byNoteAftertouchValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byChanAftertouchValue_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byChanAftertouchValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_byProgramNum_get")] public static extern byte CSharp_AkMIDIEventCallbackInfo_byProgramNum_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMIDIEventCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkMIDIEventCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMIDIEventCallbackInfo")] public static extern void CSharp_delete_AkMIDIEventCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMarkerCallbackInfo_uIdentifier_get")] public static extern uint CSharp_AkMarkerCallbackInfo_uIdentifier_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMarkerCallbackInfo_uPosition_get")] public static extern uint CSharp_AkMarkerCallbackInfo_uPosition_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMarkerCallbackInfo_strLabel_get")] public static extern global::System.IntPtr CSharp_AkMarkerCallbackInfo_strLabel_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMarkerCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkMarkerCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMarkerCallbackInfo")] public static extern void CSharp_delete_AkMarkerCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDurationCallbackInfo_fDuration_get")] public static extern float CSharp_AkDurationCallbackInfo_fDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDurationCallbackInfo_fEstimatedDuration_get")] public static extern float CSharp_AkDurationCallbackInfo_fEstimatedDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDurationCallbackInfo_audioNodeID_get")] public static extern uint CSharp_AkDurationCallbackInfo_audioNodeID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDurationCallbackInfo_mediaID_get")] public static extern uint CSharp_AkDurationCallbackInfo_mediaID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDurationCallbackInfo_bStreaming_get")] public static extern bool CSharp_AkDurationCallbackInfo_bStreaming_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkDurationCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkDurationCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkDurationCallbackInfo")] public static extern void CSharp_delete_AkDurationCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDynamicSequenceItemCallbackInfo_playingID_get")] public static extern uint CSharp_AkDynamicSequenceItemCallbackInfo_playingID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDynamicSequenceItemCallbackInfo_audioNodeID_get")] public static extern uint CSharp_AkDynamicSequenceItemCallbackInfo_audioNodeID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDynamicSequenceItemCallbackInfo_pCustomInfo_get")] public static extern global::System.IntPtr CSharp_AkDynamicSequenceItemCallbackInfo_pCustomInfo_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkDynamicSequenceItemCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkDynamicSequenceItemCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkDynamicSequenceItemCallbackInfo")] public static extern void CSharp_delete_AkDynamicSequenceItemCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_playingID_get")] public static extern uint CSharp_AkMusicSyncCallbackInfo_playingID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_iCurrentPosition_get")] public static extern int CSharp_AkMusicSyncCallbackInfo_segmentInfo_iCurrentPosition_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_iPreEntryDuration_get")] public static extern int CSharp_AkMusicSyncCallbackInfo_segmentInfo_iPreEntryDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_iActiveDuration_get")] public static extern int CSharp_AkMusicSyncCallbackInfo_segmentInfo_iActiveDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_iPostExitDuration_get")] public static extern int CSharp_AkMusicSyncCallbackInfo_segmentInfo_iPostExitDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_iRemainingLookAheadTime_get")] public static extern int CSharp_AkMusicSyncCallbackInfo_segmentInfo_iRemainingLookAheadTime_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_fBeatDuration_get")] public static extern float CSharp_AkMusicSyncCallbackInfo_segmentInfo_fBeatDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_fBarDuration_get")] public static extern float CSharp_AkMusicSyncCallbackInfo_segmentInfo_fBarDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_fGridDuration_get")] public static extern float CSharp_AkMusicSyncCallbackInfo_segmentInfo_fGridDuration_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_segmentInfo_fGridOffset_get")] public static extern float CSharp_AkMusicSyncCallbackInfo_segmentInfo_fGridOffset_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_musicSyncType_get")] public static extern int CSharp_AkMusicSyncCallbackInfo_musicSyncType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_userCueName_get")] public static extern global::System.IntPtr CSharp_AkMusicSyncCallbackInfo_userCueName_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMusicSyncCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkMusicSyncCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMusicSyncCallbackInfo")] public static extern void CSharp_delete_AkMusicSyncCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicPlaylistCallbackInfo_playlistID_get")] public static extern uint CSharp_AkMusicPlaylistCallbackInfo_playlistID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicPlaylistCallbackInfo_uNumPlaylistItems_get")] public static extern uint CSharp_AkMusicPlaylistCallbackInfo_uNumPlaylistItems_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicPlaylistCallbackInfo_uPlaylistSelection_get")] public static extern uint CSharp_AkMusicPlaylistCallbackInfo_uPlaylistSelection_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicPlaylistCallbackInfo_uPlaylistItemDone_get")] public static extern uint CSharp_AkMusicPlaylistCallbackInfo_uPlaylistItemDone_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMusicPlaylistCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkMusicPlaylistCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMusicPlaylistCallbackInfo")] public static extern void CSharp_delete_AkMusicPlaylistCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkBankCallbackInfo_bankID_get")] public static extern uint CSharp_AkBankCallbackInfo_bankID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkBankCallbackInfo_inMemoryBankPtr_get")] public static extern global::System.IntPtr CSharp_AkBankCallbackInfo_inMemoryBankPtr_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkBankCallbackInfo_loadResult_get")] public static extern int CSharp_AkBankCallbackInfo_loadResult_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkBankCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkBankCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkBankCallbackInfo")] public static extern void CSharp_delete_AkBankCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMonitoringCallbackInfo_errorCode_get")] public static extern int CSharp_AkMonitoringCallbackInfo_errorCode_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMonitoringCallbackInfo_errorLevel_get")] public static extern int CSharp_AkMonitoringCallbackInfo_errorLevel_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMonitoringCallbackInfo_playingID_get")] public static extern uint CSharp_AkMonitoringCallbackInfo_playingID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMonitoringCallbackInfo_gameObjID_get")] public static extern ulong CSharp_AkMonitoringCallbackInfo_gameObjID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMonitoringCallbackInfo_message_get")] public static extern global::System.IntPtr CSharp_AkMonitoringCallbackInfo_message_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkMonitoringCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkMonitoringCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkMonitoringCallbackInfo")] public static extern void CSharp_delete_AkMonitoringCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioInterruptionCallbackInfo_bEnterInterruption_get")] public static extern bool CSharp_AkAudioInterruptionCallbackInfo_bEnterInterruption_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkAudioInterruptionCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkAudioInterruptionCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkAudioInterruptionCallbackInfo")] public static extern void CSharp_delete_AkAudioInterruptionCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAudioSourceChangeCallbackInfo_bOtherAudioPlaying_get")] public static extern bool CSharp_AkAudioSourceChangeCallbackInfo_bOtherAudioPlaying_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkAudioSourceChangeCallbackInfo")] public static extern global::System.IntPtr CSharp_new_AkAudioSourceChangeCallbackInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkAudioSourceChangeCallbackInfo")] public static extern void CSharp_delete_AkAudioSourceChangeCallbackInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LocalOutput")] public static extern void CSharp_LocalOutput(int jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2, int jarg3, uint jarg4, ulong jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackSerializer_Init")] public static extern int CSharp_AkCallbackSerializer_Init(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackSerializer_Term")] public static extern void CSharp_AkCallbackSerializer_Term(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackSerializer_Lock")] public static extern global::System.IntPtr CSharp_AkCallbackSerializer_Lock(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackSerializer_Unlock")] public static extern void CSharp_AkCallbackSerializer_Unlock(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackSerializer_SetLocalOutput")] public static extern void CSharp_AkCallbackSerializer_SetLocalOutput(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCallbackSerializer_AudioSourceChangeCallbackFunc")] public static extern int CSharp_AkCallbackSerializer_AudioSourceChangeCallbackFunc(bool jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkCallbackSerializer")] public static extern global::System.IntPtr CSharp_new_AkCallbackSerializer(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkCallbackSerializer")] public static extern void CSharp_delete_AkCallbackSerializer(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostCode__SWIG_0")] public static extern int CSharp_PostCode__SWIG_0(int jarg1, int jarg2, uint jarg3, ulong jarg4, uint jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostCode__SWIG_1")] public static extern int CSharp_PostCode__SWIG_1(int jarg1, int jarg2, uint jarg3, ulong jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostCode__SWIG_2")] public static extern int CSharp_PostCode__SWIG_2(int jarg1, int jarg2, uint jarg3, ulong jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostCode__SWIG_3")] public static extern int CSharp_PostCode__SWIG_3(int jarg1, int jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostCode__SWIG_4")] public static extern int CSharp_PostCode__SWIG_4(int jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostString__SWIG_0")] public static extern int CSharp_PostString__SWIG_0([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, uint jarg3, ulong jarg4, uint jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostString__SWIG_1")] public static extern int CSharp_PostString__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, uint jarg3, ulong jarg4, uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostString__SWIG_2")] public static extern int CSharp_PostString__SWIG_2([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, uint jarg3, ulong jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostString__SWIG_3")] public static extern int CSharp_PostString__SWIG_3([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostString__SWIG_4")] public static extern int CSharp_PostString__SWIG_4([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetTimeStamp")] public static extern int CSharp_GetTimeStamp(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetNumNonZeroBits")] public static extern uint CSharp_GetNumNonZeroBits(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkGetDefaultHighPriorityThreadProperties")] public static extern void CSharp_AkGetDefaultHighPriorityThreadProperties(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResolveDialogueEvent__SWIG_0")] public static extern uint CSharp_ResolveDialogueEvent__SWIG_0(uint jarg1, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg2, uint jarg3, uint jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ResolveDialogueEvent__SWIG_1")] public static extern uint CSharp_ResolveDialogueEvent__SWIG_1(uint jarg1, [global::System.Runtime.InteropServices.In, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDialogueEventCustomPropertyValue__SWIG_0")] public static extern int CSharp_GetDialogueEventCustomPropertyValue__SWIG_0(uint jarg1, uint jarg2, out int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDialogueEventCustomPropertyValue__SWIG_1")] public static extern int CSharp_GetDialogueEventCustomPropertyValue__SWIG_1(uint jarg1, uint jarg2, out float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fCenterPct_set")] public static extern void CSharp_AkPositioningInfo_fCenterPct_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fCenterPct_get")] public static extern float CSharp_AkPositioningInfo_fCenterPct_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_pannerType_set")] public static extern void CSharp_AkPositioningInfo_pannerType_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_pannerType_get")] public static extern int CSharp_AkPositioningInfo_pannerType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_e3dPositioningType_set")] public static extern void CSharp_AkPositioningInfo_e3dPositioningType_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_e3dPositioningType_get")] public static extern int CSharp_AkPositioningInfo_e3dPositioningType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_bHoldEmitterPosAndOrient_set")] public static extern void CSharp_AkPositioningInfo_bHoldEmitterPosAndOrient_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_bHoldEmitterPosAndOrient_get")] public static extern bool CSharp_AkPositioningInfo_bHoldEmitterPosAndOrient_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_e3DSpatializationMode_set")] public static extern void CSharp_AkPositioningInfo_e3DSpatializationMode_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_e3DSpatializationMode_get")] public static extern int CSharp_AkPositioningInfo_e3DSpatializationMode_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_bEnableAttenuation_set")] public static extern void CSharp_AkPositioningInfo_bEnableAttenuation_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_bEnableAttenuation_get")] public static extern bool CSharp_AkPositioningInfo_bEnableAttenuation_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_bUseConeAttenuation_set")] public static extern void CSharp_AkPositioningInfo_bUseConeAttenuation_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_bUseConeAttenuation_get")] public static extern bool CSharp_AkPositioningInfo_bUseConeAttenuation_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fInnerAngle_set")] public static extern void CSharp_AkPositioningInfo_fInnerAngle_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fInnerAngle_get")] public static extern float CSharp_AkPositioningInfo_fInnerAngle_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fOuterAngle_set")] public static extern void CSharp_AkPositioningInfo_fOuterAngle_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fOuterAngle_get")] public static extern float CSharp_AkPositioningInfo_fOuterAngle_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fConeMaxAttenuation_set")] public static extern void CSharp_AkPositioningInfo_fConeMaxAttenuation_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fConeMaxAttenuation_get")] public static extern float CSharp_AkPositioningInfo_fConeMaxAttenuation_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_LPFCone_set")] public static extern void CSharp_AkPositioningInfo_LPFCone_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_LPFCone_get")] public static extern float CSharp_AkPositioningInfo_LPFCone_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_HPFCone_set")] public static extern void CSharp_AkPositioningInfo_HPFCone_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_HPFCone_get")] public static extern float CSharp_AkPositioningInfo_HPFCone_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fMaxDistance_set")] public static extern void CSharp_AkPositioningInfo_fMaxDistance_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fMaxDistance_get")] public static extern float CSharp_AkPositioningInfo_fMaxDistance_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fVolDryAtMaxDist_set")] public static extern void CSharp_AkPositioningInfo_fVolDryAtMaxDist_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fVolDryAtMaxDist_get")] public static extern float CSharp_AkPositioningInfo_fVolDryAtMaxDist_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fVolAuxGameDefAtMaxDist_set")] public static extern void CSharp_AkPositioningInfo_fVolAuxGameDefAtMaxDist_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fVolAuxGameDefAtMaxDist_get")] public static extern float CSharp_AkPositioningInfo_fVolAuxGameDefAtMaxDist_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fVolAuxUserDefAtMaxDist_set")] public static extern void CSharp_AkPositioningInfo_fVolAuxUserDefAtMaxDist_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_fVolAuxUserDefAtMaxDist_get")] public static extern float CSharp_AkPositioningInfo_fVolAuxUserDefAtMaxDist_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_LPFValueAtMaxDist_set")] public static extern void CSharp_AkPositioningInfo_LPFValueAtMaxDist_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_LPFValueAtMaxDist_get")] public static extern float CSharp_AkPositioningInfo_LPFValueAtMaxDist_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_HPFValueAtMaxDist_set")] public static extern void CSharp_AkPositioningInfo_HPFValueAtMaxDist_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPositioningInfo_HPFValueAtMaxDist_get")] public static extern float CSharp_AkPositioningInfo_HPFValueAtMaxDist_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkPositioningInfo")] public static extern global::System.IntPtr CSharp_new_AkPositioningInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkPositioningInfo")] public static extern void CSharp_delete_AkPositioningInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_objID_set")] public static extern void CSharp_AkObjectInfo_objID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_objID_get")] public static extern uint CSharp_AkObjectInfo_objID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_parentID_set")] public static extern void CSharp_AkObjectInfo_parentID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_parentID_get")] public static extern uint CSharp_AkObjectInfo_parentID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_iDepth_set")] public static extern void CSharp_AkObjectInfo_iDepth_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_iDepth_get")] public static extern int CSharp_AkObjectInfo_iDepth_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_Clear")] public static extern void CSharp_AkObjectInfo_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_GetSizeOf")] public static extern int CSharp_AkObjectInfo_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkObjectInfo_Clone")] public static extern void CSharp_AkObjectInfo_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkObjectInfo")] public static extern global::System.IntPtr CSharp_new_AkObjectInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkObjectInfo")] public static extern void CSharp_delete_AkObjectInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPosition")] public static extern int CSharp_GetPosition(ulong jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetListenerPosition")] public static extern int CSharp_GetListenerPosition(ulong jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetRTPCValue__SWIG_0")] public static extern int CSharp_GetRTPCValue__SWIG_0(uint jarg1, ulong jarg2, uint jarg3, out float jarg4, ref int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetRTPCValue__SWIG_1")] public static extern int CSharp_GetRTPCValue__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, out float jarg4, ref int jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSwitch__SWIG_0")] public static extern int CSharp_GetSwitch__SWIG_0(uint jarg1, ulong jarg2, out uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSwitch__SWIG_1")] public static extern int CSharp_GetSwitch__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, out uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetState__SWIG_0")] public static extern int CSharp_GetState__SWIG_0(uint jarg1, out uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetState__SWIG_1")] public static extern int CSharp_GetState__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, out uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetGameObjectAuxSendValues")] public static extern int CSharp_GetGameObjectAuxSendValues(ulong jarg1, global::System.IntPtr jarg2, ref uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetGameObjectDryLevelValue")] public static extern int CSharp_GetGameObjectDryLevelValue(ulong jarg1, ulong jarg2, out float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetObjectObstructionAndOcclusion")] public static extern int CSharp_GetObjectObstructionAndOcclusion(ulong jarg1, ulong jarg2, out float jarg3, out float jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_QueryAudioObjectIDs__SWIG_0")] public static extern int CSharp_QueryAudioObjectIDs__SWIG_0(uint jarg1, ref uint jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_QueryAudioObjectIDs__SWIG_1")] public static extern int CSharp_QueryAudioObjectIDs__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ref uint jarg2, global::System.IntPtr jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPositioningInfo")] public static extern int CSharp_GetPositioningInfo(uint jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetIsGameObjectActive")] public static extern bool CSharp_GetIsGameObjectActive(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetMaxRadius")] public static extern float CSharp_GetMaxRadius(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetEventIDFromPlayingID")] public static extern uint CSharp_GetEventIDFromPlayingID(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetGameObjectFromPlayingID")] public static extern ulong CSharp_GetGameObjectFromPlayingID(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetPlayingIDsFromGameObject")] public static extern int CSharp_GetPlayingIDsFromGameObject(ulong jarg1, ref uint jarg2, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetCustomPropertyValue__SWIG_0")] public static extern int CSharp_GetCustomPropertyValue__SWIG_0(uint jarg1, uint jarg2, out int jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetCustomPropertyValue__SWIG_1")] public static extern int CSharp_GetCustomPropertyValue__SWIG_1(uint jarg1, uint jarg2, out float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_SPEAKER_SETUP_FIX_LEFT_TO_CENTER")] public static extern void CSharp_AK_SPEAKER_SETUP_FIX_LEFT_TO_CENTER(ref uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_SPEAKER_SETUP_FIX_REAR_TO_SIDE")] public static extern void CSharp_AK_SPEAKER_SETUP_FIX_REAR_TO_SIDE(ref uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AK_SPEAKER_SETUP_CONVERT_TO_SUPPORTED")] public static extern void CSharp_AK_SPEAKER_SETUP_CONVERT_TO_SUPPORTED(ref uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ChannelMaskToNumChannels")] public static extern byte CSharp_ChannelMaskToNumChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ChannelMaskFromNumChannels")] public static extern uint CSharp_ChannelMaskFromNumChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ChannelBitToIndex")] public static extern byte CSharp_ChannelBitToIndex(uint jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_HasSurroundChannels")] public static extern bool CSharp_HasSurroundChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_HasStrictlyOnePairOfSurroundChannels")] public static extern bool CSharp_HasStrictlyOnePairOfSurroundChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_HasSideAndRearChannels")] public static extern bool CSharp_HasSideAndRearChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_HasHeightChannels")] public static extern bool CSharp_HasHeightChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_BackToSideChannels")] public static extern uint CSharp_BackToSideChannels(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StdChannelIndexToDisplayIndex")] public static extern uint CSharp_StdChannelIndexToDisplayIndex(int jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_uNumChannels_set")] public static extern void CSharp_AkChannelConfig_uNumChannels_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_uNumChannels_get")] public static extern uint CSharp_AkChannelConfig_uNumChannels_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_eConfigType_set")] public static extern void CSharp_AkChannelConfig_eConfigType_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_eConfigType_get")] public static extern uint CSharp_AkChannelConfig_eConfigType_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_uChannelMask_set")] public static extern void CSharp_AkChannelConfig_uChannelMask_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_uChannelMask_get")] public static extern uint CSharp_AkChannelConfig_uChannelMask_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkChannelConfig__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkChannelConfig__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkChannelConfig__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkChannelConfig__SWIG_1(uint jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_Clear")] public static extern void CSharp_AkChannelConfig_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_SetStandard")] public static extern void CSharp_AkChannelConfig_SetStandard(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_SetStandardOrAnonymous")] public static extern void CSharp_AkChannelConfig_SetStandardOrAnonymous(global::System.IntPtr jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_SetAnonymous")] public static extern void CSharp_AkChannelConfig_SetAnonymous(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_SetAmbisonic")] public static extern void CSharp_AkChannelConfig_SetAmbisonic(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_IsValid")] public static extern bool CSharp_AkChannelConfig_IsValid(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_Serialize")] public static extern uint CSharp_AkChannelConfig_Serialize(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_Deserialize")] public static extern void CSharp_AkChannelConfig_Deserialize(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_RemoveLFE")] public static extern global::System.IntPtr CSharp_AkChannelConfig_RemoveLFE(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_RemoveCenter")] public static extern global::System.IntPtr CSharp_AkChannelConfig_RemoveCenter(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkChannelConfig_IsChannelConfigSupported")] public static extern bool CSharp_AkChannelConfig_IsChannelConfigSupported(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkChannelConfig")] public static extern void CSharp_delete_AkChannelConfig(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkImageSourceParams__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkImageSourceParams__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkImageSourceParams__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkImageSourceParams__SWIG_1(UnityEngine.Vector3 jarg1, float jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_sourcePosition_set")] public static extern void CSharp_AkImageSourceParams_sourcePosition_set(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_sourcePosition_get")] public static extern UnityEngine.Vector3 CSharp_AkImageSourceParams_sourcePosition_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_fDistanceScalingFactor_set")] public static extern void CSharp_AkImageSourceParams_fDistanceScalingFactor_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_fDistanceScalingFactor_get")] public static extern float CSharp_AkImageSourceParams_fDistanceScalingFactor_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_fLevel_set")] public static extern void CSharp_AkImageSourceParams_fLevel_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_fLevel_get")] public static extern float CSharp_AkImageSourceParams_fLevel_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_fDiffraction_set")] public static extern void CSharp_AkImageSourceParams_fDiffraction_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_fDiffraction_get")] public static extern float CSharp_AkImageSourceParams_fDiffraction_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_uDiffractionEmitterSide_set")] public static extern void CSharp_AkImageSourceParams_uDiffractionEmitterSide_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_uDiffractionEmitterSide_get")] public static extern byte CSharp_AkImageSourceParams_uDiffractionEmitterSide_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_uDiffractionListenerSide_set")] public static extern void CSharp_AkImageSourceParams_uDiffractionListenerSide_set(global::System.IntPtr jarg1, byte jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceParams_uDiffractionListenerSide_get")] public static extern byte CSharp_AkImageSourceParams_uDiffractionListenerSide_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkImageSourceParams")] public static extern void CSharp_delete_AkImageSourceParams(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kDefaultMaxPathLength_get")] public static extern float CSharp_kDefaultMaxPathLength_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kDefaultDiffractionMaxEdges_get")] public static extern uint CSharp_kDefaultDiffractionMaxEdges_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kDefaultDiffractionMaxPaths_get")] public static extern uint CSharp_kDefaultDiffractionMaxPaths_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kMaxDiffraction_get")] public static extern float CSharp_kMaxDiffraction_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kDiffractionMaxEdges_get")] public static extern uint CSharp_kDiffractionMaxEdges_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kDiffractionMaxPaths_get")] public static extern uint CSharp_kDiffractionMaxPaths_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_kPortalToPortalDiffractionMaxPaths_get")] public static extern uint CSharp_kPortalToPortalDiffractionMaxPaths_get(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkSpatialAudioInitSettings")] public static extern global::System.IntPtr CSharp_new_AkSpatialAudioInitSettings(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uMaxSoundPropagationDepth_set")] public static extern void CSharp_AkSpatialAudioInitSettings_uMaxSoundPropagationDepth_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uMaxSoundPropagationDepth_get")] public static extern uint CSharp_AkSpatialAudioInitSettings_uMaxSoundPropagationDepth_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uDiffractionFlags_set")] public static extern void CSharp_AkSpatialAudioInitSettings_uDiffractionFlags_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uDiffractionFlags_get")] public static extern uint CSharp_AkSpatialAudioInitSettings_uDiffractionFlags_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fDiffractionShadowAttenFactor_set")] public static extern void CSharp_AkSpatialAudioInitSettings_fDiffractionShadowAttenFactor_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fDiffractionShadowAttenFactor_get")] public static extern float CSharp_AkSpatialAudioInitSettings_fDiffractionShadowAttenFactor_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fDiffractionShadowDegrees_set")] public static extern void CSharp_AkSpatialAudioInitSettings_fDiffractionShadowDegrees_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fDiffractionShadowDegrees_get")] public static extern float CSharp_AkSpatialAudioInitSettings_fDiffractionShadowDegrees_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fMovementThreshold_set")] public static extern void CSharp_AkSpatialAudioInitSettings_fMovementThreshold_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fMovementThreshold_get")] public static extern float CSharp_AkSpatialAudioInitSettings_fMovementThreshold_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uNumberOfPrimaryRays_set")] public static extern void CSharp_AkSpatialAudioInitSettings_uNumberOfPrimaryRays_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uNumberOfPrimaryRays_get")] public static extern uint CSharp_AkSpatialAudioInitSettings_uNumberOfPrimaryRays_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uMaxReflectionOrder_set")] public static extern void CSharp_AkSpatialAudioInitSettings_uMaxReflectionOrder_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_uMaxReflectionOrder_get")] public static extern uint CSharp_AkSpatialAudioInitSettings_uMaxReflectionOrder_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fMaxPathLength_set")] public static extern void CSharp_AkSpatialAudioInitSettings_fMaxPathLength_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_fMaxPathLength_get")] public static extern float CSharp_AkSpatialAudioInitSettings_fMaxPathLength_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_bEnableDiffractionOnReflection_set")] public static extern void CSharp_AkSpatialAudioInitSettings_bEnableDiffractionOnReflection_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_bEnableDiffractionOnReflection_get")] public static extern bool CSharp_AkSpatialAudioInitSettings_bEnableDiffractionOnReflection_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_bEnableDirectPathDiffraction_set")] public static extern void CSharp_AkSpatialAudioInitSettings_bEnableDirectPathDiffraction_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_bEnableDirectPathDiffraction_get")] public static extern bool CSharp_AkSpatialAudioInitSettings_bEnableDirectPathDiffraction_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_bEnableTransmission_set")] public static extern void CSharp_AkSpatialAudioInitSettings_bEnableTransmission_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkSpatialAudioInitSettings_bEnableTransmission_get")] public static extern bool CSharp_AkSpatialAudioInitSettings_bEnableTransmission_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkSpatialAudioInitSettings")] public static extern void CSharp_delete_AkSpatialAudioInitSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkImageSourceSettings__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkImageSourceSettings__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkImageSourceSettings__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkImageSourceSettings__SWIG_1(UnityEngine.Vector3 jarg1, float jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkImageSourceSettings")] public static extern void CSharp_delete_AkImageSourceSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceSettings_SetOneTexture")] public static extern void CSharp_AkImageSourceSettings_SetOneTexture(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceSettings_SetName")] public static extern void CSharp_AkImageSourceSettings_SetName(global::System.IntPtr jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceSettings_params__set")] public static extern void CSharp_AkImageSourceSettings_params__set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkImageSourceSettings_params__get")] public static extern global::System.IntPtr CSharp_AkImageSourceSettings_params__get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkTriangle__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkTriangle__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkTriangle__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkTriangle__SWIG_1(ushort jarg1, ushort jarg2, ushort jarg3, ushort jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_point0_set")] public static extern void CSharp_AkTriangle_point0_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_point0_get")] public static extern ushort CSharp_AkTriangle_point0_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_point1_set")] public static extern void CSharp_AkTriangle_point1_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_point1_get")] public static extern ushort CSharp_AkTriangle_point1_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_point2_set")] public static extern void CSharp_AkTriangle_point2_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_point2_get")] public static extern ushort CSharp_AkTriangle_point2_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_surface_set")] public static extern void CSharp_AkTriangle_surface_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_surface_get")] public static extern ushort CSharp_AkTriangle_surface_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_Clear")] public static extern void CSharp_AkTriangle_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_GetSizeOf")] public static extern int CSharp_AkTriangle_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkTriangle_Clone")] public static extern void CSharp_AkTriangle_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkTriangle")] public static extern void CSharp_delete_AkTriangle(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkAcousticSurface")] public static extern global::System.IntPtr CSharp_new_AkAcousticSurface(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_textureID_set")] public static extern void CSharp_AkAcousticSurface_textureID_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_textureID_get")] public static extern uint CSharp_AkAcousticSurface_textureID_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_occlusion_set")] public static extern void CSharp_AkAcousticSurface_occlusion_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_occlusion_get")] public static extern float CSharp_AkAcousticSurface_occlusion_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_strName_set")] public static extern void CSharp_AkAcousticSurface_strName_set(global::System.IntPtr jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_strName_get")] public static extern global::System.IntPtr CSharp_AkAcousticSurface_strName_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_Clear")] public static extern void CSharp_AkAcousticSurface_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_DeleteName")] public static extern void CSharp_AkAcousticSurface_DeleteName(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_GetSizeOf")] public static extern int CSharp_AkAcousticSurface_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkAcousticSurface_Clone")] public static extern void CSharp_AkAcousticSurface_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkAcousticSurface")] public static extern void CSharp_delete_AkAcousticSurface(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_imageSource_set")] public static extern void CSharp_AkReflectionPathInfo_imageSource_set(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_imageSource_get")] public static extern UnityEngine.Vector3 CSharp_AkReflectionPathInfo_imageSource_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_numPathPoints_set")] public static extern void CSharp_AkReflectionPathInfo_numPathPoints_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_numPathPoints_get")] public static extern uint CSharp_AkReflectionPathInfo_numPathPoints_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_numReflections_set")] public static extern void CSharp_AkReflectionPathInfo_numReflections_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_numReflections_get")] public static extern uint CSharp_AkReflectionPathInfo_numReflections_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_level_set")] public static extern void CSharp_AkReflectionPathInfo_level_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_level_get")] public static extern float CSharp_AkReflectionPathInfo_level_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_isOccluded_set")] public static extern void CSharp_AkReflectionPathInfo_isOccluded_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_isOccluded_get")] public static extern bool CSharp_AkReflectionPathInfo_isOccluded_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_GetSizeOf")] public static extern int CSharp_AkReflectionPathInfo_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_GetPathPoint")] public static extern UnityEngine.Vector3 CSharp_AkReflectionPathInfo_GetPathPoint(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_GetAcousticSurface")] public static extern global::System.IntPtr CSharp_AkReflectionPathInfo_GetAcousticSurface(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_GetDiffraction")] public static extern float CSharp_AkReflectionPathInfo_GetDiffraction(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkReflectionPathInfo_Clone")] public static extern void CSharp_AkReflectionPathInfo_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkReflectionPathInfo")] public static extern global::System.IntPtr CSharp_new_AkReflectionPathInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkReflectionPathInfo")] public static extern void CSharp_delete_AkReflectionPathInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_virtualPos_set")] public static extern void CSharp_AkDiffractionPathInfo_virtualPos_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_virtualPos_get")] public static extern global::System.IntPtr CSharp_AkDiffractionPathInfo_virtualPos_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_nodeCount_set")] public static extern void CSharp_AkDiffractionPathInfo_nodeCount_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_nodeCount_get")] public static extern uint CSharp_AkDiffractionPathInfo_nodeCount_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_diffraction_set")] public static extern void CSharp_AkDiffractionPathInfo_diffraction_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_diffraction_get")] public static extern float CSharp_AkDiffractionPathInfo_diffraction_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_totLength_set")] public static extern void CSharp_AkDiffractionPathInfo_totLength_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_totLength_get")] public static extern float CSharp_AkDiffractionPathInfo_totLength_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_obstructionValue_set")] public static extern void CSharp_AkDiffractionPathInfo_obstructionValue_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_obstructionValue_get")] public static extern float CSharp_AkDiffractionPathInfo_obstructionValue_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_GetSizeOf")] public static extern int CSharp_AkDiffractionPathInfo_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_GetNodes")] public static extern UnityEngine.Vector3 CSharp_AkDiffractionPathInfo_GetNodes(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_GetAngles")] public static extern float CSharp_AkDiffractionPathInfo_GetAngles(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_GetPortals")] public static extern ulong CSharp_AkDiffractionPathInfo_GetPortals(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_GetRooms")] public static extern ulong CSharp_AkDiffractionPathInfo_GetRooms(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDiffractionPathInfo_Clone")] public static extern void CSharp_AkDiffractionPathInfo_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkDiffractionPathInfo")] public static extern global::System.IntPtr CSharp_new_AkDiffractionPathInfo(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkDiffractionPathInfo")] public static extern void CSharp_delete_AkDiffractionPathInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkRoomParams__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkRoomParams__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkRoomParams__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkRoomParams__SWIG_1(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_Up_set")] public static extern void CSharp_AkRoomParams_Up_set(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_Up_get")] public static extern UnityEngine.Vector3 CSharp_AkRoomParams_Up_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_Front_set")] public static extern void CSharp_AkRoomParams_Front_set(global::System.IntPtr jarg1, UnityEngine.Vector3 jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_Front_get")] public static extern UnityEngine.Vector3 CSharp_AkRoomParams_Front_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_ReverbAuxBus_set")] public static extern void CSharp_AkRoomParams_ReverbAuxBus_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_ReverbAuxBus_get")] public static extern uint CSharp_AkRoomParams_ReverbAuxBus_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_ReverbLevel_set")] public static extern void CSharp_AkRoomParams_ReverbLevel_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_ReverbLevel_get")] public static extern float CSharp_AkRoomParams_ReverbLevel_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_WallOcclusion_set")] public static extern void CSharp_AkRoomParams_WallOcclusion_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_WallOcclusion_get")] public static extern float CSharp_AkRoomParams_WallOcclusion_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_RoomGameObj_AuxSendLevelToSelf_set")] public static extern void CSharp_AkRoomParams_RoomGameObj_AuxSendLevelToSelf_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_RoomGameObj_AuxSendLevelToSelf_get")] public static extern float CSharp_AkRoomParams_RoomGameObj_AuxSendLevelToSelf_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_RoomGameObj_KeepRegistered_set")] public static extern void CSharp_AkRoomParams_RoomGameObj_KeepRegistered_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkRoomParams_RoomGameObj_KeepRegistered_get")] public static extern bool CSharp_AkRoomParams_RoomGameObj_KeepRegistered_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkRoomParams")] public static extern void CSharp_delete_AkRoomParams(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetImageSource")] public static extern int CSharp_SetImageSource(uint jarg1, global::System.IntPtr jarg2, uint jarg3, ulong jarg4, ulong jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemoveImageSource")] public static extern int CSharp_RemoveImageSource(uint jarg1, uint jarg2, ulong jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ClearImageSources__SWIG_0")] public static extern int CSharp_ClearImageSources__SWIG_0(uint jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ClearImageSources__SWIG_1")] public static extern int CSharp_ClearImageSources__SWIG_1(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_ClearImageSources__SWIG_2")] public static extern int CSharp_ClearImageSources__SWIG_2(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemoveGeometry")] public static extern int CSharp_RemoveGeometry(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_QueryReflectionPaths")] public static extern int CSharp_QueryReflectionPaths(ulong jarg1, ref UnityEngine.Vector3 jarg2, ref UnityEngine.Vector3 jarg3, global::System.IntPtr jarg4, out uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemoveRoom")] public static extern int CSharp_RemoveRoom(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RemovePortal")] public static extern int CSharp_RemovePortal(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetGameObjectInRoom")] public static extern int CSharp_SetGameObjectInRoom(ulong jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetReflectionsOrder")] public static extern int CSharp_SetReflectionsOrder(uint jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetNumberOfPrimaryRays")] public static extern int CSharp_SetNumberOfPrimaryRays(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetEarlyReflectionsAuxSend")] public static extern int CSharp_SetEarlyReflectionsAuxSend(ulong jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetEarlyReflectionsVolume")] public static extern int CSharp_SetEarlyReflectionsVolume(ulong jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetPortalObstructionAndOcclusion")] public static extern int CSharp_SetPortalObstructionAndOcclusion(ulong jarg1, float jarg2, float jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_QueryWetDiffraction")] public static extern int CSharp_QueryWetDiffraction(ulong jarg1, out float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_QueryDiffractionPaths")] public static extern int CSharp_QueryDiffractionPaths(ulong jarg1, ref UnityEngine.Vector3 jarg2, ref UnityEngine.Vector3 jarg3, global::System.IntPtr jarg4, out uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadLEngine_set")] public static extern void CSharp_AkPlatformInitSettings_threadLEngine_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadLEngine_get")] public static extern global::System.IntPtr CSharp_AkPlatformInitSettings_threadLEngine_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadOutputMgr_set")] public static extern void CSharp_AkPlatformInitSettings_threadOutputMgr_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadOutputMgr_get")] public static extern global::System.IntPtr CSharp_AkPlatformInitSettings_threadOutputMgr_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadBankManager_set")] public static extern void CSharp_AkPlatformInitSettings_threadBankManager_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadBankManager_get")] public static extern global::System.IntPtr CSharp_AkPlatformInitSettings_threadBankManager_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadMonitor_set")] public static extern void CSharp_AkPlatformInitSettings_threadMonitor_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_threadMonitor_get")] public static extern global::System.IntPtr CSharp_AkPlatformInitSettings_threadMonitor_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_eAudioAPI_set")] public static extern void CSharp_AkPlatformInitSettings_eAudioAPI_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_eAudioAPI_get")] public static extern int CSharp_AkPlatformInitSettings_eAudioAPI_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_uSampleRate_set")] public static extern void CSharp_AkPlatformInitSettings_uSampleRate_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_uSampleRate_get")] public static extern uint CSharp_AkPlatformInitSettings_uSampleRate_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_uNumRefillsInVoice_set")] public static extern void CSharp_AkPlatformInitSettings_uNumRefillsInVoice_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_uNumRefillsInVoice_get")] public static extern ushort CSharp_AkPlatformInitSettings_uNumRefillsInVoice_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_uChannelMask_set")] public static extern void CSharp_AkPlatformInitSettings_uChannelMask_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_uChannelMask_get")] public static extern uint CSharp_AkPlatformInitSettings_uChannelMask_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_bRoundFrameSizeToHWSize_set")] public static extern void CSharp_AkPlatformInitSettings_bRoundFrameSizeToHWSize_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlatformInitSettings_bRoundFrameSizeToHWSize_get")] public static extern bool CSharp_AkPlatformInitSettings_bRoundFrameSizeToHWSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkPlatformInitSettings")] public static extern void CSharp_delete_AkPlatformInitSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetFastPathSettings")] public static extern int CSharp_GetFastPathSettings(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkStreamMgrSettings")] public static extern void CSharp_delete_AkStreamMgrSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_pIOMemory_set")] public static extern void CSharp_AkDeviceSettings_pIOMemory_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_pIOMemory_get")] public static extern global::System.IntPtr CSharp_AkDeviceSettings_pIOMemory_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uIOMemorySize_set")] public static extern void CSharp_AkDeviceSettings_uIOMemorySize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uIOMemorySize_get")] public static extern uint CSharp_AkDeviceSettings_uIOMemorySize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uIOMemoryAlignment_set")] public static extern void CSharp_AkDeviceSettings_uIOMemoryAlignment_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uIOMemoryAlignment_get")] public static extern uint CSharp_AkDeviceSettings_uIOMemoryAlignment_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_ePoolAttributes_set")] public static extern void CSharp_AkDeviceSettings_ePoolAttributes_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_ePoolAttributes_get")] public static extern uint CSharp_AkDeviceSettings_ePoolAttributes_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uGranularity_set")] public static extern void CSharp_AkDeviceSettings_uGranularity_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uGranularity_get")] public static extern uint CSharp_AkDeviceSettings_uGranularity_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uSchedulerTypeFlags_set")] public static extern void CSharp_AkDeviceSettings_uSchedulerTypeFlags_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uSchedulerTypeFlags_get")] public static extern uint CSharp_AkDeviceSettings_uSchedulerTypeFlags_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_threadProperties_set")] public static extern void CSharp_AkDeviceSettings_threadProperties_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_threadProperties_get")] public static extern global::System.IntPtr CSharp_AkDeviceSettings_threadProperties_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_fTargetAutoStmBufferLength_set")] public static extern void CSharp_AkDeviceSettings_fTargetAutoStmBufferLength_set(global::System.IntPtr jarg1, float jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_fTargetAutoStmBufferLength_get")] public static extern float CSharp_AkDeviceSettings_fTargetAutoStmBufferLength_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uMaxConcurrentIO_set")] public static extern void CSharp_AkDeviceSettings_uMaxConcurrentIO_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uMaxConcurrentIO_get")] public static extern uint CSharp_AkDeviceSettings_uMaxConcurrentIO_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_bUseStreamCache_set")] public static extern void CSharp_AkDeviceSettings_bUseStreamCache_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_bUseStreamCache_get")] public static extern bool CSharp_AkDeviceSettings_bUseStreamCache_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uMaxCachePinnedBytes_set")] public static extern void CSharp_AkDeviceSettings_uMaxCachePinnedBytes_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDeviceSettings_uMaxCachePinnedBytes_get")] public static extern uint CSharp_AkDeviceSettings_uMaxCachePinnedBytes_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkDeviceSettings")] public static extern void CSharp_delete_AkDeviceSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_nPriority_set")] public static extern void CSharp_AkThreadProperties_nPriority_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_nPriority_get")] public static extern int CSharp_AkThreadProperties_nPriority_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_uStackSize_set")] public static extern void CSharp_AkThreadProperties_uStackSize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_uStackSize_get")] public static extern uint CSharp_AkThreadProperties_uStackSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_uSchedPolicy_set")] public static extern void CSharp_AkThreadProperties_uSchedPolicy_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_uSchedPolicy_get")] public static extern int CSharp_AkThreadProperties_uSchedPolicy_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_dwAffinityMask_set")] public static extern void CSharp_AkThreadProperties_dwAffinityMask_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkThreadProperties_dwAffinityMask_get")] public static extern uint CSharp_AkThreadProperties_dwAffinityMask_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkThreadProperties")] public static extern global::System.IntPtr CSharp_new_AkThreadProperties(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkThreadProperties")] public static extern void CSharp_delete_AkThreadProperties(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetErrorLogger__SWIG_0")] public static extern void CSharp_SetErrorLogger__SWIG_0(AkLogger.ErrorLoggerInteropDelegate jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetErrorLogger__SWIG_1")] public static extern void CSharp_SetErrorLogger__SWIG_1(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetAudioInputCallbacks")] public static extern void CSharp_SetAudioInputCallbacks(AkAudioInputManager.AudioSamplesInteropDelegate jarg1, AkAudioInputManager.AudioFormatInteropDelegate jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkUnityPlatformSpecificSettings")] public static extern void CSharp_delete_AkUnityPlatformSpecificSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkCommunicationSettings")] public static extern global::System.IntPtr CSharp_new_AkCommunicationSettings(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uPoolSize_set")] public static extern void CSharp_AkCommunicationSettings_uPoolSize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uPoolSize_get")] public static extern uint CSharp_AkCommunicationSettings_uPoolSize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uDiscoveryBroadcastPort_set")] public static extern void CSharp_AkCommunicationSettings_uDiscoveryBroadcastPort_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uDiscoveryBroadcastPort_get")] public static extern ushort CSharp_AkCommunicationSettings_uDiscoveryBroadcastPort_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uCommandPort_set")] public static extern void CSharp_AkCommunicationSettings_uCommandPort_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uCommandPort_get")] public static extern ushort CSharp_AkCommunicationSettings_uCommandPort_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uNotificationPort_set")] public static extern void CSharp_AkCommunicationSettings_uNotificationPort_set(global::System.IntPtr jarg1, ushort jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_uNotificationPort_get")] public static extern ushort CSharp_AkCommunicationSettings_uNotificationPort_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_commSystem_set")] public static extern void CSharp_AkCommunicationSettings_commSystem_set(global::System.IntPtr jarg1, int jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_commSystem_get")] public static extern int CSharp_AkCommunicationSettings_commSystem_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_bInitSystemLib_set")] public static extern void CSharp_AkCommunicationSettings_bInitSystemLib_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_bInitSystemLib_get")] public static extern bool CSharp_AkCommunicationSettings_bInitSystemLib_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_szAppNetworkName_set")] public static extern void CSharp_AkCommunicationSettings_szAppNetworkName_set(global::System.IntPtr jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkCommunicationSettings_szAppNetworkName_get")] public static extern global::System.IntPtr CSharp_AkCommunicationSettings_szAppNetworkName_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkCommunicationSettings")] public static extern void CSharp_delete_AkCommunicationSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkInitializationSettings")] public static extern global::System.IntPtr CSharp_new_AkInitializationSettings(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkInitializationSettings")] public static extern void CSharp_delete_AkInitializationSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_streamMgrSettings_set")] public static extern void CSharp_AkInitializationSettings_streamMgrSettings_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_streamMgrSettings_get")] public static extern global::System.IntPtr CSharp_AkInitializationSettings_streamMgrSettings_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_deviceSettings_set")] public static extern void CSharp_AkInitializationSettings_deviceSettings_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_deviceSettings_get")] public static extern global::System.IntPtr CSharp_AkInitializationSettings_deviceSettings_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_initSettings_set")] public static extern void CSharp_AkInitializationSettings_initSettings_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_initSettings_get")] public static extern global::System.IntPtr CSharp_AkInitializationSettings_initSettings_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_platformSettings_set")] public static extern void CSharp_AkInitializationSettings_platformSettings_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_platformSettings_get")] public static extern global::System.IntPtr CSharp_AkInitializationSettings_platformSettings_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_musicSettings_set")] public static extern void CSharp_AkInitializationSettings_musicSettings_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_musicSettings_get")] public static extern global::System.IntPtr CSharp_AkInitializationSettings_musicSettings_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_unityPlatformSpecificSettings_set")] public static extern void CSharp_AkInitializationSettings_unityPlatformSpecificSettings_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_unityPlatformSpecificSettings_get")] public static extern global::System.IntPtr CSharp_AkInitializationSettings_unityPlatformSpecificSettings_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_useAsyncOpen_set")] public static extern void CSharp_AkInitializationSettings_useAsyncOpen_set(global::System.IntPtr jarg1, bool jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkInitializationSettings_useAsyncOpen_get")] public static extern bool CSharp_AkInitializationSettings_useAsyncOpen_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkExternalSourceInfo__SWIG_0")] public static extern global::System.IntPtr CSharp_new_AkExternalSourceInfo__SWIG_0(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_delete_AkExternalSourceInfo")] public static extern void CSharp_delete_AkExternalSourceInfo(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkExternalSourceInfo__SWIG_1")] public static extern global::System.IntPtr CSharp_new_AkExternalSourceInfo__SWIG_1(global::System.IntPtr jarg1, uint jarg2, uint jarg3, uint jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkExternalSourceInfo__SWIG_2")] public static extern global::System.IntPtr CSharp_new_AkExternalSourceInfo__SWIG_2([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_new_AkExternalSourceInfo__SWIG_3")] public static extern global::System.IntPtr CSharp_new_AkExternalSourceInfo__SWIG_3(uint jarg1, uint jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_Clear")] public static extern void CSharp_AkExternalSourceInfo_Clear(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_Clone")] public static extern void CSharp_AkExternalSourceInfo_Clone(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_GetSizeOf")] public static extern int CSharp_AkExternalSourceInfo_GetSizeOf(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_iExternalSrcCookie_set")] public static extern void CSharp_AkExternalSourceInfo_iExternalSrcCookie_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_iExternalSrcCookie_get")] public static extern uint CSharp_AkExternalSourceInfo_iExternalSrcCookie_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_idCodec_set")] public static extern void CSharp_AkExternalSourceInfo_idCodec_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_idCodec_get")] public static extern uint CSharp_AkExternalSourceInfo_idCodec_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_szFile_set")] public static extern void CSharp_AkExternalSourceInfo_szFile_set(global::System.IntPtr jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_szFile_get")] public static extern global::System.IntPtr CSharp_AkExternalSourceInfo_szFile_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_pInMemory_set")] public static extern void CSharp_AkExternalSourceInfo_pInMemory_set(global::System.IntPtr jarg1, global::System.IntPtr jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_pInMemory_get")] public static extern global::System.IntPtr CSharp_AkExternalSourceInfo_pInMemory_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_uiMemorySize_set")] public static extern void CSharp_AkExternalSourceInfo_uiMemorySize_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_uiMemorySize_get")] public static extern uint CSharp_AkExternalSourceInfo_uiMemorySize_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_idFile_set")] public static extern void CSharp_AkExternalSourceInfo_idFile_set(global::System.IntPtr jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkExternalSourceInfo_idFile_get")] public static extern uint CSharp_AkExternalSourceInfo_idFile_get(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_Init")] public static extern int CSharp_Init(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_InitSpatialAudio")] public static extern int CSharp_InitSpatialAudio(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_InitCommunication")] public static extern int CSharp_InitCommunication(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_Term")] public static extern void CSharp_Term(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RegisterGameObjInternal")] public static extern int CSharp_RegisterGameObjInternal(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnregisterGameObjInternal")] public static extern int CSharp_UnregisterGameObjInternal(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RegisterGameObjInternal_WithName")] public static extern int CSharp_RegisterGameObjInternal_WithName(ulong jarg1, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetBasePath")] public static extern int CSharp_SetBasePath([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetCurrentLanguage")] public static extern int CSharp_SetCurrentLanguage([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadFilePackage")] public static extern int CSharp_LoadFilePackage([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, out uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddBasePath")] public static extern int CSharp_AddBasePath([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetGameName")] public static extern int CSharp_SetGameName([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetDecodedBankPath")] public static extern int CSharp_SetDecodedBankPath([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadAndDecodeBank")] public static extern int CSharp_LoadAndDecodeBank([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, bool jarg2, out uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_LoadAndDecodeBankFromMemory")] public static extern int CSharp_LoadAndDecodeBankFromMemory(global::System.IntPtr jarg1, uint jarg2, bool jarg3, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg4, bool jarg5, out uint jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_0")] public static extern uint CSharp_PostEventOnRoom__SWIG_0([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7, uint jarg8); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_1")] public static extern uint CSharp_PostEventOnRoom__SWIG_1([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_2")] public static extern uint CSharp_PostEventOnRoom__SWIG_2([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_3")] public static extern uint CSharp_PostEventOnRoom__SWIG_3([global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetCurrentLanguage")] public static extern global::System.IntPtr CSharp_GetCurrentLanguage(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnloadFilePackage")] public static extern int CSharp_UnloadFilePackage(uint jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnloadAllFilePackages")] public static extern int CSharp_UnloadAllFilePackages(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetObjectPosition")] public static extern int CSharp_SetObjectPosition(ulong jarg1, UnityEngine.Vector3 jarg2, UnityEngine.Vector3 jarg3, UnityEngine.Vector3 jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSourceMultiplePlayPositions__SWIG_0")] public static extern int CSharp_GetSourceMultiplePlayPositions__SWIG_0(uint jarg1, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg2, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg3, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]int[] jarg4, ref uint jarg5, bool jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSourceMultiplePlayPositions__SWIG_1")] public static extern int CSharp_GetSourceMultiplePlayPositions__SWIG_1(uint jarg1, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg2, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]uint[] jarg3, [global::System.Runtime.InteropServices.Out, global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPArray)]int[] jarg4, ref uint jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetListeners")] public static extern int CSharp_SetListeners(ulong jarg1, ulong[] jarg2, uint jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetDefaultListeners")] public static extern int CSharp_SetDefaultListeners(ulong[] jarg1, uint jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddOutput__SWIG_0")] public static extern int CSharp_AddOutput__SWIG_0(global::System.IntPtr jarg1, out ulong jarg2, ulong[] jarg3, uint jarg4); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddOutput__SWIG_1")] public static extern int CSharp_AddOutput__SWIG_1(global::System.IntPtr jarg1, out ulong jarg2, ulong[] jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddOutput__SWIG_2")] public static extern int CSharp_AddOutput__SWIG_2(global::System.IntPtr jarg1, out ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AddOutput__SWIG_3")] public static extern int CSharp_AddOutput__SWIG_3(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDefaultStreamSettings")] public static extern void CSharp_GetDefaultStreamSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDefaultDeviceSettings")] public static extern void CSharp_GetDefaultDeviceSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDefaultMusicSettings")] public static extern void CSharp_GetDefaultMusicSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDefaultInitSettings")] public static extern void CSharp_GetDefaultInitSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetDefaultPlatformInitSettings")] public static extern void CSharp_GetDefaultPlatformInitSettings(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetMajorMinorVersion")] public static extern uint CSharp_GetMajorMinorVersion(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetSubminorBuildVersion")] public static extern uint CSharp_GetSubminorBuildVersion(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StartResourceMonitoring")] public static extern void CSharp_StartResourceMonitoring(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_StopResourceMonitoring")] public static extern void CSharp_StopResourceMonitoring(); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_GetResourceMonitorDataSummary")] public static extern void CSharp_GetResourceMonitorDataSummary(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRoomPortal")] public static extern int CSharp_SetRoomPortal(ulong jarg1, global::System.IntPtr jarg2, UnityEngine.Vector3 jarg3, bool jarg4, ulong jarg5, ulong jarg6); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetRoom")] public static extern int CSharp_SetRoom(ulong jarg1, global::System.IntPtr jarg2, [global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.LPStr)]string jarg3); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_RegisterSpatialAudioListener")] public static extern int CSharp_RegisterSpatialAudioListener(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_UnregisterSpatialAudioListener")] public static extern int CSharp_UnregisterSpatialAudioListener(ulong jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_SetGeometry")] public static extern int CSharp_SetGeometry(ulong jarg1, global::System.IntPtr jarg2, uint jarg3, UnityEngine.Vector3[] jarg4, uint jarg5, global::System.IntPtr jarg6, uint jarg7, ulong jarg8, bool jarg9, bool jarg10); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_4")] public static extern uint CSharp_PostEventOnRoom__SWIG_4(uint jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7, uint jarg8); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_5")] public static extern uint CSharp_PostEventOnRoom__SWIG_5(uint jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5, uint jarg6, global::System.IntPtr jarg7); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_6")] public static extern uint CSharp_PostEventOnRoom__SWIG_6(uint jarg1, ulong jarg2, uint jarg3, global::System.IntPtr jarg4, global::System.IntPtr jarg5); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_PostEventOnRoom__SWIG_7")] public static extern uint CSharp_PostEventOnRoom__SWIG_7(uint jarg1, ulong jarg2); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkPlaylist_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkPlaylist_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIPost_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkMIDIPost_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkEventCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkEventCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMIDIEventCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkMIDIEventCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMarkerCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkMarkerCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDurationCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkDurationCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkDynamicSequenceItemCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkDynamicSequenceItemCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicSyncCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkMusicSyncCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1); [global::System.Runtime.InteropServices.DllImport("AkSoundEngine", EntryPoint="CSharp_AkMusicPlaylistCallbackInfo_SWIGUpcast")] public static extern global::System.IntPtr CSharp_AkMusicPlaylistCallbackInfo_SWIGUpcast(global::System.IntPtr jarg1);} #endif // #if UNITY_ANDROID && ! UNITY_EDITOR
117.961734
622
0.843488
[ "MIT" ]
ArtemWerholetow/sound_designer_test
Assets/Wwise/Deployment/API/Generated/Android/AkSoundEnginePINVOKE_Android.cs
255,859
C#
namespace InheritanceAndPolymorphism { using System.Collections.Generic; public interface ICourse { void AddStudents(); string GetStudentsAsString(); } }
15.75
37
0.666667
[ "MIT" ]
NikolaiMishev/Telerik-Academy
Module-2/High-Quality-Code/High-quality Classes/Homework/Inheritance-and-Polymorphism/ICourse.cs
191
C#
using Bit.Core.Models; using System; using System.Collections.Generic; using System.Threading.Tasks; namespace Bit.Core.Contracts { public enum LogPolicy { /// <summary> /// Performs log only when there is an error. For example when a response is not succeed. /// </summary> InCaseOfScopeFailure, /// <summary> /// Store logs anyway. (Default) /// </summary> Always } public interface ILogger { Task LogExceptionAsync(Exception exp, string message); void LogException(Exception exp, string message); Task LogInformationAsync(string message); void LogInformation(string message); Task LogFatalAsync(string message); void LogFatal(string message); Task LogWarningAsync(string message); void LogWarning(string message); IEnumerable<LogData> LogData { get; } void AddLogData(string key, object? value); /// <summary> /// Default <see cref="LogPolicy.InCaseOfScopeFailure"/> /// </summary> LogPolicy Policy { get; set; } } }
23.604167
97
0.618711
[ "MIT" ]
Cyrus-Sushiant/bitframework
src/Server/Bit.Server.Core/Contracts/ILogger.cs
1,135
C#
using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; // Allgemeine Informationen über eine Assembly werden über die folgenden // Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern, // die einer Assembly zugeordnet sind. [assembly: AssemblyTitle("Task1")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("Task1")] [assembly: AssemblyCopyright("Copyright © 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] // Durch Festlegen von ComVisible auf FALSE werden die Typen in dieser Assembly // für COM-Komponenten unsichtbar. Wenn Sie auf einen Typ in dieser Assembly von // COM aus zugreifen müssen, sollten Sie das ComVisible-Attribut für diesen Typ auf "True" festlegen. [assembly: ComVisible(false)] // Die folgende GUID bestimmt die ID der Typbibliothek, wenn dieses Projekt für COM verfügbar gemacht wird [assembly: Guid("2a6bf3a0-e877-4976-8dcb-9a33c51b337a")] // Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten: // // Hauptversion // Nebenversion // Buildnummer // Revision // // Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden, // übernehmen, indem Sie "*" eingeben: // [assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
40.216216
106
0.762097
[ "MIT" ]
Mandrae/oom
tasks/Task1/Task1/Properties/AssemblyInfo.cs
1,504
C#
using OrchardCore.Modules.Manifest; [assembly: Module( Author = "Etch UK", Category = "Infrastructure", Description = "Specify custom script blocks for the `<head>` or at the bottom of the page", Name = "Inject Scripts", Version = "1.1.0", Website = "https://etchuk.com" )]
29.8
95
0.654362
[ "MIT" ]
EtchUK/Etch.OrchardCore.InjectScripts
Manifest.cs
298
C#
#region License // Copyright (c) 2015 1010Tires.com // // 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. #endregion namespace MXTires.Microdata { /// <summary> /// The act of manipulating/administering/supervising/controlling one or more objects. /// </summary> public class OrganizeAction : Action { } }
40.029412
90
0.745775
[ "MIT" ]
idenys/MXTires.Microdata
Actions/OrganizeAction.cs
1,363
C#
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; using System.Windows.Controls; using System.Windows.Data; using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Imaging; using System.Windows.Navigation; using System.Windows.Shapes; namespace MergeBranch { /// <summary> /// Interaction logic for MainWindow.xaml /// </summary> public partial class MainWindow : Window { public MainWindow() { InitializeComponent(); } } }
21.827586
45
0.71406
[ "MIT" ]
g2384/GitHelper
MergeBranch/MainWindow.xaml.cs
635
C#
// Copyright (c) 2010-2013 AlphaSierraPapa for the SharpDevelop Team // // 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 ICSharpCode.Decompiler.CSharp.Syntax; namespace ICSharpCode.Decompiler.CSharp.OutputVisitor { /// <summary> /// Inserts the parentheses into the AST that are needed to ensure the AST can be printed correctly. /// For example, if the AST contains /// BinaryOperatorExpresson(2, Mul, BinaryOperatorExpression(1, Add, 1))); printing that AST /// would incorrectly result in "2 * 1 + 1". By running InsertParenthesesVisitor, the necessary /// parentheses are inserted: "2 * (1 + 1)". /// </summary> public class InsertParenthesesVisitor : DepthFirstAstVisitor { /// <summary> /// Gets/Sets whether the visitor should insert parentheses to make the code better looking. /// If this property is false, it will insert parentheses only where strictly required by the language spec. /// </summary> public bool InsertParenthesesForReadability { get; set; } const int Primary = 17; const int NullableRewrap = 16; const int QueryOrLambda = 15; const int Unary = 14; const int RelationalAndTypeTesting = 10; const int Equality = 9; const int Conditional = 2; const int Assignment = 1; /// <summary> /// Gets the row number in the C# 4.0 spec operator precedence table. /// </summary> static int GetPrecedence(Expression expr) { // Note: the operator precedence table on MSDN is incorrect if (expr is QueryExpression) { // Not part of the table in the C# spec, but we need to ensure that queries within // primary expressions get parenthesized. return QueryOrLambda; } if (expr is UnaryOperatorExpression uoe) { switch (uoe.Operator) { case UnaryOperatorType.PostDecrement: case UnaryOperatorType.PostIncrement: case UnaryOperatorType.NullConditional: case UnaryOperatorType.SuppressNullableWarning: return Primary; case UnaryOperatorType.NullConditionalRewrap: return NullableRewrap; case UnaryOperatorType.IsTrue: return Conditional; default: return Unary; } } if (expr is CastExpression) return Unary; if (expr is PrimitiveExpression primitive) { var value = primitive.Value; if (value is int i && i < 0) return Unary; if (value is long l && l < 0) return Unary; if (value is float f && f < 0) return Unary; if (value is double d && d < 0) return Unary; if (value is decimal de && de < 0) return Unary; } BinaryOperatorExpression boe = expr as BinaryOperatorExpression; if (boe != null) { switch (boe.Operator) { case BinaryOperatorType.Multiply: case BinaryOperatorType.Divide: case BinaryOperatorType.Modulus: return 13; // multiplicative case BinaryOperatorType.Add: case BinaryOperatorType.Subtract: return 12; // additive case BinaryOperatorType.ShiftLeft: case BinaryOperatorType.ShiftRight: return 11; case BinaryOperatorType.GreaterThan: case BinaryOperatorType.GreaterThanOrEqual: case BinaryOperatorType.LessThan: case BinaryOperatorType.LessThanOrEqual: return RelationalAndTypeTesting; case BinaryOperatorType.Equality: case BinaryOperatorType.InEquality: return Equality; case BinaryOperatorType.BitwiseAnd: return 8; case BinaryOperatorType.ExclusiveOr: return 7; case BinaryOperatorType.BitwiseOr: return 6; case BinaryOperatorType.ConditionalAnd: return 5; case BinaryOperatorType.ConditionalOr: return 4; case BinaryOperatorType.NullCoalescing: return 3; default: throw new NotSupportedException("Invalid value for BinaryOperatorType"); } } if (expr is IsExpression || expr is AsExpression) return RelationalAndTypeTesting; if (expr is ConditionalExpression || expr is DirectionExpression) return Conditional; if (expr is AssignmentExpression || expr is LambdaExpression) return Assignment; // anything else: primary expression return Primary; } /// <summary> /// Parenthesizes the expression if it does not have the minimum required precedence. /// </summary> static void ParenthesizeIfRequired(Expression expr, int minimumPrecedence) { if (GetPrecedence(expr) < minimumPrecedence) { Parenthesize(expr); } } static void Parenthesize(Expression expr) { expr.ReplaceWith(e => new ParenthesizedExpression { Expression = e }); } // Primary expressions public override void VisitMemberReferenceExpression(MemberReferenceExpression memberReferenceExpression) { ParenthesizeIfRequired(memberReferenceExpression.Target, Primary); base.VisitMemberReferenceExpression(memberReferenceExpression); } public override void VisitPointerReferenceExpression(PointerReferenceExpression pointerReferenceExpression) { ParenthesizeIfRequired(pointerReferenceExpression.Target, Primary); base.VisitPointerReferenceExpression(pointerReferenceExpression); } public override void VisitInvocationExpression(InvocationExpression invocationExpression) { ParenthesizeIfRequired(invocationExpression.Target, Primary); base.VisitInvocationExpression(invocationExpression); } public override void VisitIndexerExpression(IndexerExpression indexerExpression) { ParenthesizeIfRequired(indexerExpression.Target, Primary); ArrayCreateExpression ace = indexerExpression.Target as ArrayCreateExpression; if (ace != null && (InsertParenthesesForReadability || ace.Initializer.IsNull)) { // require parentheses for "(new int[1])[0]" Parenthesize(indexerExpression.Target); } base.VisitIndexerExpression(indexerExpression); } // Unary expressions public override void VisitUnaryOperatorExpression(UnaryOperatorExpression unaryOperatorExpression) { ParenthesizeIfRequired(unaryOperatorExpression.Expression, GetPrecedence(unaryOperatorExpression)); UnaryOperatorExpression child = unaryOperatorExpression.Expression as UnaryOperatorExpression; if (child != null && InsertParenthesesForReadability) Parenthesize(child); base.VisitUnaryOperatorExpression(unaryOperatorExpression); } public override void VisitCastExpression(CastExpression castExpression) { // Even in readability mode, don't parenthesize casts of casts. if (!(castExpression.Expression is CastExpression)) { ParenthesizeIfRequired(castExpression.Expression, InsertParenthesesForReadability ? NullableRewrap : Unary); } // There's a nasty issue in the C# grammar: cast expressions including certain operators are ambiguous in some cases // "(int)-1" is fine, but "(A)-b" is not a cast. UnaryOperatorExpression uoe = castExpression.Expression as UnaryOperatorExpression; if (uoe != null && !(uoe.Operator == UnaryOperatorType.BitNot || uoe.Operator == UnaryOperatorType.Not)) { if (TypeCanBeMisinterpretedAsExpression(castExpression.Type)) { Parenthesize(castExpression.Expression); } } // The above issue can also happen with PrimitiveExpressions representing negative values: PrimitiveExpression pe = castExpression.Expression as PrimitiveExpression; if (pe != null && pe.Value != null && TypeCanBeMisinterpretedAsExpression(castExpression.Type)) { TypeCode typeCode = Type.GetTypeCode(pe.Value.GetType()); switch (typeCode) { case TypeCode.SByte: if ((sbyte)pe.Value < 0) Parenthesize(castExpression.Expression); break; case TypeCode.Int16: if ((short)pe.Value < 0) Parenthesize(castExpression.Expression); break; case TypeCode.Int32: if ((int)pe.Value < 0) Parenthesize(castExpression.Expression); break; case TypeCode.Int64: if ((long)pe.Value < 0) Parenthesize(castExpression.Expression); break; case TypeCode.Single: if ((float)pe.Value < 0) Parenthesize(castExpression.Expression); break; case TypeCode.Double: if ((double)pe.Value < 0) Parenthesize(castExpression.Expression); break; case TypeCode.Decimal: if ((decimal)pe.Value < 0) Parenthesize(castExpression.Expression); break; } } base.VisitCastExpression(castExpression); } static bool TypeCanBeMisinterpretedAsExpression(AstType type) { // SimpleTypes can always be misinterpreted as IdentifierExpressions // MemberTypes can be misinterpreted as MemberReferenceExpressions if they don't use double colon // PrimitiveTypes or ComposedTypes can never be misinterpreted as expressions. MemberType mt = type as MemberType; if (mt != null) return !mt.IsDoubleColon; else return type is SimpleType; } // Binary Operators public override void VisitBinaryOperatorExpression(BinaryOperatorExpression binaryOperatorExpression) { int precedence = GetPrecedence(binaryOperatorExpression); if (binaryOperatorExpression.Operator == BinaryOperatorType.NullCoalescing) { if (InsertParenthesesForReadability) { ParenthesizeIfRequired(binaryOperatorExpression.Left, NullableRewrap); if (GetBinaryOperatorType(binaryOperatorExpression.Right) == BinaryOperatorType.NullCoalescing) { ParenthesizeIfRequired(binaryOperatorExpression.Right, precedence); } else { ParenthesizeIfRequired(binaryOperatorExpression.Right, NullableRewrap); } } else { // ?? is right-associative ParenthesizeIfRequired(binaryOperatorExpression.Left, precedence + 1); ParenthesizeIfRequired(binaryOperatorExpression.Right, precedence); } } else { if (InsertParenthesesForReadability && precedence < Equality) { // In readable mode, boost the priority of the left-hand side if the operator // there isn't the same as the operator on this expression. int boostTo = IsBitwise(binaryOperatorExpression.Operator) ? Unary : Equality; if (GetBinaryOperatorType(binaryOperatorExpression.Left) == binaryOperatorExpression.Operator) { ParenthesizeIfRequired(binaryOperatorExpression.Left, precedence); } else { ParenthesizeIfRequired(binaryOperatorExpression.Left, boostTo); } ParenthesizeIfRequired(binaryOperatorExpression.Right, boostTo); } else { // all other binary operators are left-associative ParenthesizeIfRequired(binaryOperatorExpression.Left, precedence); ParenthesizeIfRequired(binaryOperatorExpression.Right, precedence + 1); } } base.VisitBinaryOperatorExpression(binaryOperatorExpression); } static bool IsBitwise(BinaryOperatorType op) { return op == BinaryOperatorType.BitwiseAnd || op == BinaryOperatorType.BitwiseOr || op == BinaryOperatorType.ExclusiveOr; } BinaryOperatorType? GetBinaryOperatorType(Expression expr) { BinaryOperatorExpression boe = expr as BinaryOperatorExpression; if (boe != null) return boe.Operator; else return null; } public override void VisitIsExpression(IsExpression isExpression) { if (InsertParenthesesForReadability) { // few people know the precedence of 'is', so always put parentheses in nice-looking mode. ParenthesizeIfRequired(isExpression.Expression, NullableRewrap); } else { ParenthesizeIfRequired(isExpression.Expression, RelationalAndTypeTesting); } base.VisitIsExpression(isExpression); } public override void VisitAsExpression(AsExpression asExpression) { if (InsertParenthesesForReadability) { // few people know the precedence of 'as', so always put parentheses in nice-looking mode. ParenthesizeIfRequired(asExpression.Expression, NullableRewrap); } else { ParenthesizeIfRequired(asExpression.Expression, RelationalAndTypeTesting); } base.VisitAsExpression(asExpression); } // Conditional operator public override void VisitConditionalExpression(ConditionalExpression conditionalExpression) { // Inside of string interpolation ?: always needs parentheses. if (conditionalExpression.Parent is Interpolation) { Parenthesize(conditionalExpression); } // Associativity here is a bit tricky: // (a ? b : c ? d : e) == (a ? b : (c ? d : e)) // (a ? b ? c : d : e) == (a ? (b ? c : d) : e) // Only ((a ? b : c) ? d : e) strictly needs the additional parentheses if (InsertParenthesesForReadability && !IsConditionalRefExpression(conditionalExpression)) { // Precedence of ?: can be confusing; so always put parentheses in nice-looking mode. ParenthesizeIfRequired(conditionalExpression.Condition, NullableRewrap); ParenthesizeIfRequired(conditionalExpression.TrueExpression, NullableRewrap); ParenthesizeIfRequired(conditionalExpression.FalseExpression, NullableRewrap); } else { ParenthesizeIfRequired(conditionalExpression.Condition, Conditional + 1); ParenthesizeIfRequired(conditionalExpression.TrueExpression, Conditional); ParenthesizeIfRequired(conditionalExpression.FalseExpression, Conditional); } base.VisitConditionalExpression(conditionalExpression); } private bool IsConditionalRefExpression(ConditionalExpression conditionalExpression) { return conditionalExpression.TrueExpression is DirectionExpression || conditionalExpression.FalseExpression is DirectionExpression; } public override void VisitAssignmentExpression(AssignmentExpression assignmentExpression) { // assignment is right-associative ParenthesizeIfRequired(assignmentExpression.Left, Assignment + 1); if (InsertParenthesesForReadability) { ParenthesizeIfRequired(assignmentExpression.Right, RelationalAndTypeTesting + 1); } else { ParenthesizeIfRequired(assignmentExpression.Right, Assignment); } base.VisitAssignmentExpression(assignmentExpression); } // don't need to handle lambdas, they have lowest precedence and unambiguous associativity public override void VisitQueryExpression(QueryExpression queryExpression) { // Query expressions are strange beasts: // "var a = -from b in c select d;" is valid, so queries bind stricter than unary expressions. // However, the end of the query is greedy. So their start sort of has a high precedence, // while their end has a very low precedence. We handle this by checking whether a query is used // as left part of a binary operator, and parenthesize it if required. if (queryExpression.Role == BinaryOperatorExpression.LeftRole) Parenthesize(queryExpression); if (queryExpression.Parent is IsExpression || queryExpression.Parent is AsExpression) Parenthesize(queryExpression); if (InsertParenthesesForReadability) { // when readability is desired, always parenthesize query expressions within unary or binary operators if (queryExpression.Parent is UnaryOperatorExpression || queryExpression.Parent is BinaryOperatorExpression) Parenthesize(queryExpression); } base.VisitQueryExpression(queryExpression); } public override void VisitNamedExpression (NamedExpression namedExpression) { if (InsertParenthesesForReadability) { ParenthesizeIfRequired(namedExpression.Expression, RelationalAndTypeTesting + 1); } base.VisitNamedExpression (namedExpression); } } }
40.37469
119
0.745683
[ "MIT" ]
164306530/ILSpy
ICSharpCode.Decompiler/CSharp/OutputVisitor/InsertParenthesesVisitor.cs
16,273
C#
using System; namespace OpenVIII.Fields.Scripts.Instructions { internal sealed class ISPARTY : JsmInstruction { private IJsmExpression _arg0; public ISPARTY(IJsmExpression arg0) { _arg0 = arg0; } public ISPARTY(Int32 parameter, IStack<IJsmExpression> stack) : this( arg0: stack.Pop()) { } public override String ToString() { return $"{nameof(ISPARTY)}({nameof(_arg0)}: {_arg0})"; } } }
20.576923
69
0.542056
[ "MIT" ]
MattLisson/OpenVIII
Core/Field/JSM/Instructions/ISPARTY.cs
537
C#
using System; using System.Linq; using Zenject; using ZenjectPrototype.Entities; using ZenjectPrototype.Entities.Capabilities; namespace ZenjectPrototype.RoundSystem { public class RoundResetter : IInitializable { private IRoundManager roundManager; private IDataHolder<Entity> entities; [Inject] public RoundResetter(IRoundManager roundManager, IDataHolder<Entity> entities) { this.roundManager = roundManager; this.entities = entities; } public void Initialize() { roundManager.OnRoundEnd += RoundManager_OnRoundEnd; } private void RoundManager_OnRoundEnd(object sender, EventArgs e) { foreach (var receiver in entities.GetAll().OfType<IReceiver<Photon>>()) { receiver.Release(); } } } }
25.457143
86
0.628507
[ "MIT" ]
Nitue/MirrorPuzzle
Assets/ZenjectPrototype/Scripts/RoundSystem/RoundResetter.cs
893
C#
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** using System; using System.Collections.Generic; using System.Collections.Immutable; using System.Threading.Tasks; using Pulumi.Serialization; namespace Pulumi.Databricks.Inputs { public sealed class SqlQueryParameterDatetimesecArgs : Pulumi.ResourceArgs { [Input("value", required: true)] public Input<string> Value { get; set; } = null!; public SqlQueryParameterDatetimesecArgs() { } } }
26.782609
88
0.693182
[ "ECL-2.0", "Apache-2.0" ]
pulumi/pulumi-databricks
sdk/dotnet/Inputs/SqlQueryParameterDatetimesecArgs.cs
616
C#
// c:\program files (x86)\windows kits\10\include\10.0.22000.0\shared\ks.h(988,9) namespace DirectN { public enum KSINTERFACE_STANDARD { KSINTERFACE_STANDARD_STREAMING = 0, KSINTERFACE_STANDARD_LOOPED_STREAMING = 1, KSINTERFACE_STANDARD_CONTROL = 2, } }
27.363636
83
0.671096
[ "MIT" ]
Steph55/DirectN
DirectN/DirectN/Generated/KSINTERFACE_STANDARD.cs
303
C#
using System; using System.Security.Cryptography; namespace Couchbase.Cryptography { internal sealed class Crc32 : HashAlgorithm { private const uint Polynomial = 0xedb88320u; private const uint Seed = 0xffffffffu; private static readonly uint[] Table = new uint[256]; private uint _hash; static Crc32() { for (var i = 0u; i < Table.Length; ++i) { var temp = i; for (var j = 8u; j > 0; --j) { if ((temp & 1) == 1) { temp = ((temp >> 1) ^ Polynomial); } else { temp >>= 1; } } Table[i] = temp; } } protected override void HashCore(byte[] array, int ibStart, int cbSize) { _hash = Seed; for (var i = ibStart; i < cbSize - ibStart; i++) { _hash = (_hash >> 8) ^ Table[array[i] ^ _hash & 0xff]; } } protected override byte[] HashFinal() { _hash = ((~_hash) >> 16) & 0x7fff; return BitConverter.GetBytes(_hash); } public override void Initialize() { _hash = Seed; } } } #region [ License information ] /* ************************************************************ * * @author Couchbase <info@couchbase.com> * @copyright 2014 Couchbase, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * * ************************************************************/ #endregion
29.631579
79
0.47913
[ "Apache-2.0" ]
4thOffice/couchbase-net-client
Src/Couchbase/Cryptography/Crc32.cs
2,254
C#
using System.ComponentModel; using System.Runtime.CompilerServices; using Forge.Forms.Annotations; namespace Forge.Forms.Demo.Models { public class FoodSelection : INotifyPropertyChanged { private string firstFood = "Pizza"; private string secondFood = "Steak"; private string thirdFood = "Salad"; private string yourFavoriteFood; [Field(DefaultValue = "Pizza")] [Value(Must.NotBeEmpty)] public string FirstFood { get => firstFood; set { firstFood = value; OnPropertyChanged(); } } [Field(DefaultValue = "Steak")] [Value(Must.NotBeEmpty)] public string SecondFood { get => secondFood; set { secondFood = value; OnPropertyChanged(); } } [Field(DefaultValue = "Salad")] [Value(Must.NotBeEmpty)] public string ThirdFood { get => thirdFood; set { thirdFood = value; OnPropertyChanged(); } } [Text("You have selected {Binding YourFavoriteFood}", Placement = Placement.After)] [SelectFrom(new[] { "{Binding FirstFood}, obviously.", "{Binding SecondFood} is best!", "I love {Binding ThirdFood}" })] public string YourFavoriteFood { get => yourFavoriteFood; set { yourFavoriteFood = value; OnPropertyChanged(); } } public event PropertyChangedEventHandler PropertyChanged; protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null) { PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); } } }
27.098592
114
0.532744
[ "MIT" ]
BenjaminSieg/Forge.Forms
Forge.Forms/src/Forge.Forms.Demo/Models/FoodSelection.cs
1,926
C#
// ------------------------------------------------------------------------------------------------- // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License (MIT). See LICENSE in the repo root for license information. // ------------------------------------------------------------------------------------------------- using System; using System.Collections.Generic; using System.Linq; using Microsoft.Health.Fhir.Liquid.Converter.Models.Hl7v2; namespace Microsoft.Health.Fhir.Liquid.Converter { /// <summary> /// Filters for conversion /// </summary> public partial class Filters { public static Dictionary<string, Hl7v2Segment> GetFirstSegments(Hl7v2Data hl7v2Data, string segmentIdContent) { var result = new Dictionary<string, Hl7v2Segment>(); var segmentIds = segmentIdContent.Split(@"|"); for (var i = 0; i < hl7v2Data.Meta.Count; ++i) { if (segmentIds.Contains(hl7v2Data.Meta[i]) && !result.ContainsKey(hl7v2Data.Meta[i])) { result[hl7v2Data.Meta[i]] = hl7v2Data.Data[i]; } } return result; } public static Dictionary<string, List<Hl7v2Segment>> GetSegmentLists(Hl7v2Data hl7v2Data, string segmentIdContent) { var segmentIds = segmentIdContent.Split(@"|"); return GetSegmentListsInternal(hl7v2Data, segmentIds); } public static Dictionary<string, List<Hl7v2Segment>> GetRelatedSegmentList(Hl7v2Data hl7v2Data, Hl7v2Segment parentSegment, string childSegmentId) { var result = new Dictionary<string, List<Hl7v2Segment>>(); List<Hl7v2Segment> segments = new List<Hl7v2Segment>(); var parentFound = false; var childIndex = -1; for (var i = 0; i < hl7v2Data.Meta.Count; ++i) { if (ReferenceEquals(hl7v2Data.Data[i], parentSegment)) { parentFound = true; } else if (string.Equals(hl7v2Data.Meta[i], childSegmentId, StringComparison.InvariantCultureIgnoreCase) && parentFound) { childIndex = i; break; } } if (childIndex > -1) { while (childIndex < hl7v2Data.Meta.Count && string.Equals(hl7v2Data.Meta[childIndex], childSegmentId, StringComparison.InvariantCultureIgnoreCase)) { segments.Add(hl7v2Data.Data[childIndex]); childIndex++; } result[childSegmentId] = segments; } return result; } public static Dictionary<string, Hl7v2Segment> GetParentSegment(Hl7v2Data hl7v2Data, string childSegmentId, int childIndex, string parentSegmentId) { var result = new Dictionary<string, Hl7v2Segment>(); var targetChildIndex = -1; var foundChildSegmentCount = -1; for (var i = 0; i < hl7v2Data.Meta.Count; ++i) { if (string.Equals(hl7v2Data.Meta[i], childSegmentId, StringComparison.InvariantCultureIgnoreCase)) { foundChildSegmentCount++; if (foundChildSegmentCount == childIndex) { targetChildIndex = i; break; } } } for (var i = targetChildIndex; i > -1; i--) { if (string.Equals(hl7v2Data.Meta[i], parentSegmentId, StringComparison.InvariantCultureIgnoreCase)) { result[parentSegmentId] = hl7v2Data.Data[i]; break; } } return result; } public static bool HasSegments(Hl7v2Data hl7v2Data, string segmentIdContent) { var segmentIds = segmentIdContent.Split(@"|"); var segmentLists = GetSegmentListsInternal(hl7v2Data, segmentIds); return segmentIds.All(segmentLists.ContainsKey); } private static Dictionary<string, List<Hl7v2Segment>> GetSegmentListsInternal(Hl7v2Data hl7v2Data, string[] segmentIds) { var result = new Dictionary<string, List<Hl7v2Segment>>(); for (var i = 0; i < hl7v2Data.Meta.Count; ++i) { if (segmentIds.Contains(hl7v2Data.Meta[i])) { if (result.ContainsKey(hl7v2Data.Meta[i])) { result[hl7v2Data.Meta[i]].Add(hl7v2Data.Data[i]); } else { result[hl7v2Data.Meta[i]] = new List<Hl7v2Segment> { hl7v2Data.Data[i] }; } } } return result; } public static List<Hl7v2Data> SplitDataBySegments(Hl7v2Data hl7v2Data, string segmentIdSeparators) { var results = new List<Hl7v2Data>(); var result = new Hl7v2Data(); var segmentIds = new HashSet<string>(segmentIdSeparators.Split(@"|", StringSplitOptions.RemoveEmptyEntries)); if (segmentIdSeparators == string.Empty || !segmentIds.Intersect(hl7v2Data.Meta).Any()) { results.Add(hl7v2Data); return results; } for (var i = 0; i < hl7v2Data.Meta.Count; ++i) { if (segmentIds.Contains(hl7v2Data.Meta[i])) { results.Add(result); result = new Hl7v2Data(); } result.Meta.Add(hl7v2Data.Meta[i]); result.Data.Add(hl7v2Data.Data[i]); } if (result.Meta.Count > 0) { results.Add(result); } return results; } } }
36.872727
163
0.512985
[ "MIT" ]
Cognosante/FHIR-Converter
src/Microsoft.Health.Fhir.Liquid.Converter/Filters/SegmentFilters.cs
6,086
C#
// Copyright (c) 2010-2014 SharpDX - Alexandre Mutel // // 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.Runtime.InteropServices; using SharpDX.Direct3D; namespace SharpDX.Direct3D9 { public partial class Resource { /// <summary> /// Gets or sets the debug-name for this object. /// </summary> /// <value> /// The debug name. /// </value> public string DebugName { get { unsafe { byte* pname = stackalloc byte[1024]; int size = 1024 - 1; if (GetPrivateData(CommonGuid.DebugObjectName, new IntPtr(pname), ref size).Failure) return string.Empty; pname[size] = 0; return Marshal.PtrToStringAnsi(new IntPtr(pname)); } } set { if (string.IsNullOrEmpty(value)) { SetPrivateData(CommonGuid.DebugObjectName, IntPtr.Zero, 0, 0); } else { var namePtr = Marshal.StringToHGlobalAnsi(value); SetPrivateData(CommonGuid.DebugObjectName, namePtr, value.Length, 0); } } } protected override void NativePointerUpdated(IntPtr oldNativePointer) { DisposeDevice(); base.NativePointerUpdated(oldNativePointer); } protected override unsafe void Dispose(bool disposing) { if (disposing) { DisposeDevice(); } base.Dispose(disposing); } private void DisposeDevice() { if (Device__ != null) { // Don't use Dispose() in order to avoid circular references with DeviceContext ((IUnknown)Device__).Release(); Device__ = null; } } } }
34.333333
104
0.577346
[ "MIT" ]
Altair7610/SharpDX
Source/SharpDX.Direct3D9/Resource.cs
3,090
C#
using System; using System.Linq; using System.Threading.Tasks; namespace Ultraschall.Data.Abstractions { public interface IGenericRepository<TEntity> where TEntity : class, IEntity { IQueryable<TEntity> GetAll(); Task<TEntity> GetById(Guid id); Task Create(TEntity entity); Task Update(Guid id, TEntity entity); Task Delete(Guid id); } }
26.066667
79
0.680307
[ "MIT" ]
Ultraschall/ultraschall-playground
danlin/Ultraschall/Data/Abstractions/IGenericRepository.cs
393
C#
using System; using Xunit; namespace Enable.Extensions.Interval.Tests { public class ShortIntervalTests { public void ThrowsException_IfBoundsAreInvalid() { // Arrange var expectedExceptionMessage = "Invalid bounds specified: upper bound must be greater or equal to lower bound." + Environment.NewLine + "Parameter name: upperBound"; var lowerBound = short.MinValue; var upperBound = short.MaxValue; // Act var exception = Record.Exception(() => new Interval<short>(upperBound, lowerBound)); // Assert Assert.IsType<ArgumentOutOfRangeException>(exception); Assert.Equal(expectedExceptionMessage, exception.Message); } [Theory] [InlineData(0, 0, 0)] [InlineData(-1, 1, -1)] [InlineData(-1, 1, 0)] [InlineData(-1, 1, 1)] public void ReturnsTrueIfValueInInterval( short lowerBound, short upperBound, short valueToTest) { // Arrange var sut = new Interval<short>(lowerBound, upperBound); // Act var result = sut.Contains(valueToTest); // Assert Assert.True(result); } [Theory] [InlineData(-1, 1, -2)] [InlineData(-1, 1, 2)] public void ReturnsFalseIfValueOutOfInterval( short lowerBound, short upperBound, short valueToTest) { // Arrange var sut = new Interval<short>(lowerBound, upperBound); // Act var result = sut.Contains(valueToTest); // Assert Assert.False(result); } } }
27.873016
177
0.550683
[ "MIT" ]
EnableSoftware/Enable.Extensions.Interval
test/Enable.Extensions.Interval.Tests/ShortIntervalTests.cs
1,756
C#
using OpenQA.Selenium; using OpenQA.Selenium.Support.PageObjects; using Sfa.Automation.Framework.Selenium; using System; using System.Linq; namespace SFA.DAS.Forecasting.Web.Automation { public class HomePage: BasePage { [FindsBy(How = How.Id, Using = "service-start")] public IWebElement StartButton; [FindsBy(How = How.XPath, Using = "//*[@id=\"content\"]/div/div/form/div[1]/fieldset/label[1]")] public IWebElement UsedServiceBefore { get; set; } [FindsBy(How = How.XPath, Using = "//*[@id=\"content\"]/div/div/form/div[1]/fieldset/label[2]")] private IWebElement NotUsedServiceBefore { get; set; } [FindsBy(How = How.Id, Using = "submit-button")] public IWebElement Continue { get; set; } public HomePage(IWebDriver webDriver) : base(webDriver) { } public LoginPage MoveToLoginPage() { StartButton.ClickThisElement(); UsedServiceBefore.CheckThisRadioButton(); Continue.ClickThisElement(); return new LoginPage(Driver); } } }
38.321429
159
0.650513
[ "MIT" ]
SkillsFundingAgency/das-forecasting-tool
src/SFA.DAS.Forecasting.Web.Automation/HomePage.cs
1,075
C#
using System; using System.IO; using System.Reflection; using log4net; using log4net.Config; using Microsoft.Extensions.Logging; namespace CoreFX.Logging.Log4net { public class Log4netAdapter : Microsoft.Extensions.Logging.ILogger { public Log4netAdapter(string loggerName, FileInfo fileInfo) { var repository = LogManager.CreateRepository( Assembly.GetEntryAssembly(), typeof(log4net.Repository.Hierarchy.Hierarchy) ); XmlConfigurator.Configure(repository, fileInfo); Logger = LogManager.GetLogger(repository.Name, loggerName); } public IDisposable BeginScope<TState>(TState state) => null; public bool IsEnabled(Microsoft.Extensions.Logging.LogLevel logLevel) { switch (logLevel) { case LogLevel.Debug: case LogLevel.Trace: return Logger.IsDebugEnabled; case LogLevel.Critical: return Logger.IsFatalEnabled; case LogLevel.Error: return Logger.IsErrorEnabled; case LogLevel.Information: return Logger.IsInfoEnabled; case LogLevel.Warning: return Logger.IsWarnEnabled; default: return false; } } public void Log<T>( LogLevel logLevel, Microsoft.Extensions.Logging.EventId eventId, T state, Exception exception, Func<T, Exception, string> formatter) { if (false == IsEnabled(logLevel)) { return; } if (null == formatter) { throw new ArgumentNullException(nameof(formatter)); } var message = formatter(state, exception); if (string.IsNullOrWhiteSpace(message)) { message = exception?.ToString(); } if (false == string.IsNullOrWhiteSpace(message)) { switch (logLevel) { case LogLevel.Critical: Logger.Fatal(message); break; case LogLevel.Debug: case LogLevel.Trace: Logger.Debug(message); break; case LogLevel.Error: Logger.Error(message); break; case LogLevel.Information: Logger.Info(message); break; case LogLevel.Warning: Logger.Warn(message); break; default: // Silence break; } } } public ILog Logger { get; private set; } } }
31.159574
77
0.49505
[ "BSD-3-Clause" ]
BlackIkeEagle0/osisdie4
src/Library/CoreFX/Logging/Log4net/Log4netAdapter.cs
2,931
C#
// Copyright © Tanner Gooding and Contributors. Licensed under the MIT License (MIT). See License.md in the repository root for more information. // Ported from um/MsiDefs.h in the Windows SDK for Windows 10.0.20348.0 // Original source is Copyright © Microsoft. All rights reserved. namespace TerraFX.Interop.Windows; /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes"]/*' /> public enum msidbDialogAttributes { /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesVisible"]/*' /> msidbDialogAttributesVisible = 0x00000001, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesModal"]/*' /> msidbDialogAttributesModal = 0x00000002, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesMinimize"]/*' /> msidbDialogAttributesMinimize = 0x00000004, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesSysModal"]/*' /> msidbDialogAttributesSysModal = 0x00000008, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesKeepModeless"]/*' /> msidbDialogAttributesKeepModeless = 0x00000010, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesTrackDiskSpace"]/*' /> msidbDialogAttributesTrackDiskSpace = 0x00000020, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesUseCustomPalette"]/*' /> msidbDialogAttributesUseCustomPalette = 0x00000040, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesRTLRO"]/*' /> msidbDialogAttributesRTLRO = 0x00000080, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesRightAligned"]/*' /> msidbDialogAttributesRightAligned = 0x00000100, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesLeftScroll"]/*' /> msidbDialogAttributesLeftScroll = 0x00000200, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesBiDi"]/*' /> msidbDialogAttributesBiDi = msidbDialogAttributesRTLRO | msidbDialogAttributesRightAligned | msidbDialogAttributesLeftScroll, /// <include file='msidbDialogAttributes.xml' path='doc/member[@name="msidbDialogAttributes.msidbDialogAttributesError"]/*' /> msidbDialogAttributesError = 0x00010000, }
58.744681
145
0.777255
[ "MIT" ]
IngmarBitter/terrafx.interop.windows
sources/Interop/Windows/Windows/um/MsiDefs/msidbDialogAttributes.cs
2,763
C#
 using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Sunctum.Domain.Logic.DisplayType { public interface IDisplayType { System.Windows.Controls.ViewBase Get(); } }
16.3125
47
0.735632
[ "MIT" ]
dhq-boiler/Sunctum
Sunctum.Domain/Logic/DisplayType/IDisplayType.cs
263
C#
/* Copyright 2006 Jerry Huxtable Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ using System; using GeoAPI.Geometries; using Proj4Net.Datum; using Proj4Net.Utility; namespace Proj4Net.Projection { public class LambertConformalConicProjection : ConicProjection { private double n; private double rho0; private double c; public LambertConformalConicProjection() { MinLatitude = ProjectionMath.ToRadians(0); MaxLatitude = ProjectionMath.ToRadians(80.0); ProjectionLatitude = ProjectionMath.PiFourth; ProjectionLatitude1 = 0; ProjectionLatitude2 = 0; Initialize(); } /** * Set up a projection suitable for State Place Coordinates. */ public LambertConformalConicProjection(Ellipsoid ellipsoid, double lon_0, double lat_1, double lat_2, double lat_0, double x_0, double y_0) { Ellipsoid = ellipsoid; ProjectionLongitude = lon_0; ProjectionLatitude = lat_0; ScaleFactor = 1.0; FalseEasting = x_0; FalseNorthing = y_0; ProjectionLatitude1 = lat_1; ProjectionLatitude2 = lat_2; Initialize(); } public override Coordinate Project(double x, double y, Coordinate coord) { double rho; if (Math.Abs(Math.Abs(y) - ProjectionMath.PiHalf) < 1e-10) rho = 0.0; else { rho = c * (Spherical ? Math.Pow(Math.Tan(ProjectionMath.PiFourth + .5 * y), -n) : Math.Pow(ProjectionMath.tsfn(y, Math.Sin(y), Eccentricity), n)); } coord.X = ScaleFactor * (rho * Math.Sin(x *= n)); coord.Y = ScaleFactor * (rho0 - rho * Math.Cos(x)); return coord; } public override Coordinate ProjectInverse(double x, double y, Coordinate coord) { x /= ScaleFactor; y /= ScaleFactor; double rho = ProjectionMath.Distance(x, y = rho0 - y); if (rho != 0) { if (n < 0.0) { rho = -rho; x = -x; y = -y; } if (Spherical) coord.Y = 2.0 * Math.Atan(Math.Pow(c / rho, 1.0 / n)) - ProjectionMath.PiHalf; else coord.Y = ProjectionMath.Phi2(Math.Pow(rho / c, 1.0 / n), Eccentricity); coord.X = Math.Atan2(x, y) / n; } else { coord.X = 0.0; coord.Y = n > 0.0 ? ProjectionMath.PiHalf : -ProjectionMath.PiHalf; } return coord; } public override void Initialize() { base.Initialize(); double cosphi, sinphi; Boolean secant; if (ProjectionLatitude1 == 0) ProjectionLatitude1 = ProjectionLatitude2 = ProjectionLatitude; if (Math.Abs(ProjectionLatitude1 + ProjectionLatitude2) < 1e-10) throw new ProjectionException(); n = sinphi = Math.Sin(ProjectionLatitude1); cosphi = Math.Cos(ProjectionLatitude1); secant = Math.Abs(ProjectionLatitude1 - ProjectionLatitude2) >= 1e-10; _spherical = (EccentricitySquared == 0.0); if (!Spherical) { double ml1, m1; m1 = ProjectionMath.msfn(sinphi, cosphi, EccentricitySquared); ml1 = ProjectionMath.tsfn(ProjectionLatitude1, sinphi, Eccentricity); if (secant) { n = Math.Log(m1 / ProjectionMath.msfn(sinphi = Math.Sin(ProjectionLatitude2), Math.Cos(ProjectionLatitude2), EccentricitySquared)); n /= Math.Log(ml1 / ProjectionMath.tsfn(ProjectionLatitude2, sinphi, Eccentricity)); } c = (rho0 = m1 * Math.Pow(ml1, -n) / n); rho0 *= (Math.Abs(Math.Abs(ProjectionLatitude) - ProjectionMath.PiHalf) < 1e-10) ? 0.0 : Math.Pow(ProjectionMath.tsfn(ProjectionLatitude, Math.Sin(ProjectionLatitude), Eccentricity), n); } else { if (secant) n = Math.Log(cosphi / Math.Cos(ProjectionLatitude2)) / Math.Log(Math.Tan(ProjectionMath.PiFourth + .5 * ProjectionLatitude2) / Math.Tan(ProjectionMath.PiFourth + .5 * ProjectionLatitude1)); c = cosphi * Math.Pow(Math.Tan(ProjectionMath.PiFourth + .5 * ProjectionLatitude1), n) / n; rho0 = (Math.Abs(Math.Abs(ProjectionLatitude) - ProjectionMath.PiHalf) < 1e-10) ? 0.0 : c * Math.Pow(Math.Tan(ProjectionMath.PiFourth + .5 * ProjectionLatitude), -n); } } /// <summary> /// Gets a value indicating whether this projection is conformal /// </summary> public override Boolean IsConformal { get { return true; } } /// <summary> /// Gets a value indicating whether this projection has an inverse /// </summary> public override Boolean HasInverse { get { return true; } } public override String ToString() { return "Lambert Conformal Conic"; } } }
36.283133
147
0.545741
[ "Apache-2.0" ]
jugstalt/gview5
gView.Proj/Proj4Net/Projection/LambertConformalConicProjection.cs
6,023
C#
// Copyright (c) .NET Foundation. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; using System.Collections.Generic; using System.ComponentModel; using System.Diagnostics; using System.Linq; using System.Linq.Expressions; using System.Threading; using System.Threading.Tasks; using JetBrains.Annotations; using Microsoft.EntityFrameworkCore.ChangeTracking; using Microsoft.EntityFrameworkCore.ChangeTracking.Internal; using Microsoft.EntityFrameworkCore.Diagnostics; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Internal; using Microsoft.EntityFrameworkCore.Metadata; using Microsoft.EntityFrameworkCore.Query; using Microsoft.EntityFrameworkCore.Utilities; using Microsoft.Extensions.DependencyInjection; namespace Microsoft.EntityFrameworkCore { /// <summary> /// A DbContext instance represents a session with the database and can be used to query and save /// instances of your entities. DbContext is a combination of the Unit Of Work and Repository patterns. /// </summary> /// <remarks> /// <para> /// Typically you create a class that derives from DbContext and contains <see cref="DbSet{TEntity}" /> /// properties for each entity in the model. If the <see cref="DbSet{TEntity}" /> properties have a public setter, /// they are automatically initialized when the instance of the derived context is created. /// </para> /// <para> /// Override the <see cref="OnConfiguring(DbContextOptionsBuilder)" /> method to configure the database (and /// other options) to be used for the context. Alternatively, if you would rather perform configuration externally /// instead of inline in your context, you can use <see cref="DbContextOptionsBuilder{TContext}" /> /// (or <see cref="DbContextOptionsBuilder" />) to externally create an instance of <see cref="DbContextOptions{TContext}" /> /// (or <see cref="DbContextOptions" />) and pass it to a base constructor of <see cref="DbContext" />. /// </para> /// <para> /// The model is discovered by running a set of conventions over the entity classes found in the /// <see cref="DbSet{TEntity}" /> properties on the derived context. To further configure the model that /// is discovered by convention, you can override the <see cref="OnModelCreating(ModelBuilder)" /> method. /// </para> /// </remarks> public class DbContext : IDisposable, IAsyncDisposable, IInfrastructure<IServiceProvider>, IDbContextDependencies, IDbSetCache, IDbContextPoolable { private IDictionary<(Type Type, string Name), object> _sets; private readonly DbContextOptions _options; private IDbContextServices _contextServices; private IDbContextDependencies _dbContextDependencies; private DatabaseFacade _database; private ChangeTracker _changeTracker; private IServiceScope _serviceScope; private DbContextLease _lease = DbContextLease.InactiveLease; private DbContextPoolConfigurationSnapshot _configurationSnapshot; private bool _initializing; private bool _disposed; private readonly Guid _contextId = Guid.NewGuid(); private int _leaseCount; /// <summary> /// <para> /// Initializes a new instance of the <see cref="DbContext" /> class. The /// <see cref="OnConfiguring(DbContextOptionsBuilder)" /> /// method will be called to configure the database (and other options) to be used for this context. /// </para> /// </summary> protected DbContext() : this(new DbContextOptions<DbContext>()) { } /// <summary> /// <para> /// Initializes a new instance of the <see cref="DbContext" /> class using the specified options. /// The <see cref="OnConfiguring(DbContextOptionsBuilder)" /> method will still be called to allow further /// configuration of the options. /// </para> /// </summary> /// <param name="options">The options for this context.</param> public DbContext([NotNull] DbContextOptions options) { Check.NotNull(options, nameof(options)); if (!options.ContextType.IsAssignableFrom(GetType())) { throw new InvalidOperationException(CoreStrings.NonGenericOptions(GetType().ShortDisplayName())); } _options = options; // This service is not stored in _setInitializer as this may not be the service provider that will be used // as the internal service provider going forward, because at this time OnConfiguring has not yet been called. // Mostly that isn't a problem because set initialization is done by our internal services, but in the case // where some of those services are replaced, this could initialize set using non-replaced services. // In this rare case if this is a problem for the app, then the app can just not use this mechanism to create // DbSet instances, and this code becomes a no-op. However, if this set initializer is then saved and used later // for the Set method, then it makes the problem bigger because now an app is using the non-replaced services // even when it doesn't need to. ServiceProviderCache.Instance.GetOrAdd(options, providerRequired: false) .GetRequiredService<IDbSetInitializer>() .InitializeSets(this); EntityFrameworkEventSource.Log.DbContextInitializing(); } /// <summary> /// Provides access to database related information and operations for this context. /// </summary> public virtual DatabaseFacade Database { get { CheckDisposed(); return _database ??= new DatabaseFacade(this); } } /// <summary> /// Provides access to information and operations for entity instances this context is tracking. /// </summary> public virtual ChangeTracker ChangeTracker => _changeTracker ??= InternalServiceProvider.GetRequiredService<IChangeTrackerFactory>().Create(); /// <summary> /// The metadata about the shape of entities, the relationships between them, and how they map to the database. /// </summary> public virtual IModel Model { [DebuggerStepThrough] get => DbContextDependencies.Model; } /// <summary> /// <para> /// A unique identifier for the context instance and pool lease, if any. /// </para> /// <para> /// This identifier is primarily intended as a correlation ID for logging and debugging such /// that it is easy to identify that multiple events are using the same or different context instances. /// </para> /// </summary> public virtual DbContextId ContextId => new(_contextId, _leaseCount); /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IDbSetSource IDbContextDependencies.SetSource => DbContextDependencies.SetSource; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IEntityFinderFactory IDbContextDependencies.EntityFinderFactory => DbContextDependencies.EntityFinderFactory; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IAsyncQueryProvider IDbContextDependencies.QueryProvider => DbContextDependencies.QueryProvider; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IStateManager IDbContextDependencies.StateManager => DbContextDependencies.StateManager; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IChangeDetector IDbContextDependencies.ChangeDetector => DbContextDependencies.ChangeDetector; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IEntityGraphAttacher IDbContextDependencies.EntityGraphAttacher => DbContextDependencies.EntityGraphAttacher; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IDiagnosticsLogger<DbLoggerCategory.Update> IDbContextDependencies.UpdateLogger => DbContextDependencies.UpdateLogger; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] IDiagnosticsLogger<DbLoggerCategory.Infrastructure> IDbContextDependencies.InfrastructureLogger => DbContextDependencies.InfrastructureLogger; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] object IDbSetCache.GetOrAddSet(IDbSetSource source, Type type) { CheckDisposed(); if (_sets == null) { _sets = new Dictionary<(Type Type, string Name), object>(); } if (!_sets.TryGetValue((type, null), out var set)) { set = source.Create(this, type); _sets[(type, null)] = set; } return set; } /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] object IDbSetCache.GetOrAddSet(IDbSetSource source, string entityTypeName, Type type) { CheckDisposed(); if (_sets == null) { _sets = new Dictionary<(Type Type, string Name), object>(); } if (!_sets.TryGetValue((type, entityTypeName), out var set)) { set = source.Create(this, entityTypeName, type); _sets[(type, entityTypeName)] = set; } return set; } /// <summary> /// Creates a <see cref="DbSet{TEntity}" /> that can be used to query and save instances of <typeparamref name="TEntity" />. /// </summary> /// <typeparam name="TEntity"> The type of entity for which a set should be returned. </typeparam> /// <returns> A set for the given entity type. </returns> public virtual DbSet<TEntity> Set<TEntity>() where TEntity : class => (DbSet<TEntity>)((IDbSetCache)this).GetOrAddSet(DbContextDependencies.SetSource, typeof(TEntity)); /// <summary> /// Creates a <see cref="DbSet{TEntity}" /> that can be used to query and save instances of <typeparamref name="TEntity" />. /// </summary> /// <typeparam name="TEntity"> The type of entity for which a set should be returned. </typeparam> /// <returns> A set for the given entity type. </returns> public virtual DbSet<TEntity> Set<TEntity>([NotNull] string name) where TEntity : class => (DbSet<TEntity>)((IDbSetCache)this).GetOrAddSet(DbContextDependencies.SetSource, name, typeof(TEntity)); private IEntityFinder Finder(Type type) { var entityType = Model.FindEntityType(type); if (entityType == null) { if (Model.IsShared(type)) { throw new InvalidOperationException(CoreStrings.InvalidSetSharedType(type.ShortDisplayName())); } throw new InvalidOperationException(CoreStrings.InvalidSetType(type.ShortDisplayName())); } if (entityType.FindPrimaryKey() == null) { throw new InvalidOperationException(CoreStrings.InvalidSetKeylessOperation(type.ShortDisplayName())); } return DbContextDependencies.EntityFinderFactory.Create(entityType); } private IServiceProvider InternalServiceProvider { get { CheckDisposed(); if (_contextServices != null) { return _contextServices.InternalServiceProvider; } if (_initializing) { throw new InvalidOperationException(CoreStrings.RecursiveOnConfiguring); } try { _initializing = true; var optionsBuilder = new DbContextOptionsBuilder(_options); OnConfiguring(optionsBuilder); if (_options.IsFrozen && !ReferenceEquals(_options, optionsBuilder.Options)) { throw new InvalidOperationException(CoreStrings.PoolingOptionsModified); } var options = optionsBuilder.Options; _serviceScope = ServiceProviderCache.Instance.GetOrAdd(options, providerRequired: true) .GetRequiredService<IServiceScopeFactory>() .CreateScope(); var scopedServiceProvider = _serviceScope.ServiceProvider; var contextServices = scopedServiceProvider.GetService<IDbContextServices>(); contextServices.Initialize(scopedServiceProvider, options, this); _contextServices = contextServices; DbContextDependencies.InfrastructureLogger.ContextInitialized(this, options); } finally { _initializing = false; } return _contextServices.InternalServiceProvider; } } private IDbContextDependencies DbContextDependencies { [DebuggerStepThrough] get { CheckDisposed(); return _dbContextDependencies ??= InternalServiceProvider.GetRequiredService<IDbContextDependencies>(); } } [DebuggerStepThrough] private void CheckDisposed() { if (_disposed) { throw new ObjectDisposedException(GetType().ShortDisplayName(), CoreStrings.ContextDisposed); } } /// <summary> /// <para> /// Override this method to configure the database (and other options) to be used for this context. /// This method is called for each instance of the context that is created. /// The base implementation does nothing. /// </para> /// <para> /// In situations where an instance of <see cref="DbContextOptions" /> may or may not have been passed /// to the constructor, you can use <see cref="DbContextOptionsBuilder.IsConfigured" /> to determine if /// the options have already been set, and skip some or all of the logic in /// <see cref="OnConfiguring(DbContextOptionsBuilder)" />. /// </para> /// </summary> /// <param name="optionsBuilder"> /// A builder used to create or modify options for this context. Databases (and other extensions) /// typically define extension methods on this object that allow you to configure the context. /// </param> protected internal virtual void OnConfiguring(DbContextOptionsBuilder optionsBuilder) { } /// <summary> /// Override this method to further configure the model that was discovered by convention from the entity types /// exposed in <see cref="DbSet{TEntity}" /> properties on your derived context. The resulting model may be cached /// and re-used for subsequent instances of your derived context. /// </summary> /// <remarks> /// If a model is explicitly set on the options for this context (via <see cref="DbContextOptionsBuilder.UseModel(IModel)" />) /// then this method will not be run. /// </remarks> /// <param name="modelBuilder"> /// The builder being used to construct the model for this context. Databases (and other extensions) typically /// define extension methods on this object that allow you to configure aspects of the model that are specific /// to a given database. /// </param> protected internal virtual void OnModelCreating(ModelBuilder modelBuilder) { } /// <summary> /// <para> /// Saves all changes made in this context to the database. /// </para> /// <para> /// This method will automatically call <see cref="ChangeTracker.DetectChanges" /> to discover any /// changes to entity instances before saving to the underlying database. This can be disabled via /// <see cref="ChangeTracker.AutoDetectChangesEnabled" />. /// </para> /// </summary> /// <returns> /// The number of state entries written to the database. /// </returns> /// <exception cref="DbUpdateException"> /// An error is encountered while saving to the database. /// </exception> /// <exception cref="DbUpdateConcurrencyException"> /// A concurrency violation is encountered while saving to the database. /// A concurrency violation occurs when an unexpected number of rows are affected during save. /// This is usually because the data in the database has been modified since it was loaded into memory. /// </exception> public virtual int SaveChanges() => SaveChanges(acceptAllChangesOnSuccess: true); /// <summary> /// <para> /// Saves all changes made in this context to the database. /// </para> /// <para> /// This method will automatically call <see cref="ChangeTracker.DetectChanges" /> to discover any /// changes to entity instances before saving to the underlying database. This can be disabled via /// <see cref="ChangeTracker.AutoDetectChangesEnabled" />. /// </para> /// </summary> /// <param name="acceptAllChangesOnSuccess"> /// Indicates whether <see cref="ChangeTracker.AcceptAllChanges" /> is called after the changes have /// been sent successfully to the database. /// </param> /// <returns> /// The number of state entries written to the database. /// </returns> /// <exception cref="DbUpdateException"> /// An error is encountered while saving to the database. /// </exception> /// <exception cref="DbUpdateConcurrencyException"> /// A concurrency violation is encountered while saving to the database. /// A concurrency violation occurs when an unexpected number of rows are affected during save. /// This is usually because the data in the database has been modified since it was loaded into memory. /// </exception> public virtual int SaveChanges(bool acceptAllChangesOnSuccess) { CheckDisposed(); SavingChanges?.Invoke(this, new SavingChangesEventArgs(acceptAllChangesOnSuccess)); var interceptionResult = DbContextDependencies.UpdateLogger.SaveChangesStarting(this); TryDetectChanges(); try { var entitiesSaved = interceptionResult.HasResult ? interceptionResult.Result : DbContextDependencies.StateManager.SaveChanges(acceptAllChangesOnSuccess); var result = DbContextDependencies.UpdateLogger.SaveChangesCompleted(this, entitiesSaved); SavedChanges?.Invoke(this, new SavedChangesEventArgs(acceptAllChangesOnSuccess, result)); return result; } catch (DbUpdateConcurrencyException exception) { EntityFrameworkEventSource.Log.OptimisticConcurrencyFailure(); DbContextDependencies.UpdateLogger.OptimisticConcurrencyException(this, exception); SaveChangesFailed?.Invoke(this, new SaveChangesFailedEventArgs(acceptAllChangesOnSuccess, exception)); throw; } catch (Exception exception) { DbContextDependencies.UpdateLogger.SaveChangesFailed(this, exception); SaveChangesFailed?.Invoke(this, new SaveChangesFailedEventArgs(acceptAllChangesOnSuccess, exception)); throw; } } private void TryDetectChanges() { if (ChangeTracker.AutoDetectChangesEnabled) { ChangeTracker.DetectChanges(); } } private void TryDetectChanges(EntityEntry entry) { if (ChangeTracker.AutoDetectChangesEnabled) { entry.DetectChanges(); } } /// <summary> /// <para> /// Saves all changes made in this context to the database. /// </para> /// <para> /// This method will automatically call <see cref="ChangeTracker.DetectChanges" /> to discover any /// changes to entity instances before saving to the underlying database. This can be disabled via /// <see cref="ChangeTracker.AutoDetectChangesEnabled" />. /// </para> /// <para> /// Multiple active operations on the same context instance are not supported. Use <see langword="await" /> to ensure /// that any asynchronous operations have completed before calling another method on this context. /// </para> /// </summary> /// <param name="cancellationToken"> A <see cref="CancellationToken" /> to observe while waiting for the task to complete. </param> /// <returns> /// A task that represents the asynchronous save operation. The task result contains the /// number of state entries written to the database. /// </returns> /// <exception cref="DbUpdateException"> /// An error is encountered while saving to the database. /// </exception> /// <exception cref="DbUpdateConcurrencyException"> /// A concurrency violation is encountered while saving to the database. /// A concurrency violation occurs when an unexpected number of rows are affected during save. /// This is usually because the data in the database has been modified since it was loaded into memory. /// </exception> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual Task<int> SaveChangesAsync(CancellationToken cancellationToken = default) => SaveChangesAsync(acceptAllChangesOnSuccess: true, cancellationToken: cancellationToken); /// <summary> /// <para> /// Saves all changes made in this context to the database. /// </para> /// <para> /// This method will automatically call <see cref="ChangeTracker.DetectChanges" /> to discover any /// changes to entity instances before saving to the underlying database. This can be disabled via /// <see cref="ChangeTracker.AutoDetectChangesEnabled" />. /// </para> /// <para> /// Multiple active operations on the same context instance are not supported. Use <see langword="await" /> to ensure /// that any asynchronous operations have completed before calling another method on this context. /// </para> /// </summary> /// <param name="acceptAllChangesOnSuccess"> /// Indicates whether <see cref="ChangeTracker.AcceptAllChanges" /> is called after the changes have /// been sent successfully to the database. /// </param> /// <param name="cancellationToken"> A <see cref="CancellationToken" /> to observe while waiting for the task to complete. </param> /// <returns> /// A task that represents the asynchronous save operation. The task result contains the /// number of state entries written to the database. /// </returns> /// <exception cref="DbUpdateException"> /// An error is encountered while saving to the database. /// </exception> /// <exception cref="DbUpdateConcurrencyException"> /// A concurrency violation is encountered while saving to the database. /// A concurrency violation occurs when an unexpected number of rows are affected during save. /// This is usually because the data in the database has been modified since it was loaded into memory. /// </exception> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual async Task<int> SaveChangesAsync( bool acceptAllChangesOnSuccess, CancellationToken cancellationToken = default) { CheckDisposed(); SavingChanges?.Invoke(this, new SavingChangesEventArgs(acceptAllChangesOnSuccess)); var interceptionResult = await DbContextDependencies.UpdateLogger .SaveChangesStartingAsync(this, cancellationToken).ConfigureAwait(false); TryDetectChanges(); try { var entitiesSaved = interceptionResult.HasResult ? interceptionResult.Result : await DbContextDependencies.StateManager .SaveChangesAsync(acceptAllChangesOnSuccess, cancellationToken) .ConfigureAwait(false); var result = await DbContextDependencies.UpdateLogger .SaveChangesCompletedAsync(this, entitiesSaved, cancellationToken) .ConfigureAwait(false); SavedChanges?.Invoke(this, new SavedChangesEventArgs(acceptAllChangesOnSuccess, result)); return result; } catch (DbUpdateConcurrencyException exception) { EntityFrameworkEventSource.Log.OptimisticConcurrencyFailure(); await DbContextDependencies.UpdateLogger.OptimisticConcurrencyExceptionAsync(this, exception, cancellationToken) .ConfigureAwait(false); SaveChangesFailed?.Invoke(this, new SaveChangesFailedEventArgs(acceptAllChangesOnSuccess, exception)); throw; } catch (Exception exception) { await DbContextDependencies.UpdateLogger.SaveChangesFailedAsync(this, exception, cancellationToken).ConfigureAwait(false); SaveChangesFailed?.Invoke(this, new SaveChangesFailedEventArgs(acceptAllChangesOnSuccess, exception)); throw; } } /// <summary> /// An event fired at the beginning of a call to <see cref="M:SaveChanges" /> or <see cref="M:SaveChangesAsync" /> /// </summary> public event EventHandler<SavingChangesEventArgs> SavingChanges; /// <summary> /// An event fired at the end of a call to <see cref="M:SaveChanges" /> or <see cref="M:SaveChangesAsync" /> /// </summary> public event EventHandler<SavedChangesEventArgs> SavedChanges; /// <summary> /// An event fired if a call to <see cref="M:SaveChanges" /> or <see cref="M:SaveChangesAsync" /> fails with an exception. /// </summary> public event EventHandler<SaveChangesFailedEventArgs> SaveChangesFailed; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] void IDbContextPoolable.ClearLease() => _lease = DbContextLease.InactiveLease; /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] void IDbContextPoolable.SetLease(DbContextLease lease) { _lease = lease; _disposed = false; ++_leaseCount; if (_configurationSnapshot?.AutoDetectChangesEnabled != null) { Check.DebugAssert( _configurationSnapshot.QueryTrackingBehavior.HasValue, "!configurationSnapshot.QueryTrackingBehavior.HasValue"); Check.DebugAssert(_configurationSnapshot.LazyLoadingEnabled.HasValue, "!configurationSnapshot.LazyLoadingEnabled.HasValue"); Check.DebugAssert( _configurationSnapshot.CascadeDeleteTiming.HasValue, "!configurationSnapshot.CascadeDeleteTiming.HasValue"); Check.DebugAssert( _configurationSnapshot.DeleteOrphansTiming.HasValue, "!configurationSnapshot.DeleteOrphansTiming.HasValue"); ChangeTracker.AutoDetectChangesEnabled = _configurationSnapshot.AutoDetectChangesEnabled.Value; ChangeTracker.QueryTrackingBehavior = _configurationSnapshot.QueryTrackingBehavior.Value; ChangeTracker.LazyLoadingEnabled = _configurationSnapshot.LazyLoadingEnabled.Value; ChangeTracker.CascadeDeleteTiming = _configurationSnapshot.CascadeDeleteTiming.Value; ChangeTracker.DeleteOrphansTiming = _configurationSnapshot.DeleteOrphansTiming.Value; } else { ((IResettableService)_changeTracker)?.ResetState(); } if (_database != null) { _database.AutoTransactionsEnabled = _configurationSnapshot?.AutoTransactionsEnabled == null || _configurationSnapshot.AutoTransactionsEnabled.Value; _database.AutoSavepointsEnabled = _configurationSnapshot?.AutoSavepointsEnabled == null || _configurationSnapshot.AutoSavepointsEnabled.Value; } } /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] void IDbContextPoolable.SnapshotConfiguration() => _configurationSnapshot = new DbContextPoolConfigurationSnapshot( _changeTracker?.AutoDetectChangesEnabled, _changeTracker?.QueryTrackingBehavior, _database?.AutoTransactionsEnabled, _database?.AutoSavepointsEnabled, _changeTracker?.LazyLoadingEnabled, _changeTracker?.CascadeDeleteTiming, _changeTracker?.DeleteOrphansTiming); /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] void IResettableService.ResetState() { foreach (var service in GetResettableServices()) { service.ResetState(); } ClearEvents(); _disposed = true; } /// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> [EntityFrameworkInternal] async Task IResettableService.ResetStateAsync(CancellationToken cancellationToken) { foreach (var service in GetResettableServices()) { await service.ResetStateAsync(cancellationToken).ConfigureAwait(false); } ClearEvents(); _disposed = true; } private IEnumerable<IResettableService> GetResettableServices() { var resettableServices = _contextServices?.InternalServiceProvider? .GetService<IEnumerable<IResettableService>>()?.ToList(); if (resettableServices != null) { foreach (var service in resettableServices) { yield return service; } } if (_sets != null) { foreach (var set in _sets.Values) { if (set is IResettableService resettable) { yield return resettable; } } } } /// <summary> /// Releases the allocated resources for this context. /// </summary> public virtual void Dispose() { if (DisposeSync()) { _serviceScope?.Dispose(); } } private bool DisposeSync() { if (_lease.IsActive) { if (_lease.ContextDisposed()) { _disposed = true; ClearEvents(); _lease = DbContextLease.InactiveLease; } } else if (!_disposed) { EntityFrameworkEventSource.Log.DbContextDisposing(); _dbContextDependencies?.InfrastructureLogger.ContextDisposed(this); _disposed = true; _dbContextDependencies?.StateManager.Unsubscribe(); _dbContextDependencies = null; _changeTracker = null; _database = null; ClearEvents(); return true; } return false; } /// <summary> /// Releases the allocated resources for this context. /// </summary> public virtual ValueTask DisposeAsync() => DisposeSync() ? _serviceScope.DisposeAsyncIfAvailable() : default; private void ClearEvents() { SavingChanges = null; SavedChanges = null; SaveChangesFailed = null; } /// <summary> /// Gets an <see cref="EntityEntry{TEntity}" /> for the given entity. The entry provides /// access to change tracking information and operations for the entity. /// </summary> /// <typeparam name="TEntity"> The type of the entity. </typeparam> /// <param name="entity"> The entity to get the entry for. </param> /// <returns> The entry for the given entity. </returns> public virtual EntityEntry<TEntity> Entry<TEntity>([NotNull] TEntity entity) where TEntity : class { Check.NotNull(entity, nameof(entity)); CheckDisposed(); var entry = EntryWithoutDetectChanges(entity); TryDetectChanges(entry); return entry; } private EntityEntry<TEntity> EntryWithoutDetectChanges<TEntity>(TEntity entity) where TEntity : class => new(DbContextDependencies.StateManager.GetOrCreateEntry(entity)); /// <summary> /// <para> /// Gets an <see cref="EntityEntry" /> for the given entity. The entry provides /// access to change tracking information and operations for the entity. /// </para> /// <para> /// This method may be called on an entity that is not tracked. You can then /// set the <see cref="EntityEntry.State" /> property on the returned entry /// to have the context begin tracking the entity in the specified state. /// </para> /// </summary> /// <param name="entity"> The entity to get the entry for. </param> /// <returns> The entry for the given entity. </returns> public virtual EntityEntry Entry([NotNull] object entity) { Check.NotNull(entity, nameof(entity)); CheckDisposed(); var entry = EntryWithoutDetectChanges(entity); TryDetectChanges(entry); return entry; } private EntityEntry EntryWithoutDetectChanges(object entity) => new(DbContextDependencies.StateManager.GetOrCreateEntry(entity)); private void SetEntityState(InternalEntityEntry entry, EntityState entityState) { if (entry.EntityState == EntityState.Detached) { DbContextDependencies.EntityGraphAttacher.AttachGraph( entry, entityState, entityState, forceStateWhenUnknownKey: true); } else { entry.SetEntityState( entityState, acceptChanges: true, forceStateWhenUnknownKey: entityState); } } private Task SetEntityStateAsync( InternalEntityEntry entry, EntityState entityState, CancellationToken cancellationToken) { return entry.EntityState == EntityState.Detached ? DbContextDependencies.EntityGraphAttacher.AttachGraphAsync( entry, entityState, entityState, forceStateWhenUnknownKey: true, cancellationToken: cancellationToken) : entry.SetEntityStateAsync( entityState, acceptChanges: true, forceStateWhenUnknownKey: entityState, cancellationToken: cancellationToken); } /// <summary> /// <para> /// Begins tracking the given entity, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that /// they will be inserted into the database when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <typeparam name="TEntity"> The type of the entity. </typeparam> /// <param name="entity"> The entity to add. </param> /// <returns> /// The <see cref="EntityEntry{TEntity}" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry<TEntity> Add<TEntity>([NotNull] TEntity entity) where TEntity : class { CheckDisposed(); return SetEntityState(Check.NotNull(entity, nameof(entity)), EntityState.Added); } /// <summary> /// <para> /// Begins tracking the given entity, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// This method is async only to allow special value generators, such as the one used by /// 'Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy.SequenceHiLo', /// to access the database asynchronously. For all other cases the non async method should be used. /// </para> /// </summary> /// <typeparam name="TEntity"> The type of the entity. </typeparam> /// <param name="entity"> The entity to add. </param> /// <param name="cancellationToken">A <see cref="CancellationToken" /> to observe while waiting for the task to complete.</param> /// <returns> /// A task that represents the asynchronous Add operation. The task result contains the /// <see cref="EntityEntry{TEntity}" /> for the entity. The entry provides access to change tracking /// information and operations for the entity. /// </returns> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual async ValueTask<EntityEntry<TEntity>> AddAsync<TEntity>( [NotNull] TEntity entity, CancellationToken cancellationToken = default) where TEntity : class { CheckDisposed(); var entry = EntryWithoutDetectChanges(Check.NotNull(entity, nameof(entity))); await SetEntityStateAsync(entry.GetInfrastructure(), EntityState.Added, cancellationToken) .ConfigureAwait(false); return entry; } /// <summary> /// <para> /// Begins tracking the given entity and entries reachable from the given entity using /// the <see cref="EntityState.Unchanged" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Unchanged" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure only new entities will be inserted. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Unchanged" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <typeparam name="TEntity"> The type of the entity. </typeparam> /// <param name="entity"> The entity to attach. </param> /// <returns> /// The <see cref="EntityEntry{TEntity}" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry<TEntity> Attach<TEntity>([NotNull] TEntity entity) where TEntity : class { CheckDisposed(); return SetEntityState(Check.NotNull(entity, nameof(entity)), EntityState.Unchanged); } /// <summary> /// <para> /// Begins tracking the given entity and entries reachable from the given entity using /// the <see cref="EntityState.Modified" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Modified" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure new entities will be inserted, while existing entities will be updated. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Modified" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <typeparam name="TEntity"> The type of the entity. </typeparam> /// <param name="entity"> The entity to update. </param> /// <returns> /// The <see cref="EntityEntry{TEntity}" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry<TEntity> Update<TEntity>([NotNull] TEntity entity) where TEntity : class { CheckDisposed(); return SetEntityState(Check.NotNull(entity, nameof(entity)), EntityState.Modified); } /// <summary> /// Begins tracking the given entity in the <see cref="EntityState.Deleted" /> state such that it will /// be removed from the database when <see cref="SaveChanges()" /> is called. /// </summary> /// <remarks> /// <para> /// If the entity is already tracked in the <see cref="EntityState.Added" /> state then the context will /// stop tracking the entity (rather than marking it as <see cref="EntityState.Deleted" />) since the /// entity was previously added to the context and does not exist in the database. /// </para> /// <para> /// Any other reachable entities that are not already being tracked will be tracked in the same way that /// they would be if <see cref="Attach{TEntity}(TEntity)" /> was called before calling this method. /// This allows any cascading actions to be applied when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </remarks> /// <typeparam name="TEntity"> The type of the entity. </typeparam> /// <param name="entity"> The entity to remove. </param> /// <returns> /// The <see cref="EntityEntry{TEntity}" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry<TEntity> Remove<TEntity>([NotNull] TEntity entity) where TEntity : class { Check.NotNull(entity, nameof(entity)); CheckDisposed(); var entry = EntryWithoutDetectChanges(entity); var initialState = entry.State; if (initialState == EntityState.Detached) { SetEntityState(entry.GetInfrastructure(), EntityState.Unchanged); } // An Added entity does not yet exist in the database. If it is then marked as deleted there is // nothing to delete because it was not yet inserted, so just make sure it doesn't get inserted. entry.State = initialState == EntityState.Added ? EntityState.Detached : EntityState.Deleted; return entry; } private EntityEntry<TEntity> SetEntityState<TEntity>( TEntity entity, EntityState entityState) where TEntity : class { var entry = EntryWithoutDetectChanges(entity); SetEntityState(entry.GetInfrastructure(), entityState); return entry; } /// <summary> /// <para> /// Begins tracking the given entity, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entity"> The entity to add. </param> /// <returns> /// The <see cref="EntityEntry" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry Add([NotNull] object entity) { CheckDisposed(); return SetEntityState(Check.NotNull(entity, nameof(entity)), EntityState.Added); } /// <summary> /// <para> /// Begins tracking the given entity, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// <para> /// This method is async only to allow special value generators, such as the one used by /// 'Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy.SequenceHiLo', /// to access the database asynchronously. For all other cases the non async method should be used. /// </para> /// </summary> /// <param name="entity"> The entity to add. </param> /// <param name="cancellationToken">A <see cref="CancellationToken" /> to observe while waiting for the task to complete.</param> /// <returns> /// A task that represents the asynchronous Add operation. The task result contains the /// <see cref="EntityEntry" /> for the entity. The entry provides access to change tracking /// information and operations for the entity. /// </returns> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual async ValueTask<EntityEntry> AddAsync( [NotNull] object entity, CancellationToken cancellationToken = default) { CheckDisposed(); var entry = EntryWithoutDetectChanges(Check.NotNull(entity, nameof(entity))); await SetEntityStateAsync(entry.GetInfrastructure(), EntityState.Added, cancellationToken) .ConfigureAwait(false); return entry; } /// <summary> /// <para> /// Begins tracking the given entity and entries reachable from the given entity using /// the <see cref="EntityState.Unchanged" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Unchanged" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure only new entities will be inserted. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Unchanged" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entity"> The entity to attach. </param> /// <returns> /// The <see cref="EntityEntry" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry Attach([NotNull] object entity) { CheckDisposed(); return SetEntityState(Check.NotNull(entity, nameof(entity)), EntityState.Unchanged); } /// <summary> /// <para> /// Begins tracking the given entity and entries reachable from the given entity using /// the <see cref="EntityState.Modified" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Modified" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure new entities will be inserted, while existing entities will be updated. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Modified" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entity"> The entity to update. </param> /// <returns> /// The <see cref="EntityEntry" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry Update([NotNull] object entity) { CheckDisposed(); return SetEntityState(Check.NotNull(entity, nameof(entity)), EntityState.Modified); } /// <summary> /// Begins tracking the given entity in the <see cref="EntityState.Deleted" /> state such that it will /// be removed from the database when <see cref="SaveChanges()" /> is called. /// </summary> /// <remarks> /// <para> /// If the entity is already tracked in the <see cref="EntityState.Added" /> state then the context will /// stop tracking the entity (rather than marking it as <see cref="EntityState.Deleted" />) since the /// entity was previously added to the context and does not exist in the database. /// </para> /// <para> /// Any other reachable entities that are not already being tracked will be tracked in the same way that /// they would be if <see cref="Attach(object)" /> was called before calling this method. /// This allows any cascading actions to be applied when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </remarks> /// <param name="entity"> The entity to remove. </param> /// <returns> /// The <see cref="EntityEntry" /> for the entity. The entry provides /// access to change tracking information and operations for the entity. /// </returns> public virtual EntityEntry Remove([NotNull] object entity) { Check.NotNull(entity, nameof(entity)); CheckDisposed(); var entry = EntryWithoutDetectChanges(entity); var initialState = entry.State; if (initialState == EntityState.Detached) { SetEntityState(entry.GetInfrastructure(), EntityState.Unchanged); } // An Added entity does not yet exist in the database. If it is then marked as deleted there is // nothing to delete because it was not yet inserted, so just make sure it doesn't get inserted. entry.State = initialState == EntityState.Added ? EntityState.Detached : EntityState.Deleted; return entry; } private EntityEntry SetEntityState(object entity, EntityState entityState) { var entry = EntryWithoutDetectChanges(entity); SetEntityState(entry.GetInfrastructure(), entityState); return entry; } /// <summary> /// Begins tracking the given entities, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </summary> /// <param name="entities"> The entities to add. </param> public virtual void AddRange([NotNull] params object[] entities) { CheckDisposed(); AddRange((IEnumerable<object>)entities); } /// <summary> /// <para> /// Begins tracking the given entity, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// This method is async only to allow special value generators, such as the one used by /// 'Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy.SequenceHiLo', /// to access the database asynchronously. For all other cases the non async method should be used. /// </para> /// </summary> /// <param name="entities"> The entities to add. </param> /// <returns> A task that represents the asynchronous operation. </returns> public virtual Task AddRangeAsync([NotNull] params object[] entities) { CheckDisposed(); return AddRangeAsync((IEnumerable<object>)entities); } /// <summary> /// <para> /// Begins tracking the given entities and entries reachable from the given entities using /// the <see cref="EntityState.Unchanged" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Unchanged" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure only new entities will be inserted. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Unchanged" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entities"> The entities to attach. </param> public virtual void AttachRange([NotNull] params object[] entities) { CheckDisposed(); AttachRange((IEnumerable<object>)entities); } /// <summary> /// <para> /// Begins tracking the given entities and entries reachable from the given entities using /// the <see cref="EntityState.Modified" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Modified" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure new entities will be inserted, while existing entities will be updated. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Modified" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entities"> The entities to update. </param> public virtual void UpdateRange([NotNull] params object[] entities) { CheckDisposed(); UpdateRange((IEnumerable<object>)entities); } /// <summary> /// Begins tracking the given entity in the <see cref="EntityState.Deleted" /> state such that it will /// be removed from the database when <see cref="SaveChanges()" /> is called. /// </summary> /// <remarks> /// <para> /// If any of the entities are already tracked in the <see cref="EntityState.Added" /> state then the context will /// stop tracking those entities (rather than marking them as <see cref="EntityState.Deleted" />) since those /// entities were previously added to the context and do not exist in the database. /// </para> /// <para> /// Any other reachable entities that are not already being tracked will be tracked in the same way that /// they would be if <see cref="AttachRange(object[])" /> was called before calling this method. /// This allows any cascading actions to be applied when <see cref="SaveChanges()" /> is called. /// </para> /// </remarks> /// <param name="entities"> The entities to remove. </param> public virtual void RemoveRange([NotNull] params object[] entities) { CheckDisposed(); RemoveRange((IEnumerable<object>)entities); } private void SetEntityStates(IEnumerable<object> entities, EntityState entityState) { var stateManager = DbContextDependencies.StateManager; foreach (var entity in entities) { SetEntityState(stateManager.GetOrCreateEntry(entity), entityState); } } /// <summary> /// Begins tracking the given entities, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </summary> /// <param name="entities"> The entities to add. </param> public virtual void AddRange([NotNull] IEnumerable<object> entities) { CheckDisposed(); SetEntityStates(Check.NotNull(entities, nameof(entities)), EntityState.Added); } /// <summary> /// <para> /// Begins tracking the given entity, and any other reachable entities that are /// not already being tracked, in the <see cref="EntityState.Added" /> state such that they will /// be inserted into the database when <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// This method is async only to allow special value generators, such as the one used by /// 'Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy.SequenceHiLo', /// to access the database asynchronously. For all other cases the non async method should be used. /// </para> /// </summary> /// <param name="entities"> The entities to add. </param> /// <param name="cancellationToken">A <see cref="CancellationToken" /> to observe while waiting for the task to complete.</param> /// <returns> /// A task that represents the asynchronous operation. /// </returns> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual async Task AddRangeAsync( [NotNull] IEnumerable<object> entities, CancellationToken cancellationToken = default) { CheckDisposed(); var stateManager = DbContextDependencies.StateManager; foreach (var entity in entities) { await SetEntityStateAsync( stateManager.GetOrCreateEntry(entity), EntityState.Added, cancellationToken) .ConfigureAwait(false); } } /// <summary> /// <para> /// Begins tracking the given entities and entries reachable from the given entities using /// the <see cref="EntityState.Unchanged" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Unchanged" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure only new entities will be inserted. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Unchanged" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entities"> The entities to attach. </param> public virtual void AttachRange([NotNull] IEnumerable<object> entities) { CheckDisposed(); SetEntityStates(Check.NotNull(entities, nameof(entities)), EntityState.Unchanged); } /// <summary> /// <para> /// Begins tracking the given entities and entries reachable from the given entities using /// the <see cref="EntityState.Modified" /> state by default, but see below for cases /// when a different state will be used. /// </para> /// <para> /// Generally, no database interaction will be performed until <see cref="SaveChanges()" /> is called. /// </para> /// <para> /// A recursive search of the navigation properties will be performed to find reachable entities /// that are not already being tracked by the context. All entities found will be tracked /// by the context. /// </para> /// <para> /// For entity types with generated keys if an entity has its primary key value set /// then it will be tracked in the <see cref="EntityState.Modified" /> state. If the primary key /// value is not set then it will be tracked in the <see cref="EntityState.Added" /> state. /// This helps ensure new entities will be inserted, while existing entities will be updated. /// An entity is considered to have its primary key value set if the primary key property is set /// to anything other than the CLR default for the property type. /// </para> /// <para> /// For entity types without generated keys, the state set is always <see cref="EntityState.Modified" />. /// </para> /// <para> /// Use <see cref="EntityEntry.State" /> to set the state of only a single entity. /// </para> /// </summary> /// <param name="entities"> The entities to update. </param> public virtual void UpdateRange([NotNull] IEnumerable<object> entities) { CheckDisposed(); SetEntityStates(Check.NotNull(entities, nameof(entities)), EntityState.Modified); } /// <summary> /// Begins tracking the given entity in the <see cref="EntityState.Deleted" /> state such that it will /// be removed from the database when <see cref="SaveChanges()" /> is called. /// </summary> /// <remarks> /// <para> /// If any of the entities are already tracked in the <see cref="EntityState.Added" /> state then the context will /// stop tracking those entities (rather than marking them as <see cref="EntityState.Deleted" />) since those /// entities were previously added to the context and do not exist in the database. /// </para> /// <para> /// Any other reachable entities that are not already being tracked will be tracked in the same way that /// they would be if <see cref="AttachRange(IEnumerable{object})" /> was called before calling this method. /// This allows any cascading actions to be applied when <see cref="SaveChanges()" /> is called. /// </para> /// </remarks> /// <param name="entities"> The entities to remove. </param> public virtual void RemoveRange([NotNull] IEnumerable<object> entities) { Check.NotNull(entities, nameof(entities)); CheckDisposed(); var stateManager = DbContextDependencies.StateManager; // An Added entity does not yet exist in the database. If it is then marked as deleted there is // nothing to delete because it was not yet inserted, so just make sure it doesn't get inserted. foreach (var entity in entities) { var entry = stateManager.GetOrCreateEntry(entity); var initialState = entry.EntityState; if (initialState == EntityState.Detached) { SetEntityState(entry, EntityState.Unchanged); } entry.SetEntityState( initialState == EntityState.Added ? EntityState.Detached : EntityState.Deleted); } } /// <summary> /// Finds an entity with the given primary key values. If an entity with the given primary key values /// is being tracked by the context, then it is returned immediately without making a request to the /// database. Otherwise, a query is made to the database for an entity with the given primary key values /// and this entity, if found, is attached to the context and returned. If no entity is found, then /// null is returned. /// </summary> /// <param name="entityType"> The type of entity to find. </param> /// <param name="keyValues">The values of the primary key for the entity to be found.</param> /// <returns>The entity found, or <see langword="null" />.</returns> public virtual object Find([NotNull] Type entityType, [CanBeNull] params object[] keyValues) { CheckDisposed(); return Finder(entityType).Find(keyValues); } /// <summary> /// Finds an entity with the given primary key values. If an entity with the given primary key values /// is being tracked by the context, then it is returned immediately without making a request to the /// database. Otherwise, a query is made to the database for an entity with the given primary key values /// and this entity, if found, is attached to the context and returned. If no entity is found, then /// null is returned. /// </summary> /// <param name="entityType"> The type of entity to find. </param> /// <param name="keyValues">The values of the primary key for the entity to be found.</param> /// <returns>The entity found, or <see langword="null" />.</returns> public virtual ValueTask<object> FindAsync([NotNull] Type entityType, [CanBeNull] params object[] keyValues) { CheckDisposed(); return Finder(entityType).FindAsync(keyValues); } /// <summary> /// Finds an entity with the given primary key values. If an entity with the given primary key values /// is being tracked by the context, then it is returned immediately without making a request to the /// database. Otherwise, a query is made to the database for an entity with the given primary key values /// and this entity, if found, is attached to the context and returned. If no entity is found, then /// null is returned. /// </summary> /// <param name="entityType"> The type of entity to find. </param> /// <param name="keyValues">The values of the primary key for the entity to be found.</param> /// <param name="cancellationToken">A <see cref="CancellationToken" /> to observe while waiting for the task to complete.</param> /// <returns>The entity found, or <see langword="null" />.</returns> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual ValueTask<object> FindAsync( [NotNull] Type entityType, [CanBeNull] object[] keyValues, CancellationToken cancellationToken) { CheckDisposed(); return Finder(entityType).FindAsync(keyValues, cancellationToken); } /// <summary> /// Finds an entity with the given primary key values. If an entity with the given primary key values /// is being tracked by the context, then it is returned immediately without making a request to the /// database. Otherwise, a query is made to the database for an entity with the given primary key values /// and this entity, if found, is attached to the context and returned. If no entity is found, then /// null is returned. /// </summary> /// <typeparam name="TEntity"> The type of entity to find. </typeparam> /// <param name="keyValues">The values of the primary key for the entity to be found.</param> /// <returns>The entity found, or <see langword="null" />.</returns> public virtual TEntity Find<TEntity>([CanBeNull] params object[] keyValues) where TEntity : class { CheckDisposed(); return ((IEntityFinder<TEntity>)Finder(typeof(TEntity))).Find(keyValues); } /// <summary> /// Finds an entity with the given primary key values. If an entity with the given primary key values /// is being tracked by the context, then it is returned immediately without making a request to the /// database. Otherwise, a query is made to the database for an entity with the given primary key values /// and this entity, if found, is attached to the context and returned. If no entity is found, then /// null is returned. /// </summary> /// <typeparam name="TEntity"> The type of entity to find. </typeparam> /// <param name="keyValues">The values of the primary key for the entity to be found.</param> /// <returns>The entity found, or <see langword="null" />.</returns> public virtual ValueTask<TEntity> FindAsync<TEntity>([CanBeNull] params object[] keyValues) where TEntity : class { CheckDisposed(); return ((IEntityFinder<TEntity>)Finder(typeof(TEntity))).FindAsync(keyValues); } /// <summary> /// Finds an entity with the given primary key values. If an entity with the given primary key values /// is being tracked by the context, then it is returned immediately without making a request to the /// database. Otherwise, a query is made to the database for an entity with the given primary key values /// and this entity, if found, is attached to the context and returned. If no entity is found, then /// null is returned. /// </summary> /// <typeparam name="TEntity"> The type of entity to find. </typeparam> /// <param name="keyValues">The values of the primary key for the entity to be found.</param> /// <param name="cancellationToken">A <see cref="CancellationToken" /> to observe while waiting for the task to complete.</param> /// <returns>The entity found, or <see langword="null" />.</returns> /// <exception cref="OperationCanceledException"> If the <see cref="CancellationToken"/> is canceled. </exception> public virtual ValueTask<TEntity> FindAsync<TEntity>([CanBeNull] object[] keyValues, CancellationToken cancellationToken) where TEntity : class { CheckDisposed(); return ((IEntityFinder<TEntity>)Finder(typeof(TEntity))).FindAsync(keyValues, cancellationToken); } /// <summary> /// <para> /// Gets the scoped <see cref="IServiceProvider" /> being used to resolve services. /// </para> /// <para> /// This property is intended for use by extension methods that need to make use of services /// not directly exposed in the public API surface. /// </para> /// </summary> IServiceProvider IInfrastructure<IServiceProvider>.Instance => InternalServiceProvider; /// <summary> /// Creates a queryable for given query expression. /// </summary> /// <typeparam name="TResult"> The result type of the query expression. </typeparam> /// <param name="expression"> The query expression to create. </param> /// <returns> An <see cref="IQueryable{T}" /> representing the query. </returns> public virtual IQueryable<TResult> FromExpression<TResult>([NotNull] Expression<Func<IQueryable<TResult>>> expression) { Check.NotNull(expression, nameof(expression)); return DbContextDependencies.QueryProvider.CreateQuery<TResult>(expression.Body); } #region Hidden System.Object members /// <summary> /// Returns a string that represents the current object. /// </summary> /// <returns> A string that represents the current object. </returns> [EditorBrowsable(EditorBrowsableState.Never)] public override string ToString() => base.ToString(); /// <summary> /// Determines whether the specified object is equal to the current object. /// </summary> /// <param name="obj"> The object to compare with the current object. </param> /// <returns> <see langword="true" /> if the specified object is equal to the current object; otherwise, <see langword="false" />. </returns> [EditorBrowsable(EditorBrowsableState.Never)] public override bool Equals(object obj) => base.Equals(obj); /// <summary> /// Serves as the default hash function. /// </summary> /// <returns> A hash code for the current object. </returns> [EditorBrowsable(EditorBrowsableState.Never)] public override int GetHashCode() => base.GetHashCode(); #endregion } }
49.558935
149
0.595026
[ "Apache-2.0" ]
benaadams/efcore
src/EFCore/DbContext.cs
91,238
C#
using System.ComponentModel; namespace FluentBootstrap { public enum FormInputType { [Description("text")] Text, [Description("password")] Password, [Description("datetime")] DateTime, [Description("datetime-local")] DateTimeLocal, [Description("date")] Date, [Description("month")] Month, [Description("time")] Time, [Description("week")] Week, [Description("number")] Number, [Description("email")] Email, [Description("url")] Url, [Description("search")] Search, [Description("tel")] Tel, [Description("color")] Color } }
20.621622
39
0.500655
[ "MIT" ]
burcinsahin/FluentBootstrap
FluentBootstrap/Forms/FormInputType.cs
765
C#
using Base.Utils; using PP_Parser.Parser; namespace PhoenixPoint.Tactical.Levels { public class TacticalFactionVision { public class KnownCounters : PhonixBaseObjectBaseValue { public PhoenixGenericCollection<PhoenixGenericKeyValue<PhoenixEnum, int>> _counters { get; set; } } } }
23.642857
109
0.697885
[ "MIT" ]
realares/Phoenix-Point_SavegameEditor
PWRA_Parser/PhoenixPoint/Tactical/Levels/TacticalFactionVision.cs
333
C#
//--------------------------------------------------------------------------------------------------------- // ▽ Submarine Mirage Framework for Unity // Copyright (c) 2020 夢想海の水底より(from Seabed of Reverie) // Released under the MIT License : // https://github.com/FromSeabedOfReverie/SubmarineMirageFrameworkForUnity/blob/master/LICENSE //--------------------------------------------------------------------------------------------------------- namespace SubmarineMirageFramework.Process { using System; using UniRx.Async; ///==================================================================================================== /// <summary> /// ■ 処理のインターフェース ///---------------------------------------------------------------------------------------------------- /// 各種処理のインターフェースが、継承して使用する。 /// </summary> ///==================================================================================================== public interface IProcess { ///------------------------------------------------------------------------------------------------ /// ● 要素 ///------------------------------------------------------------------------------------------------ /// <summary>実行済処理の状態</summary> CoreProcessManager.ExecutedState _executedState { get; set; } /// <summary>登録するか?</summary> bool _isRegister { get; } /// <summary>場面内だけ存在するか?</summary> bool _isInSceneOnly { get; } /// <summary>中心処理初期化後まで待機するか?</summary> bool _isWaitInitializedCoreProcesses { get; } /// <summary>初期化済か?</summary> bool _isInitialized { get; } /// <summary>初期化時のイベント</summary> Func<UniTask> _initializeEvent { get; } /// <summary>終了時のイベント</summary> Func<UniTask> _finalizeEvent { get; } ///------------------------------------------------------------------------------------------------ /// ● 仮想関数 ///------------------------------------------------------------------------------------------------ /// <summary>● 初期化</summary> UniTask Initialize(); /// <summary>● 終了</summary> UniTask Finalize(); } }
47.116279
107
0.371668
[ "Apache-2.0" ]
FromSeabedOfReverie/SubmarineMirageFrameworkForUnity
Assets/SubmarineMirageFrameworkForUnity/Scripts/System/Process/Base/IProcess.cs
2,274
C#
using System.Reflection; using System.Resources; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Windows; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("VidCompare")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("VidCompare")] [assembly: AssemblyCopyright("Copyright © 2016")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] // Setting ComVisible to false makes the types in this assembly not visible // to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] //In order to begin building localizable applications, set //<UICulture>CultureYouAreCodingWith</UICulture> in your .csproj file //inside a <PropertyGroup>. For example, if you are using US english //in your source files, set the <UICulture> to en-US. Then uncomment //the NeutralResourceLanguage attribute below. Update the "en-US" in //the line below to match the UICulture setting in the project file. //[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)] [assembly: ThemeInfo( ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located //(used if a resource is not found in the page, // or application resource dictionaries) ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located //(used if a resource is not found in the page, // app, or any theme specific resource dictionaries) )] // Version information for an assembly consists of the following four values: // // Major Version // Minor Version // Build Number // Revision // // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
42.428571
98
0.70665
[ "MIT" ]
dend456/VideoCompare
VidCompare/Properties/AssemblyInfo.cs
2,379
C#
// This file is part of Silk.NET. // // You may modify and distribute Silk.NET under the terms // of the MIT license. See the LICENSE file for details. using System; using System.Runtime.InteropServices; using System.Runtime.CompilerServices; using System.Text; using Silk.NET.Core; using Silk.NET.Core.Native; using Silk.NET.Core.Attributes; using Silk.NET.Core.Contexts; using Silk.NET.Core.Loader; #pragma warning disable 1591 namespace Silk.NET.Direct3D11 { [NativeName("Name", "D3D11_BUFFER_DESC")] public unsafe partial struct BufferDesc { public BufferDesc ( uint? byteWidth = null, Usage? usage = null, uint? bindFlags = null, uint? cPUAccessFlags = null, uint? miscFlags = null, uint? structureByteStride = null ) : this() { if (byteWidth is not null) { ByteWidth = byteWidth.Value; } if (usage is not null) { Usage = usage.Value; } if (bindFlags is not null) { BindFlags = bindFlags.Value; } if (cPUAccessFlags is not null) { CPUAccessFlags = cPUAccessFlags.Value; } if (miscFlags is not null) { MiscFlags = miscFlags.Value; } if (structureByteStride is not null) { StructureByteStride = structureByteStride.Value; } } [NativeName("Type", "UINT")] [NativeName("Type.Name", "UINT")] [NativeName("Name", "ByteWidth")] public uint ByteWidth; [NativeName("Type", "D3D11_USAGE")] [NativeName("Type.Name", "D3D11_USAGE")] [NativeName("Name", "Usage")] public Usage Usage; [NativeName("Type", "UINT")] [NativeName("Type.Name", "UINT")] [NativeName("Name", "BindFlags")] public uint BindFlags; [NativeName("Type", "UINT")] [NativeName("Type.Name", "UINT")] [NativeName("Name", "CPUAccessFlags")] public uint CPUAccessFlags; [NativeName("Type", "UINT")] [NativeName("Type.Name", "UINT")] [NativeName("Name", "MiscFlags")] public uint MiscFlags; [NativeName("Type", "UINT")] [NativeName("Type.Name", "UINT")] [NativeName("Name", "StructureByteStride")] public uint StructureByteStride; } }
26.175258
64
0.544703
[ "MIT" ]
ThomasMiz/Silk.NET
src/Microsoft/Silk.NET.Direct3D11/Structs/BufferDesc.gen.cs
2,539
C#
// Copy file example
11
21
0.681818
[ "MIT" ]
amwaters/vs-templates
src/CSharp Project File Templates/CopyFileExample.cs
24
C#
// Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. /****************************************************************************** * This file is auto-generated from a template file by the GenerateTests.csx * * script in tests\src\JIT\HardwareIntrinsics\X86\Shared. In order to make * * changes, please update the corresponding template and run according to the * * directions listed in the file. * ******************************************************************************/ using System; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Intrinsics; namespace JIT.HardwareIntrinsics.General { public static partial class Program { private static void GreaterThanAllInt16() { var test = new VectorBooleanBinaryOpTest__GreaterThanAllInt16(); // Validates basic functionality works, using Unsafe.Read test.RunBasicScenario_UnsafeRead(); // Validates calling via reflection works, using Unsafe.Read test.RunReflectionScenario_UnsafeRead(); // Validates passing a static member works test.RunClsVarScenario(); // Validates passing a local works, using Unsafe.Read test.RunLclVarScenario_UnsafeRead(); // Validates passing the field of a local class works test.RunClassLclFldScenario(); // Validates passing an instance member of a class works test.RunClassFldScenario(); // Validates passing the field of a local struct works test.RunStructLclFldScenario(); // Validates passing an instance member of a struct works test.RunStructFldScenario(); if (!test.Succeeded) { throw new Exception("One or more scenarios did not complete as expected."); } } } public sealed unsafe class VectorBooleanBinaryOpTest__GreaterThanAllInt16 { private struct DataTable { private byte[] inArray1; private byte[] inArray2; private GCHandle inHandle1; private GCHandle inHandle2; private ulong alignment; public DataTable(Int16[] inArray1, Int16[] inArray2, int alignment) { int sizeOfinArray1 = inArray1.Length * Unsafe.SizeOf<Int16>(); int sizeOfinArray2 = inArray2.Length * Unsafe.SizeOf<Int16>(); if ((alignment != 32 && alignment != 16 && alignment != 8) || (alignment * 2) < sizeOfinArray1 || (alignment * 2) < sizeOfinArray2) { throw new ArgumentException("Invalid value of alignment"); } this.inArray1 = new byte[alignment * 2]; this.inArray2 = new byte[alignment * 2]; this.inHandle1 = GCHandle.Alloc(this.inArray1, GCHandleType.Pinned); this.inHandle2 = GCHandle.Alloc(this.inArray2, GCHandleType.Pinned); this.alignment = (ulong)alignment; Unsafe.CopyBlockUnaligned(ref Unsafe.AsRef<byte>(inArray1Ptr), ref Unsafe.As<Int16, byte>(ref inArray1[0]), (uint)sizeOfinArray1); Unsafe.CopyBlockUnaligned(ref Unsafe.AsRef<byte>(inArray2Ptr), ref Unsafe.As<Int16, byte>(ref inArray2[0]), (uint)sizeOfinArray2); } public void* inArray1Ptr => Align((byte*)(inHandle1.AddrOfPinnedObject().ToPointer()), alignment); public void* inArray2Ptr => Align((byte*)(inHandle2.AddrOfPinnedObject().ToPointer()), alignment); public void Dispose() { inHandle1.Free(); inHandle2.Free(); } private static unsafe void* Align(byte* buffer, ulong expectedAlignment) { return (void*)(((ulong)buffer + expectedAlignment - 1) & ~(expectedAlignment - 1)); } } private struct TestStruct { public Vector256<Int16> _fld1; public Vector256<Int16> _fld2; public static TestStruct Create() { var testStruct = new TestStruct(); for (var i = 0; i < Op1ElementCount; i++) { _data1[i] = TestLibrary.Generator.GetInt16(); } Unsafe.CopyBlockUnaligned(ref Unsafe.As<Vector256<Int16>, byte>(ref testStruct._fld1), ref Unsafe.As<Int16, byte>(ref _data1[0]), (uint)Unsafe.SizeOf<Vector256<Int16>>()); for (var i = 0; i < Op2ElementCount; i++) { _data2[i] = TestLibrary.Generator.GetInt16(); } Unsafe.CopyBlockUnaligned(ref Unsafe.As<Vector256<Int16>, byte>(ref testStruct._fld2), ref Unsafe.As<Int16, byte>(ref _data2[0]), (uint)Unsafe.SizeOf<Vector256<Int16>>()); return testStruct; } public void RunStructFldScenario(VectorBooleanBinaryOpTest__GreaterThanAllInt16 testClass) { var result = Vector256.GreaterThanAll(_fld1, _fld2); testClass.ValidateResult(_fld1, _fld2, result); } } private static readonly int LargestVectorSize = 32; private static readonly int Op1ElementCount = Unsafe.SizeOf<Vector256<Int16>>() / sizeof(Int16); private static readonly int Op2ElementCount = Unsafe.SizeOf<Vector256<Int16>>() / sizeof(Int16); private static Int16[] _data1 = new Int16[Op1ElementCount]; private static Int16[] _data2 = new Int16[Op2ElementCount]; private static Vector256<Int16> _clsVar1; private static Vector256<Int16> _clsVar2; private Vector256<Int16> _fld1; private Vector256<Int16> _fld2; private DataTable _dataTable; static VectorBooleanBinaryOpTest__GreaterThanAllInt16() { for (var i = 0; i < Op1ElementCount; i++) { _data1[i] = TestLibrary.Generator.GetInt16(); } Unsafe.CopyBlockUnaligned(ref Unsafe.As<Vector256<Int16>, byte>(ref _clsVar1), ref Unsafe.As<Int16, byte>(ref _data1[0]), (uint)Unsafe.SizeOf<Vector256<Int16>>()); for (var i = 0; i < Op2ElementCount; i++) { _data2[i] = TestLibrary.Generator.GetInt16(); } Unsafe.CopyBlockUnaligned(ref Unsafe.As<Vector256<Int16>, byte>(ref _clsVar2), ref Unsafe.As<Int16, byte>(ref _data2[0]), (uint)Unsafe.SizeOf<Vector256<Int16>>()); } public VectorBooleanBinaryOpTest__GreaterThanAllInt16() { Succeeded = true; for (var i = 0; i < Op1ElementCount; i++) { _data1[i] = TestLibrary.Generator.GetInt16(); } Unsafe.CopyBlockUnaligned(ref Unsafe.As<Vector256<Int16>, byte>(ref _fld1), ref Unsafe.As<Int16, byte>(ref _data1[0]), (uint)Unsafe.SizeOf<Vector256<Int16>>()); for (var i = 0; i < Op2ElementCount; i++) { _data2[i] = TestLibrary.Generator.GetInt16(); } Unsafe.CopyBlockUnaligned(ref Unsafe.As<Vector256<Int16>, byte>(ref _fld2), ref Unsafe.As<Int16, byte>(ref _data2[0]), (uint)Unsafe.SizeOf<Vector256<Int16>>()); for (var i = 0; i < Op1ElementCount; i++) { _data1[i] = TestLibrary.Generator.GetInt16(); } for (var i = 0; i < Op2ElementCount; i++) { _data2[i] = TestLibrary.Generator.GetInt16(); } _dataTable = new DataTable(_data1, _data2, LargestVectorSize); } public bool Succeeded { get; set; } public void RunBasicScenario_UnsafeRead() { TestLibrary.TestFramework.BeginScenario(nameof(RunBasicScenario_UnsafeRead)); var result = Vector256.GreaterThanAll( Unsafe.Read<Vector256<Int16>>(_dataTable.inArray1Ptr), Unsafe.Read<Vector256<Int16>>(_dataTable.inArray2Ptr) ); ValidateResult(_dataTable.inArray1Ptr, _dataTable.inArray2Ptr, result); } public void RunReflectionScenario_UnsafeRead() { TestLibrary.TestFramework.BeginScenario(nameof(RunReflectionScenario_UnsafeRead)); var method = typeof(Vector256).GetMethod(nameof(Vector256.GreaterThanAll), new Type[] { typeof(Vector256<Int16>), typeof(Vector256<Int16>) }); if (method is null) { method = typeof(Vector256).GetMethod(nameof(Vector256.GreaterThanAll), 1, new Type[] { typeof(Vector256<>).MakeGenericType(Type.MakeGenericMethodParameter(0)), typeof(Vector256<>).MakeGenericType(Type.MakeGenericMethodParameter(0)) }); } if (method.IsGenericMethodDefinition) { method = method.MakeGenericMethod(typeof(Int16)); } var result = method.Invoke(null, new object[] { Unsafe.Read<Vector256<Int16>>(_dataTable.inArray1Ptr), Unsafe.Read<Vector256<Int16>>(_dataTable.inArray2Ptr) }); ValidateResult(_dataTable.inArray1Ptr, _dataTable.inArray2Ptr, (bool)(result)); } public void RunClsVarScenario() { TestLibrary.TestFramework.BeginScenario(nameof(RunClsVarScenario)); var result = Vector256.GreaterThanAll( _clsVar1, _clsVar2 ); ValidateResult(_clsVar1, _clsVar2, result); } public void RunLclVarScenario_UnsafeRead() { TestLibrary.TestFramework.BeginScenario(nameof(RunLclVarScenario_UnsafeRead)); var op1 = Unsafe.Read<Vector256<Int16>>(_dataTable.inArray1Ptr); var op2 = Unsafe.Read<Vector256<Int16>>(_dataTable.inArray2Ptr); var result = Vector256.GreaterThanAll(op1, op2); ValidateResult(op1, op2, result); } public void RunClassLclFldScenario() { TestLibrary.TestFramework.BeginScenario(nameof(RunClassLclFldScenario)); var test = new VectorBooleanBinaryOpTest__GreaterThanAllInt16(); var result = Vector256.GreaterThanAll(test._fld1, test._fld2); ValidateResult(test._fld1, test._fld2, result); } public void RunClassFldScenario() { TestLibrary.TestFramework.BeginScenario(nameof(RunClassFldScenario)); var result = Vector256.GreaterThanAll(_fld1, _fld2); ValidateResult(_fld1, _fld2, result); } public void RunStructLclFldScenario() { TestLibrary.TestFramework.BeginScenario(nameof(RunStructLclFldScenario)); var test = TestStruct.Create(); var result = Vector256.GreaterThanAll(test._fld1, test._fld2); ValidateResult(test._fld1, test._fld2, result); } public void RunStructFldScenario() { TestLibrary.TestFramework.BeginScenario(nameof(RunStructFldScenario)); var test = TestStruct.Create(); test.RunStructFldScenario(this); } private void ValidateResult(Vector256<Int16> op1, Vector256<Int16> op2, bool result, [CallerMemberName] string method = "") { Int16[] inArray1 = new Int16[Op1ElementCount]; Int16[] inArray2 = new Int16[Op2ElementCount]; Unsafe.WriteUnaligned(ref Unsafe.As<Int16, byte>(ref inArray1[0]), op1); Unsafe.WriteUnaligned(ref Unsafe.As<Int16, byte>(ref inArray2[0]), op2); ValidateResult(inArray1, inArray2, result, method); } private void ValidateResult(void* op1, void* op2, bool result, [CallerMemberName] string method = "") { Int16[] inArray1 = new Int16[Op1ElementCount]; Int16[] inArray2 = new Int16[Op2ElementCount]; Unsafe.CopyBlockUnaligned(ref Unsafe.As<Int16, byte>(ref inArray1[0]), ref Unsafe.AsRef<byte>(op1), (uint)Unsafe.SizeOf<Vector256<Int16>>()); Unsafe.CopyBlockUnaligned(ref Unsafe.As<Int16, byte>(ref inArray2[0]), ref Unsafe.AsRef<byte>(op2), (uint)Unsafe.SizeOf<Vector256<Int16>>()); ValidateResult(inArray1, inArray2, result, method); } private void ValidateResult(Int16[] left, Int16[] right, bool result, [CallerMemberName] string method = "") { bool succeeded = true; var expectedResult = true; for (var i = 0; i < Op1ElementCount; i++) { expectedResult &= (left[i] > right[i]); } succeeded = (expectedResult == result); if (!succeeded) { TestLibrary.TestFramework.LogInformation($"{nameof(Vector256)}.{nameof(Vector256.GreaterThanAll)}<Int16>(Vector256<Int16>, Vector256<Int16>): {method} failed:"); TestLibrary.TestFramework.LogInformation($" left: ({string.Join(", ", left)})"); TestLibrary.TestFramework.LogInformation($" right: ({string.Join(", ", right)})"); TestLibrary.TestFramework.LogInformation($" result: ({result})"); TestLibrary.TestFramework.LogInformation(string.Empty); Succeeded = false; } } } }
42.079114
187
0.606077
[ "MIT" ]
333fred/runtime
src/tests/JIT/HardwareIntrinsics/General/Vector256/GreaterThanAll.Int16.cs
13,297
C#
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Collections; using System.IO; namespace UnstandardnessTestForDM { public partial class Form1 : Form { DMSource source; public Form1() { InitializeComponent(); source = new DMSource(); source.mainform = this; } private void button1_Click(object sender, EventArgs e) { source.find_all_defines(); generate_define_report(); } public void generate_define_report() { TextWriter tw = new StreamWriter("DEFINES REPORT.txt"); tw.WriteLine("Unstandardness Test For DM report for DEFINES"); tw.WriteLine("Generated on " + DateTime.Now); tw.WriteLine("Total number of defines " + source.defines.Count()); tw.WriteLine("Total number of Files " + source.filessearched); tw.WriteLine("Total number of references " + source.totalreferences); tw.WriteLine("Total number of errorous defines " + source.errordefines); tw.WriteLine("------------------------------------------------"); foreach (Define d in source.defines) { tw.WriteLine(d.name); tw.WriteLine("\tValue: " + d.value); tw.WriteLine("\tComment: " + d.comment); tw.WriteLine("\tDefined in: " + d.location + " : " + d.line); tw.WriteLine("\tNumber of references: " + d.references.Count()); foreach (String s in d.references) { tw.WriteLine("\t\t" + s); } } tw.WriteLine("------------------------------------------------"); tw.WriteLine("SUCCESS"); tw.Close(); } private void listBox1_SelectedIndexChanged(object sender, EventArgs e) { try { Define d = (Define)listBox1.Items[listBox1.SelectedIndex]; label1.Text = d.name; label2.Text = "Defined in: " + d.location + " : " + d.line; label3.Text = "Value: " + d.value; label4.Text = "References: " + d.references.Count(); listBox2.Items.Clear(); foreach (String s in d.references) { listBox2.Items.Add(s); } } catch (Exception ex) { Console.WriteLine("ERROR HERE: " + ex.Message); } } } public class DMSource { public List<Define> defines; public const int FLAG_DEFINE = 1; public Form1 mainform; public int filessearched = 0; public int totalreferences = 0; public int errordefines = 0; public List<String> filenames; public DMSource() { defines = new List<Define>(); filenames = new List<String>(); } public void find_all_defines() { find_all_files(); foreach(String filename in filenames){ searchFileForDefines(filename); } } public void find_all_files() { filenames = new List<String>(); String dmefilename = ""; foreach (string f in Directory.GetFiles(".")) { if (f.ToLower().EndsWith(".dme")) { dmefilename = f; break; } } if (dmefilename.Equals("")) { MessageBox.Show("dme file not found"); return; } using (var reader = File.OpenText(dmefilename)) { String s; while (true) { s = reader.ReadLine(); if (!(s is String)) break; if (s.StartsWith("#include")) { int start = s.IndexOf("\"")+1; s = s.Substring(start, s.Length - 11); if (s.EndsWith(".dm")) { filenames.Add(s); } } s = s.Trim(' '); if (s == "") { continue; } } reader.Close(); } } public void DirSearch(string sDir, int flag) { try { foreach (string d in Directory.GetDirectories(sDir)) { foreach (string f in Directory.GetFiles(d)) { if (f.ToLower().EndsWith(".dm")) { if ((flag & FLAG_DEFINE) > 0) { searchFileForDefines(f); } } } DirSearch(d, flag); } } catch (System.Exception excpt) { Console.WriteLine("ERROR IN DIRSEARCH"); Console.WriteLine(excpt.Message); Console.WriteLine(excpt.Data); Console.WriteLine(excpt.ToString()); Console.WriteLine(excpt.StackTrace); Console.WriteLine("END OF ERROR IN DIRSEARCH"); } } //DEFINES public void searchFileForDefines(String fileName) { filessearched++; FileInfo f = new FileInfo(fileName); List<String> lines = new List<String>(); List<String> lines_without_comments = new List<String>(); mainform.label5.Text = "Files searched: " + filessearched + "; Defines found: " + defines.Count() + "; References found: " + totalreferences + "; Errorous defines: " + errordefines; mainform.label5.Refresh(); //This code segment reads the file and stores it into the lines variable. using (var reader = File.OpenText(fileName)) { try { String s; while (true) { s = reader.ReadLine(); lines.Add(s); s = s.Trim(' '); if (s == "") { continue; } } } catch { } reader.Close(); } mainform.listBox1.Items.Add("ATTEMPTING: " + fileName); lines_without_comments = remove_comments(lines); /*TextWriter tw = new StreamWriter(fileName); foreach (String s in lines_without_comments) { tw.WriteLine(s); } tw.Close(); mainform.listBox1.Items.Add("REWRITE: "+fileName);*/ try { for (int i = 0; i < lines_without_comments.Count; i++) { String line = lines_without_comments[i]; if (!(line is string)) continue; //Console.WriteLine("LINE: " + line); foreach (Define define in defines) { if (line.IndexOf(define.name) >= 0) { define.references.Add(fileName + " : " + i); totalreferences++; } } if( line.ToLower().IndexOf("#define") >= 0 ) { line = line.Trim(); line = line.Replace('\t', ' '); //Console.WriteLine("LINE = "+line); String[] slist = line.Split(' '); if(slist.Length >= 3){ //slist[0] has the value of "#define" String name = slist[1]; String value = slist[2]; for (int j = 3; j < slist.Length; j++) { value += " " + slist[j]; //Console.WriteLine("LISTITEM["+j+"] = "+slist[j]); } value = value.Trim(); String comment = ""; if (value.IndexOf("//") >= 0) { comment = value.Substring(value.IndexOf("//")); value = value.Substring(0, value.IndexOf("//")); } comment = comment.Trim(); value = value.Trim(); Define d = new Define(fileName,i,name,value,comment); defines.Add(d); mainform.listBox1.Items.Add(d); mainform.listBox1.Refresh(); }else{ Define d = new Define(fileName, i, "ERROR ERROR", "Something went wrong here", line); errordefines++; defines.Add(d); mainform.listBox1.Items.Add(d); mainform.listBox1.Refresh(); } } } } catch (Exception e) { Console.WriteLine(e.Message); Console.WriteLine(e.StackTrace); MessageBox.Show("Exception: " + e.Message + " | " + e.ToString()); } } bool iscomment = false; int ismultilinecomment = 0; bool isstring = false; bool ismultilinestring = false; int escapesequence = 0; int stringvar = 0; public List<String> remove_comments(List<String> lines) { List<String> r = new List<String>(); iscomment = false; ismultilinecomment = 0; isstring = false; ismultilinestring = false; bool skiponechar = false; //Used so the / in */ doesn't get written; for (int i = 0; i < lines.Count(); i++) { String line = lines[i]; if (!(line is String)) continue; iscomment = false; isstring = false; char ca = ' '; escapesequence = 0; String newline = ""; int k = line.Length; for (int j = 0; j < k; j++) { char c = line.ToCharArray()[j]; if (escapesequence == 0) if (normalstatus()) { if (ca == '/' && c == '/') { c = ' '; iscomment = true; newline = newline.Remove(newline.Length - 1); k = line.Length; } if (ca == '/' && c == '*') { c = ' '; ismultilinecomment = 1; newline = newline.Remove(newline.Length - 1); k = line.Length; } if (c == '"') { isstring = true; } if (ca == '{' && c == '"') { ismultilinestring = true; } } else if (isstring) { if (c == '\\') { escapesequence = 2; } else if (stringvar > 0) { if (c == ']') { stringvar--; } else if (c == '[') { stringvar++; } } else if (c == '"') { isstring = false; } else if (c == '[') { stringvar++; } } else if (ismultilinestring) { if (ca == '"' && c == '}') { ismultilinestring = false; } } else if (ismultilinecomment > 0) { if (ca == '/' && c == '*') { c = ' '; //These things are here to prevent /*/ from bieng interpreted as the start and end of a comment. skiponechar = true; ismultilinecomment++; } if (ca == '*' && c == '/') { c = ' '; //These things are here to prevent /*/ from bieng interpreted as the start and end of a comment. skiponechar = true; ismultilinecomment--; } } if (!iscomment && (ismultilinecomment==0) && !skiponechar) { newline += c; } if (skiponechar) { skiponechar = false; } if (escapesequence > 0) { escapesequence--; } else { ca = c; } } r.Add(newline.TrimEnd()); } return r; } private bool normalstatus() { return !isstring && !ismultilinestring && (ismultilinecomment==0) && !iscomment && (escapesequence == 0); } } public class Define { public String location; public int line; public String name; public String value; public String comment; public List<String> references; public Define(String location, int line, String name, String value, String comment) { this.location = location; this.line = line; this.name = name; this.value = value; this.comment = comment; this.references = new List<String>(); } public override String ToString() { return "DEFINE: \""+name+"\" is defined as \""+value+"\" AT "+location+" : "+line; } } }
33.035052
193
0.362626
[ "MIT" ]
liambaloh/OpenEOB
Assets/StreamingAssets/tools/UnstandardnessTestForDM/UnstandardnessTestForDM/Form1.cs
16,024
C#
using System; using Altinn.Studio.Designer.Helpers; using Xunit; namespace Designer.Tests.Helpers { public class GuardTests { [Theory] [InlineData("filename.xsd", ".xs")] [InlineData("path/to/filename.json", "json")] [InlineData("path/to/filename.schema.json", "jsonschema")] public void AssertFileExtensionIsOfType_InCorrectType_ShouldThrowException(string file, string incorrectExtension) { Assert.Throws<ArgumentException>(() => Guard.AssertFileExtensionIsOfType(file, incorrectExtension)); } [Theory] [InlineData("filename.xsd", ".xsd")] [InlineData("path/to/filename.json", ".json")] [InlineData("path/to/filename.schema.json", ".json")] public void AssertFileExtensionIsOfType_CorrectType_ShouldNotThrowException(string file, string correctExtension) { Guard.AssertFileExtensionIsOfType(file, correctExtension); Assert.True(true); } [Theory] [InlineData("apps-test")] [InlineData("endring-av-navn-v2")] public void AssertValidAppRepoName_ValidName_ShouldNotThrowException(string name) { Guard.AssertValidAppRepoName(name); Assert.True(true); } [Theory] [InlineData("2021-apps-test")] [InlineData("datamodels")] public void AssertValidAppRepoName_InvalidName_ShouldThrowException(string name) { Assert.Throws<ArgumentException>(() => Guard.AssertValidAppRepoName(name)); } } }
32.916667
122
0.646203
[ "BSD-3-Clause" ]
Altinn/altinn-studio
src/studio/src/designer/backend.Tests/Helpers/GuardTests.cs
1,580
C#
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; namespace DiskmemeoryBomb { public partial class About : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } } }
17.611111
60
0.687697
[ "Apache-2.0", "MIT" ]
UhuruSoftware/vcap-dotnet
src/Uhuru.CloudFoundry.Test/TestApps/DiskmemeoryBomb/App/About.aspx.cs
319
C#
#region License // Copyright (c) Jeremy Skinner (http://www.jeremyskinner.co.uk) // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // // The latest version of this file can be found at https://github.com/JeremySkinner/FluentValidation #endregion namespace FluentValidation.Tests { using System; using System.Globalization; using System.Threading; public class CultureScope : IDisposable { CultureInfo _originalUiCulture; CultureInfo _originalCulture; public CultureScope(CultureInfo culture) { _originalCulture = Thread.CurrentThread.CurrentCulture; _originalUiCulture = Thread.CurrentThread.CurrentUICulture; Thread.CurrentThread.CurrentCulture = culture; Thread.CurrentThread.CurrentUICulture = culture; } public CultureScope(string culture) : this(new CultureInfo(culture)) { } public void Dispose() { Thread.CurrentThread.CurrentCulture = _originalCulture; Thread.CurrentThread.CurrentUICulture = _originalUiCulture; } public static void SetDefaultCulture() { Thread.CurrentThread.CurrentCulture = new CultureInfo("en-US"); Thread.CurrentThread.CurrentUICulture = new CultureInfo("en-US"); } } }
35.163265
101
0.738828
[ "Apache-2.0" ]
bostjankosi/FluentValidation
src/FluentValidation.Tests/CultureScope.cs
1,725
C#
/******************************************************************************* * Copyright 2012-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. * Licensed under the Apache License, Version 2.0 (the "License"). You may not use * this file except in compliance with the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. * This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the * specific language governing permissions and limitations under the License. * ***************************************************************************** * * AWS Tools for Windows (TM) PowerShell (TM) * */ using System; using System.Collections.Generic; using System.Linq; using System.Management.Automation; using System.Text; using Amazon.PowerShell.Common; using Amazon.Runtime; using Amazon.Chime; using Amazon.Chime.Model; namespace Amazon.PowerShell.Cmdlets.CHM { /// <summary> /// Retrieves details for the specified bot, such as bot email address, bot type, status, /// and display name. /// </summary> [Cmdlet("Get", "CHMBot")] [OutputType("Amazon.Chime.Model.Bot")] [AWSCmdlet("Calls the Amazon Chime GetBot API operation.", Operation = new[] {"GetBot"}, SelectReturnType = typeof(Amazon.Chime.Model.GetBotResponse))] [AWSCmdletOutput("Amazon.Chime.Model.Bot or Amazon.Chime.Model.GetBotResponse", "This cmdlet returns an Amazon.Chime.Model.Bot object.", "The service call response (type Amazon.Chime.Model.GetBotResponse) can also be referenced from properties attached to the cmdlet entry in the $AWSHistory stack." )] public partial class GetCHMBotCmdlet : AmazonChimeClientCmdlet, IExecutor { #region Parameter AccountId /// <summary> /// <para> /// <para>The Amazon Chime account ID.</para> /// </para> /// </summary> #if !MODULAR [System.Management.Automation.Parameter(ValueFromPipelineByPropertyName = true)] #else [System.Management.Automation.Parameter(ValueFromPipelineByPropertyName = true, Mandatory = true)] [System.Management.Automation.AllowEmptyString] [System.Management.Automation.AllowNull] #endif [Amazon.PowerShell.Common.AWSRequiredParameter] public System.String AccountId { get; set; } #endregion #region Parameter BotId /// <summary> /// <para> /// <para>The bot ID.</para> /// </para> /// </summary> #if !MODULAR [System.Management.Automation.Parameter(Position = 0, ValueFromPipelineByPropertyName = true, ValueFromPipeline = true)] #else [System.Management.Automation.Parameter(Position = 0, ValueFromPipelineByPropertyName = true, ValueFromPipeline = true, Mandatory = true)] [System.Management.Automation.AllowEmptyString] [System.Management.Automation.AllowNull] #endif [Amazon.PowerShell.Common.AWSRequiredParameter] public System.String BotId { get; set; } #endregion #region Parameter Select /// <summary> /// Use the -Select parameter to control the cmdlet output. The default value is 'Bot'. /// Specifying -Select '*' will result in the cmdlet returning the whole service response (Amazon.Chime.Model.GetBotResponse). /// Specifying the name of a property of type Amazon.Chime.Model.GetBotResponse will result in that property being returned. /// Specifying -Select '^ParameterName' will result in the cmdlet returning the selected cmdlet parameter value. /// </summary> [System.Management.Automation.Parameter(ValueFromPipelineByPropertyName = true)] public string Select { get; set; } = "Bot"; #endregion #region Parameter PassThru /// <summary> /// Changes the cmdlet behavior to return the value passed to the BotId parameter. /// The -PassThru parameter is deprecated, use -Select '^BotId' instead. This parameter will be removed in a future version. /// </summary> [System.Obsolete("The -PassThru parameter is deprecated, use -Select '^BotId' instead. This parameter will be removed in a future version.")] [System.Management.Automation.Parameter(ValueFromPipelineByPropertyName = true)] public SwitchParameter PassThru { get; set; } #endregion protected override void ProcessRecord() { base.ProcessRecord(); var context = new CmdletContext(); // allow for manipulation of parameters prior to loading into context PreExecutionContextLoad(context); #pragma warning disable CS0618, CS0612 //A class member was marked with the Obsolete attribute if (ParameterWasBound(nameof(this.Select))) { context.Select = CreateSelectDelegate<Amazon.Chime.Model.GetBotResponse, GetCHMBotCmdlet>(Select) ?? throw new System.ArgumentException("Invalid value for -Select parameter.", nameof(this.Select)); if (this.PassThru.IsPresent) { throw new System.ArgumentException("-PassThru cannot be used when -Select is specified.", nameof(this.Select)); } } else if (this.PassThru.IsPresent) { context.Select = (response, cmdlet) => this.BotId; } #pragma warning restore CS0618, CS0612 //A class member was marked with the Obsolete attribute context.AccountId = this.AccountId; #if MODULAR if (this.AccountId == null && ParameterWasBound(nameof(this.AccountId))) { WriteWarning("You are passing $null as a value for parameter AccountId which is marked as required. In case you believe this parameter was incorrectly marked as required, report this by opening an issue at https://github.com/aws/aws-tools-for-powershell/issues."); } #endif context.BotId = this.BotId; #if MODULAR if (this.BotId == null && ParameterWasBound(nameof(this.BotId))) { WriteWarning("You are passing $null as a value for parameter BotId which is marked as required. In case you believe this parameter was incorrectly marked as required, report this by opening an issue at https://github.com/aws/aws-tools-for-powershell/issues."); } #endif // allow further manipulation of loaded context prior to processing PostExecutionContextLoad(context); var output = Execute(context) as CmdletOutput; ProcessOutput(output); } #region IExecutor Members public object Execute(ExecutorContext context) { var cmdletContext = context as CmdletContext; // create request var request = new Amazon.Chime.Model.GetBotRequest(); if (cmdletContext.AccountId != null) { request.AccountId = cmdletContext.AccountId; } if (cmdletContext.BotId != null) { request.BotId = cmdletContext.BotId; } CmdletOutput output; // issue call var client = Client ?? CreateClient(_CurrentCredentials, _RegionEndpoint); try { var response = CallAWSServiceOperation(client, request); object pipelineOutput = null; pipelineOutput = cmdletContext.Select(response, this); output = new CmdletOutput { PipelineOutput = pipelineOutput, ServiceResponse = response }; } catch (Exception e) { output = new CmdletOutput { ErrorResponse = e }; } return output; } public ExecutorContext CreateContext() { return new CmdletContext(); } #endregion #region AWS Service Operation Call private Amazon.Chime.Model.GetBotResponse CallAWSServiceOperation(IAmazonChime client, Amazon.Chime.Model.GetBotRequest request) { Utils.Common.WriteVerboseEndpointMessage(this, client.Config, "Amazon Chime", "GetBot"); try { #if DESKTOP return client.GetBot(request); #elif CORECLR return client.GetBotAsync(request).GetAwaiter().GetResult(); #else #error "Unknown build edition" #endif } catch (AmazonServiceException exc) { var webException = exc.InnerException as System.Net.WebException; if (webException != null) { throw new Exception(Utils.Common.FormatNameResolutionFailureMessage(client.Config, webException.Message), webException); } throw; } } #endregion internal partial class CmdletContext : ExecutorContext { public System.String AccountId { get; set; } public System.String BotId { get; set; } public System.Func<Amazon.Chime.Model.GetBotResponse, GetCHMBotCmdlet, object> Select { get; set; } = (response, cmdlet) => response.Bot; } } }
43.104348
280
0.595824
[ "Apache-2.0" ]
5u5hma/aws-tools-for-powershell
modules/AWSPowerShell/Cmdlets/Chime/Basic/Get-CHMBot-Cmdlet.cs
9,914
C#
namespace $safeprojectname$.Services { using System.Windows; using Catel; using Catel.MVVM; using Catel.Services; using global::MahApps.Metro.Controls; using global::MahApps.Metro.IconPacks; using Orchestra; using Orchestra.Models; using Orchestra.Services; using Orchestra.ViewModels; using Orchestra.Views; using Views; public class MahAppsService : IMahAppsService { public WindowCommands GetRightWindowCommands() { var windowCommands = new WindowCommands(); var settingsButton = WindowCommandHelper.CreateWindowCommandButton(new PackIconMaterial { Kind = PackIconMaterialKind.Settings }, "settings"); //settingsButton.SetCurrentValue(System.Windows.Controls.Primitives.ButtonBase.CommandProperty, _commandManager.GetCommand(AppCommands.Settings.General)); windowCommands.Items.Add(settingsButton); return windowCommands; } public FlyoutsControl GetFlyouts() { return null; } public FrameworkElement GetMainView() { return new MainView(); } public FrameworkElement GetStatusBar() { return null; } public AboutInfo GetAboutInfo() { return new AboutInfo(); } } }
27.734694
166
0.640912
[ "MIT" ]
Catel/Catel.Templates
templates/C#/ProjectTemplates/Orchestra.MahApps.Application/Services/MahAppsService.cs
1,361
C#
using System.Collections.Generic; using System.Runtime.Serialization; using Service.Liquidity.Monitoring.Domain.Models.Actions; namespace Service.Liquidity.Hedger.Domain.Models { [DataContract] public class StopHedgeMonitoringAction : IMonitoringAction { [DataMember(Order = 1)] public string TypeName { get; set; } = nameof(StopHedgeMonitoringAction); [DataMember(Order = 2)] public Dictionary<string, string> ParamValuesByName { get; set; } [DataMember(Order = 3)] public ICollection<MonitoringActionParamInfo> ParamInfos { get; set; } } }
41.642857
105
0.740995
[ "MIT" ]
MyJetWallet/Service.Liquidity.Hedger
src/Service.Liquidity.Hedger.Domain.Models/MonitoringActions/StopHedgeMonitoringAction.cs
585
C#
using UnityEssentials.Geometry.shape3d; using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEssentials.Geometry.extensions; namespace UnityEssentials.Geometry.MovableShape { public class MovableCapsuleHalfAdvanced : MovableCapsuleHalf { [SerializeField] private float _radiusMin = 0; [SerializeField] private float _radiusMax = 10; #if UNITY_EDITOR [SerializeField] private bool _drawRadius = true; #endif public override bool GetClosestPoint(Vector3 position, ref Vector3 closestPoint) { bool canApplyGravity = true; closestPoint = CapsuleHalf.GetClosestPoint(position); if (canApplyGravity) { closestPoint = ExtMovableShapeAdvanced.GetRightPosWithRange(position, closestPoint, _radiusMin * transform.lossyScale.Maximum(), _radiusMax * transform.lossyScale.Maximum(), out bool outOfRange); if (outOfRange) { canApplyGravity = false; } } return (canApplyGravity); } #if UNITY_EDITOR public override void Draw() { CapsuleHalf.Draw(base.GetColor()); if (!_drawRadius) { return; } if (_radiusMin > 0) { CapsuleHalf.DrawWithExtraSize(Color.gray, new Vector3(_radiusMin * transform.lossyScale.Maximum(), _radiusMin * transform.lossyScale.Maximum(), _radiusMin * transform.lossyScale.Maximum())); } if (_radiusMax > 0) { CapsuleHalf.DrawWithExtraSize(Color.red, new Vector3(_radiusMax * transform.lossyScale.Maximum(), _radiusMax * transform.lossyScale.Maximum(), _radiusMax * transform.lossyScale.Maximum())); } } #endif } }
35.961538
211
0.624599
[ "MIT" ]
usernameHed/Philae-Lander
Assets/Plugins/Unity Essentials - Movable Shape/Shapes/Capsule/MovableCapsuleHalfAdvanced.cs
1,872
C#
using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Reflection; using System.Runtime.Serialization; using System.Xml.Serialization; using NewLife; using NewLife.Log; using XCode.DataAccessLayer; namespace XCode.Configuration { /// <summary>数据表元数据</summary> public class TableItem { #region 特性 /// <summary>实体类型</summary> public Type EntityType { get; } /// <summary>绑定表特性</summary> private readonly BindTableAttribute _Table; /// <summary>绑定索引特性</summary> private readonly BindIndexAttribute[] _Indexes; private readonly DescriptionAttribute _Description; /// <summary>说明</summary> public String Description { get { if (_Description != null && !String.IsNullOrEmpty(_Description.Description)) return _Description.Description; if (_Table != null && !String.IsNullOrEmpty(_Table.Description)) return _Table.Description; return null; } } #endregion #region 属性 private String _TableName; /// <summary>表名</summary> public String TableName { get { if (_TableName.IsNullOrEmpty()) _TableName = _Table?.Name ?? EntityType.Name; return _TableName; } set { _TableName = value; DataTable.TableName = value; } } private String _ConnName; /// <summary>连接名</summary> public String ConnName { get { if (_ConnName.IsNullOrEmpty()) { var connName = _Table?.ConnName; _ConnName = connName; } return _ConnName; } set => _ConnName = value; } #endregion #region 扩展属性 /// <summary>数据字段</summary> [XmlArray] [Description("数据字段")] public FieldItem[] Fields { get; private set; } /// <summary>所有字段</summary> [XmlIgnore, IgnoreDataMember] public FieldItem[] AllFields { get; private set; } /// <summary>标识列</summary> [XmlIgnore, IgnoreDataMember] public FieldItem Identity { get; private set; } /// <summary>主键。不会返回null</summary> [XmlIgnore, IgnoreDataMember] public FieldItem[] PrimaryKeys { get; private set; } /// <summary>主字段。主字段作为业务主要字段,代表当前数据行意义</summary> public FieldItem Master { get; private set; } private ICollection<String> _FieldNames; /// <summary>字段名集合,不区分大小写的哈希表存储,外部不要修改元素数据</summary> [XmlIgnore, IgnoreDataMember] public ICollection<String> FieldNames { get { if (_FieldNames != null) return _FieldNames; var list = new HashSet<String>(StringComparer.OrdinalIgnoreCase); var dic = new Dictionary<String, String>(StringComparer.OrdinalIgnoreCase); foreach (var item in Fields) { if (!list.Contains(item.Name)) { list.Add(item.Name); dic.Add(item.Name, item.Name); } else DAL.WriteLog("数据表{0}发现同名但不同大小写的字段{1}和{2},违反设计原则!", TableName, dic[item.Name], item.Name); } //_FieldNames = new ReadOnlyCollection<String>(list); _FieldNames = list; return _FieldNames; } } private ICollection<String> _ExtendFieldNames; /// <summary>扩展属性集合,不区分大小写的哈希表存储,外部不要修改元素数据</summary> [XmlIgnore, IgnoreDataMember] public ICollection<String> ExtendFieldNames { get { if (_ExtendFieldNames != null) return _ExtendFieldNames; var list = new HashSet<String>(StringComparer.OrdinalIgnoreCase); foreach (var item in AllFields) { if (!item.IsDataObjectField && !list.Contains(item.Name)) list.Add(item.Name); } _ExtendFieldNames = list; return _ExtendFieldNames; } } /// <summary>数据表架构</summary> [XmlIgnore, IgnoreDataMember] public IDataTable DataTable { get; private set; } /// <summary>模型检查模式</summary> public ModelCheckModes ModelCheckMode { get; } = ModelCheckModes.CheckAllTablesWhenInit; #endregion #region 构造 private TableItem(Type type) { EntityType = type; _Table = type.GetCustomAttribute<BindTableAttribute>(true); if (_Table == null) throw new ArgumentOutOfRangeException(nameof(type), "类型" + type + "没有" + typeof(BindTableAttribute).Name + "特性!"); _Indexes = type.GetCustomAttributes<BindIndexAttribute>(true).ToArray(); //_Relations = type.GetCustomAttributes<BindRelationAttribute>(true).ToArray(); _Description = type.GetCustomAttribute<DescriptionAttribute>(true); var att = type.GetCustomAttribute<ModelCheckModeAttribute>(true); if (att != null) ModelCheckMode = att.Mode; InitFields(); } private static readonly ConcurrentDictionary<Type, TableItem> cache = new(); /// <summary>创建</summary> /// <param name="type">类型</param> /// <returns></returns> public static TableItem Create(Type type) { if (type == null) throw new ArgumentNullException(nameof(type)); // 不能给没有BindTableAttribute特性的类型创建TableItem,否则可能会在InitFields中抛出异常 return cache.GetOrAdd(type, key => key.GetCustomAttribute<BindTableAttribute>(true) != null ? new TableItem(key) : null); } private void InitFields() { var bt = _Table; var table = DAL.CreateTable(); DataTable = table; table.TableName = bt.Name; //// 构建DataTable时也要注意表前缀,避免反向工程用错 //table.TableName = GetTableName(bt); table.Name = EntityType.Name; table.DbType = bt.DbType; table.IsView = bt.IsView || bt.Name[0] == '#'; table.Description = Description; //table.ConnName = ConnName; var allfields = new List<FieldItem>(); var fields = new List<FieldItem>(); var pkeys = new List<FieldItem>(); foreach (var item in GetFields(EntityType)) { var fi = item; allfields.Add(fi); if (fi.IsDataObjectField) { fields.Add(fi); var f = table.CreateColumn(); fi.Fill(f); table.Columns.Add(f); } if (fi.PrimaryKey) pkeys.Add(fi); if (fi.IsIdentity) Identity = fi; if (fi.Master) Master = fi; } // 先完成allfields才能专门处理 foreach (var item in allfields) { if (!item.IsDynamic) { // 如果不是数据字段,则检查绑定关系 var map = item.Map; if (map != null) { // 找到被关系映射的字段,拷贝相关属性 var fi = allfields.FirstOrDefault(e => e.Name.EqualIgnoreCase(map.Name)); if (fi != null) { if (item.OriField == null) item.OriField = fi; if (item.DisplayName.IsNullOrEmpty()) item.DisplayName = fi.DisplayName; if (item.Description.IsNullOrEmpty()) item.Description = fi.Description; item.ColumnName = fi.ColumnName; } } } } var ids = _Indexes; if (ids != null) { foreach (var item in ids) { var di = table.CreateIndex(); item.Fill(di); if (table.GetIndex(di.Columns) != null) continue; // 如果索引全部就是主键,无需创建索引 if (table.GetColumns(di.Columns).All(e => e.PrimaryKey)) continue; table.Indexes.Add(di); } // 检查索引重复,最左原则 for (var i = 0; i < table.Indexes.Count; i++) { var di = table.Indexes[i]; for (var j = i + 1; j < table.Indexes.Count; j++) { var di2 = table.Indexes[j]; //var flag = true; //for (int k = 0; k < di.Columns.Length && k < di2.Columns.Length; k++) //{ // if (!di.Columns[k].Equals(di2.Columns[k])) // { // flag = false; // break; // } //} // 取最小长度,如果序列相等,说明前缀相同 var count = Math.Min(di.Columns.Length, di2.Columns.Length); if (count > 0 && di.Columns.Take(count).SequenceEqual(di2.Columns.Take(count), StringComparer.OrdinalIgnoreCase)) { var cs = di.Columns.Length == count ? di.Columns : di2.Columns; var cs2 = di.Columns.Length == count ? di2.Columns : di.Columns; XTrace.WriteLine("实体类[{0}]/数据表[{1}]的索引重复,可去除({2}),保留({3})", EntityType.FullName, TableName, cs.Join(), cs2.Join()); } } } } // 不允许为null AllFields = allfields.ToArray(); Fields = fields.ToArray(); PrimaryKeys = pkeys.ToArray(); } /// <summary>获取属性,保证基类属性在前</summary> /// <param name="type">类型</param> /// <returns></returns> private IEnumerable<Field> GetFields(Type type) { // 先拿到所有属性,可能是先排子类,再排父类 var list = new List<Field>(); foreach (var item in type.GetProperties()) { if (item.GetIndexParameters().Length <= 0) list.Add(new Field(this, item)); } var att = type.GetCustomAttribute<ModelSortModeAttribute>(true); if (att == null || att.Mode == ModelSortModes.BaseFirst) { // 然后用栈来处理,基类优先 var stack = new Stack<Field>(); var t = type; while (t != null && t != typeof(EntityBase) && list.Count > 0) { // 反序入栈,因为属性可能是顺序的,这里先反序,待会出来再反一次 // 没有数据属性的 for (var i = list.Count - 1; i >= 0; i--) { var item = list[i]; if (item.DeclaringType == t && !item.IsDataObjectField) { stack.Push(item); list.RemoveAt(i); } } // 有数据属性的 for (var i = list.Count - 1; i >= 0; i--) { var item = list[i]; if (item.DeclaringType == t && item.IsDataObjectField) { stack.Push(item); list.RemoveAt(i); } } t = t.BaseType; } foreach (var item in stack) { yield return item; } } else { // 子类优先 var t = type; while (t != null && t != typeof(EntityBase) && list.Count > 0) { // 有数据属性的 foreach (var item in list) { if (item.DeclaringType == t && item.IsDataObjectField) yield return item; } // 没有数据属性的 foreach (var item in list) { if (item.DeclaringType == t && !item.IsDataObjectField) yield return item; } t = t.BaseType; } } } #endregion #region 方法 private Dictionary<String, Field> _all; /// <summary>根据名称查找</summary> /// <param name="name">名称</param> /// <returns></returns> public Field FindByName(String name) { //if (String.IsNullOrEmpty(name)) throw new ArgumentNullException("name"); if (name.IsNullOrEmpty()) return null; // 特殊处理行号 if (name.EqualIgnoreCase("RowNumber")) return null; // 借助字典,快速搜索数据列 if (_all == null) { var dic = new Dictionary<String, Field>(StringComparer.OrdinalIgnoreCase); foreach (var item in Fields) { if (!dic.ContainsKey(item.Name)) dic.Add(item.Name, item as Field); } foreach (var item in AllFields) { if (!dic.ContainsKey(item.Name)) dic.Add(item.Name, item as Field); else if (!item.ColumnName.IsNullOrEmpty() && !dic.ContainsKey(item.ColumnName)) dic.Add(item.ColumnName, item as Field); } // 宁可重复计算,也要避免锁 _all = dic; } if (_all.TryGetValue(name, out var f)) return f; foreach (var item in Fields) { if (item.Name.EqualIgnoreCase(name)) return item as Field; } foreach (var item in Fields) { if (item.ColumnName.EqualIgnoreCase(name)) return item as Field; } foreach (var item in AllFields) { if (item.Name.EqualIgnoreCase(name)) return item as Field; } return null; } /// <summary>已重载。</summary> /// <returns></returns> public override String ToString() { if (String.IsNullOrEmpty(Description)) return TableName; else return $"{TableName}({Description})"; } #endregion #region 动态增加字段 /// <summary>动态增加字段</summary> /// <param name="name"></param> /// <param name="type"></param> /// <param name="description"></param> /// <param name="length"></param> /// <returns></returns> public TableItem Add(String name, Type type, String description = null, Int32 length = 0) { var f = new Field(this, name, type, description, length); var list = new List<FieldItem>(Fields) { f }; Fields = list.ToArray(); list = new List<FieldItem>(AllFields) { f }; AllFields = list.ToArray(); var dc = DataTable.CreateColumn(); f.Fill(dc); DataTable.Columns.Add(dc); return this; } #endregion } }
35.924107
147
0.458556
[ "MIT" ]
NewLifeX/NewLife.XCode
XCode/Configuration/TableItem.cs
17,116
C#
using Content.Server.GameObjects; using Robust.Shared.Interfaces.GameObjects; namespace Content.Server.AI.Operators.Inventory { public class DropHandItemsOperator : AiOperator { private readonly IEntity _owner; public DropHandItemsOperator(IEntity owner) { _owner = owner; } public override Outcome Execute(float frameTime) { if (!_owner.TryGetComponent(out HandsComponent handsComponent)) { return Outcome.Failed; } foreach (var item in handsComponent.GetAllHeldItems()) { handsComponent.Drop(item.Owner); } return Outcome.Success; } } }
24.387097
75
0.57672
[ "MIT" ]
Watermelon914/space-station-14
Content.Server/AI/Operators/Inventory/DropHandItemsOperator.cs
756
C#
// ReSharper disable once CheckNamespace namespace HandyControlDemo.UserControl { public partial class ClockDemoCtl { public ClockDemoCtl() { InitializeComponent(); } } }
19.909091
41
0.625571
[ "MIT" ]
ZeroX-V/HandyControl
HandyControlDemo/UserControl/Controls/ClockDemoCtl.xaml.cs
221
C#
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; namespace AreasRotas.Areas.Admin.Controllers { public class NoticiaController : Controller { // GET: Admin/Noticia public ActionResult Index() { return View(); } } }
19.411765
47
0.642424
[ "MIT" ]
xtuser777/VSFIPP2018
AreasRotas/AreasRotas/Areas/Admin/Controllers/NoticiaController.cs
332
C#
using System; using System.Collections.Generic; using System.Reflection; using System.Reflection.Emit; using HarmonyLib; using TaleWorlds.CampaignSystem; using TaleWorlds.Core; using TaleWorlds.Engine; using TaleWorlds.Library; using TaleWorlds.Localization; using TaleWorlds.ObjectSystem; using SandBox; namespace QOLfixes { [HarmonyPatch] static class SkipCampaignIntroAndCharCreation { public static Dictionary<string, Vec2> _startingPoints = new Dictionary<string, Vec2> { { "empire", new Vec2(657.95f, 279.08f) }, { "sturgia", new Vec2(356.75f, 551.52f) }, { "aserai", new Vec2(300.78f, 259.99f) }, { "battania", new Vec2(293.64f, 446.39f) }, { "khuzait", new Vec2(680.73f, 480.8f) }, { "vlandia", new Vec2(207.04f, 389.04f) } }; [HarmonyTranspiler] [HarmonyPatch(typeof(SandBoxGameManager), nameof(SandBoxGameManager.OnLoadFinished))] public static IEnumerable<CodeInstruction> PatchOnLoadFinished(IEnumerable<CodeInstruction> instructions) { MethodInfo fromMethod = AccessTools.Method(typeof(SandBoxGameManager), nameof(SandBoxGameManager.LaunchSandboxCharacterCreation)); MethodInfo toMethod = SymbolExtensions.GetMethodInfo(() => SkipCampaignIntroAndCharCreation.HandleQuickStart()); MethodInfo GetDevMode = AccessTools.PropertyGetter(typeof(TaleWorlds.Core.Game), nameof(TaleWorlds.Core.Game.IsDevelopmentMode)); CodeInstruction prevInstruc = new CodeInstruction(OpCodes.Nop); Label? funcEnd; foreach (var instruc in instructions) { if (ConfigFileManager.configs.skipCharacterCreation && instruc.opcode == OpCodes.Ldftn && instruc.operand as MethodInfo == fromMethod) instruc.operand = toMethod; if (ConfigFileManager.configs.skipCampaignIntro && prevInstruc.Calls(GetDevMode) && instruc.Branches(out funcEnd)) { //Load true so it definitely skips loading campaign video yield return new CodeInstruction(OpCodes.Pop); yield return new CodeInstruction(OpCodes.Ldc_I4_1); } prevInstruc = instruc; yield return instruc; } } public static IEnumerable<CultureObject> GetCultures() { foreach (CultureObject cultureObject in MBObjectManager.Instance.GetObjectTypeList<CultureObject>()) { if (cultureObject.IsMainCulture) { yield return cultureObject; } } } public static void HandleQuickStart() { /* Skip creating CharacterCreationStages and what not entirely. Instead set values of Hero and Clan directly * and initialize the call to MapState to load campaign. */ /* * 1) <CharacterCreationState> calls initializes which traces back to <CharacterCreationContentBase> which calls * * this.initializeMainheroStats() */ // Initialize Hero SKills/Attributes Hero.MainHero.HeroDeveloper.ClearHero(); Hero.MainHero.HitPoints = 100; Hero.MainHero.SetBirthDay(CampaignTime.YearsFromNow(-20)); Hero.MainHero.SetName(new TextObject("Umer"), null); Hero.MainHero.HeroDeveloper.UnspentFocusPoints = 15; Hero.MainHero.HeroDeveloper.UnspentAttributePoints = 15; Hero.MainHero.HeroDeveloper.SetInitialLevel(1); foreach (SkillObject skill in Skills.All) { Hero.MainHero.HeroDeveloper.InitializeSkillXp(skill); } foreach (CharacterAttribute attrib in Attributes.All) { Hero.MainHero.HeroDeveloper.AddAttribute(attrib, 2, false); } //Apply Culture Clan.PlayerClan.ChangeClanName(Helpers.FactionHelper.GenerateClanNameforPlayer()); CharacterObject.PlayerCharacter.Culture = SkipCampaignIntroAndCharCreation.GetCultures().GetRandomElementInefficiently<CultureObject>(); Clan.PlayerClan.Culture = CharacterObject.PlayerCharacter.Culture; Clan.PlayerClan.UpdateHomeSettlement(null); Clan.PlayerClan.Renown = 0f; Hero.MainHero.BornSettlement = Clan.PlayerClan.HomeSettlement; //Can apply equipments here but we skip, since goal is to test campaign. We can make do with random/default. /* 2) <CharacterCreationState> calls <FinalizeCharacterCreation()> * This calls * * CharacterCreationScreen.OnCharacterCreationFinalized() * this.CurrentCharacterCreationContent.OnCharacterCreationFinalized(); * CampaignEventDispatcher.Instance.OnCharacterCreationIsOver(); * * These calls mainly do the main work of applying culture and initializing main hero stats which we have done above, * Hence we only need to initialize MapState now and teleport the camera onto map where party is. */ LoadingWindow.EnableGlobalLoadingWindow(); Game.Current.GameStateManager.CleanAndPushState(Game.Current.GameStateManager.CreateState<MapState>(), 0); PartyBase.MainParty.Visuals.SetMapIconAsDirty(); CultureObject culture = CharacterObject.PlayerCharacter.Culture; Vec2 position2D; if (_startingPoints.TryGetValue(culture.StringId, out position2D)) { MobileParty.MainParty.Position2D = position2D; } else { MobileParty.MainParty.Position2D = Campaign.Current.DefaultStartingPosition; FileLog.Log("Selected culture is not in the dictionary!" + "\r\nIn HandleQuickStart(), Line No: 224 at <SkipIntro.cs>"); } CampaignEventDispatcher.Instance.OnCharacterCreationIsOver(); MapState mapState; if ((mapState = (GameStateManager.Current.ActiveState as MapState)) != null) { mapState.Handler.ResetCamera(); mapState.Handler.TeleportCameraToMainParty(); } } } }
41.302469
150
0.607981
[ "MIT" ]
gallickgunner/Bannerlord-QOLfixes
QOLfixes/Patches/SkipCampaignIntroAndCharCreation.cs
6,693
C#
using System; using NUnit.Framework; namespace MemoryCacheT.Test.CacheItem { [TestFixture] internal class NonExpiringCacheItemTests : CacheItemTestBase { [Test] public void IsExpired_CurrentTimeIsPast_ReturnsFalse() { bool isExpired = _cacheItem.IsExpired; Assert.False(isExpired); } [Test] public void CreateNewCacheItem_NewValue_ValueIsUpdated() { int newValue = _value + 7; ICacheItem<int> newCacheItem = _cacheItem.CreateNewCacheItem(newValue); Assert.AreEqual(newValue, newCacheItem.Value); } [Test] public void CreateNewCacheItem_NewValue_OnExpireIsAssigned() { int newValue = _value + 7; Action<int, DateTime> onExpire = (i, time) => { }; _cacheItem.OnExpire = onExpire; ICacheItem<int> newCacheItem = _cacheItem.CreateNewCacheItem(newValue); Assert.AreEqual(onExpire, newCacheItem.OnExpire); } [Test] public void CreateNewCacheItem_NewValue_OnRemoveIsAssigned() { int newValue = _value + 7; Action<int, DateTime> onRemove = (i, time) => { }; _cacheItem.OnRemove = onRemove; ICacheItem<int> newCacheItem = _cacheItem.CreateNewCacheItem(newValue); Assert.AreEqual(onRemove, newCacheItem.OnRemove); } } }
28.313725
83
0.612188
[ "MIT" ]
uhaciogullari/MemoryCacheT
MemoryCacheT.Test/CacheItem/NonExpiringCacheItemTests.cs
1,444
C#
/* * Swagger Petstore * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * * OpenAPI spec version: 1.0.0 * Contact: apiteam@swagger.io * Generated by: https://github.com/swagger-api/swagger-codegen.git */ using System; using System.Linq; using System.IO; using System.Text; using System.Text.RegularExpressions; using System.Collections; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Runtime.Serialization; using Newtonsoft.Json; using Newtonsoft.Json.Converters; using System.ComponentModel.DataAnnotations; using SwaggerDateConverter = IO.Swagger.Client.SwaggerDateConverter; namespace IO.Swagger.Model { /// <summary> /// Cat /// </summary> [DataContract] public partial class Cat : Animal, IEquatable<Cat> { /// <summary> /// Initializes a new instance of the <see cref="Cat" /> class. /// </summary> /// <param name="declawed">declawed.</param> public Cat(bool? declawed = default(bool?), string className = default(string), string color = "red") : base(className, color) { this.Declawed = declawed; } /// <summary> /// Gets or Sets Declawed /// </summary> [DataMember(Name="declawed", EmitDefaultValue=false)] public bool? Declawed { get; set; } /// <summary> /// Returns the string presentation of the object /// </summary> /// <returns>String presentation of the object</returns> public override string ToString() { var sb = new StringBuilder(); sb.Append("class Cat {\n"); sb.Append(" ").Append(base.ToString().Replace("\n", "\n ")).Append("\n"); sb.Append(" Declawed: ").Append(Declawed).Append("\n"); sb.Append("}\n"); return sb.ToString(); } /// <summary> /// Returns the JSON string presentation of the object /// </summary> /// <returns>JSON string presentation of the object</returns> public override string ToJson() { return JsonConvert.SerializeObject(this, Formatting.Indented); } /// <summary> /// Returns true if objects are equal /// </summary> /// <param name="input">Object to be compared</param> /// <returns>Boolean</returns> public override bool Equals(object input) { return this.Equals(input as Cat); } /// <summary> /// Returns true if Cat instances are equal /// </summary> /// <param name="input">Instance of Cat to be compared</param> /// <returns>Boolean</returns> public bool Equals(Cat input) { if (input == null) return false; return base.Equals(input) && ( this.Declawed == input.Declawed || (this.Declawed != null && this.Declawed.Equals(input.Declawed)) ); } /// <summary> /// Gets the hash code /// </summary> /// <returns>Hash code</returns> public override int GetHashCode() { unchecked // Overflow is fine, just wrap { int hashCode = base.GetHashCode(); if (this.Declawed != null) hashCode = hashCode * 59 + this.Declawed.GetHashCode(); return hashCode; } } } }
31.782609
159
0.559508
[ "Apache-2.0" ]
Cadcorp/swagger-codegen
samples/client/petstore/csharp/SwaggerClientNet35/src/IO.Swagger/Model/Cat.cs
3,655
C#
namespace Thrinax.Chardet.NChardet { /// <summary> /// Description of BIG5Verifier. /// </summary> public sealed class BIG5Verifier : Verifier { static int[] _cclass ; static int[] _states ; static int _stFactor ; static string _charset ; public override int[] cclass() { return _cclass ; } public override int[] states() { return _states ; } public override int stFactor() { return _stFactor ; } public override string charset() { return _charset ; } public BIG5Verifier() { _cclass = new int[256/8] ; _cclass[0] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[1] = ((int)((( ((int)((( ((int)((( 0) << 4) | (0))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[2] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[3] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((0) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[4] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[5] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[6] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[7] = ((int)((( ((int)((( ((int)((( 1) << 4) | (1))) ) << 8) | (((int)(((1) << 4) | ( 1))) ))) ) << 16) | ( ((int)((( ((int)(((1) << 4) | (1))) ) << 8) | ( ((int)(((1) << 4) | (1))) )))))) ; _cclass[8] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[9] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[10] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[11] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[12] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[13] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[14] = ((int)((( ((int)((( ((int)((( 2) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[15] = ((int)((( ((int)((( ((int)((( 1) << 4) | (2))) ) << 8) | (((int)(((2) << 4) | ( 2))) ))) ) << 16) | ( ((int)((( ((int)(((2) << 4) | (2))) ) << 8) | ( ((int)(((2) << 4) | (2))) )))))) ; _cclass[16] = ((int)((( ((int)((( ((int)((( 4) << 4) | (4))) ) << 8) | (((int)(((4) << 4) | ( 4))) ))) ) << 16) | ( ((int)((( ((int)(((4) << 4) | (4))) ) << 8) | ( ((int)(((4) << 4) | (4))) )))))) ; _cclass[17] = ((int)((( ((int)((( ((int)((( 4) << 4) | (4))) ) << 8) | (((int)(((4) << 4) | ( 4))) ))) ) << 16) | ( ((int)((( ((int)(((4) << 4) | (4))) ) << 8) | ( ((int)(((4) << 4) | (4))) )))))) ; _cclass[18] = ((int)((( ((int)((( ((int)((( 4) << 4) | (4))) ) << 8) | (((int)(((4) << 4) | ( 4))) ))) ) << 16) | ( ((int)((( ((int)(((4) << 4) | (4))) ) << 8) | ( ((int)(((4) << 4) | (4))) )))))) ; _cclass[19] = ((int)((( ((int)((( ((int)((( 4) << 4) | (4))) ) << 8) | (((int)(((4) << 4) | ( 4))) ))) ) << 16) | ( ((int)((( ((int)(((4) << 4) | (4))) ) << 8) | ( ((int)(((4) << 4) | (4))) )))))) ; _cclass[20] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (4))) )))))) ; _cclass[21] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[22] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[23] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[24] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[25] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[26] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[27] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[28] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[29] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[30] = ((int)((( ((int)((( ((int)((( 3) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _cclass[31] = ((int)((( ((int)((( ((int)((( 0) << 4) | (3))) ) << 8) | (((int)(((3) << 4) | ( 3))) ))) ) << 16) | ( ((int)((( ((int)(((3) << 4) | (3))) ) << 8) | ( ((int)(((3) << 4) | (3))) )))))) ; _states = new int[3] ; _states[0] = ((int)((( ((int)((( ((int)((( eError) << 4) | (eError))) ) << 8) | (((int)(((eError) << 4) | ( eError))) ))) ) << 16) | ( ((int)((( ((int)((( 3) << 4) | (eStart))) ) << 8) | ( ((int)(((eStart) << 4) | (eError))) )))))) ; _states[1] = ((int)((( ((int)((( ((int)((( eError) << 4) | (eItsMe))) ) << 8) | (((int)(((eItsMe) << 4) | ( eItsMe))) ))) ) << 16) | ( ((int)((( ((int)(((eItsMe) << 4) | (eItsMe))) ) << 8) | ( ((int)(((eError) << 4) | (eError))) )))))) ; _states[2] = ((int)((( ((int)((( ((int)((( eStart) << 4) | (eStart))) ) << 8) | (((int)(((eStart) << 4) | ( eStart))) ))) ) << 16) | ( ((int)((( ((int)(((eStart) << 4) | (eStart))) ) << 8) | ( ((int)(((eStart) << 4) | (eError))) )))))) ; _charset = "Big5"; _stFactor = 5; } public override bool isUCS2() { return false; } } }
126.738462
250
0.260743
[ "Apache-2.0" ]
GlaryJoker/thrinax
src/Thrinax/Chardet/NChardet/BIG5Verifier.cs
8,240
C#