diff --git a/middleware/JsonCSharpClassGeneratorLib/CodeWriters/CSharpCodeWriter.cs b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/CSharpCodeWriter.cs new file mode 100644 index 0000000..7f90ea3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/CSharpCodeWriter.cs @@ -0,0 +1,302 @@ +using Newtonsoft.Json; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator.CodeWriters +{ + public class CSharpCodeWriter : ICodeWriter + { + public string FileExtension + { + get { return ".cs"; } + } + + public string DisplayName + { + get { return "C#"; } + } + + + private const string NoRenameAttribute = "[Obfuscation(Feature = \"renaming\", Exclude = true)]"; + private const string NoPruneAttribute = "[Obfuscation(Feature = \"trigger\", Exclude = false)]"; + + public string GetTypeName(JsonType type, IJsonClassGeneratorConfig config) + { + var arraysAsLists = !config.ExplicitDeserialization; + + switch (type.Type) + { + case JsonTypeEnum.Anything: return "object"; + case JsonTypeEnum.Array: return arraysAsLists ? "IList<" + GetTypeName(type.InternalType, config) + ">" : GetTypeName(type.InternalType, config) + "[]"; + case JsonTypeEnum.Dictionary: return "Dictionary"; + case JsonTypeEnum.Boolean: return "bool"; + case JsonTypeEnum.Float: return "double"; + case JsonTypeEnum.Integer: return "int"; + case JsonTypeEnum.Long: return "long"; + case JsonTypeEnum.Date: return "DateTime"; + case JsonTypeEnum.NonConstrained: return "object"; + case JsonTypeEnum.NullableBoolean: return "bool?"; + case JsonTypeEnum.NullableFloat: return "double?"; + case JsonTypeEnum.NullableInteger: return "int?"; + case JsonTypeEnum.NullableLong: return "long?"; + case JsonTypeEnum.NullableDate: return "DateTime?"; + case JsonTypeEnum.NullableSomething: return "object"; + case JsonTypeEnum.Object: return type.AssignedName; + case JsonTypeEnum.String: return "string"; + default: throw new System.NotSupportedException("Unsupported json type"); + } + } + + + private bool ShouldApplyNoRenamingAttribute(IJsonClassGeneratorConfig config) + { + return config.ApplyObfuscationAttributes && !config.ExplicitDeserialization && !config.UsePascalCase; + } + private bool ShouldApplyNoPruneAttribute(IJsonClassGeneratorConfig config) + { + return config.ApplyObfuscationAttributes && !config.ExplicitDeserialization && config.UseProperties; + } + + public void WriteFileStart(IJsonClassGeneratorConfig config, TextWriter sw) + { + if (config.UseNamespaces) + { + foreach (var line in JsonClassGenerator.FileHeader) + { + sw.WriteLine("// " + line); + } + sw.WriteLine(); + sw.WriteLine("using System;"); + sw.WriteLine("using System.Collections.Generic;"); + if (ShouldApplyNoPruneAttribute(config) || ShouldApplyNoRenamingAttribute(config)) + sw.WriteLine("using System.Reflection;"); + if (!config.ExplicitDeserialization && config.UsePascalCase) + sw.WriteLine("using Newtonsoft.Json;"); + sw.WriteLine("using Newtonsoft.Json.Linq;"); + if (config.ExplicitDeserialization) + sw.WriteLine("using JsonCSharpClassGenerator;"); + if (config.SecondaryNamespace != null && config.HasSecondaryClasses && !config.UseNestedClasses) + { + sw.WriteLine("using {0};", config.SecondaryNamespace); + } + } + + if (config.UseNestedClasses) + { + sw.WriteLine(" {0} class {1}", config.InternalVisibility ? "internal" : "public", config.MainClass); + sw.WriteLine(" {"); + } + } + + public void WriteFileEnd(IJsonClassGeneratorConfig config, TextWriter sw) + { + if (config.UseNestedClasses) + { + sw.WriteLine(" }"); + } + } + + + public void WriteNamespaceStart(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + sw.WriteLine(); + sw.WriteLine("namespace {0}", root && !config.UseNestedClasses ? config.Namespace : (config.SecondaryNamespace ?? config.Namespace)); + sw.WriteLine("{"); + sw.WriteLine(); + } + + public void WriteNamespaceEnd(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + sw.WriteLine("}"); + } + + public void WriteClass(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type) + { + var visibility = config.InternalVisibility ? "internal" : "public"; + + + + if (config.UseNestedClasses) + { + if (!type.IsRoot) + { + if (ShouldApplyNoRenamingAttribute(config)) sw.WriteLine(" " + NoRenameAttribute); + if (ShouldApplyNoPruneAttribute(config)) sw.WriteLine(" " + NoPruneAttribute); + sw.WriteLine(" {0} class {1}", visibility, type.AssignedName); + sw.WriteLine(" {"); + } + } + else + { + if (ShouldApplyNoRenamingAttribute(config)) sw.WriteLine(" " + NoRenameAttribute); + if (ShouldApplyNoPruneAttribute(config)) sw.WriteLine(" " + NoPruneAttribute); + sw.WriteLine(" {0} class {1}", visibility, type.AssignedName); + sw.WriteLine(" {"); + } + + var prefix = config.UseNestedClasses && !type.IsRoot ? " " : " "; + + + var shouldSuppressWarning = config.InternalVisibility && !config.UseProperties && !config.ExplicitDeserialization; + if (shouldSuppressWarning) + { + sw.WriteLine("#pragma warning disable 0649"); + if (!config.UsePascalCase) sw.WriteLine(); + } + + if (type.IsRoot && config.ExplicitDeserialization) WriteStringConstructorExplicitDeserialization(config, sw, type, prefix); + + if (config.ExplicitDeserialization) + { + if (config.UseProperties) WriteClassWithPropertiesExplicitDeserialization(sw, type, prefix); + else WriteClassWithFieldsExplicitDeserialization(sw, type, prefix); + } + else + { + WriteClassMembers(config, sw, type, prefix); + } + + if (shouldSuppressWarning) + { + sw.WriteLine(); + sw.WriteLine("#pragma warning restore 0649"); + sw.WriteLine(); + } + + + if (config.UseNestedClasses && !type.IsRoot) + sw.WriteLine(" }"); + + if (!config.UseNestedClasses) + sw.WriteLine(" }"); + + sw.WriteLine(); + + + } + + + + private void WriteClassMembers(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type, string prefix) + { + IList theFields = type.Fields; + if (config.SortMemberFields) theFields = theFields.OrderBy(f => f.JsonMemberName).ToList(); + foreach (var field in theFields) + { + if (config.UsePascalCase || config.ExamplesInDocumentation) sw.WriteLine(); + + if (config.ExamplesInDocumentation) + { + sw.WriteLine(prefix + "/// "); + sw.WriteLine(prefix + "/// Examples: " + field.GetExamplesText()); + sw.WriteLine(prefix + "/// "); + } + + if (config.UsePascalCase) + { + + sw.WriteLine(prefix + "[JsonProperty(\"{0}\")]", field.JsonMemberName); + } + + if (config.UseProperties) + { + sw.WriteLine(prefix + "public {0} {1} {{ get; set; }}", field.Type.GetTypeName(), field.MemberName); + } + else + { + sw.WriteLine(prefix + "public {0} {1};", field.Type.GetTypeName(), field.MemberName); + } + } + + } + + + + + + + + #region Code for (obsolete) explicit deserialization + private void WriteClassWithPropertiesExplicitDeserialization(TextWriter sw, JsonType type, string prefix) + { + + sw.WriteLine(prefix + "private JObject __jobject;"); + sw.WriteLine(prefix + "public {0}(JObject obj)", type.AssignedName); + sw.WriteLine(prefix + "{"); + sw.WriteLine(prefix + " this.__jobject = obj;"); + sw.WriteLine(prefix + "}"); + sw.WriteLine(); + + foreach (var field in type.Fields) + { + + string variable = null; + if (field.Type.MustCache) + { + variable = "_" + char.ToLower(field.MemberName[0]) + field.MemberName.Substring(1); + sw.WriteLine(prefix + "[System.Diagnostics.DebuggerBrowsable(System.Diagnostics.DebuggerBrowsableState.Never)]"); + sw.WriteLine(prefix + "private {0} {1};", field.Type.GetTypeName(), variable); + } + + + sw.WriteLine(prefix + "public {0} {1}", field.Type.GetTypeName(), field.MemberName); + sw.WriteLine(prefix + "{"); + sw.WriteLine(prefix + " get"); + sw.WriteLine(prefix + " {"); + if (field.Type.MustCache) + { + sw.WriteLine(prefix + " if ({0} == null)", variable); + sw.WriteLine(prefix + " {0} = {1};", variable, field.GetGenerationCode("__jobject")); + sw.WriteLine(prefix + " return {0};", variable); + } + else + { + sw.WriteLine(prefix + " return {0};", field.GetGenerationCode("__jobject")); + } + sw.WriteLine(prefix + " }"); + sw.WriteLine(prefix + "}"); + sw.WriteLine(); + + } + + } + + + private void WriteStringConstructorExplicitDeserialization(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type, string prefix) + { + sw.WriteLine(); + sw.WriteLine(prefix + "public {1}(string json)", config.InternalVisibility ? "internal" : "public", type.AssignedName); + sw.WriteLine(prefix + " : this(JObject.Parse(json))"); + sw.WriteLine(prefix + "{"); + sw.WriteLine(prefix + "}"); + sw.WriteLine(); + } + + private void WriteClassWithFieldsExplicitDeserialization(TextWriter sw, JsonType type, string prefix) + { + + + sw.WriteLine(prefix + "public {0}(JObject obj)", type.AssignedName); + sw.WriteLine(prefix + "{"); + + foreach (var field in type.Fields) + { + sw.WriteLine(prefix + " this.{0} = {1};", field.MemberName, field.GetGenerationCode("obj")); + + } + + sw.WriteLine(prefix + "}"); + sw.WriteLine(); + + foreach (var field in type.Fields) + { + sw.WriteLine(prefix + "public readonly {0} {1};", field.Type.GetTypeName(), field.MemberName); + } + } + #endregion + + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/CodeWriters/JavaCodeWriter.cs b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/JavaCodeWriter.cs new file mode 100644 index 0000000..3df1a1a --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/JavaCodeWriter.cs @@ -0,0 +1,153 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text; +using Xamasoft.JsonClassGenerator.Utils; + +namespace Xamasoft.JsonClassGenerator.CodeWriters +{ + public class JavaCodeWriter : ICodeWriter + { + public string FileExtension + { + get { return ".java"; } + } + + public string DisplayName + { + get { return "Java"; } + } + + public string GetTypeName(JsonType type, IJsonClassGeneratorConfig config) + { + var arraysAsLists = !config.ExplicitDeserialization; + + switch (type.Type) + { + case JsonTypeEnum.Anything: return "Object"; + case JsonTypeEnum.Array: return arraysAsLists ? "IList<" + GetTypeName(type.InternalType, config) + ">" : GetTypeName(type.InternalType, config) + "[]"; + case JsonTypeEnum.Dictionary: return "Map"; + case JsonTypeEnum.Boolean: return "boolean"; + case JsonTypeEnum.Float: return "float"; + case JsonTypeEnum.Double: return "double"; + case JsonTypeEnum.Integer: return "int"; + case JsonTypeEnum.Long: return "long"; + case JsonTypeEnum.Date: return "Date"; + case JsonTypeEnum.NonConstrained: return "Object"; + case JsonTypeEnum.NullableBoolean: return "Boolean"; + case JsonTypeEnum.NullableFloat: return "Double"; + case JsonTypeEnum.NullableInteger: return "Integer"; + case JsonTypeEnum.NullableLong: return "Long"; + case JsonTypeEnum.NullableDate: return "Date"; + case JsonTypeEnum.NullableSomething: return "Object"; + case JsonTypeEnum.Object: return type.AssignedName; + case JsonTypeEnum.String: return "String"; + default: throw new System.NotSupportedException("Unsupported json type"); + } + } + + public void WriteClass(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type) + { + sw.WriteLine("/**"); + sw.WriteLine(" * Description"); + sw.WriteLine(" * "); + sw.WriteLine(" * @author Dincat@WorrilessGo"); + sw.WriteLine(" */"); + + var visibility = config.InternalVisibility ? "internal" : "public"; + + + if (config.UseNestedClasses) + { + if (!type.IsRoot) + { + sw.WriteLine("{0} class {1}", visibility, type.AssignedName); + sw.WriteLine("{"); + } + } + else + { + sw.WriteLine("{0} class {1}", visibility, type.AssignedName); + sw.WriteLine("{"); + } + + var prefix =" "; + + WriteClassMembers(config, sw, type, prefix); + + + if (config.UseNestedClasses && !type.IsRoot) + sw.WriteLine("}"); + + if (!config.UseNestedClasses) + sw.WriteLine("}"); + + //sw.WriteLine(); + } + + public void WriteFileStart(IJsonClassGeneratorConfig config, TextWriter sw) + { + + } + + public void WriteFileEnd(IJsonClassGeneratorConfig config, TextWriter sw) + { + if (config.UseNestedClasses) + { + sw.WriteLine("}"); + } + } + + public void WriteNamespaceStart(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + if (string.IsNullOrEmpty(config.Namespace)) + { + return; + } + + sw.WriteLine(); + sw.WriteLine("package ", config.Namespace); + sw.WriteLine(); + } + + public void WriteNamespaceEnd(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + + } + + + private void WriteClassMembers(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type, string prefix) + { + IList theFields = type.Fields; + if (config.SortMemberFields) theFields = theFields.OrderBy(f => f.JsonMemberName).ToList(); + foreach (var field in theFields) + { + if (config.UsePascalCase || config.ExamplesInDocumentation) sw.WriteLine(); + + if (config.ExamplesInDocumentation) + { + sw.WriteLine(prefix + "/**"); + sw.WriteLine(prefix + " * Examples: " + field.GetExamplesText()); + sw.WriteLine(prefix + "*/"); + } + + if (config.UsePascalCase) + { + sw.WriteLine(prefix + "@JsonProperty(value=\"{0}\")", field.JsonMemberName); + } + + var lowCaseName = StringUtils.LowerCaseFirstLetter(field.MemberName); + sw.WriteLine(prefix + "private {0} {1};", field.Type.GetTypeName(), lowCaseName); + sw.WriteLine(); + sw.WriteLine(prefix + "public {0} get{1}(){{ return {2}; }}", field.Type.GetTypeName(), field.MemberName, lowCaseName); + sw.WriteLine(); + sw.WriteLine(prefix + "private {0} set{1}({2}){{ this.{3}={4} }}", field.Type.GetTypeName(), field.MemberName, lowCaseName, lowCaseName, lowCaseName); + + + } + + } + + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/CodeWriters/TypeScriptCodeWriter.cs b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/TypeScriptCodeWriter.cs new file mode 100644 index 0000000..166a7b3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/TypeScriptCodeWriter.cs @@ -0,0 +1,118 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator.CodeWriters +{ + public class TypeScriptCodeWriter : ICodeWriter + { + public string FileExtension + { + get { return ".ts"; } + } + + public string DisplayName + { + get { return "TypeScript"; } + } + + public string GetTypeName(JsonType type, IJsonClassGeneratorConfig config) + { + switch (type.Type) + { + case JsonTypeEnum.Anything: return "any"; + case JsonTypeEnum.String: return "string"; + case JsonTypeEnum.Boolean: return "bool"; + case JsonTypeEnum.Integer: + case JsonTypeEnum.Long: + case JsonTypeEnum.Float: return "number"; + case JsonTypeEnum.Date: return "Date"; + case JsonTypeEnum.NullableInteger: + case JsonTypeEnum.NullableLong: + case JsonTypeEnum.NullableFloat: return "number"; + case JsonTypeEnum.NullableBoolean: return "bool"; + case JsonTypeEnum.NullableDate: return "Date"; + case JsonTypeEnum.Object: return type.AssignedName; + case JsonTypeEnum.Array: return GetTypeName(type.InternalType, config) + "[]"; + case JsonTypeEnum.Dictionary: return "{ [key: string]: " + GetTypeName(type.InternalType, config) + "; }"; + case JsonTypeEnum.NullableSomething: return "any"; + case JsonTypeEnum.NonConstrained: return "any"; + default: throw new NotSupportedException("Unsupported type"); + } + } + + public void WriteClass(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type) + { + var prefix = GetNamespace(config, type.IsRoot) != null ? " " : ""; + var exported = !config.InternalVisibility || config.SecondaryNamespace != null; + sw.WriteLine(prefix + (exported ? "export " : string.Empty) + "interface " + type.AssignedName + " {"); + foreach (var field in type.Fields) + { + var shouldDefineNamespace = type.IsRoot && config.SecondaryNamespace != null && config.Namespace != null && (field.Type.Type == JsonTypeEnum.Object || (field.Type.InternalType != null && field.Type.InternalType.Type == JsonTypeEnum.Object)); + if (config.ExamplesInDocumentation) + { + sw.WriteLine(); + sw.WriteLine(prefix + " /**"); + sw.WriteLine(prefix + " * Examples: " + field.GetExamplesText()); + sw.WriteLine(prefix + " */"); + } + + + sw.WriteLine(prefix + " " + field.JsonMemberName + (IsNullable(field.Type.Type) ? "?" : "") + ": " + (shouldDefineNamespace ? config.SecondaryNamespace + "." : string.Empty) + GetTypeName(field.Type, config) + ";"); + } + sw.WriteLine(prefix + "}"); + sw.WriteLine(); + } + + private bool IsNullable(JsonTypeEnum type) + { + return + type == JsonTypeEnum.NullableBoolean || + type == JsonTypeEnum.NullableDate || + type == JsonTypeEnum.NullableFloat || + type == JsonTypeEnum.NullableInteger || + type == JsonTypeEnum.NullableLong || + type == JsonTypeEnum.NullableSomething; + } + + public void WriteFileStart(IJsonClassGeneratorConfig config, TextWriter sw) + { + foreach (var line in JsonClassGenerator.FileHeader) + { + sw.WriteLine("// " + line); + } + sw.WriteLine(); + } + + public void WriteFileEnd(IJsonClassGeneratorConfig config, TextWriter sw) + { + } + + private string GetNamespace(IJsonClassGeneratorConfig config, bool root) + { + return root ? config.Namespace : (config.SecondaryNamespace ?? config.Namespace); + } + + public void WriteNamespaceStart(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + if (GetNamespace(config, root) != null) + { + + sw.WriteLine("module " + GetNamespace(config, root) + " {"); + sw.WriteLine(); + } + } + + public void WriteNamespaceEnd(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + if (GetNamespace(config, root) != null) + { + sw.WriteLine("}"); + sw.WriteLine(); + } + } + + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/CodeWriters/VisualBasicCodeWriter.cs b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/VisualBasicCodeWriter.cs new file mode 100644 index 0000000..5376b6e --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/CodeWriters/VisualBasicCodeWriter.cs @@ -0,0 +1,168 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator.CodeWriters +{ + public class VisualBasicCodeWriter : ICodeWriter + { + public string FileExtension + { + get { return ".vb"; } + } + + public string DisplayName + { + get { return "Visual Basic .NET"; } + } + + private const string NoRenameAttribute = ""; + private const string NoPruneAttribute = ""; + + public string GetTypeName(JsonType type, IJsonClassGeneratorConfig config) + { + var arraysAsLists = config.ExplicitDeserialization; + + switch (type.Type) + { + case JsonTypeEnum.Anything: return "Object"; + case JsonTypeEnum.Array: return arraysAsLists ? "IList(Of " + GetTypeName(type.InternalType, config) + ")" : GetTypeName(type.InternalType, config) + "()"; + case JsonTypeEnum.Dictionary: return "Dictionary(Of String, " + GetTypeName(type.InternalType, config) + ")"; + case JsonTypeEnum.Boolean: return "Boolean"; + case JsonTypeEnum.Float: return "Double"; + case JsonTypeEnum.Integer: return "Integer"; + case JsonTypeEnum.Long: return "Long"; + case JsonTypeEnum.Date: return "DateTime"; + case JsonTypeEnum.NonConstrained: return "Object"; + case JsonTypeEnum.NullableBoolean: return "Boolean?"; + case JsonTypeEnum.NullableFloat: return "Double?"; + case JsonTypeEnum.NullableInteger: return "Integer?"; + case JsonTypeEnum.NullableLong: return "Long?"; + case JsonTypeEnum.NullableDate: return "DateTime?"; + case JsonTypeEnum.NullableSomething: return "Object"; + case JsonTypeEnum.Object: return type.AssignedName; + case JsonTypeEnum.String: return "String"; + default: throw new System.NotSupportedException("Unsupported json type"); + } + } + + private bool ShouldApplyNoRenamingAttribute(IJsonClassGeneratorConfig config) + { + return config.ApplyObfuscationAttributes && !config.ExplicitDeserialization && !config.UsePascalCase; + } + private bool ShouldApplyNoPruneAttribute(IJsonClassGeneratorConfig config) + { + return config.ApplyObfuscationAttributes && !config.ExplicitDeserialization && config.UseProperties; + } + + public void WriteClass(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type) + { + var visibility = config.InternalVisibility ? "Friend" : "Public"; + + if (config.UseNestedClasses) + { + sw.WriteLine(" {0} Partial Class {1}", visibility, config.MainClass); + if (!type.IsRoot) + { + if (ShouldApplyNoRenamingAttribute(config)) sw.WriteLine(" " + NoRenameAttribute); + if (ShouldApplyNoPruneAttribute(config)) sw.WriteLine(" " + NoPruneAttribute); + sw.WriteLine(" {0} Class {1}", visibility, type.AssignedName); + } + } + else + { + if (ShouldApplyNoRenamingAttribute(config)) sw.WriteLine(" " + NoRenameAttribute); + if (ShouldApplyNoPruneAttribute(config)) sw.WriteLine(" " + NoPruneAttribute); + sw.WriteLine(" {0} Class {1}", visibility, type.AssignedName); + } + + var prefix = config.UseNestedClasses && !type.IsRoot ? " " : " "; + + WriteClassMembers(config, sw, type, prefix); + + if (config.UseNestedClasses && !type.IsRoot) + sw.WriteLine(" End Class"); + + sw.WriteLine(" End Class"); + sw.WriteLine(); + + } + + + private void WriteClassMembers(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type, string prefix) + { + foreach (var field in type.Fields) + { + if (config.UsePascalCase || config.ExamplesInDocumentation) sw.WriteLine(); + + if (config.ExamplesInDocumentation) + { + sw.WriteLine(prefix + "''' "); + sw.WriteLine(prefix + "''' Examples: " + field.GetExamplesText()); + sw.WriteLine(prefix + "''' "); + } + + + if (config.UsePascalCase) + { + sw.WriteLine(prefix + "", field.JsonMemberName); + } + + if (config.UseProperties) + { + sw.WriteLine(prefix + "Public Property {1} As {0}", field.Type.GetTypeName(), field.MemberName); + } + else + { + sw.WriteLine(prefix + "Public {1} As {0}", field.Type.GetTypeName(), field.MemberName); + } + } + + } + + + + + + public void WriteFileStart(IJsonClassGeneratorConfig config, TextWriter sw) + { + foreach (var line in JsonClassGenerator.FileHeader) + { + sw.WriteLine("' " + line); + } + sw.WriteLine(); + sw.WriteLine("Imports System"); + sw.WriteLine("Imports System.Collections.Generic"); + if (ShouldApplyNoRenamingAttribute(config) || ShouldApplyNoPruneAttribute(config)) + sw.WriteLine("Imports System.Reflection"); + if (config.UsePascalCase) + sw.WriteLine("Imports Newtonsoft.Json"); + sw.WriteLine("Imports Newtonsoft.Json.Linq"); + if (config.SecondaryNamespace != null && config.HasSecondaryClasses && !config.UseNestedClasses) + { + sw.WriteLine("Imports {0}", config.SecondaryNamespace); + } + } + + public void WriteFileEnd(IJsonClassGeneratorConfig config, TextWriter sw) + { + } + + + public void WriteNamespaceStart(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + sw.WriteLine(); + sw.WriteLine("Namespace Global.{0}", root && !config.UseNestedClasses ? config.Namespace : (config.SecondaryNamespace ?? config.Namespace)); + sw.WriteLine(); + } + + public void WriteNamespaceEnd(IJsonClassGeneratorConfig config, TextWriter sw, bool root) + { + + sw.WriteLine("End Namespace"); + + } + } +} \ No newline at end of file diff --git a/middleware/JsonCSharpClassGeneratorLib/FieldInfo.cs b/middleware/JsonCSharpClassGeneratorLib/FieldInfo.cs new file mode 100644 index 0000000..37f253b --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/FieldInfo.cs @@ -0,0 +1,83 @@ +// Copyright © 2010 Xamasoft + +using Newtonsoft.Json; +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator +{ + [DebuggerDisplay("MemberName = {MemberName}/{JsonMemberName}")] + public class FieldInfo + { + + public FieldInfo(IJsonClassGeneratorConfig generator, string jsonMemberName, JsonType type, bool usePascalCase, IList Examples) + { + this.generator = generator; + this.JsonMemberName = jsonMemberName; + this.MemberName = jsonMemberName; + if (usePascalCase) MemberName = JsonClassGenerator.ToTitleCase(MemberName); + this.Type = type; + this.Examples = Examples; + } + private IJsonClassGeneratorConfig generator; + public string MemberName { get; private set; } + public string JsonMemberName { get; private set; } + public JsonType Type { get; private set; } + public IList Examples { get; private set; } + + public void UpdateMemberName(string newMemberName) + { + MemberName = newMemberName; + JsonMemberName = newMemberName; + } + + public string GetGenerationCode(string jobject) + { + var field = this; + if (field.Type.Type == JsonTypeEnum.Array) + { + var innermost = field.Type.GetInnermostType(); + return string.Format("({1})JsonClassHelper.ReadArray<{5}>(JsonClassHelper.GetJToken({0}, \"{2}\"), JsonClassHelper.{3}, typeof({6}))", + jobject, + field.Type.GetTypeName(), + field.JsonMemberName, + innermost.GetReaderName(), + -1, + innermost.GetTypeName(), + field.Type.GetTypeName() + ); + } + else if (field.Type.Type == JsonTypeEnum.Dictionary) + { + + return string.Format("({1})JsonClassHelper.ReadDictionary<{2}>(JsonClassHelper.GetJToken({0}, \"{3}\"))", + jobject, + field.Type.GetTypeName(), + field.Type.InternalType.GetTypeName(), + field.JsonMemberName, + field.Type.GetTypeName() + ); + } + else + { + return string.Format("JsonClassHelper.{1}(JsonClassHelper.GetJToken<{2}>({0}, \"{3}\"))", + jobject, + field.Type.GetReaderName(), + field.Type.GetJTokenType(), + field.JsonMemberName); + } + + } + + + + public string GetExamplesText() + { + return string.Join(", ", Examples.Take(5).Select(x => JsonConvert.SerializeObject(x)).ToArray()); + } + + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/ICodeWriter.cs b/middleware/JsonCSharpClassGeneratorLib/ICodeWriter.cs new file mode 100644 index 0000000..5838daa --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/ICodeWriter.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator +{ + public interface ICodeWriter + { + string FileExtension { get; } + string DisplayName { get; } + string GetTypeName(JsonType type, IJsonClassGeneratorConfig config); + void WriteClass(IJsonClassGeneratorConfig config, TextWriter sw, JsonType type); + void WriteFileStart(IJsonClassGeneratorConfig config, TextWriter sw); + void WriteFileEnd(IJsonClassGeneratorConfig config, TextWriter sw); + void WriteNamespaceStart(IJsonClassGeneratorConfig config, TextWriter sw, bool root); + void WriteNamespaceEnd(IJsonClassGeneratorConfig config, TextWriter sw, bool root); + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/IJsonClassGeneratorConfig.cs b/middleware/JsonCSharpClassGeneratorLib/IJsonClassGeneratorConfig.cs new file mode 100644 index 0000000..a2dbd49 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/IJsonClassGeneratorConfig.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator +{ + public interface IJsonClassGeneratorConfig + { + string Namespace { get; set; } + string SecondaryNamespace { get; set; } + bool UseProperties { get; set; } + bool InternalVisibility { get; set; } + bool ExplicitDeserialization { get; set; } + bool NoHelperClass { get; set; } + string MainClass { get; set; } + bool SortMemberFields { get; set; } + bool UsePascalCase { get; set; } + bool UseNestedClasses { get; set; } + bool ApplyObfuscationAttributes { get; set; } + bool SingleFile { get; set; } + ICodeWriter CodeWriter { get; set; } + bool HasSecondaryClasses { get; } + bool AlwaysUseNullableValues { get; set; } + bool UseNamespaces { get; } + bool ExamplesInDocumentation { get; set; } + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/JsonClassGenerator.cs b/middleware/JsonCSharpClassGeneratorLib/JsonClassGenerator.cs new file mode 100644 index 0000000..1c303cf --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/JsonClassGenerator.cs @@ -0,0 +1,461 @@ +// Copyright © 2010 Xamasoft + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using System.IO; +using System.Diagnostics; +using System.Globalization; +using Xamasoft.JsonClassGenerator.CodeWriters; +using System.Data.Entity.Design.PluralizationServices; + +namespace Xamasoft.JsonClassGenerator +{ + public class JsonClassGenerator : IJsonClassGeneratorConfig + { + public string Example { get; set; } + public string TargetFolder { get; set; } + public string Namespace { get; set; } + public string SecondaryNamespace { get; set; } + public bool UseProperties { get; set; } + public bool InternalVisibility { get; set; } + public bool ExplicitDeserialization { get; set; } + public bool NoHelperClass { get; set; } + public string MainClass { get; set; } + public bool SortMemberFields { get; set; } + public bool UsePascalCase { get; set; } + public bool UseNestedClasses { get; set; } + public bool ApplyObfuscationAttributes { get; set; } + public bool SingleFile { get; set; } + public ICodeWriter CodeWriter { get; set; } + public TextWriter OutputStream { get; set; } + public bool AlwaysUseNullableValues { get; set; } + public bool ExamplesInDocumentation { get; set; } + public bool DeduplicateClasses { get; set; } + + private PluralizationService pluralizationService = PluralizationService.CreateService(new CultureInfo("en-us")); + + public Action FeedBack { get; set; } + + private bool used = false; + public bool UseNamespaces { get { return Namespace != null; } } + + public void GenerateClasses() + { + if (CodeWriter == null) CodeWriter = new CSharpCodeWriter(); + if (ExplicitDeserialization && !(CodeWriter is CSharpCodeWriter)) throw new ArgumentException("Explicit deserialization is obsolete and is only supported by the C# provider."); + + if (used) throw new InvalidOperationException("This instance of JsonClassGenerator has already been used. Please create a new instance."); + used = true; + + + var writeToDisk = TargetFolder != null; + if (writeToDisk && !Directory.Exists(TargetFolder)) Directory.CreateDirectory(TargetFolder); + + + JObject[] examples; + var example = Example.StartsWith("HTTP/") ? Example.Substring(Example.IndexOf("\r\n\r\n")) : Example; + using (var sr = new StringReader(example)) + using (var reader = new JsonTextReader(sr)) + { + var json = JToken.ReadFrom(reader); + if (json is JArray) + { + examples = ((JArray)json).Cast().ToArray(); + } + else if (json is JObject) + { + examples = new[] { (JObject)json }; + } + else + { + throw new Exception("Sample JSON must be either a JSON array, or a JSON object."); + } + } + + Types = new List(); + Names.Add(MainClass); + var rootType = new JsonType(this, examples[0]); + rootType.IsRoot = true; + rootType.AssignName(MainClass, MainClass); + GenerateClass(examples, rootType); + + if (DeduplicateClasses) + { + FeedBack?.Invoke("De-duplicating classes"); + DeDuplicateClasses(); + } + + FeedBack?.Invoke("Writing classes to disk."); + if (writeToDisk) + { + + var parentFolder = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location); + if (writeToDisk && !NoHelperClass && ExplicitDeserialization) File.WriteAllBytes(Path.Combine(TargetFolder, "JsonClassHelper.cs"), Properties.Resources.JsonClassHelper); + if (SingleFile) + { + WriteClassesToFile(Path.Combine(TargetFolder, MainClass + CodeWriter.FileExtension), Types); + } + else + { + + foreach (var type in Types) + { + var folder = TargetFolder; + if (!UseNestedClasses && !type.IsRoot && SecondaryNamespace != null) + { + var s = SecondaryNamespace; + if (s.StartsWith(Namespace + ".")) s = s.Substring(Namespace.Length + 1); + folder = Path.Combine(folder, s); + Directory.CreateDirectory(folder); + } + WriteClassesToFile(Path.Combine(folder, (UseNestedClasses && !type.IsRoot ? MainClass + "." : string.Empty) + type.AssignedName + CodeWriter.FileExtension), new[] { type }); + } + } + } + else if (OutputStream != null) + { + WriteClassesToFile(OutputStream, Types); + } + + } + + /// + /// De-duplicate classes. + /// + /// + /// So, we have a bunch of classes. Th eproblem is, if structures have been nested, we might end up with + /// many classes which are all duplicates in everything but name. This bit of logic is intended to clean + /// this up as best it can. + /// + /// First, we get all of the "base" classes. These are all of the classes that were the first generated + /// classes. The first occurrence of any class. We alwys want these. + /// + /// Next we may (or may not) have a list of classes that may (or may not) be duplicates of the first occurrence + /// class. For example, assume we have a first occurrence class called "Wombat". Nested clases may have been + /// generated called "Womnats2" or "Wombats3". All three classes may have the same content, so we need to + /// discard the copy classes and replace any references to them with the original Wonbats class. + /// + /// This is fun. + /// + /// + private void DeDuplicateClasses() + { + // Get the first occurrence classes (original name = assigned name) as we always want these + var newTypes = (from tt in Types + where string.Compare(tt.OriginalName, tt.AssignedName, StringComparison.InvariantCultureIgnoreCase) == 0 + select tt).ToList(); + + // If we replace references to classes (Say "Wombats2" with "Womnbats", we need to know it has + // happen4ed and we need to fix the fields. This is the list of translations. + var typeNameReplacements = new Dictionary(); + + // Get the potential duplicate classes. These are classes where the class name does not match + // the original name (i.e. we added a count to it). + var possibleDuplicates = from tt in Types + where string.Compare(tt.OriginalName, tt.AssignedName, StringComparison.InvariantCultureIgnoreCase) != 0 + select tt; + + try + { + // Check the dupliates to see if they are the same as the first occurrence classes. Add to the first + // occurrence list if they are different or create field fixup's if they are the same. We are very + // simplistic in testing for the "same" or "different". Do they hae the same number of fields and + // are the field names the same. (Note, cannot use field types as these may be one of our classes that + // we are foing to replace e.g. Wombats2 that will be replaced with Wombats). + foreach (var duplicate in possibleDuplicates) + { + var original = newTypes.FirstOrDefault(tt => tt.OriginalName == duplicate.OriginalName); + + if (FirstOccurrenceClassNotFound(original)) + { + newTypes.Add(duplicate); + continue; + } + + // Classes are the same - Merge the fields + MergeFieldFromDuplicateToOriginal(original, duplicate); + + // Two objects are the 'same', so we want to replace the duplicate with the original. We will + // need to fix-up the field types when we are done. + typeNameReplacements.Add(duplicate.AssignedName, original.AssignedName); + } + + // We now need to apply our class name translations to the new base types list. So, something that + // might currently be referring to Wombats2 wil be changed to refer to Wombats. + foreach (var jsonType in newTypes) + { + foreach (var field in jsonType.Fields) + { + var internalTypeName = GetInternalTypeName(field); + if (internalTypeName != null && typeNameReplacements.ContainsKey(internalTypeName)) + { + field.Type.InternalType.AssignName(typeNameReplacements[internalTypeName], typeNameReplacements[internalTypeName]); + } + + var typeName = GetTypeName(field); + if (typeName != null && typeNameReplacements.ContainsKey(typeName)) + { + field.Type.AssignName(typeNameReplacements[typeName], typeNameReplacements[typeName]); + } + } + } + + // Replace the previous type list with the new type list + Types.Clear(); + newTypes.ForEach(tt => Types.Add(tt)); + } + catch(Exception ex) + { + // Worst case scenario - deduplication failed, so generate all the classes. + Debug.Print($"Deduplication failed:\r\n\n{ex.Message}\r\n\r\n{ex.StackTrace}"); + } + } + + private void MergeFieldFromDuplicateToOriginal(JsonType original, JsonType duplicate) + { + var fieldDifferences = GetFieldDifferences(original.Fields, duplicate.Fields, x => x.MemberName); + foreach (var fieldDifference in fieldDifferences) + { + original.Fields.Add(duplicate.Fields.First(fld => fld.MemberName == fieldDifference)); + } + } + + private string GetInternalTypeName(FieldInfo field) + { + // Sorry about this, but we can get nulls at all sorts of levels. Quite irritating really. So we have to + // check all the way down to get the assigned name. Returns blank if we fail at any point. + return field?.Type?.InternalType?.AssignedName; + } + + private string GetTypeName(FieldInfo field) + { + // Sorry about this, but we can get nulls at all sorts of levels. Quite irritating really. So we have to + // check all the way down to get the assigned name. Returns blank if we fail at any point. + return field?.Type?.AssignedName; + } + + private bool FirstOccurrenceClassNotFound(JsonType original) { return original == null; } + + public IEnumerable GetFieldDifferences(IEnumerable source, IEnumerable other, Func keySelector) + { + var setSource = new HashSet(source.Select(keySelector)); + var setOther = new HashSet(other.Select(keySelector)); + + return setOther.Except(setSource); + } + + private void WriteClassesToFile(string path, IEnumerable types) + { + FeedBack?.Invoke($"Writing {path}"); + using (var sw = new StreamWriter(path, false, Encoding.UTF8)) + { + WriteClassesToFile(sw, types); + } + } + + private void WriteClassesToFile(TextWriter sw, IEnumerable types) + { + var inNamespace = false; + var rootNamespace = false; + + CodeWriter.WriteFileStart(this, sw); + foreach (var type in types) + { + if (UseNamespaces && inNamespace && rootNamespace != type.IsRoot && SecondaryNamespace != null) { CodeWriter.WriteNamespaceEnd(this, sw, rootNamespace); inNamespace = false; } + if (UseNamespaces && !inNamespace) { CodeWriter.WriteNamespaceStart(this, sw, type.IsRoot); inNamespace = true; rootNamespace = type.IsRoot; } + CodeWriter.WriteClass(this, sw, type); + } + if (UseNamespaces && inNamespace) CodeWriter.WriteNamespaceEnd(this, sw, rootNamespace); + CodeWriter.WriteFileEnd(this, sw); + } + + + private void GenerateClass(JObject[] examples, JsonType type) + { + var jsonFields = new Dictionary(); + var fieldExamples = new Dictionary>(); + + var first = true; + + foreach (var obj in examples) + { + foreach (var prop in obj.Properties()) + { + JsonType fieldType; + var currentType = new JsonType(this, prop.Value); + var propName = prop.Name; + if (jsonFields.TryGetValue(propName, out fieldType)) + { + + var commonType = fieldType.GetCommonType(currentType); + + jsonFields[propName] = commonType; + } + else + { + var commonType = currentType; + if (first) commonType = commonType.MaybeMakeNullable(this); + else commonType = commonType.GetCommonType(JsonType.GetNull(this)); + jsonFields.Add(propName, commonType); + fieldExamples[propName] = new List(); + } + var fe = fieldExamples[propName]; + var val = prop.Value; + if (val.Type == JTokenType.Null || val.Type == JTokenType.Undefined) + { + if (!fe.Contains(null)) + { + fe.Insert(0, null); + } + } + else + { + var v = val.Type == JTokenType.Array || val.Type == JTokenType.Object ? val : val.Value(); + if (!fe.Any(x => v.Equals(x))) + fe.Add(v); + } + } + first = false; + } + + if (UseNestedClasses) + { + foreach (var field in jsonFields) + { + Names.Add(field.Key.ToLower()); + } + } + + foreach (var field in jsonFields) + { + var fieldType = field.Value; + if (fieldType.Type == JsonTypeEnum.Object) + { + var subexamples = new List(examples.Length); + foreach (var obj in examples) + { + JToken value; + if (obj.TryGetValue(field.Key, out value)) + { + if (value.Type == JTokenType.Object) + { + subexamples.Add((JObject)value); + } + } + } + + fieldType.AssignName(CreateUniqueClassName(field.Key), field.Key); + GenerateClass(subexamples.ToArray(), fieldType); + } + + if (fieldType.InternalType != null && fieldType.InternalType.Type == JsonTypeEnum.Object) + { + var subexamples = new List(examples.Length); + foreach (var obj in examples) + { + JToken value; + if (obj.TryGetValue(field.Key, out value)) + { + if (value.Type == JTokenType.Array) + { + foreach (var item in (JArray)value) + { + if (!(item is JObject)) throw new NotSupportedException("Arrays of non-objects are not supported yet."); + subexamples.Add((JObject)item); + } + + } + else if (value.Type == JTokenType.Object) + { + foreach (var item in (JObject)value) + { + if (!(item.Value is JObject)) throw new NotSupportedException("Arrays of non-objects are not supported yet."); + + subexamples.Add((JObject)item.Value); + } + } + } + } + + field.Value.InternalType.AssignName(CreateUniqueClassNameFromPlural(field.Key), + ConvertPluralToSingle(field.Key)); + GenerateClass(subexamples.ToArray(), field.Value.InternalType); + } + } + + type.Fields = jsonFields.Select(x => new FieldInfo(this, x.Key, x.Value, UsePascalCase, fieldExamples[x.Key])).ToList(); + + FeedBack?.Invoke($"Generating class {type.AssignedName}"); + Types.Add(type); + } + + public IList Types { get; private set; } + private HashSet Names = new HashSet(); + + private string CreateUniqueClassName(string name) + { + name = ToTitleCase(name); + + var finalName = name; + var i = 2; + while (Names.Any(x => x.Equals(finalName, StringComparison.OrdinalIgnoreCase))) + { + finalName = name + i.ToString(); + i++; + } + + Names.Add(finalName); + return finalName; + } + + private string CreateUniqueClassNameFromPlural(string plural) + { + plural = ToTitleCase(plural); + return CreateUniqueClassName(pluralizationService.Singularize(plural)); + } + + private string ConvertPluralToSingle(string plural) + { + plural = ToTitleCase(plural); + return pluralizationService.Singularize(plural); + } + + + + internal static string ToTitleCase(string str) + { + var sb = new StringBuilder(str.Length); + var flag = true; + + for (int i = 0; i < str.Length; i++) + { + var c = str[i]; + if (char.IsLetterOrDigit(c)) + { + sb.Append(flag ? char.ToUpper(c) : c); + flag = false; + } + else + { + flag = true; + } + } + + return sb.ToString(); + } + + public bool HasSecondaryClasses + { + get { return Types.Count > 1; } + } + + public static readonly string[] FileHeader = new[] { + "Generated by Xamasoft JSON Class Generator", + "http://www.xamasoft.com/json-class-generator" + }; + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/JsonClassGeneratorLib.csproj b/middleware/JsonCSharpClassGeneratorLib/JsonClassGeneratorLib.csproj new file mode 100644 index 0000000..e5f13c3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/JsonClassGeneratorLib.csproj @@ -0,0 +1,88 @@ + + + + + Debug + AnyCPU + {7BEF7EAA-DE37-40FB-BD33-3DEF0685031F} + Library + Properties + Xamasoft.JsonClassGenerator + Xamasoft.JsonClassGenerator + v4.8 + 512 + + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\packages\EasyModbusTCP.5.6.0\lib\net40\EasyModbus.dll + + + ..\..\..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll + + + + + + ..\References\System.Data.Entity.Design.PluralizationServices.dll + + + + + ..\References\Xamasoft.BetterLinkLabel.dll + + + + + + + + + + + + + True + True + Resources.resx + + + + + + + + + + + ResXFileCodeGenerator + Resources.Designer.cs + Designer + + + + + \ No newline at end of file diff --git a/middleware/JsonCSharpClassGeneratorLib/JsonClassHelper.cs b/middleware/JsonCSharpClassGeneratorLib/JsonClassHelper.cs new file mode 100644 index 0000000..60db2e3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/JsonClassHelper.cs @@ -0,0 +1,198 @@ +// JSON C# Class Generator +// http://www.xamasoft.com/json-class-generator + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Newtonsoft.Json.Linq; + +namespace JsonCSharpClassGenerator +{ + internal static class JsonClassHelper + { + + public static T GetJToken(JObject obj, string field) where T : JToken + { + JToken value; + if (obj.TryGetValue(field, out value)) return GetJToken(value); + else return null; + } + + private static T GetJToken(JToken token) where T : JToken + { + if (token == null) return null; + if (token.Type == JTokenType.Null) return null; + if (token.Type == JTokenType.Undefined) return null; + return (T)token; + } + + public static string ReadString(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + return (string)value.Value; + } + + + public static bool ReadBoolean(JToken token) + { + var value = GetJToken(token); + if (value == null) throw new Newtonsoft.Json.JsonSerializationException(); + return Convert.ToBoolean(value.Value); + + } + + public static bool? ReadNullableBoolean(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + return Convert.ToBoolean(value.Value); + } + + + public static int ReadInteger(JToken token) + { + var value = GetJToken(token); + if (value == null) throw new Newtonsoft.Json.JsonSerializationException(); + return Convert.ToInt32((long)value.Value); + + } + + public static int? ReadNullableInteger(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + return Convert.ToInt32((long)value.Value); + + } + + + + public static long ReadLong(JToken token) + { + var value = GetJToken(token); + if (value == null) throw new Newtonsoft.Json.JsonSerializationException(); + return Convert.ToInt64(value.Value); + + } + + public static long? ReadNullableLong(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + return Convert.ToInt64(value.Value); + } + + + public static double ReadFloat(JToken token) + { + var value = GetJToken(token); + if (value == null) throw new Newtonsoft.Json.JsonSerializationException(); + return Convert.ToDouble(value.Value); + + } + + public static double? ReadNullableFloat(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + return Convert.ToDouble(value.Value); + + } + + + + + public static DateTime ReadDate(JToken token) + { + var value = GetJToken(token); + if (value == null) throw new Newtonsoft.Json.JsonSerializationException(); + return Convert.ToDateTime(value.Value); + + } + + public static DateTime? ReadNullableDate(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + return Convert.ToDateTime(value.Value); + + } + + public static object ReadObject(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + if (value.Type == JTokenType.Object) return value; + if (value.Type == JTokenType.Array) return ReadArray(value, ReadObject); + + var jvalue = value as JValue; + if (jvalue != null) return jvalue.Value; + + return value; + } + + public static T ReadStronglyTypedObject(JToken token) where T : class + { + var value = GetJToken(token); + if (value == null) return null; + return (T)Activator.CreateInstance(typeof(T), new object[] { token }); + + } + + + public delegate T ValueReader(JToken token); + + + + public static T[] ReadArray(JToken token, ValueReader reader) + { + var value = GetJToken(token); + if (value == null) return null; + + var array = new T[value.Count]; + for (int i = 0; i < array.Length; i++) + { + array[i] = reader(value[i]); + } + return array; + + } + + + + public static Dictionary ReadDictionary(JToken token) + { + var value = GetJToken(token); + if (value == null) return null; + + var dict = new Dictionary(); + + return dict; + } + + public static Array ReadArray(JArray jArray, ValueReader reader, Type type) + { + if (jArray == null) return null; + + var elemType = type.GetElementType(); + + var array = Array.CreateInstance(elemType, jArray.Count); + for (int i = 0; i < array.Length; i++) + { + if (elemType.IsArray) + { + array.SetValue(ReadArray(GetJToken(jArray[i]), reader, elemType), i); + } + else + { + array.SetValue(reader(jArray[i]), i); + } + + } + return array; + + } + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/JsonType.cs b/middleware/JsonCSharpClassGeneratorLib/JsonType.cs new file mode 100644 index 0000000..8cdf0f3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/JsonType.cs @@ -0,0 +1,325 @@ +// Copyright © 2010 Xamasoft + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Newtonsoft.Json.Linq; +using System.Data.Entity.Design.PluralizationServices; +using System.Globalization; + +namespace Xamasoft.JsonClassGenerator +{ + public class JsonType + { + + + private JsonType(IJsonClassGeneratorConfig generator) + { + this.generator = generator; + } + + public JsonType(IJsonClassGeneratorConfig generator, JToken token) + : this(generator) + { + + Type = GetFirstTypeEnum(token); + + if (Type == JsonTypeEnum.Array) + { + var array = (JArray)token; + InternalType = GetCommonType(generator, array.ToArray()); + } + } + + internal static JsonType GetNull(IJsonClassGeneratorConfig generator) + { + return new JsonType(generator, JsonTypeEnum.NullableSomething); + } + + private IJsonClassGeneratorConfig generator; + + internal JsonType(IJsonClassGeneratorConfig generator, JsonTypeEnum type) + : this(generator) + { + this.Type = type; + } + + + public static JsonType GetCommonType(IJsonClassGeneratorConfig generator, JToken[] tokens) + { + + if (tokens.Length == 0) return new JsonType(generator, JsonTypeEnum.NonConstrained); + + var common = new JsonType(generator, tokens[0]).MaybeMakeNullable(generator); + + for (int i = 1; i < tokens.Length; i++) + { + var current = new JsonType(generator, tokens[i]); + common = common.GetCommonType(current); + } + + return common; + + } + + internal JsonType MaybeMakeNullable(IJsonClassGeneratorConfig generator) + { + if (!generator.AlwaysUseNullableValues) return this; + return this.GetCommonType(JsonType.GetNull(generator)); + } + + + public JsonTypeEnum Type { get; private set; } + public JsonType InternalType { get; private set; } + public string AssignedName { get; private set; } + public string OriginalName { get; private set; } + + public void AssignName(string name, string originalName) + { + AssignedName = name; + OriginalName = originalName; + } + + + + public bool MustCache + { + get + { + switch (Type) + { + case JsonTypeEnum.Array: return true; + case JsonTypeEnum.Object: return true; + case JsonTypeEnum.Anything: return true; + case JsonTypeEnum.Dictionary: return true; + case JsonTypeEnum.NonConstrained: return true; + default: return false; + } + } + } + + public string GetReaderName() + { + if (Type == JsonTypeEnum.Anything || Type == JsonTypeEnum.NullableSomething || Type == JsonTypeEnum.NonConstrained) + { + return "ReadObject"; + } + if (Type == JsonTypeEnum.Object) + { + return string.Format("ReadStronglyTypedObject<{0}>", AssignedName); + } + else if (Type == JsonTypeEnum.Array) + { + return string.Format("ReadArray<{0}>", InternalType.GetTypeName()); + } + else + { + return string.Format("Read{0}", Enum.GetName(typeof(JsonTypeEnum), Type)); + } + } + + public JsonType GetInnermostType() + { + if (Type != JsonTypeEnum.Array) throw new InvalidOperationException(); + if (InternalType.Type != JsonTypeEnum.Array) return InternalType; + return InternalType.GetInnermostType(); + } + + + public string GetTypeName() + { + return generator.CodeWriter.GetTypeName(this, generator); + } + + public string GetJTokenType() + { + switch (Type) + { + case JsonTypeEnum.Boolean: + case JsonTypeEnum.Integer: + case JsonTypeEnum.Long: + case JsonTypeEnum.Float: + case JsonTypeEnum.Date: + case JsonTypeEnum.NullableBoolean: + case JsonTypeEnum.NullableInteger: + case JsonTypeEnum.NullableLong: + case JsonTypeEnum.NullableFloat: + case JsonTypeEnum.NullableDate: + case JsonTypeEnum.String: + return "JValue"; + case JsonTypeEnum.Array: + return "JArray"; + case JsonTypeEnum.Dictionary: + return "JObject"; + case JsonTypeEnum.Object: + return "JObject"; + default: + return "JToken"; + + } + } + + public JsonType GetCommonType(JsonType type2) + { + var commonType = GetCommonTypeEnum(this.Type, type2.Type); + + if (commonType == JsonTypeEnum.Array) + { + if (type2.Type == JsonTypeEnum.NullableSomething) return this; + if (this.Type == JsonTypeEnum.NullableSomething) return type2; + var commonInternalType = InternalType.GetCommonType(type2.InternalType).MaybeMakeNullable(generator); + if (commonInternalType != InternalType) return new JsonType(generator, JsonTypeEnum.Array) { InternalType = commonInternalType }; + } + + + //if (commonType == JsonTypeEnum.Dictionary) + //{ + // var commonInternalType = InternalType.GetCommonType(type2.InternalType); + // if (commonInternalType != InternalType) return new JsonType(JsonTypeEnum.Dictionary) { InternalType = commonInternalType }; + //} + + + if (this.Type == commonType) return this; + return new JsonType(generator, commonType).MaybeMakeNullable(generator); + } + + + private static bool IsNull(JsonTypeEnum type) + { + return type == JsonTypeEnum.NullableSomething; + } + + + + private JsonTypeEnum GetCommonTypeEnum(JsonTypeEnum type1, JsonTypeEnum type2) + { + if (type1 == JsonTypeEnum.NonConstrained) return type2; + if (type2 == JsonTypeEnum.NonConstrained) return type1; + + switch (type1) + { + case JsonTypeEnum.Boolean: + if (IsNull(type2)) return JsonTypeEnum.NullableBoolean; + if (type2 == JsonTypeEnum.Boolean) return type1; + break; + case JsonTypeEnum.NullableBoolean: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Boolean) return type1; + break; + case JsonTypeEnum.Integer: + if (IsNull(type2)) return JsonTypeEnum.NullableInteger; + if (type2 == JsonTypeEnum.Float) return JsonTypeEnum.Float; + if (type2 == JsonTypeEnum.Long) return JsonTypeEnum.Long; + if (type2 == JsonTypeEnum.Integer) return type1; + break; + case JsonTypeEnum.NullableInteger: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Float) return JsonTypeEnum.NullableFloat; + if (type2 == JsonTypeEnum.Long) return JsonTypeEnum.NullableLong; + if (type2 == JsonTypeEnum.Integer) return type1; + break; + case JsonTypeEnum.Float: + if (IsNull(type2)) return JsonTypeEnum.NullableFloat; + if (type2 == JsonTypeEnum.Float) return type1; + if (type2 == JsonTypeEnum.Integer) return type1; + if (type2 == JsonTypeEnum.Long) return type1; + break; + case JsonTypeEnum.NullableFloat: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Float) return type1; + if (type2 == JsonTypeEnum.Integer) return type1; + if (type2 == JsonTypeEnum.Long) return type1; + break; + case JsonTypeEnum.Long: + if (IsNull(type2)) return JsonTypeEnum.NullableLong; + if (type2 == JsonTypeEnum.Float) return JsonTypeEnum.Float; + if (type2 == JsonTypeEnum.Integer) return type1; + break; + case JsonTypeEnum.NullableLong: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Float) return JsonTypeEnum.NullableFloat; + if (type2 == JsonTypeEnum.Integer) return type1; + if (type2 == JsonTypeEnum.Long) return type1; + break; + case JsonTypeEnum.Date: + if (IsNull(type2)) return JsonTypeEnum.NullableDate; + if (type2 == JsonTypeEnum.Date) return JsonTypeEnum.Date; + break; + case JsonTypeEnum.NullableDate: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Date) return type1; + break; + case JsonTypeEnum.NullableSomething: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.String) return JsonTypeEnum.String; + if (type2 == JsonTypeEnum.Integer) return JsonTypeEnum.NullableInteger; + if (type2 == JsonTypeEnum.Float) return JsonTypeEnum.NullableFloat; + if (type2 == JsonTypeEnum.Long) return JsonTypeEnum.NullableLong; + if (type2 == JsonTypeEnum.Boolean) return JsonTypeEnum.NullableBoolean; + if (type2 == JsonTypeEnum.Date) return JsonTypeEnum.NullableDate; + if (type2 == JsonTypeEnum.Array) return JsonTypeEnum.Array; + if (type2 == JsonTypeEnum.Object) return JsonTypeEnum.Object; + break; + case JsonTypeEnum.Object: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Object) return type1; + if (type2 == JsonTypeEnum.Dictionary) throw new ArgumentException(); + break; + case JsonTypeEnum.Dictionary: + throw new ArgumentException(); + //if (IsNull(type2)) return type1; + //if (type2 == JsonTypeEnum.Object) return type1; + //if (type2 == JsonTypeEnum.Dictionary) return type1; + // break; + case JsonTypeEnum.Array: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.Array) return type1; + break; + case JsonTypeEnum.String: + if (IsNull(type2)) return type1; + if (type2 == JsonTypeEnum.String) return type1; + break; + } + + return JsonTypeEnum.Anything; + + } + + private static bool IsNull(JTokenType type) + { + return type == JTokenType.Null || type == JTokenType.Undefined; + } + + + + private static JsonTypeEnum GetFirstTypeEnum(JToken token) + { + var type = token.Type; + if (type == JTokenType.Integer) + { + if ((long)((JValue)token).Value < int.MaxValue) return JsonTypeEnum.Integer; + else return JsonTypeEnum.Long; + + } + switch (type) + { + case JTokenType.Array: return JsonTypeEnum.Array; + case JTokenType.Boolean: return JsonTypeEnum.Boolean; + case JTokenType.Float: return JsonTypeEnum.Float; + case JTokenType.Null: return JsonTypeEnum.NullableSomething; + case JTokenType.Undefined: return JsonTypeEnum.NullableSomething; + case JTokenType.String: return JsonTypeEnum.String; + case JTokenType.Object: return JsonTypeEnum.Object; + case JTokenType.Date: return JsonTypeEnum.Date; + + default: return JsonTypeEnum.Anything; + + } + } + + + public IList Fields { get; internal set; } + public bool IsRoot { get; internal set; } + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/JsonTypeEnum.cs b/middleware/JsonCSharpClassGeneratorLib/JsonTypeEnum.cs new file mode 100644 index 0000000..2ae17bd --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/JsonTypeEnum.cs @@ -0,0 +1,33 @@ +// Copyright © 2010 Xamasoft + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace Xamasoft.JsonClassGenerator +{ + public enum JsonTypeEnum + { + Anything, + String, + Boolean, + Integer, + Long, + Float, + Double, + Date, + NullableInteger, + NullableLong, + NullableFloat, + NullableBoolean, + NullableDate, + Object, + Array, + Dictionary, + NullableSomething, + NonConstrained + + + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/Properties/AssemblyInfo.cs b/middleware/JsonCSharpClassGeneratorLib/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..71cc6d8 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +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("Json Class Generator")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("Xamasoft")] +[assembly: AssemblyProduct("Json Class Generator")] +[assembly: AssemblyCopyright("Copyright © Xamasoft 2010-2013")] +[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("d85f4fb4-29b8-4315-ad2d-74f24098c968")] + +// 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.5.1.0")] +[assembly: AssemblyFileVersion("1.5.1.0")] diff --git a/middleware/JsonCSharpClassGeneratorLib/Properties/Resources.Designer.cs b/middleware/JsonCSharpClassGeneratorLib/Properties/Resources.Designer.cs new file mode 100644 index 0000000..c4befe1 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/Properties/Resources.Designer.cs @@ -0,0 +1,73 @@ +//------------------------------------------------------------------------------ +// +// 此代码由工具生成。 +// 运行时版本:4.0.30319.42000 +// +// 对此文件的更改可能会导致不正确的行为,并且如果 +// 重新生成代码,这些更改将会丢失。 +// +//------------------------------------------------------------------------------ + +namespace Xamasoft.JsonClassGenerator.Properties { + using System; + + + /// + /// 一个强类型的资源类,用于查找本地化的字符串等。 + /// + // 此类是由 StronglyTypedResourceBuilder + // 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。 + // 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen + // (以 /str 作为命令选项),或重新生成 VS 项目。 + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + internal class Resources { + + private static global::System.Resources.ResourceManager resourceMan; + + private static global::System.Globalization.CultureInfo resourceCulture; + + [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] + internal Resources() { + } + + /// + /// 返回此类使用的缓存的 ResourceManager 实例。 + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Resources.ResourceManager ResourceManager { + get { + if (object.ReferenceEquals(resourceMan, null)) { + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Xamasoft.JsonClassGenerator.Properties.Resources", typeof(Resources).Assembly); + resourceMan = temp; + } + return resourceMan; + } + } + + /// + /// 重写当前线程的 CurrentUICulture 属性,对 + /// 使用此强类型资源类的所有资源查找执行重写。 + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Globalization.CultureInfo Culture { + get { + return resourceCulture; + } + set { + resourceCulture = value; + } + } + + /// + /// 查找 System.Byte[] 类型的本地化资源。 + /// + internal static byte[] JsonClassHelper { + get { + object obj = ResourceManager.GetObject("JsonClassHelper", resourceCulture); + return ((byte[])(obj)); + } + } + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/Properties/Resources.resx b/middleware/JsonCSharpClassGeneratorLib/Properties/Resources.resx new file mode 100644 index 0000000..1d23163 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/Properties/Resources.resx @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 1.3 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ..\jsonclasshelper.cs;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/middleware/JsonCSharpClassGeneratorLib/Utils/StringUtils.cs b/middleware/JsonCSharpClassGeneratorLib/Utils/StringUtils.cs new file mode 100644 index 0000000..d76e8d9 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/Utils/StringUtils.cs @@ -0,0 +1,334 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Text.RegularExpressions; +using System.Threading.Tasks; + +namespace Xamasoft.JsonClassGenerator.Utils +{ + internal static class StringUtils + { + + public static string RemoveText(this string source, String removeText) + { + string result = string.Empty; + int i = source.IndexOf(removeText); + if (i >= 0) + { + result = source.Remove(i, removeText.Length); + return result; + } + return source; + } + + public static string GetSafeFilename(string arbitraryString) + { + var invalidChars = System.IO.Path.GetInvalidFileNameChars(); + var replaceIndex = arbitraryString.IndexOfAny(invalidChars, 0); + if (replaceIndex == -1) return arbitraryString; + + var r = new StringBuilder(); + var i = 0; + + do + { + r.Append(arbitraryString, i, replaceIndex - i); + + switch (arbitraryString[replaceIndex]) + { + case '"': + r.Append("''"); + break; + case '<': + r.Append('\u02c2'); // '˂' (modifier letter left arrowhead) + break; + case '>': + r.Append('\u02c3'); // '˃' (modifier letter right arrowhead) + break; + case '|': + r.Append('\u2223'); // '∣' (divides) + break; + case ':': + r.Append('-'); + break; + case '*': + r.Append('\u2217'); // '∗' (asterisk operator) + break; + case '\\': + case '/': + r.Append('\u2044'); // '⁄' (fraction slash) + break; + case '\0': + case '\f': + case '?': + break; + case '\t': + case '\n': + case '\r': + case '\v': + r.Append(' '); + break; + default: + r.Append('_'); + break; + } + + i = replaceIndex + 1; + replaceIndex = arbitraryString.IndexOfAny(invalidChars, i); + } while (replaceIndex != -1); + + r.Append(arbitraryString, i, arbitraryString.Length - i); + + return r.ToString(); + } + + public static int StringToInt(string str) + { + str = "" + str; + int val = 0; + int.TryParse(str, out val); + return val; + } + + public static int TryParseInt(this string str) + { + str = "" + str; + int val = 0; + int.TryParse(str, out val); + return val; + } + + public static double TryParseDouble(this string str) + { + str = "" + str; + double val = 0; + double.TryParse(str, out val); + return val; + } + + public static string[] split(this String source, String spString) + { + string[] rt = null; + rt = source.Split(new string[] { spString }, StringSplitOptions.RemoveEmptyEntries); + return rt; + } + + + + /// + /// 数据库命名法转化为驼峰命名法 + /// + /// + /// is Big Camel Caes + /// + public static string DBNamingToCamelCase(string name, bool isBigCamelCaes = false) + { + if (name == null || name.Length == 0) { return ""; } + if (name.Contains("_")) + { + string[] words = name.Split('_'); + string result = string.Empty; + for (int i = 0; i < words.Length; i++) + { + if (i == 0) + { + result = words[i]; + } + else + { + result += UpperCaseFirstLetter(words[i]); + } + } + if (isBigCamelCaes == true) + { + return UpperCaseFirstLetter(result); + } + return result; + } + else + { + if (isBigCamelCaes == true) + { + return UpperCaseFirstLetter(name); + } + + return name; + } + } + /// + /// 驼峰命名法转化为数据库命名法 + /// + /// + /// is Big Camel Caes + /// + public static string CamelCaseToDBnameing(string name, bool isBigCamelCaes = false) + { + if (name != null && name.Length > 0) + { + if (isBigCamelCaes == true) + { + name = LowerCaseFirstLetter(name); + } + char[] array = name.ToCharArray(); + string result = string.Empty; + for (int i = 0; i < array.Length; i++) + { + if (i == 0) + { + result += array[i].ToString().ToLower(); + } + else + { + if (isUpper(array[i])) + { + result += "_" + array[i].ToString().ToLower(); + } + else if (IsInt(array[i].ToString())) + { + result += "_" + array[i].ToString(); + } + else + { + result += array[i].ToString(); + } + } + } + return result; + } + return ""; + } + /// + /// 是否为整型 + /// + /// + /// + public static bool IsInt(string value) + { + return Regex.IsMatch(value, @"^[+-]?/d*$"); + } + /// + /// Json 命名改为数据库命名 + /// + /// + /// + public static string JsonCamelCaseToDBnameing(string json) + { + if (string.IsNullOrEmpty(json)) + { + return null; + } + string resultString = string.Empty; + string pattern = "([\"](\\w+?)[\"][:]{1}?)"; + MatchCollection colls = Regex.Matches(json, pattern); + for (int i = 0; i < colls.Count; i++) + { + json = json.Replace(colls[i].ToString(), DBNamingToCamelCase(colls[i].ToString())); + } + return json; + } + /// + /// Json 命名改为驼峰命名 + /// + /// + /// + public static string JsonDBnameingToCamelCase(string json) + { + if (string.IsNullOrEmpty(json)) + { + return null; + } + string resultString = string.Empty; + string pattern = "([\"](\\w+?)[\"][:]{1}?)"; + MatchCollection colls = Regex.Matches(json, pattern); + for (int i = 0; i < colls.Count; i++) + { + json = json.Replace(colls[i].ToString(), CamelCaseToDBnameing(colls[i].ToString())); + } + return json; + } + + + + /// + /// 数据库表名转化为类名 + /// + /// 数据库表名 + /// 要替换的字符 + /// 类名 + public static string dbNameToClassName(string dbname, string removeStr) + { + return upperCaseFirstLetter(dbname, removeStr); + } + + /// + /// 数据库表名转化为类名 + /// + /// 数据库表名 + /// 类名 + public static string dbNameToClassName(string dbname) + { + return UpperCaseFirstLetter(dbname); + } + + /// + /// 数据库表名转小写 + /// + /// + /// + /// + public static string dbNameToLowCase(string str, string removeStr) + { + if (string.IsNullOrEmpty(str)) return ""; + + str = str.Replace(removeStr, ""); + + return str.ToLower(); + } + + + /// + /// 将一个单词的第一个字母变为大写 + /// + /// + /// + public static string upperCaseFirstLetter(string str, string removeStr) + { + if (string.IsNullOrEmpty(str)) return ""; + + str = str.Replace(removeStr, ""); + + return str.Substring(0, 1).ToUpper() + str.Substring(1); + } + + + /// + /// 将一个单词的第一个字母变为大写 + /// + /// + /// + public static string UpperCaseFirstLetter(string str) + { + return str.Substring(0, 1).ToUpper() + str.Substring(1); + } + + /// + /// 将一个单词的第一个字母变为小写 + /// + /// + /// + public static string LowerCaseFirstLetter(string str) + { + return str.Substring(0, 1).ToLower() + str.Substring(1); + } + /// + /// 判断字符是否为大写字母 + /// + /// + /// + public static bool isUpper(char c) + { + return c > 'A' && c < 'Z'; + } + } +} diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Debug/EasyModbus.dll b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/EasyModbus.dll new file mode 100644 index 0000000..484b2da Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/EasyModbus.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Debug/EasyModbus.xml b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/EasyModbus.xml new file mode 100644 index 0000000..6b9e142 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/EasyModbus.xml @@ -0,0 +1,425 @@ + + + + EasyModbus + + + + + Implements a ModbusClient. + + + + + Constructor which determines the Master ip-address and the Master Port. + + IP-Address of the Master device + Listening port of the Master device (should be 502) + + + + Constructor which determines the Serial-Port + + Serial-Port Name e.G. "COM1" + + + + Parameterless constructor + + + + + Establish connection to Master device in case of Modbus TCP. Opens COM-Port in case of Modbus RTU + + + + + Establish connection to Master device in case of Modbus TCP. + + + + + Converts two ModbusRegisters to Float - Example: EasyModbus.ModbusClient.ConvertRegistersToFloat(modbusClient.ReadHoldingRegisters(19,2)) + + Two Register values received from Modbus + Connected float value + + + + Converts two ModbusRegisters to Float, Registers can by swapped + + Two Register values received from Modbus + Desired Word Order (Low Register first or High Register first + Connected float value + + + + Converts two ModbusRegisters to 32 Bit Integer value + + Two Register values received from Modbus + Connected 32 Bit Integer value + + + + Converts two ModbusRegisters to 32 Bit Integer Value - Registers can be swapped + + Two Register values received from Modbus + Desired Word Order (Low Register first or High Register first + Connecteds 32 Bit Integer value + + + + Convert four 16 Bit Registers to 64 Bit Integer value Register Order "LowHigh": Reg0: Low Word.....Reg3: High Word, "HighLow": Reg0: High Word.....Reg3: Low Word + + four Register values received from Modbus + 64 bit value + + + + Convert four 16 Bit Registers to 64 Bit Integer value - Registers can be swapped + + four Register values received from Modbus + Desired Word Order (Low Register first or High Register first + Connected 64 Bit Integer value + + + + Convert four 16 Bit Registers to 64 Bit double prec. value Register Order "LowHigh": Reg0: Low Word.....Reg3: High Word, "HighLow": Reg0: High Word.....Reg3: Low Word + + four Register values received from Modbus + 64 bit value + + + + Convert four 16 Bit Registers to 64 Bit double prec. value - Registers can be swapped + + four Register values received from Modbus + Desired Word Order (Low Register first or High Register first + Connected double prec. float value + + + + Converts float to two ModbusRegisters - Example: modbusClient.WriteMultipleRegisters(24, EasyModbus.ModbusClient.ConvertFloatToTwoRegisters((float)1.22)); + + Float value which has to be converted into two registers + Register values + + + + Converts float to two ModbusRegisters Registers - Registers can be swapped + + Float value which has to be converted into two registers + Desired Word Order (Low Register first or High Register first + Register values + + + + Converts 32 Bit Value to two ModbusRegisters + + Int value which has to be converted into two registers + Register values + + + + Converts 32 Bit Value to two ModbusRegisters Registers - Registers can be swapped + + Double value which has to be converted into two registers + Desired Word Order (Low Register first or High Register first + Register values + + + + Converts 64 Bit Value to four ModbusRegisters + + long value which has to be converted into four registers + Register values + + + + Converts 64 Bit Value to four ModbusRegisters - Registers can be swapped + + long value which has to be converted into four registers + Desired Word Order (Low Register first or High Register first + Register values + + + + Converts 64 Bit double prec Value to four ModbusRegisters + + double value which has to be converted into four registers + Register values + + + + Converts 64 Bit double prec. Value to four ModbusRegisters - Registers can be swapped + + double value which has to be converted into four registers + Desired Word Order (Low Register first or High Register first + Register values + + + + Converts 16 - Bit Register values to String + + Register array received via Modbus + First Register containing the String to convert + number of characters in String (must be even) + Converted String + + + + Converts a String to 16 - Bit Registers + + Register array received via Modbus + Converted String + + + + Calculates the CRC16 for Modbus-RTU + + Byte buffer to send + Number of bytes to calculate CRC + First byte in buffer to start calculating CRC + + + + Read Discrete Inputs from Server device (FC2). + + First discrete input to read + Number of discrete Inputs to read + Boolean Array which contains the discrete Inputs + + + + Read Coils from Server device (FC1). + + First coil to read + Numer of coils to read + Boolean Array which contains the coils + + + + Read Holding Registers from Master device (FC3). + + First holding register to be read + Number of holding registers to be read + Int Array which contains the holding registers + + + + Read Input Registers from Master device (FC4). + + First input register to be read + Number of input registers to be read + Int Array which contains the input registers + + + + Write single Coil to Master device (FC5). + + Coil to be written + Coil Value to be written + + + + Write single Register to Master device (FC6). + + Register to be written + Register Value to be written + + + + Write multiple coils to Master device (FC15). + + First coil to be written + Coil Values to be written + + + + Write multiple registers to Master device (FC16). + + First register to be written + register Values to be written + + + + Read/Write Multiple Registers (FC23). + + First input register to read + Number of input registers to read + First input register to write + Values to write + Int Array which contains the Holding registers + + + + Close connection to Master Device. + + + + + Destructor - Close connection to Master Device. + + + + + Returns "TRUE" if Client is connected to Server and "FALSE" if not. In case of Modbus RTU returns if COM-Port is opened + + + + + Gets or Sets the IP-Address of the Server. + + + + + Gets or Sets the Port were the Modbus-TCP Server is reachable (Standard is 502). + + + + + Gets or Sets the UDP-Flag to activate Modbus UDP. + + + + + Gets or Sets the Unit identifier in case of serial connection (Default = 0) + + + + + Gets or Sets the Baudrate for serial connection (Default = 9600) + + + + + Gets or Sets the of Parity in case of serial connection + + + + + Gets or Sets the number of stopbits in case of serial connection + + + + + Gets or Sets the connection Timeout in case of ModbusTCP connection + + + + + Gets or Sets the serial Port + + + + + Gets or Sets the Filename for the LogFile + + + + + Exception to be thrown if serial port is not opened + + + + + Exception to be thrown if Connection to Modbus device failed + + + + + Exception to be thrown if Modbus Server returns error code "Function code not supported" + + + + + Exception to be thrown if Modbus Server returns error code "quantity invalid" + + + + + Exception to be thrown if Modbus Server returns error code "starting adddress and quantity invalid" + + + + + Exception to be thrown if Modbus Server returns error code "Function Code not executed (0x04)" + + + + + Exception to be thrown if CRC Check failed + + + + + Modbus Protocol informations. + + + + When making a server TCP listen socket, will listen to this IP address. + + + + Listen to all network interfaces. + + TCP port to listen + + + + Listen to a specific network interface. + + IP address of network interface to listen + TCP port to listen + + + + Modbus TCP Server. + + + + + When creating a TCP or UDP socket, the local IP address to attach to. + + + + + Gets or Sets the Filename for the LogFile + + + + + Store Log-Data in a File + + + + + Private constructor; Ensures the access of the class only via "instance" + + + + + Returns the instance of the class (singleton) + + instance (Singleton) + + + + Store message in Log-File + + Message to append to the Log-File + + + + Store message in Log-File including Timestamp + + Message to append to the Log-File + Timestamp to add to the same Row + + + + Gets or Sets the Filename to Store Strings in a File + + + + diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Newtonsoft.Json.dll b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Newtonsoft.Json.dll new file mode 100644 index 0000000..7af125a Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Newtonsoft.Json.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Xamasoft.JsonClassGenerator.dll b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Xamasoft.JsonClassGenerator.dll new file mode 100644 index 0000000..45019c0 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Xamasoft.JsonClassGenerator.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Xamasoft.JsonClassGenerator.pdb b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Xamasoft.JsonClassGenerator.pdb new file mode 100644 index 0000000..a1a7c2d Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Debug/Xamasoft.JsonClassGenerator.pdb differ diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Release/Newtonsoft.Json.dll b/middleware/JsonCSharpClassGeneratorLib/bin/Release/Newtonsoft.Json.dll new file mode 100644 index 0000000..7af125a Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Release/Newtonsoft.Json.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Release/Xamasoft.JsonClassGenerator.dll b/middleware/JsonCSharpClassGeneratorLib/bin/Release/Xamasoft.JsonClassGenerator.dll new file mode 100644 index 0000000..b361215 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Release/Xamasoft.JsonClassGenerator.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/bin/Release/Xamasoft.JsonClassGenerator.pdb b/middleware/JsonCSharpClassGeneratorLib/bin/Release/Xamasoft.JsonClassGenerator.pdb new file mode 100644 index 0000000..a98ed71 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/bin/Release/Xamasoft.JsonClassGenerator.pdb differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/.NETFramework,Version=v4.5.2.AssemblyAttributes.cs b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/.NETFramework,Version=v4.5.2.AssemblyAttributes.cs new file mode 100644 index 0000000..ff3eeb3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/.NETFramework,Version=v4.5.2.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.5.2", FrameworkDisplayName = ".NET Framework 4.5.2")] diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/.NETFramework,Version=v4.8.AssemblyAttributes.cs b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/.NETFramework,Version=v4.8.AssemblyAttributes.cs new file mode 100644 index 0000000..3cf0af3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/.NETFramework,Version=v4.8.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")] diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/DesignTimeResolveAssemblyReferences.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/DesignTimeResolveAssemblyReferences.cache new file mode 100644 index 0000000..f5e894a Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/DesignTimeResolveAssemblyReferences.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache new file mode 100644 index 0000000..f6f82f4 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.AssemblyReference.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.AssemblyReference.cache new file mode 100644 index 0000000..fe421c3 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.AssemblyReference.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.CopyComplete b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.CopyComplete new file mode 100644 index 0000000..e69de29 diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.CoreCompileInputs.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..52d21b5 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +b5dbd2e9c9b46f20a278ab3b93a0f4c0f1714f7b diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.FileListAbsolute.txt b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..24e3a52 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.FileListAbsolute.txt @@ -0,0 +1,41 @@ +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.dll +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.pdb +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\bin\Debug\Newtonsoft.Json.dll +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.Properties.Resources.resources +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.GenerateResource.cache +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CoreCompileInputs.cache +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CopyComplete +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.dll +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.pdb +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.dll +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.pdb +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Newtonsoft.Json.dll +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.Properties.Resources.resources +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.GenerateResource.cache +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CoreCompileInputs.cache +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CopyComplete +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.dll +F:\CSharp\Project\20230829shiyanshi\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.pdb +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.dll +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.pdb +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Newtonsoft.Json.dll +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.AssemblyReference.cache +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.Properties.Resources.resources +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.GenerateResource.cache +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CoreCompileInputs.cache +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CopyComplete +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.dll +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.pdb +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\EasyModbus.dll +C:\Users\Administrator\Desktop\zdhsys20231228\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\EasyModbus.xml +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.dll +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\Xamasoft.JsonClassGenerator.pdb +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\EasyModbus.dll +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\bin\Debug\EasyModbus.xml +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.AssemblyReference.cache +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.Properties.Resources.resources +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.GenerateResource.cache +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CoreCompileInputs.cache +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\JsonClassGeneratorLib.csproj.CopyComplete +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.dll +C:\Users\Administrator\Desktop\zdhsys20250116\zdhsys\JsonCSharpClassGeneratorLib\obj\Debug\Xamasoft.JsonClassGenerator.pdb diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.GenerateResource.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.GenerateResource.cache new file mode 100644 index 0000000..f36a988 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/JsonClassGeneratorLib.csproj.GenerateResource.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll new file mode 100644 index 0000000..ec01563 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.Properties.Resources.resources b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.Properties.Resources.resources new file mode 100644 index 0000000..544f0b7 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.Properties.Resources.resources differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.dll b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.dll new file mode 100644 index 0000000..45019c0 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.pdb b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.pdb new file mode 100644 index 0000000..a1a7c2d Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Debug/Xamasoft.JsonClassGenerator.pdb differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/.NETFramework,Version=v4.5.2.AssemblyAttributes.cs b/middleware/JsonCSharpClassGeneratorLib/obj/Release/.NETFramework,Version=v4.5.2.AssemblyAttributes.cs new file mode 100644 index 0000000..ff3eeb3 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Release/.NETFramework,Version=v4.5.2.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.5.2", FrameworkDisplayName = ".NET Framework 4.5.2")] diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/DesignTimeResolveAssemblyReferencesInput.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Release/DesignTimeResolveAssemblyReferencesInput.cache new file mode 100644 index 0000000..c27a89d Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.AssemblyReference.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.AssemblyReference.cache new file mode 100644 index 0000000..547d106 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.AssemblyReference.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.CopyComplete b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.CopyComplete new file mode 100644 index 0000000..e69de29 diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.CoreCompileInputs.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..80ebd32 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +d850a0e32f3df46e9695ba932ef235ed248c0afe diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.FileListAbsolute.txt b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..29e50fd --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.FileListAbsolute.txt @@ -0,0 +1,9 @@ +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\bin\Release\Xamasoft.JsonClassGenerator.dll +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\bin\Release\Xamasoft.JsonClassGenerator.pdb +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\bin\Release\Newtonsoft.Json.dll +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Release\Xamasoft.JsonClassGenerator.Properties.Resources.resources +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Release\JsonClassGeneratorLib.csproj.GenerateResource.cache +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Release\JsonClassGeneratorLib.csproj.CoreCompileInputs.cache +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Release\JsonClassGeneratorLib.csproj.CopyComplete +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Release\Xamasoft.JsonClassGenerator.dll +F:\CSharp\recCode\20231202\JsonTool-main\JsonCSharpClassGeneratorLib\obj\Release\Xamasoft.JsonClassGenerator.pdb diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.GenerateResource.cache b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.GenerateResource.cache new file mode 100644 index 0000000..6212607 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/JsonClassGeneratorLib.csproj.GenerateResource.cache differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/TempPE/Properties.Resources.Designer.cs.dll b/middleware/JsonCSharpClassGeneratorLib/obj/Release/TempPE/Properties.Resources.Designer.cs.dll new file mode 100644 index 0000000..c40db74 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/TempPE/Properties.Resources.Designer.cs.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.Properties.Resources.resources b/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.Properties.Resources.resources new file mode 100644 index 0000000..544f0b7 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.Properties.Resources.resources differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.dll b/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.dll new file mode 100644 index 0000000..b361215 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.dll differ diff --git a/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.pdb b/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.pdb new file mode 100644 index 0000000..a98ed71 Binary files /dev/null and b/middleware/JsonCSharpClassGeneratorLib/obj/Release/Xamasoft.JsonClassGenerator.pdb differ diff --git a/middleware/JsonCSharpClassGeneratorLib/packages.config b/middleware/JsonCSharpClassGeneratorLib/packages.config new file mode 100644 index 0000000..0340715 --- /dev/null +++ b/middleware/JsonCSharpClassGeneratorLib/packages.config @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/middleware/packages/AvalonEdit.6.3.0.90/.signature.p7s b/middleware/packages/AvalonEdit.6.3.0.90/.signature.p7s new file mode 100644 index 0000000..acf2855 Binary files /dev/null and b/middleware/packages/AvalonEdit.6.3.0.90/.signature.p7s differ diff --git a/middleware/packages/AvalonEdit.6.3.0.90/AvalonEdit.6.3.0.90.nupkg b/middleware/packages/AvalonEdit.6.3.0.90/AvalonEdit.6.3.0.90.nupkg new file mode 100644 index 0000000..475ddd8 Binary files /dev/null and b/middleware/packages/AvalonEdit.6.3.0.90/AvalonEdit.6.3.0.90.nupkg differ diff --git a/middleware/packages/AvalonEdit.6.3.0.90/PackageReadme.md b/middleware/packages/AvalonEdit.6.3.0.90/PackageReadme.md new file mode 100644 index 0000000..b18b88f --- /dev/null +++ b/middleware/packages/AvalonEdit.6.3.0.90/PackageReadme.md @@ -0,0 +1,8 @@ +## About + +Check out the [official documentation](http://avalonedit.net/documentation/) and the +[samples and articles wiki page](https://github.com/icsharpcode/AvalonEdit/wiki/Samples-and-Articles) + +Make sure to try the AvalonEdit sample application in the repository - its project has additional documentation included. + +OSS projects using AvalonEdit are listed on the repository main page. \ No newline at end of file diff --git a/middleware/packages/AvalonEdit.6.3.0.90/images/AvalonEditNuGetPackageIcon.png b/middleware/packages/AvalonEdit.6.3.0.90/images/AvalonEditNuGetPackageIcon.png new file mode 100644 index 0000000..69836c2 Binary files /dev/null and b/middleware/packages/AvalonEdit.6.3.0.90/images/AvalonEditNuGetPackageIcon.png differ diff --git a/middleware/packages/EasyModbusTCP.5.6.0/.signature.p7s b/middleware/packages/EasyModbusTCP.5.6.0/.signature.p7s new file mode 100644 index 0000000..eeb5357 Binary files /dev/null and b/middleware/packages/EasyModbusTCP.5.6.0/.signature.p7s differ diff --git a/middleware/packages/EasyModbusTCP.5.6.0/EasyModbusTCP.5.6.0.nupkg b/middleware/packages/EasyModbusTCP.5.6.0/EasyModbusTCP.5.6.0.nupkg new file mode 100644 index 0000000..0d73027 Binary files /dev/null and b/middleware/packages/EasyModbusTCP.5.6.0/EasyModbusTCP.5.6.0.nupkg differ diff --git a/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/.signature.p7s b/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/.signature.p7s new file mode 100644 index 0000000..d6a6f92 Binary files /dev/null and b/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/.signature.p7s differ diff --git a/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/Microsoft.Xaml.Behaviors.Wpf.1.1.77.nupkg b/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/Microsoft.Xaml.Behaviors.Wpf.1.1.77.nupkg new file mode 100644 index 0000000..16bd3a1 Binary files /dev/null and b/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/Microsoft.Xaml.Behaviors.Wpf.1.1.77.nupkg differ diff --git a/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/tools/Install.ps1 b/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/tools/Install.ps1 new file mode 100644 index 0000000..6013fc1 --- /dev/null +++ b/middleware/packages/Microsoft.Xaml.Behaviors.Wpf.1.1.77/tools/Install.ps1 @@ -0,0 +1,5 @@ +param($installPath, $toolsPath, $package, $project) + +# Remove the reference to the .Design.dll, which is incorrectly referenced during +# the NuGet package installation in .NET Framework applications (not .NET Core). +$project.Object.References | Where-Object { $_.Name -eq 'Microsoft.Xaml.Behaviors.Design' -or $_.Name -eq 'Microsoft.Xaml.Behaviors.DesignTools' } | ForEach-Object { $_.Remove() } \ No newline at end of file diff --git a/middleware/packages/Newtonsoft.Json.13.0.1/.signature.p7s b/middleware/packages/Newtonsoft.Json.13.0.1/.signature.p7s new file mode 100644 index 0000000..988b1e1 Binary files /dev/null and b/middleware/packages/Newtonsoft.Json.13.0.1/.signature.p7s differ diff --git a/middleware/packages/Newtonsoft.Json.13.0.1/LICENSE.md b/middleware/packages/Newtonsoft.Json.13.0.1/LICENSE.md new file mode 100644 index 0000000..6cc88f2 --- /dev/null +++ b/middleware/packages/Newtonsoft.Json.13.0.1/LICENSE.md @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2007 James Newton-King + +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. diff --git a/middleware/packages/Newtonsoft.Json.13.0.1/Newtonsoft.Json.13.0.1.nupkg b/middleware/packages/Newtonsoft.Json.13.0.1/Newtonsoft.Json.13.0.1.nupkg new file mode 100644 index 0000000..9eb2ddd Binary files /dev/null and b/middleware/packages/Newtonsoft.Json.13.0.1/Newtonsoft.Json.13.0.1.nupkg differ diff --git a/middleware/packages/Newtonsoft.Json.13.0.1/packageIcon.png b/middleware/packages/Newtonsoft.Json.13.0.1/packageIcon.png new file mode 100644 index 0000000..10c06a5 Binary files /dev/null and b/middleware/packages/Newtonsoft.Json.13.0.1/packageIcon.png differ diff --git a/middleware/packages/Newtonsoft.Json.13.0.3/.signature.p7s b/middleware/packages/Newtonsoft.Json.13.0.3/.signature.p7s new file mode 100644 index 0000000..d55e472 Binary files /dev/null and b/middleware/packages/Newtonsoft.Json.13.0.3/.signature.p7s differ diff --git a/middleware/packages/Newtonsoft.Json.13.0.3/LICENSE.md b/middleware/packages/Newtonsoft.Json.13.0.3/LICENSE.md new file mode 100644 index 0000000..6cc88f2 --- /dev/null +++ b/middleware/packages/Newtonsoft.Json.13.0.3/LICENSE.md @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2007 James Newton-King + +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. diff --git a/middleware/packages/Newtonsoft.Json.13.0.3/Newtonsoft.Json.13.0.3.nupkg b/middleware/packages/Newtonsoft.Json.13.0.3/Newtonsoft.Json.13.0.3.nupkg new file mode 100644 index 0000000..5829e3d Binary files /dev/null and b/middleware/packages/Newtonsoft.Json.13.0.3/Newtonsoft.Json.13.0.3.nupkg differ diff --git a/middleware/packages/Newtonsoft.Json.13.0.3/README.md b/middleware/packages/Newtonsoft.Json.13.0.3/README.md new file mode 100644 index 0000000..c17a272 --- /dev/null +++ b/middleware/packages/Newtonsoft.Json.13.0.3/README.md @@ -0,0 +1,71 @@ +# ![Logo](https://raw.githubusercontent.com/JamesNK/Newtonsoft.Json/master/Doc/icons/logo.jpg) Json.NET + +[![NuGet version (Newtonsoft.Json)](https://img.shields.io/nuget/v/Newtonsoft.Json.svg?style=flat-square)](https://www.nuget.org/packages/Newtonsoft.Json/) +[![Build status](https://dev.azure.com/jamesnk/Public/_apis/build/status/JamesNK.Newtonsoft.Json?branchName=master)](https://dev.azure.com/jamesnk/Public/_build/latest?definitionId=8) + +Json.NET is a popular high-performance JSON framework for .NET + +## Serialize JSON + +```csharp +Product product = new Product(); +product.Name = "Apple"; +product.Expiry = new DateTime(2008, 12, 28); +product.Sizes = new string[] { "Small" }; + +string json = JsonConvert.SerializeObject(product); +// { +// "Name": "Apple", +// "Expiry": "2008-12-28T00:00:00", +// "Sizes": [ +// "Small" +// ] +// } +``` + +## Deserialize JSON + +```csharp +string json = @"{ + 'Name': 'Bad Boys', + 'ReleaseDate': '1995-4-7T00:00:00', + 'Genres': [ + 'Action', + 'Comedy' + ] +}"; + +Movie m = JsonConvert.DeserializeObject(json); + +string name = m.Name; +// Bad Boys +``` + +## LINQ to JSON + +```csharp +JArray array = new JArray(); +array.Add("Manual text"); +array.Add(new DateTime(2000, 5, 23)); + +JObject o = new JObject(); +o["MyArray"] = array; + +string json = o.ToString(); +// { +// "MyArray": [ +// "Manual text", +// "2000-05-23T00:00:00" +// ] +// } +``` + +## Links + +- [Homepage](https://www.newtonsoft.com/json) +- [Documentation](https://www.newtonsoft.com/json/help) +- [NuGet Package](https://www.nuget.org/packages/Newtonsoft.Json) +- [Release Notes](https://github.com/JamesNK/Newtonsoft.Json/releases) +- [Contributing Guidelines](https://github.com/JamesNK/Newtonsoft.Json/blob/master/CONTRIBUTING.md) +- [License](https://github.com/JamesNK/Newtonsoft.Json/blob/master/LICENSE.md) +- [Stack Overflow](https://stackoverflow.com/questions/tagged/json.net) diff --git a/middleware/packages/Newtonsoft.Json.13.0.3/packageIcon.png b/middleware/packages/Newtonsoft.Json.13.0.3/packageIcon.png new file mode 100644 index 0000000..10c06a5 Binary files /dev/null and b/middleware/packages/Newtonsoft.Json.13.0.3/packageIcon.png differ diff --git a/middleware/packages/SQLitePCLRaw.bundle_green.2.0.4/.signature.p7s b/middleware/packages/SQLitePCLRaw.bundle_green.2.0.4/.signature.p7s new file mode 100644 index 0000000..dbca578 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.bundle_green.2.0.4/.signature.p7s differ diff --git a/middleware/packages/SQLitePCLRaw.bundle_green.2.0.4/SQLitePCLRaw.bundle_green.2.0.4.nupkg b/middleware/packages/SQLitePCLRaw.bundle_green.2.0.4/SQLitePCLRaw.bundle_green.2.0.4.nupkg new file mode 100644 index 0000000..37fb8b2 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.bundle_green.2.0.4/SQLitePCLRaw.bundle_green.2.0.4.nupkg differ diff --git a/middleware/packages/SQLitePCLRaw.core.2.0.4/.signature.p7s b/middleware/packages/SQLitePCLRaw.core.2.0.4/.signature.p7s new file mode 100644 index 0000000..3202093 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.core.2.0.4/.signature.p7s differ diff --git a/middleware/packages/SQLitePCLRaw.core.2.0.4/SQLitePCLRaw.core.2.0.4.nupkg b/middleware/packages/SQLitePCLRaw.core.2.0.4/SQLitePCLRaw.core.2.0.4.nupkg new file mode 100644 index 0000000..844d0bd Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.core.2.0.4/SQLitePCLRaw.core.2.0.4.nupkg differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/.signature.p7s b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/.signature.p7s new file mode 100644 index 0000000..4af2716 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/.signature.p7s differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/SQLitePCLRaw.lib.e_sqlite3.2.0.4.nupkg b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/SQLitePCLRaw.lib.e_sqlite3.2.0.4.nupkg new file mode 100644 index 0000000..73613af Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/SQLitePCLRaw.lib.e_sqlite3.2.0.4.nupkg differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/osx-x64/native/libe_sqlite3.dylib b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/osx-x64/native/libe_sqlite3.dylib new file mode 100644 index 0000000..3b9e7a4 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/osx-x64/native/libe_sqlite3.dylib differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-arm/native/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-arm/native/e_sqlite3.dll new file mode 100644 index 0000000..d019891 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-arm/native/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-arm64/native/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-arm64/native/e_sqlite3.dll new file mode 100644 index 0000000..d8b3149 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-arm64/native/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-x64/native/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-x64/native/e_sqlite3.dll new file mode 100644 index 0000000..8d3ca0c Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-x64/native/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-x86/native/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-x86/native/e_sqlite3.dll new file mode 100644 index 0000000..3ad1bc9 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win-x86/native/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-arm/nativeassets/uap10.0/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-arm/nativeassets/uap10.0/e_sqlite3.dll new file mode 100644 index 0000000..b06265d Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-arm/nativeassets/uap10.0/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-arm64/nativeassets/uap10.0/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-arm64/nativeassets/uap10.0/e_sqlite3.dll new file mode 100644 index 0000000..602d9d7 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-arm64/nativeassets/uap10.0/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-x64/nativeassets/uap10.0/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-x64/nativeassets/uap10.0/e_sqlite3.dll new file mode 100644 index 0000000..b3b04d0 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-x64/nativeassets/uap10.0/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-x86/nativeassets/uap10.0/e_sqlite3.dll b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-x86/nativeassets/uap10.0/e_sqlite3.dll new file mode 100644 index 0000000..916c791 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.lib.e_sqlite3.2.0.4/runtimes/win10-x86/nativeassets/uap10.0/e_sqlite3.dll differ diff --git a/middleware/packages/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4/.signature.p7s b/middleware/packages/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4/.signature.p7s new file mode 100644 index 0000000..6aa10e2 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4/.signature.p7s differ diff --git a/middleware/packages/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4.nupkg b/middleware/packages/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4.nupkg new file mode 100644 index 0000000..f5546a7 Binary files /dev/null and b/middleware/packages/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4/SQLitePCLRaw.provider.dynamic_cdecl.2.0.4.nupkg differ diff --git a/middleware/packages/System.Buffers.4.4.0/.signature.p7s b/middleware/packages/System.Buffers.4.4.0/.signature.p7s new file mode 100644 index 0000000..34d8bab Binary files /dev/null and b/middleware/packages/System.Buffers.4.4.0/.signature.p7s differ diff --git a/middleware/packages/System.Buffers.4.4.0/LICENSE.TXT b/middleware/packages/System.Buffers.4.4.0/LICENSE.TXT new file mode 100644 index 0000000..fa3121d --- /dev/null +++ b/middleware/packages/System.Buffers.4.4.0/LICENSE.TXT @@ -0,0 +1,23 @@ +The MIT License (MIT) + +Copyright (c) .NET Foundation and Contributors + +All rights reserved. + +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. diff --git a/middleware/packages/System.Buffers.4.4.0/System.Buffers.4.4.0.nupkg b/middleware/packages/System.Buffers.4.4.0/System.Buffers.4.4.0.nupkg new file mode 100644 index 0000000..c261fa8 Binary files /dev/null and b/middleware/packages/System.Buffers.4.4.0/System.Buffers.4.4.0.nupkg differ diff --git a/middleware/packages/System.Buffers.4.4.0/THIRD-PARTY-NOTICES.TXT b/middleware/packages/System.Buffers.4.4.0/THIRD-PARTY-NOTICES.TXT new file mode 100644 index 0000000..111123c --- /dev/null +++ b/middleware/packages/System.Buffers.4.4.0/THIRD-PARTY-NOTICES.TXT @@ -0,0 +1,226 @@ +.NET Core uses third-party libraries or other resources that may be +distributed under licenses different than the .NET Core software. + +In the event that we accidentally failed to list a required notice, please +bring it to our attention. Post an issue or email us: + + dotnet@microsoft.com + +The attached notices are provided for information only. + +License notice for Slicing-by-8 +------------------------------- + +http://sourceforge.net/projects/slicing-by-8/ + +Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + + +This software program is licensed subject to the BSD License, available at +http://www.opensource.org/licenses/bsd-license.html. + + +License notice for Unicode data +------------------------------- + +http://www.unicode.org/copyright.html#License + +Copyright © 1991-2017 Unicode, Inc. All rights reserved. +Distributed under the Terms of Use in http://www.unicode.org/copyright.html. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Unicode data files and any associated documentation +(the "Data Files") or Unicode software and any associated documentation +(the "Software") to deal in the Data Files or Software +without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, and/or sell copies of +the Data Files or Software, and to permit persons to whom the Data Files +or Software are furnished to do so, provided that either +(a) this copyright and permission notice appear with all copies +of the Data Files or Software, or +(b) this copyright and permission notice appear in associated +Documentation. + +THE DATA FILES AND SOFTWARE ARE 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 OF THIRD PARTY RIGHTS. +IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS +NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL +DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THE DATA FILES OR SOFTWARE. + +Except as contained in this notice, the name of a copyright holder +shall not be used in advertising or otherwise to promote the sale, +use or other dealings in these Data Files or Software without prior +written authorization of the copyright holder. + +License notice for Zlib +----------------------- + +https://github.com/madler/zlib +http://zlib.net/zlib_license.html + +/* zlib.h -- interface of the 'zlib' general purpose compression library + version 1.2.11, January 15th, 2017 + + Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +*/ + +License notice for Mono +------------------------------- + +http://www.mono-project.com/docs/about-mono/ + +Copyright (c) .NET Foundation Contributors + +MIT License + +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. + +License notice for International Organization for Standardization +----------------------------------------------------------------- + +Portions (C) International Organization for Standardization 1986: + Permission to copy in any form is granted for use with + conforming SGML systems and applications as defined in + ISO 8879, provided this notice is included in all copies. + +License notice for Intel +------------------------ + +"Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this +list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License notice for Xamarin and Novell +------------------------------------- + +Copyright (c) 2015 Xamarin, Inc (http://www.xamarin.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. + +Copyright (c) 2011 Novell, Inc (http://www.novell.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. + +Third party notice for W3C +-------------------------- + +"W3C SOFTWARE AND DOCUMENT NOTICE AND LICENSE +Status: This license takes effect 13 May, 2015. +This work is being provided by the copyright holders under the following license. +License +By obtaining and/or copying this work, you (the licensee) agree that you have read, understood, and will comply with the following terms and conditions. +Permission to copy, modify, and distribute this work, with or without modification, for any purpose and without fee or royalty is hereby granted, provided that you include the following on ALL copies of the work or portions thereof, including modifications: +The full text of this NOTICE in a location viewable to users of the redistributed or derivative work. +Any pre-existing intellectual property disclaimers, notices, or terms and conditions. If none exist, the W3C Software and Document Short Notice should be included. +Notice of any changes or modifications, through a copyright statement on the new code or document such as "This software or document includes material copied from or derived from [title and URI of the W3C document]. Copyright © [YEAR] W3C® (MIT, ERCIM, Keio, Beihang)." +Disclaimers +THIS WORK IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENT WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS. +COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENT. +The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the work without specific, written prior permission. Title to copyright in this work will at all times remain with copyright holders." + +License notice for Bit Twiddling Hacks +-------------------------------------- + +Bit Twiddling Hacks + +By Sean Eron Anderson +seander@cs.stanford.edu + +Individually, the code snippets here are in the public domain (unless otherwise +noted) — feel free to use them however you please. The aggregate collection and +descriptions are © 1997-2005 Sean Eron Anderson. The code and descriptions are +distributed in the hope that they will be useful, but WITHOUT ANY WARRANTY and +without even the implied warranty of merchantability or fitness for a particular +purpose. diff --git a/middleware/packages/System.Buffers.4.4.0/ref/netcoreapp2.0/_._ b/middleware/packages/System.Buffers.4.4.0/ref/netcoreapp2.0/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Buffers.4.4.0/ref/netstandard1.1/System.Buffers.dll b/middleware/packages/System.Buffers.4.4.0/ref/netstandard1.1/System.Buffers.dll new file mode 100644 index 0000000..33880ef Binary files /dev/null and b/middleware/packages/System.Buffers.4.4.0/ref/netstandard1.1/System.Buffers.dll differ diff --git a/middleware/packages/System.Buffers.4.4.0/ref/netstandard1.1/System.Buffers.xml b/middleware/packages/System.Buffers.4.4.0/ref/netstandard1.1/System.Buffers.xml new file mode 100644 index 0000000..8b1b5cf --- /dev/null +++ b/middleware/packages/System.Buffers.4.4.0/ref/netstandard1.1/System.Buffers.xml @@ -0,0 +1,39 @@ + + + + System.Buffers + + + + Provides a resource pool that enables reusing instances of type . + The type of the objects that are in the resource pool. + + + Initializes a new instance of the class. + + + Creates a new instance of the class. + A new instance of the class. + + + Creates a new instance of the class using the specifed configuration. + The maximum length of an array instance that may be stored in the pool. + The maximum number of array instances that may be stored in each bucket in the pool. The pool groups arrays of similar lengths into buckets for faster access. + A new instance of the class with the specified configuration. + + + Retrieves a buffer that is at least the requested length. + The minimum length of the array. + An array of type that is at least minimumLength in length. + + + Returns an array to the pool that was previously obtained using the method on the same instance. + A buffer to return to the pool that was previously obtained using the method. + Indicates whether the contents of the buffer should be cleared before reuse. If bufferLength is set to true, and if the pool will store the buffer to enable subsequent reuse, the method will clear the array of its contents so that a subsequent caller using the method will not see the content of the previous caller. If bufferLength is set to false or if the pool will release the buffer, the array's contents are left unchanged. + + + Gets a shared instance. + A shared instance. + + + \ No newline at end of file diff --git a/middleware/packages/System.Buffers.4.4.0/ref/netstandard2.0/System.Buffers.dll b/middleware/packages/System.Buffers.4.4.0/ref/netstandard2.0/System.Buffers.dll new file mode 100644 index 0000000..fa635a9 Binary files /dev/null and b/middleware/packages/System.Buffers.4.4.0/ref/netstandard2.0/System.Buffers.dll differ diff --git a/middleware/packages/System.Buffers.4.4.0/ref/netstandard2.0/System.Buffers.xml b/middleware/packages/System.Buffers.4.4.0/ref/netstandard2.0/System.Buffers.xml new file mode 100644 index 0000000..8b1b5cf --- /dev/null +++ b/middleware/packages/System.Buffers.4.4.0/ref/netstandard2.0/System.Buffers.xml @@ -0,0 +1,39 @@ + + + + System.Buffers + + + + Provides a resource pool that enables reusing instances of type . + The type of the objects that are in the resource pool. + + + Initializes a new instance of the class. + + + Creates a new instance of the class. + A new instance of the class. + + + Creates a new instance of the class using the specifed configuration. + The maximum length of an array instance that may be stored in the pool. + The maximum number of array instances that may be stored in each bucket in the pool. The pool groups arrays of similar lengths into buckets for faster access. + A new instance of the class with the specified configuration. + + + Retrieves a buffer that is at least the requested length. + The minimum length of the array. + An array of type that is at least minimumLength in length. + + + Returns an array to the pool that was previously obtained using the method on the same instance. + A buffer to return to the pool that was previously obtained using the method. + Indicates whether the contents of the buffer should be cleared before reuse. If bufferLength is set to true, and if the pool will store the buffer to enable subsequent reuse, the method will clear the array of its contents so that a subsequent caller using the method will not see the content of the previous caller. If bufferLength is set to false or if the pool will release the buffer, the array's contents are left unchanged. + + + Gets a shared instance. + A shared instance. + + + \ No newline at end of file diff --git a/middleware/packages/System.Buffers.4.4.0/useSharedDesignerContext.txt b/middleware/packages/System.Buffers.4.4.0/useSharedDesignerContext.txt new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Buffers.4.4.0/version.txt b/middleware/packages/System.Buffers.4.4.0/version.txt new file mode 100644 index 0000000..f35e2ed --- /dev/null +++ b/middleware/packages/System.Buffers.4.4.0/version.txt @@ -0,0 +1 @@ +8321c729934c0f8be754953439b88e6e1c120c24 diff --git a/middleware/packages/System.Memory.4.5.3/.signature.p7s b/middleware/packages/System.Memory.4.5.3/.signature.p7s new file mode 100644 index 0000000..d9e4415 Binary files /dev/null and b/middleware/packages/System.Memory.4.5.3/.signature.p7s differ diff --git a/middleware/packages/System.Memory.4.5.3/LICENSE.TXT b/middleware/packages/System.Memory.4.5.3/LICENSE.TXT new file mode 100644 index 0000000..fa3121d --- /dev/null +++ b/middleware/packages/System.Memory.4.5.3/LICENSE.TXT @@ -0,0 +1,23 @@ +The MIT License (MIT) + +Copyright (c) .NET Foundation and Contributors + +All rights reserved. + +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. diff --git a/middleware/packages/System.Memory.4.5.3/System.Memory.4.5.3.nupkg b/middleware/packages/System.Memory.4.5.3/System.Memory.4.5.3.nupkg new file mode 100644 index 0000000..5fa1550 Binary files /dev/null and b/middleware/packages/System.Memory.4.5.3/System.Memory.4.5.3.nupkg differ diff --git a/middleware/packages/System.Memory.4.5.3/THIRD-PARTY-NOTICES.TXT b/middleware/packages/System.Memory.4.5.3/THIRD-PARTY-NOTICES.TXT new file mode 100644 index 0000000..207a2a7 --- /dev/null +++ b/middleware/packages/System.Memory.4.5.3/THIRD-PARTY-NOTICES.TXT @@ -0,0 +1,309 @@ +.NET Core uses third-party libraries or other resources that may be +distributed under licenses different than the .NET Core software. + +In the event that we accidentally failed to list a required notice, please +bring it to our attention. Post an issue or email us: + + dotnet@microsoft.com + +The attached notices are provided for information only. + +License notice for Slicing-by-8 +------------------------------- + +http://sourceforge.net/projects/slicing-by-8/ + +Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + + +This software program is licensed subject to the BSD License, available at +http://www.opensource.org/licenses/bsd-license.html. + + +License notice for Unicode data +------------------------------- + +http://www.unicode.org/copyright.html#License + +Copyright © 1991-2017 Unicode, Inc. All rights reserved. +Distributed under the Terms of Use in http://www.unicode.org/copyright.html. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Unicode data files and any associated documentation +(the "Data Files") or Unicode software and any associated documentation +(the "Software") to deal in the Data Files or Software +without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, and/or sell copies of +the Data Files or Software, and to permit persons to whom the Data Files +or Software are furnished to do so, provided that either +(a) this copyright and permission notice appear with all copies +of the Data Files or Software, or +(b) this copyright and permission notice appear in associated +Documentation. + +THE DATA FILES AND SOFTWARE ARE 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 OF THIRD PARTY RIGHTS. +IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS +NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL +DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THE DATA FILES OR SOFTWARE. + +Except as contained in this notice, the name of a copyright holder +shall not be used in advertising or otherwise to promote the sale, +use or other dealings in these Data Files or Software without prior +written authorization of the copyright holder. + +License notice for Zlib +----------------------- + +https://github.com/madler/zlib +http://zlib.net/zlib_license.html + +/* zlib.h -- interface of the 'zlib' general purpose compression library + version 1.2.11, January 15th, 2017 + + Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +*/ + +License notice for Mono +------------------------------- + +http://www.mono-project.com/docs/about-mono/ + +Copyright (c) .NET Foundation Contributors + +MIT License + +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. + +License notice for International Organization for Standardization +----------------------------------------------------------------- + +Portions (C) International Organization for Standardization 1986: + Permission to copy in any form is granted for use with + conforming SGML systems and applications as defined in + ISO 8879, provided this notice is included in all copies. + +License notice for Intel +------------------------ + +"Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this +list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License notice for Xamarin and Novell +------------------------------------- + +Copyright (c) 2015 Xamarin, Inc (http://www.xamarin.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. + +Copyright (c) 2011 Novell, Inc (http://www.novell.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. + +Third party notice for W3C +-------------------------- + +"W3C SOFTWARE AND DOCUMENT NOTICE AND LICENSE +Status: This license takes effect 13 May, 2015. +This work is being provided by the copyright holders under the following license. +License +By obtaining and/or copying this work, you (the licensee) agree that you have read, understood, and will comply with the following terms and conditions. +Permission to copy, modify, and distribute this work, with or without modification, for any purpose and without fee or royalty is hereby granted, provided that you include the following on ALL copies of the work or portions thereof, including modifications: +The full text of this NOTICE in a location viewable to users of the redistributed or derivative work. +Any pre-existing intellectual property disclaimers, notices, or terms and conditions. If none exist, the W3C Software and Document Short Notice should be included. +Notice of any changes or modifications, through a copyright statement on the new code or document such as "This software or document includes material copied from or derived from [title and URI of the W3C document]. Copyright © [YEAR] W3C® (MIT, ERCIM, Keio, Beihang)." +Disclaimers +THIS WORK IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENT WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS. +COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENT. +The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the work without specific, written prior permission. Title to copyright in this work will at all times remain with copyright holders." + +License notice for Bit Twiddling Hacks +-------------------------------------- + +Bit Twiddling Hacks + +By Sean Eron Anderson +seander@cs.stanford.edu + +Individually, the code snippets here are in the public domain (unless otherwise +noted) — feel free to use them however you please. The aggregate collection and +descriptions are © 1997-2005 Sean Eron Anderson. The code and descriptions are +distributed in the hope that they will be useful, but WITHOUT ANY WARRANTY and +without even the implied warranty of merchantability or fitness for a particular +purpose. + +License notice for Brotli +-------------------------------------- + +Copyright (c) 2009, 2010, 2013-2016 by the Brotli Authors. + +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. + +compress_fragment.c: +Copyright (c) 2011, Google Inc. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +""AS IS"" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +decode_fuzzer.c: +Copyright (c) 2015 The Chromium Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +""AS IS"" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." + diff --git a/middleware/packages/System.Memory.4.5.3/ref/netcoreapp2.1/_._ b/middleware/packages/System.Memory.4.5.3/ref/netcoreapp2.1/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Memory.4.5.3/useSharedDesignerContext.txt b/middleware/packages/System.Memory.4.5.3/useSharedDesignerContext.txt new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Memory.4.5.3/version.txt b/middleware/packages/System.Memory.4.5.3/version.txt new file mode 100644 index 0000000..8409833 --- /dev/null +++ b/middleware/packages/System.Memory.4.5.3/version.txt @@ -0,0 +1 @@ +c6cf790234e063b855fcdb50f3fb1b3cfac73275 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/.signature.p7s b/middleware/packages/System.Numerics.Vectors.4.4.0/.signature.p7s new file mode 100644 index 0000000..804a5d4 Binary files /dev/null and b/middleware/packages/System.Numerics.Vectors.4.4.0/.signature.p7s differ diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/LICENSE.TXT b/middleware/packages/System.Numerics.Vectors.4.4.0/LICENSE.TXT new file mode 100644 index 0000000..fa3121d --- /dev/null +++ b/middleware/packages/System.Numerics.Vectors.4.4.0/LICENSE.TXT @@ -0,0 +1,23 @@ +The MIT License (MIT) + +Copyright (c) .NET Foundation and Contributors + +All rights reserved. + +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. diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/System.Numerics.Vectors.4.4.0.nupkg b/middleware/packages/System.Numerics.Vectors.4.4.0/System.Numerics.Vectors.4.4.0.nupkg new file mode 100644 index 0000000..d1faf30 Binary files /dev/null and b/middleware/packages/System.Numerics.Vectors.4.4.0/System.Numerics.Vectors.4.4.0.nupkg differ diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/THIRD-PARTY-NOTICES.TXT b/middleware/packages/System.Numerics.Vectors.4.4.0/THIRD-PARTY-NOTICES.TXT new file mode 100644 index 0000000..111123c --- /dev/null +++ b/middleware/packages/System.Numerics.Vectors.4.4.0/THIRD-PARTY-NOTICES.TXT @@ -0,0 +1,226 @@ +.NET Core uses third-party libraries or other resources that may be +distributed under licenses different than the .NET Core software. + +In the event that we accidentally failed to list a required notice, please +bring it to our attention. Post an issue or email us: + + dotnet@microsoft.com + +The attached notices are provided for information only. + +License notice for Slicing-by-8 +------------------------------- + +http://sourceforge.net/projects/slicing-by-8/ + +Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + + +This software program is licensed subject to the BSD License, available at +http://www.opensource.org/licenses/bsd-license.html. + + +License notice for Unicode data +------------------------------- + +http://www.unicode.org/copyright.html#License + +Copyright © 1991-2017 Unicode, Inc. All rights reserved. +Distributed under the Terms of Use in http://www.unicode.org/copyright.html. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Unicode data files and any associated documentation +(the "Data Files") or Unicode software and any associated documentation +(the "Software") to deal in the Data Files or Software +without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, and/or sell copies of +the Data Files or Software, and to permit persons to whom the Data Files +or Software are furnished to do so, provided that either +(a) this copyright and permission notice appear with all copies +of the Data Files or Software, or +(b) this copyright and permission notice appear in associated +Documentation. + +THE DATA FILES AND SOFTWARE ARE 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 OF THIRD PARTY RIGHTS. +IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS +NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL +DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THE DATA FILES OR SOFTWARE. + +Except as contained in this notice, the name of a copyright holder +shall not be used in advertising or otherwise to promote the sale, +use or other dealings in these Data Files or Software without prior +written authorization of the copyright holder. + +License notice for Zlib +----------------------- + +https://github.com/madler/zlib +http://zlib.net/zlib_license.html + +/* zlib.h -- interface of the 'zlib' general purpose compression library + version 1.2.11, January 15th, 2017 + + Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +*/ + +License notice for Mono +------------------------------- + +http://www.mono-project.com/docs/about-mono/ + +Copyright (c) .NET Foundation Contributors + +MIT License + +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. + +License notice for International Organization for Standardization +----------------------------------------------------------------- + +Portions (C) International Organization for Standardization 1986: + Permission to copy in any form is granted for use with + conforming SGML systems and applications as defined in + ISO 8879, provided this notice is included in all copies. + +License notice for Intel +------------------------ + +"Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this +list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License notice for Xamarin and Novell +------------------------------------- + +Copyright (c) 2015 Xamarin, Inc (http://www.xamarin.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. + +Copyright (c) 2011 Novell, Inc (http://www.novell.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. + +Third party notice for W3C +-------------------------- + +"W3C SOFTWARE AND DOCUMENT NOTICE AND LICENSE +Status: This license takes effect 13 May, 2015. +This work is being provided by the copyright holders under the following license. +License +By obtaining and/or copying this work, you (the licensee) agree that you have read, understood, and will comply with the following terms and conditions. +Permission to copy, modify, and distribute this work, with or without modification, for any purpose and without fee or royalty is hereby granted, provided that you include the following on ALL copies of the work or portions thereof, including modifications: +The full text of this NOTICE in a location viewable to users of the redistributed or derivative work. +Any pre-existing intellectual property disclaimers, notices, or terms and conditions. If none exist, the W3C Software and Document Short Notice should be included. +Notice of any changes or modifications, through a copyright statement on the new code or document such as "This software or document includes material copied from or derived from [title and URI of the W3C document]. Copyright © [YEAR] W3C® (MIT, ERCIM, Keio, Beihang)." +Disclaimers +THIS WORK IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENT WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS. +COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENT. +The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the work without specific, written prior permission. Title to copyright in this work will at all times remain with copyright holders." + +License notice for Bit Twiddling Hacks +-------------------------------------- + +Bit Twiddling Hacks + +By Sean Eron Anderson +seander@cs.stanford.edu + +Individually, the code snippets here are in the public domain (unless otherwise +noted) — feel free to use them however you please. The aggregate collection and +descriptions are © 1997-2005 Sean Eron Anderson. The code and descriptions are +distributed in the hope that they will be useful, but WITHOUT ANY WARRANTY and +without even the implied warranty of merchantability or fitness for a particular +purpose. diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/MonoAndroid10/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/MonoAndroid10/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/MonoTouch10/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/MonoTouch10/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/net46/System.Numerics.Vectors.dll b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/net46/System.Numerics.Vectors.dll new file mode 100644 index 0000000..e91f855 Binary files /dev/null and b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/net46/System.Numerics.Vectors.dll differ diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/net46/System.Numerics.Vectors.xml b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/net46/System.Numerics.Vectors.xml new file mode 100644 index 0000000..b8c2f94 --- /dev/null +++ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/net46/System.Numerics.Vectors.xml @@ -0,0 +1,2597 @@ + + + + System.Numerics.Vectors + + + + Represents a 3x2 matrix. + + + Creates a 3x2 matrix from the specified components. + The value to assign to the first element in the first row. + The value to assign to the second element in the first row. + The value to assign to the first element in the second row. + The value to assign to the second element in the second row. + The value to assign to the first element in the third row. + The value to assign to the second element in the third row. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values of value1 and value2. + + + Creates a rotation matrix using the given rotation in radians. + The amount of rotation, in radians. + The rotation matrix. + + + Creates a rotation matrix using the specified rotation in radians and a center point. + The amount of rotation, in radians. + The center point. + The rotation matrix. + + + Creates a scaling matrix from the specified X and Y components. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The scaling matrix. + + + Creates a scaling matrix that scales uniformly with the specified scale with an offset from the specified center. + The uniform scale to use. + The center offset. + The scaling matrix. + + + Creates a scaling matrix that is offset by a given center point. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The center point. + The scaling matrix. + + + Creates a scaling matrix that scales uniformly with the given scale. + The uniform scale to use. + The scaling matrix. + + + Creates a scaling matrix from the specified vector scale. + The scale to use. + The scaling matrix. + + + Creates a scaling matrix from the specified vector scale with an offset from the specified center point. + The scale to use. + The center offset. + The scaling matrix. + + + Creates a skew matrix from the specified angles in radians. + The X angle, in radians. + The Y angle, in radians. + The skew matrix. + + + Creates a skew matrix from the specified angles in radians and a center point. + The X angle, in radians. + The Y angle, in radians. + The center point. + The skew matrix. + + + Creates a translation matrix from the specified 2-dimensional vector. + The translation position. + The translation matrix. + + + Creates a translation matrix from the specified X and Y components. + The X position. + The Y position. + The translation matrix. + + + Returns a value that indicates whether this instance and another 3x2 matrix are equal. + The other matrix. + true if the two matrices are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Calculates the determinant for this matrix. + The determinant. + + + Returns the hash code for this instance. + The hash code. + + + Gets the multiplicative identity matrix. + The multiplicative identify matrix. + + + Inverts the specified matrix. The return value indicates whether the operation succeeded. + The matrix to invert. + When this method returns, contains the inverted matrix if the operation succeeded. + true if matrix was converted successfully; otherwise, false. + + + Indicates whether the current matrix is the identity matrix. + true if the current matrix is the identity matrix; otherwise, false. + + + Performs a linear interpolation from one matrix to a second matrix based on a value that specifies the weighting of the second matrix. + The first matrix. + The second matrix. + The relative weighting of matrix2. + The interpolated matrix. + + + The first element of the first row. + + + + The second element of the first row. + + + + The first element of the second row. + + + + The second element of the second row. + + + + The first element of the third row. + + + + The second element of the third row. + + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values. + + + Returns a value that indicates whether the specified matrices are equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether the specified matrices are not equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this matrix. + The string representation of this matrix. + + + Gets or sets the translation component of this matrix. + The translation component of the current instance. + + + Represents a 4x4 matrix. + + + Creates a object from a specified object. + A 3x2 matrix. + + + Creates a 4x4 matrix from the specified components. + The value to assign to the first element in the first row. + The value to assign to the second element in the first row. + The value to assign to the third element in the first row. + The value to assign to the fourth element in the first row. + The value to assign to the first element in the second row. + The value to assign to the second element in the second row. + The value to assign to the third element in the second row. + The value to assign to the third element in the second row. + The value to assign to the first element in the third row. + The value to assign to the second element in the third row. + The value to assign to the third element in the third row. + The value to assign to the fourth element in the third row. + The value to assign to the first element in the fourth row. + The value to assign to the second element in the fourth row. + The value to assign to the third element in the fourth row. + The value to assign to the fourth element in the fourth row. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values of value1 and value2. + + + Creates a spherical billboard that rotates around a specified object position. + The position of the object that the billboard will rotate around. + The position of the camera. + The up vector of the camera. + The forward vector of the camera. + The created billboard. + + + Creates a cylindrical billboard that rotates around a specified axis. + The position of the object that the billboard will rotate around. + The position of the camera. + The axis to rotate the billboard around. + The forward vector of the camera. + The forward vector of the object. + The billboard matrix. + + + Creates a matrix that rotates around an arbitrary vector. + The axis to rotate around. + The angle to rotate around axis, in radians. + The rotation matrix. + + + Creates a rotation matrix from the specified Quaternion rotation value. + The source Quaternion. + The rotation matrix. + + + Creates a rotation matrix from the specified yaw, pitch, and roll. + The angle of rotation, in radians, around the Y axis. + The angle of rotation, in radians, around the X axis. + The angle of rotation, in radians, around the Z axis. + The rotation matrix. + + + Creates a view matrix. + The position of the camera. + The target towards which the camera is pointing. + The direction that is "up" from the camera's point of view. + The view matrix. + + + Creates an orthographic perspective matrix from the given view volume dimensions. + The width of the view volume. + The height of the view volume. + The minimum Z-value of the view volume. + The maximum Z-value of the view volume. + The orthographic projection matrix. + + + Creates a customized orthographic projection matrix. + The minimum X-value of the view volume. + The maximum X-value of the view volume. + The minimum Y-value of the view volume. + The maximum Y-value of the view volume. + The minimum Z-value of the view volume. + The maximum Z-value of the view volume. + The orthographic projection matrix. + + + Creates a perspective projection matrix from the given view volume dimensions. + The width of the view volume at the near view plane. + The height of the view volume at the near view plane. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a perspective projection matrix based on a field of view, aspect ratio, and near and far view plane distances. + The field of view in the y direction, in radians. + The aspect ratio, defined as view space width divided by height. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + fieldOfView is less than or equal to zero. -or- fieldOfView is greater than or equal to . nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a customized perspective projection matrix. + The minimum x-value of the view volume at the near view plane. + The maximum x-value of the view volume at the near view plane. + The minimum y-value of the view volume at the near view plane. + The maximum y-value of the view volume at the near view plane. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a matrix that reflects the coordinate system about a specified plane. + The plane about which to create a reflection. + A new matrix expressing the reflection. + + + Creates a matrix for rotating points around the X axis. + The amount, in radians, by which to rotate around the X axis. + The rotation matrix. + + + Creates a matrix for rotating points around the X axis from a center point. + The amount, in radians, by which to rotate around the X axis. + The center point. + The rotation matrix. + + + The amount, in radians, by which to rotate around the Y axis from a center point. + The amount, in radians, by which to rotate around the Y-axis. + The center point. + The rotation matrix. + + + Creates a matrix for rotating points around the Y axis. + The amount, in radians, by which to rotate around the Y-axis. + The rotation matrix. + + + Creates a matrix for rotating points around the Z axis. + The amount, in radians, by which to rotate around the Z-axis. + The rotation matrix. + + + Creates a matrix for rotating points around the Z axis from a center point. + The amount, in radians, by which to rotate around the Z-axis. + The center point. + The rotation matrix. + + + Creates a scaling matrix from the specified vector scale. + The scale to use. + The scaling matrix. + + + Creates a uniform scaling matrix that scale equally on each axis. + The uniform scaling factor. + The scaling matrix. + + + Creates a scaling matrix with a center point. + The vector that contains the amount to scale on each axis. + The center point. + The scaling matrix. + + + Creates a uniform scaling matrix that scales equally on each axis with a center point. + The uniform scaling factor. + The center point. + The scaling matrix. + + + Creates a scaling matrix from the specified X, Y, and Z components. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The value to scale by on the Z axis. + The scaling matrix. + + + Creates a scaling matrix that is offset by a given center point. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The value to scale by on the Z axis. + The center point. + The scaling matrix. + + + Creates a matrix that flattens geometry into a specified plane as if casting a shadow from a specified light source. + The direction from which the light that will cast the shadow is coming. + The plane onto which the new matrix should flatten geometry so as to cast a shadow. + A new matrix that can be used to flatten geometry onto the specified plane from the specified direction. + + + Creates a translation matrix from the specified 3-dimensional vector. + The amount to translate in each axis. + The translation matrix. + + + Creates a translation matrix from the specified X, Y, and Z components. + The amount to translate on the X axis. + The amount to translate on the Y axis. + The amount to translate on the Z axis. + The translation matrix. + + + Creates a world matrix with the specified parameters. + The position of the object. + The forward direction of the object. + The upward direction of the object. Its value is usually [0, 1, 0]. + The world matrix. + + + Attempts to extract the scale, translation, and rotation components from the given scale, rotation, or translation matrix. The return value indicates whether the operation succeeded. + The source matrix. + When this method returns, contains the scaling component of the transformation matrix if the operation succeeded. + When this method returns, contains the rotation component of the transformation matrix if the operation succeeded. + When the method returns, contains the translation component of the transformation matrix if the operation succeeded. + true if matrix was decomposed successfully; otherwise, false. + + + Returns a value that indicates whether this instance and another 4x4 matrix are equal. + The other matrix. + true if the two matrices are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Calculates the determinant of the current 4x4 matrix. + The determinant. + + + Returns the hash code for this instance. + The hash code. + + + Gets the multiplicative identity matrix. + Gets the multiplicative identity matrix. + + + Inverts the specified matrix. The return value indicates whether the operation succeeded. + The matrix to invert. + When this method returns, contains the inverted matrix if the operation succeeded. + true if matrix was converted successfully; otherwise, false. + + + Indicates whether the current matrix is the identity matrix. + true if the current matrix is the identity matrix; otherwise, false. + + + Performs a linear interpolation from one matrix to a second matrix based on a value that specifies the weighting of the second matrix. + The first matrix. + The second matrix. + The relative weighting of matrix2. + The interpolated matrix. + + + The first element of the first row. + + + + The second element of the first row. + + + + The third element of the first row. + + + + The fourth element of the first row. + + + + The first element of the second row. + + + + The second element of the second row. + + + + The third element of the second row. + + + + The fourth element of the second row. + + + + The first element of the third row. + + + + The second element of the third row. + + + + The third element of the third row. + + + + The fourth element of the third row. + + + + The first element of the fourth row. + + + + The second element of the fourth row. + + + + The third element of the fourth row. + + + + The fourth element of the fourth row. + + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values. + + + Returns a value that indicates whether the specified matrices are equal. + The first matrix to compare. + The second matrix to care + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether the specified matrices are not equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this matrix. + The string representation of this matrix. + + + Transforms the specified matrix by applying the specified Quaternion rotation. + The matrix to transform. + The rotation t apply. + The transformed matrix. + + + Gets or sets the translation component of this matrix. + The translation component of the current instance. + + + Transposes the rows and columns of a matrix. + The matrix to transpose. + The transposed matrix. + + + Represents a three-dimensional plane. + + + Creates a object from a specified four-dimensional vector. + A vector whose first three elements describe the normal vector, and whose defines the distance along that normal from the origin. + + + Creates a object from a specified normal and the distance along the normal from the origin. + The plane's normal vector. + The plane's distance from the origin along its normal vector. + + + Creates a object from the X, Y, and Z components of its normal, and its distance from the origin on that normal. + The X component of the normal. + The Y component of the normal. + The Z component of the normal. + The distance of the plane along its normal from the origin. + + + Creates a object that contains three specified points. + The first point defining the plane. + The second point defining the plane. + The third point defining the plane. + The plane containing the three points. + + + The distance of the plane along its normal from the origin. + + + + Calculates the dot product of a plane and a 4-dimensional vector. + The plane. + The four-dimensional vector. + The dot product. + + + Returns the dot product of a specified three-dimensional vector and the normal vector of this plane plus the distance () value of the plane. + The plane. + The 3-dimensional vector. + The dot product. + + + Returns the dot product of a specified three-dimensional vector and the vector of this plane. + The plane. + The three-dimensional vector. + The dot product. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns a value that indicates whether this instance and another plane object are equal. + The other plane. + true if the two planes are equal; otherwise, false. + + + Returns the hash code for this instance. + The hash code. + + + The normal vector of the plane. + + + + Creates a new object whose normal vector is the source plane's normal vector normalized. + The source plane. + The normalized plane. + + + Returns a value that indicates whether two planes are equal. + The first plane to compare. + The second plane to compare. + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether two planes are not equal. + The first plane to compare. + The second plane to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the string representation of this plane object. + A string that represents this object. + + + Transforms a normalized plane by a 4x4 matrix. + The normalized plane to transform. + The transformation matrix to apply to plane. + The transformed plane. + + + Transforms a normalized plane by a Quaternion rotation. + The normalized plane to transform. + The Quaternion rotation to apply to the plane. + A new plane that results from applying the Quaternion rotation. + + + Represents a vector that is used to encode three-dimensional physical rotations. + + + Creates a quaternion from the specified vector and rotation parts. + The vector part of the quaternion. + The rotation part of the quaternion. + + + Constructs a quaternion from the specified components. + The value to assign to the X component of the quaternion. + The value to assign to the Y component of the quaternion. + The value to assign to the Z component of the quaternion. + The value to assign to the W component of the quaternion. + + + Adds each element in one quaternion with its corresponding element in a second quaternion. + The first quaternion. + The second quaternion. + The quaternion that contains the summed values of value1 and value2. + + + Concatenates two quaternions. + The first quaternion rotation in the series. + The second quaternion rotation in the series. + A new quaternion representing the concatenation of the value1 rotation followed by the value2 rotation. + + + Returns the conjugate of a specified quaternion. + The quaternion. + A new quaternion that is the conjugate of value. + + + Creates a quaternion from a vector and an angle to rotate about the vector. + The vector to rotate around. + The angle, in radians, to rotate around the vector. + The newly created quaternion. + + + Creates a quaternion from the specified rotation matrix. + The rotation matrix. + The newly created quaternion. + + + Creates a new quaternion from the given yaw, pitch, and roll. + The yaw angle, in radians, around the Y axis. + The pitch angle, in radians, around the X axis. + The roll angle, in radians, around the Z axis. + The resulting quaternion. + + + Divides one quaternion by a second quaternion. + The dividend. + The divisor. + The quaternion that results from dividing value1 by value2. + + + Calculates the dot product of two quaternions. + The first quaternion. + The second quaternion. + The dot product. + + + Returns a value that indicates whether this instance and another quaternion are equal. + The other quaternion. + true if the two quaternions are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Gets a quaternion that represents no rotation. + A quaternion whose values are (0, 0, 0, 1). + + + Returns the inverse of a quaternion. + The quaternion. + The inverted quaternion. + + + Gets a value that indicates whether the current instance is the identity quaternion. + true if the current instance is the identity quaternion; otherwise, false. + + + Calculates the length of the quaternion. + The computed length of the quaternion. + + + Calculates the squared length of the quaternion. + The length squared of the quaternion. + + + Performs a linear interpolation between two quaternions based on a value that specifies the weighting of the second quaternion. + The first quaternion. + The second quaternion. + The relative weight of quaternion2 in the interpolation. + The interpolated quaternion. + + + Returns the quaternion that results from multiplying two quaternions together. + The first quaternion. + The second quaternion. + The product quaternion. + + + Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor. + The source quaternion. + The scalar value. + The scaled quaternion. + + + Reverses the sign of each component of the quaternion. + The quaternion to negate. + The negated quaternion. + + + Divides each component of a specified by its length. + The quaternion to normalize. + The normalized quaternion. + + + Adds each element in one quaternion with its corresponding element in a second quaternion. + The first quaternion. + The second quaternion. + The quaternion that contains the summed values of value1 and value2. + + + Divides one quaternion by a second quaternion. + The dividend. + The divisor. + The quaternion that results from dividing value1 by value2. + + + Returns a value that indicates whether two quaternions are equal. + The first quaternion to compare. + The second quaternion to compare. + true if the two quaternions are equal; otherwise, false. + + + Returns a value that indicates whether two quaternions are not equal. + The first quaternion to compare. + The second quaternion to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor. + The source quaternion. + The scalar value. + The scaled quaternion. + + + Returns the quaternion that results from multiplying two quaternions together. + The first quaternion. + The second quaternion. + The product quaternion. + + + Subtracts each element in a second quaternion from its corresponding element in a first quaternion. + The first quaternion. + The second quaternion. + The quaternion containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Reverses the sign of each component of the quaternion. + The quaternion to negate. + The negated quaternion. + + + Interpolates between two quaternions, using spherical linear interpolation. + The first quaternion. + The second quaternion. + The relative weight of the second quaternion in the interpolation. + The interpolated quaternion. + + + Subtracts each element in a second quaternion from its corresponding element in a first quaternion. + The first quaternion. + The second quaternion. + The quaternion containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this quaternion. + The string representation of this quaternion. + + + The rotation component of the quaternion. + + + + The X value of the vector component of the quaternion. + + + + The Y value of the vector component of the quaternion. + + + + The Z value of the vector component of the quaternion. + + + + Represents a single vector of a specified numeric type that is suitable for low-level optimization of parallel algorithms. + The vector type. T can be any primitive numeric type. + + + Creates a vector whose components are of a specified type. + The numeric type that defines the type of the components in the vector. + + + Creates a vector from a specified array. + A numeric array. + values is null. + + + Creates a vector from a specified array starting at a specified index position. + A numeric array. + The starting index position from which to create the vector. + values is null. + index is less than zero. -or- The length of values minus index is less than . + + + Copies the vector instance to a specified destination array. + The array to receive a copy of the vector values. + destination is null. + The number of elements in the current vector is greater than the number of elements available in the destination array. + + + Copies the vector instance to a specified destination array starting at a specified index position. + The array to receive a copy of the vector values. + The starting index in destination at which to begin the copy operation. + destination is null. + The number of elements in the current instance is greater than the number of elements available from startIndex to the end of the destination array. + index is less than zero or greater than the last index in destination. + + + Returns the number of elements stored in the vector. + The number of elements stored in the vector. + Access to the property getter via reflection is not supported. + + + Returns a value that indicates whether this instance is equal to a specified vector. + The vector to compare with this instance. + true if the current instance and other are equal; otherwise, false. + + + Returns a value that indicates whether this instance is equal to a specified object. + The object to compare with this instance. + true if the current instance and obj are equal; otherwise, false. The method returns false if obj is null, or if obj is a vector of a different type than the current instance. + + + Returns the hash code for this instance. + The hash code. + + + Gets the element at a specified index. + The index of the element to return. + The element at index index. + index is less than zero. -or- index is greater than or equal to . + + + Returns a vector containing all ones. + A vector containing all ones. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Returns a new vector by performing a bitwise And operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise And of left and right. + + + Returns a new vector by performing a bitwise Or operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise Or of the elements in left and right. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Returns a value that indicates whether each pair of elements in two specified vectors are equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a new vector by performing a bitwise XOr operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise XOr of the elements in left and right. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Returns a value that indicates whether any single pair of elements in the specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if any element pairs in left and right are equal. false if no element pairs are equal. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar value. + The source vector. + A scalar value. + The scaled vector. + + + Multiplies a vector by the given scalar. + The scalar value. + The source vector. + The scaled vector. + + + Returns a new vector whose elements are obtained by taking the one's complement of a specified vector's elements. + The source vector. + The one's complement vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates a given vector. + The vector to negate. + The negated vector. + + + Returns the string representation of this vector using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Returns the string representation of this vector using default formatting. + The string representation of this vector. + + + Returns the string representation of this vector using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns a vector containing all zeroes. + A vector containing all zeroes. + + + Provides a collection of static convenience methods for creating, manipulating, combining, and converting generic vectors. + + + Returns a new vector whose elements are the absolute values of the given vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The absolute value vector. + + + Returns a new vector whose values are the sum of each pair of elements from two given vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The summed vector. + + + Returns a new vector by performing a bitwise And Not operation on each pair of corresponding elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned bytes. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a double-precision floating-point vector. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of 16-bit integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of long integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of signed bytes. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a single-precision floating-point vector. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned 16-bit integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned long integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Returns a new vector by performing a bitwise And operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a new vector by performing a bitwise Or operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Creates a new single-precision vector with elements selected between two specified single-precision source vectors based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The new vector with elements selected based on the mask. + + + Creates a new double-precision vector with elements selected between two specified double-precision source vectors based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The new vector with elements selected based on the mask. + + + Creates a new vector of a specified type with elements selected between two specified source vectors of the same type based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The vector type. T can be any primitive numeric type. + The new vector with elements selected based on the mask. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector whose values are the result of dividing the first vector's elements by the corresponding elements in the second vector. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The divided vector. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The dot product. + + + Returns a new integral vector whose elements signal whether the elements in two specified double-precision vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in two specified integral vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in two specified long integer vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in two specified single-precision vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector of a specified type whose elements signal whether the elements in two specified vectors of the same type are equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether each pair of elements in the given vectors is equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left and right are equal; otherwise, false. + + + Returns a value that indicates whether any single pair of elements in the given vectors is equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element pair in left and right is equal; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are greater than their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are greater than their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are greater than their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision floating-point vector are greater than their corresponding elements in a second single-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector of a specified type are greater than their corresponding elements in the second vector of the same time. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are greater than the corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left are greater than the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is greater than the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is greater than the corresponding element in right; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one vector are greater than or equal to their corresponding elements in the single-precision floating-point second vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are greater than or equal to their corresponding elements in the second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are greater than or equal to their corresponding elements in the second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one vector are greater than or equal to their corresponding elements in the second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector of a specified type are greater than or equal to their corresponding elements in the second vector of the same type. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are greater than or equal to all the corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left are greater than or equal to the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is greater than or equal to the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is greater than or equal to the corresponding element in right; otherwise, false. + + + Gets a value that indicates whether vector operations are subject to hardware acceleration through JIT intrinsic support. + true if vector operations are subject to hardware acceleration; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are less than their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are less than their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are less than their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision vector are less than their corresponding elements in a second single-precision vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector of a specified type whose elements signal whether the elements in one vector are less than their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all of the elements in the first vector are less than their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all of the elements in left are less than the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is less than the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is less than the corresponding element in right; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are less than or equal to their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are less than or equal to their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are less or equal to their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision floating-point vector are less than or equal to their corresponding elements in a second single-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector are less than or equal to their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are less than or equal to their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all of the elements in left are less than or equal to the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is less than or equal to the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is less than or equal to the corresponding element in right; otherwise, false. + + + Returns a new vector whose elements are the maximum of each pair of elements in the two given vectors. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The maximum vector. + + + Returns a new vector whose elements are the minimum of each pair of elements in the two given vectors. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The minimum vector. + + + Returns a new vector whose values are a scalar value multiplied by each of the values of a specified vector. + The scalar value. + The vector. + The vector type. T can be any primitive numeric type. + The scaled vector. + + + Returns a new vector whose values are the product of each pair of elements in two specified vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The product vector. + + + Returns a new vector whose values are the values of a specified vector each multiplied by a scalar value. + The vector. + The scalar value. + The vector type. T can be any primitive numeric type. + The scaled vector. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector whose elements are the negation of the corresponding element in the specified vector. + The source vector. + The vector type. T can be any primitive numeric type. + The negated vector. + + + Returns a new vector whose elements are obtained by taking the one's complement of a specified vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a new vector whose elements are the square roots of a specified vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The square root vector. + + + Returns a new vector whose values are the difference between the elements in the second vector and their corresponding elements in the first vector. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The difference vector. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector by performing a bitwise exclusive Or (XOr) operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Represents a vector with two single-precision floating-point values. + + + Creates a new object whose two elements have the same value. + The value to assign to both elements. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of the vector. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 2 elements are equal to one. + A vector whose two elements are equal to one (that is, it returns the vector (1,1). + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns the reflection of a vector off a surface that has the specified normal. + The source vector. + The normal of the surface being reflected off. + The reflected vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a vector by a specified 3x2 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a vector normal by the given 3x2 matrix. + The source vector. + The matrix. + The transformed vector. + + + Transforms a vector normal by the given 4x4 matrix. + The source vector. + The matrix. + The transformed vector. + + + Gets the vector (1,0). + The vector (1,0). + + + Gets the vector (0,1). + The vector (0,1). + + + The X component of the vector. + + + + The Y component of the vector. + + + + Returns a vector whose 2 elements are equal to zero. + A vector whose two elements are equal to zero (that is, it returns the vector (0,0). + + + Represents a vector with three single-precision floating-point values. + + + Creates a new object whose three elements have the same value. + The value to assign to all three elements. + + + Creates a new object from the specified object and the specified value. + The vector with two elements. + The additional value to assign to the field. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the cross product of two vectors. + The first vector. + The second vector. + The cross product. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of this vector object. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 3 elements are equal to one. + A vector whose three elements are equal to one (that is, it returns the vector (1,1,1). + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns the reflection of a vector off a surface that has the specified normal. + The source vector. + The normal of the surface being reflected off. + The reflected vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a vector normal by the given 4x4 matrix. + The source vector. + The matrix. + The transformed vector. + + + Gets the vector (1,0,0). + The vector (1,0,0). + + + Gets the vector (0,1,0). + The vector (0,1,0).. + + + Gets the vector (0,0,1). + The vector (0,0,1). + + + The X component of the vector. + + + + The Y component of the vector. + + + + The Z component of the vector. + + + + Gets a vector whose 3 elements are equal to zero. + A vector whose three elements are equal to zero (that is, it returns the vector (0,0,0). + + + Represents a vector with four single-precision floating-point values. + + + Creates a new object whose four elements have the same value. + The value to assign to all four elements. + + + Constructs a new object from the specified object and a W component. + The vector to use for the X, Y, and Z components. + The W component. + + + Creates a new object from the specified object and a Z and a W component. + The vector to use for the X and Y components. + The Z component. + The W component. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of this vector object. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 4 elements are equal to one. + Returns . + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a four-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a four-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a three-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a two-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a two-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a three-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Gets the vector (0,0,0,1). + The vector (0,0,0,1). + + + Gets the vector (1,0,0,0). + The vector (1,0,0,0). + + + Gets the vector (0,1,0,0). + The vector (0,1,0,0).. + + + Gets a vector whose 4 elements are equal to zero. + The vector (0,0,1,0). + + + The W component of the vector. + + + + The X component of the vector. + + + + The Y component of the vector. + + + + The Z component of the vector. + + + + Gets a vector whose 4 elements are equal to zero. + A vector whose four elements are equal to zero (that is, it returns the vector (0,0,0,0). + + + \ No newline at end of file diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netcoreapp2.0/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netcoreapp2.0/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard1.0/System.Numerics.Vectors.dll b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard1.0/System.Numerics.Vectors.dll new file mode 100644 index 0000000..d174da0 Binary files /dev/null and b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard1.0/System.Numerics.Vectors.dll differ diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard1.0/System.Numerics.Vectors.xml b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard1.0/System.Numerics.Vectors.xml new file mode 100644 index 0000000..b8c2f94 --- /dev/null +++ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard1.0/System.Numerics.Vectors.xml @@ -0,0 +1,2597 @@ + + + + System.Numerics.Vectors + + + + Represents a 3x2 matrix. + + + Creates a 3x2 matrix from the specified components. + The value to assign to the first element in the first row. + The value to assign to the second element in the first row. + The value to assign to the first element in the second row. + The value to assign to the second element in the second row. + The value to assign to the first element in the third row. + The value to assign to the second element in the third row. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values of value1 and value2. + + + Creates a rotation matrix using the given rotation in radians. + The amount of rotation, in radians. + The rotation matrix. + + + Creates a rotation matrix using the specified rotation in radians and a center point. + The amount of rotation, in radians. + The center point. + The rotation matrix. + + + Creates a scaling matrix from the specified X and Y components. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The scaling matrix. + + + Creates a scaling matrix that scales uniformly with the specified scale with an offset from the specified center. + The uniform scale to use. + The center offset. + The scaling matrix. + + + Creates a scaling matrix that is offset by a given center point. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The center point. + The scaling matrix. + + + Creates a scaling matrix that scales uniformly with the given scale. + The uniform scale to use. + The scaling matrix. + + + Creates a scaling matrix from the specified vector scale. + The scale to use. + The scaling matrix. + + + Creates a scaling matrix from the specified vector scale with an offset from the specified center point. + The scale to use. + The center offset. + The scaling matrix. + + + Creates a skew matrix from the specified angles in radians. + The X angle, in radians. + The Y angle, in radians. + The skew matrix. + + + Creates a skew matrix from the specified angles in radians and a center point. + The X angle, in radians. + The Y angle, in radians. + The center point. + The skew matrix. + + + Creates a translation matrix from the specified 2-dimensional vector. + The translation position. + The translation matrix. + + + Creates a translation matrix from the specified X and Y components. + The X position. + The Y position. + The translation matrix. + + + Returns a value that indicates whether this instance and another 3x2 matrix are equal. + The other matrix. + true if the two matrices are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Calculates the determinant for this matrix. + The determinant. + + + Returns the hash code for this instance. + The hash code. + + + Gets the multiplicative identity matrix. + The multiplicative identify matrix. + + + Inverts the specified matrix. The return value indicates whether the operation succeeded. + The matrix to invert. + When this method returns, contains the inverted matrix if the operation succeeded. + true if matrix was converted successfully; otherwise, false. + + + Indicates whether the current matrix is the identity matrix. + true if the current matrix is the identity matrix; otherwise, false. + + + Performs a linear interpolation from one matrix to a second matrix based on a value that specifies the weighting of the second matrix. + The first matrix. + The second matrix. + The relative weighting of matrix2. + The interpolated matrix. + + + The first element of the first row. + + + + The second element of the first row. + + + + The first element of the second row. + + + + The second element of the second row. + + + + The first element of the third row. + + + + The second element of the third row. + + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values. + + + Returns a value that indicates whether the specified matrices are equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether the specified matrices are not equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this matrix. + The string representation of this matrix. + + + Gets or sets the translation component of this matrix. + The translation component of the current instance. + + + Represents a 4x4 matrix. + + + Creates a object from a specified object. + A 3x2 matrix. + + + Creates a 4x4 matrix from the specified components. + The value to assign to the first element in the first row. + The value to assign to the second element in the first row. + The value to assign to the third element in the first row. + The value to assign to the fourth element in the first row. + The value to assign to the first element in the second row. + The value to assign to the second element in the second row. + The value to assign to the third element in the second row. + The value to assign to the third element in the second row. + The value to assign to the first element in the third row. + The value to assign to the second element in the third row. + The value to assign to the third element in the third row. + The value to assign to the fourth element in the third row. + The value to assign to the first element in the fourth row. + The value to assign to the second element in the fourth row. + The value to assign to the third element in the fourth row. + The value to assign to the fourth element in the fourth row. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values of value1 and value2. + + + Creates a spherical billboard that rotates around a specified object position. + The position of the object that the billboard will rotate around. + The position of the camera. + The up vector of the camera. + The forward vector of the camera. + The created billboard. + + + Creates a cylindrical billboard that rotates around a specified axis. + The position of the object that the billboard will rotate around. + The position of the camera. + The axis to rotate the billboard around. + The forward vector of the camera. + The forward vector of the object. + The billboard matrix. + + + Creates a matrix that rotates around an arbitrary vector. + The axis to rotate around. + The angle to rotate around axis, in radians. + The rotation matrix. + + + Creates a rotation matrix from the specified Quaternion rotation value. + The source Quaternion. + The rotation matrix. + + + Creates a rotation matrix from the specified yaw, pitch, and roll. + The angle of rotation, in radians, around the Y axis. + The angle of rotation, in radians, around the X axis. + The angle of rotation, in radians, around the Z axis. + The rotation matrix. + + + Creates a view matrix. + The position of the camera. + The target towards which the camera is pointing. + The direction that is "up" from the camera's point of view. + The view matrix. + + + Creates an orthographic perspective matrix from the given view volume dimensions. + The width of the view volume. + The height of the view volume. + The minimum Z-value of the view volume. + The maximum Z-value of the view volume. + The orthographic projection matrix. + + + Creates a customized orthographic projection matrix. + The minimum X-value of the view volume. + The maximum X-value of the view volume. + The minimum Y-value of the view volume. + The maximum Y-value of the view volume. + The minimum Z-value of the view volume. + The maximum Z-value of the view volume. + The orthographic projection matrix. + + + Creates a perspective projection matrix from the given view volume dimensions. + The width of the view volume at the near view plane. + The height of the view volume at the near view plane. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a perspective projection matrix based on a field of view, aspect ratio, and near and far view plane distances. + The field of view in the y direction, in radians. + The aspect ratio, defined as view space width divided by height. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + fieldOfView is less than or equal to zero. -or- fieldOfView is greater than or equal to . nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a customized perspective projection matrix. + The minimum x-value of the view volume at the near view plane. + The maximum x-value of the view volume at the near view plane. + The minimum y-value of the view volume at the near view plane. + The maximum y-value of the view volume at the near view plane. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a matrix that reflects the coordinate system about a specified plane. + The plane about which to create a reflection. + A new matrix expressing the reflection. + + + Creates a matrix for rotating points around the X axis. + The amount, in radians, by which to rotate around the X axis. + The rotation matrix. + + + Creates a matrix for rotating points around the X axis from a center point. + The amount, in radians, by which to rotate around the X axis. + The center point. + The rotation matrix. + + + The amount, in radians, by which to rotate around the Y axis from a center point. + The amount, in radians, by which to rotate around the Y-axis. + The center point. + The rotation matrix. + + + Creates a matrix for rotating points around the Y axis. + The amount, in radians, by which to rotate around the Y-axis. + The rotation matrix. + + + Creates a matrix for rotating points around the Z axis. + The amount, in radians, by which to rotate around the Z-axis. + The rotation matrix. + + + Creates a matrix for rotating points around the Z axis from a center point. + The amount, in radians, by which to rotate around the Z-axis. + The center point. + The rotation matrix. + + + Creates a scaling matrix from the specified vector scale. + The scale to use. + The scaling matrix. + + + Creates a uniform scaling matrix that scale equally on each axis. + The uniform scaling factor. + The scaling matrix. + + + Creates a scaling matrix with a center point. + The vector that contains the amount to scale on each axis. + The center point. + The scaling matrix. + + + Creates a uniform scaling matrix that scales equally on each axis with a center point. + The uniform scaling factor. + The center point. + The scaling matrix. + + + Creates a scaling matrix from the specified X, Y, and Z components. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The value to scale by on the Z axis. + The scaling matrix. + + + Creates a scaling matrix that is offset by a given center point. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The value to scale by on the Z axis. + The center point. + The scaling matrix. + + + Creates a matrix that flattens geometry into a specified plane as if casting a shadow from a specified light source. + The direction from which the light that will cast the shadow is coming. + The plane onto which the new matrix should flatten geometry so as to cast a shadow. + A new matrix that can be used to flatten geometry onto the specified plane from the specified direction. + + + Creates a translation matrix from the specified 3-dimensional vector. + The amount to translate in each axis. + The translation matrix. + + + Creates a translation matrix from the specified X, Y, and Z components. + The amount to translate on the X axis. + The amount to translate on the Y axis. + The amount to translate on the Z axis. + The translation matrix. + + + Creates a world matrix with the specified parameters. + The position of the object. + The forward direction of the object. + The upward direction of the object. Its value is usually [0, 1, 0]. + The world matrix. + + + Attempts to extract the scale, translation, and rotation components from the given scale, rotation, or translation matrix. The return value indicates whether the operation succeeded. + The source matrix. + When this method returns, contains the scaling component of the transformation matrix if the operation succeeded. + When this method returns, contains the rotation component of the transformation matrix if the operation succeeded. + When the method returns, contains the translation component of the transformation matrix if the operation succeeded. + true if matrix was decomposed successfully; otherwise, false. + + + Returns a value that indicates whether this instance and another 4x4 matrix are equal. + The other matrix. + true if the two matrices are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Calculates the determinant of the current 4x4 matrix. + The determinant. + + + Returns the hash code for this instance. + The hash code. + + + Gets the multiplicative identity matrix. + Gets the multiplicative identity matrix. + + + Inverts the specified matrix. The return value indicates whether the operation succeeded. + The matrix to invert. + When this method returns, contains the inverted matrix if the operation succeeded. + true if matrix was converted successfully; otherwise, false. + + + Indicates whether the current matrix is the identity matrix. + true if the current matrix is the identity matrix; otherwise, false. + + + Performs a linear interpolation from one matrix to a second matrix based on a value that specifies the weighting of the second matrix. + The first matrix. + The second matrix. + The relative weighting of matrix2. + The interpolated matrix. + + + The first element of the first row. + + + + The second element of the first row. + + + + The third element of the first row. + + + + The fourth element of the first row. + + + + The first element of the second row. + + + + The second element of the second row. + + + + The third element of the second row. + + + + The fourth element of the second row. + + + + The first element of the third row. + + + + The second element of the third row. + + + + The third element of the third row. + + + + The fourth element of the third row. + + + + The first element of the fourth row. + + + + The second element of the fourth row. + + + + The third element of the fourth row. + + + + The fourth element of the fourth row. + + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values. + + + Returns a value that indicates whether the specified matrices are equal. + The first matrix to compare. + The second matrix to care + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether the specified matrices are not equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this matrix. + The string representation of this matrix. + + + Transforms the specified matrix by applying the specified Quaternion rotation. + The matrix to transform. + The rotation t apply. + The transformed matrix. + + + Gets or sets the translation component of this matrix. + The translation component of the current instance. + + + Transposes the rows and columns of a matrix. + The matrix to transpose. + The transposed matrix. + + + Represents a three-dimensional plane. + + + Creates a object from a specified four-dimensional vector. + A vector whose first three elements describe the normal vector, and whose defines the distance along that normal from the origin. + + + Creates a object from a specified normal and the distance along the normal from the origin. + The plane's normal vector. + The plane's distance from the origin along its normal vector. + + + Creates a object from the X, Y, and Z components of its normal, and its distance from the origin on that normal. + The X component of the normal. + The Y component of the normal. + The Z component of the normal. + The distance of the plane along its normal from the origin. + + + Creates a object that contains three specified points. + The first point defining the plane. + The second point defining the plane. + The third point defining the plane. + The plane containing the three points. + + + The distance of the plane along its normal from the origin. + + + + Calculates the dot product of a plane and a 4-dimensional vector. + The plane. + The four-dimensional vector. + The dot product. + + + Returns the dot product of a specified three-dimensional vector and the normal vector of this plane plus the distance () value of the plane. + The plane. + The 3-dimensional vector. + The dot product. + + + Returns the dot product of a specified three-dimensional vector and the vector of this plane. + The plane. + The three-dimensional vector. + The dot product. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns a value that indicates whether this instance and another plane object are equal. + The other plane. + true if the two planes are equal; otherwise, false. + + + Returns the hash code for this instance. + The hash code. + + + The normal vector of the plane. + + + + Creates a new object whose normal vector is the source plane's normal vector normalized. + The source plane. + The normalized plane. + + + Returns a value that indicates whether two planes are equal. + The first plane to compare. + The second plane to compare. + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether two planes are not equal. + The first plane to compare. + The second plane to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the string representation of this plane object. + A string that represents this object. + + + Transforms a normalized plane by a 4x4 matrix. + The normalized plane to transform. + The transformation matrix to apply to plane. + The transformed plane. + + + Transforms a normalized plane by a Quaternion rotation. + The normalized plane to transform. + The Quaternion rotation to apply to the plane. + A new plane that results from applying the Quaternion rotation. + + + Represents a vector that is used to encode three-dimensional physical rotations. + + + Creates a quaternion from the specified vector and rotation parts. + The vector part of the quaternion. + The rotation part of the quaternion. + + + Constructs a quaternion from the specified components. + The value to assign to the X component of the quaternion. + The value to assign to the Y component of the quaternion. + The value to assign to the Z component of the quaternion. + The value to assign to the W component of the quaternion. + + + Adds each element in one quaternion with its corresponding element in a second quaternion. + The first quaternion. + The second quaternion. + The quaternion that contains the summed values of value1 and value2. + + + Concatenates two quaternions. + The first quaternion rotation in the series. + The second quaternion rotation in the series. + A new quaternion representing the concatenation of the value1 rotation followed by the value2 rotation. + + + Returns the conjugate of a specified quaternion. + The quaternion. + A new quaternion that is the conjugate of value. + + + Creates a quaternion from a vector and an angle to rotate about the vector. + The vector to rotate around. + The angle, in radians, to rotate around the vector. + The newly created quaternion. + + + Creates a quaternion from the specified rotation matrix. + The rotation matrix. + The newly created quaternion. + + + Creates a new quaternion from the given yaw, pitch, and roll. + The yaw angle, in radians, around the Y axis. + The pitch angle, in radians, around the X axis. + The roll angle, in radians, around the Z axis. + The resulting quaternion. + + + Divides one quaternion by a second quaternion. + The dividend. + The divisor. + The quaternion that results from dividing value1 by value2. + + + Calculates the dot product of two quaternions. + The first quaternion. + The second quaternion. + The dot product. + + + Returns a value that indicates whether this instance and another quaternion are equal. + The other quaternion. + true if the two quaternions are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Gets a quaternion that represents no rotation. + A quaternion whose values are (0, 0, 0, 1). + + + Returns the inverse of a quaternion. + The quaternion. + The inverted quaternion. + + + Gets a value that indicates whether the current instance is the identity quaternion. + true if the current instance is the identity quaternion; otherwise, false. + + + Calculates the length of the quaternion. + The computed length of the quaternion. + + + Calculates the squared length of the quaternion. + The length squared of the quaternion. + + + Performs a linear interpolation between two quaternions based on a value that specifies the weighting of the second quaternion. + The first quaternion. + The second quaternion. + The relative weight of quaternion2 in the interpolation. + The interpolated quaternion. + + + Returns the quaternion that results from multiplying two quaternions together. + The first quaternion. + The second quaternion. + The product quaternion. + + + Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor. + The source quaternion. + The scalar value. + The scaled quaternion. + + + Reverses the sign of each component of the quaternion. + The quaternion to negate. + The negated quaternion. + + + Divides each component of a specified by its length. + The quaternion to normalize. + The normalized quaternion. + + + Adds each element in one quaternion with its corresponding element in a second quaternion. + The first quaternion. + The second quaternion. + The quaternion that contains the summed values of value1 and value2. + + + Divides one quaternion by a second quaternion. + The dividend. + The divisor. + The quaternion that results from dividing value1 by value2. + + + Returns a value that indicates whether two quaternions are equal. + The first quaternion to compare. + The second quaternion to compare. + true if the two quaternions are equal; otherwise, false. + + + Returns a value that indicates whether two quaternions are not equal. + The first quaternion to compare. + The second quaternion to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor. + The source quaternion. + The scalar value. + The scaled quaternion. + + + Returns the quaternion that results from multiplying two quaternions together. + The first quaternion. + The second quaternion. + The product quaternion. + + + Subtracts each element in a second quaternion from its corresponding element in a first quaternion. + The first quaternion. + The second quaternion. + The quaternion containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Reverses the sign of each component of the quaternion. + The quaternion to negate. + The negated quaternion. + + + Interpolates between two quaternions, using spherical linear interpolation. + The first quaternion. + The second quaternion. + The relative weight of the second quaternion in the interpolation. + The interpolated quaternion. + + + Subtracts each element in a second quaternion from its corresponding element in a first quaternion. + The first quaternion. + The second quaternion. + The quaternion containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this quaternion. + The string representation of this quaternion. + + + The rotation component of the quaternion. + + + + The X value of the vector component of the quaternion. + + + + The Y value of the vector component of the quaternion. + + + + The Z value of the vector component of the quaternion. + + + + Represents a single vector of a specified numeric type that is suitable for low-level optimization of parallel algorithms. + The vector type. T can be any primitive numeric type. + + + Creates a vector whose components are of a specified type. + The numeric type that defines the type of the components in the vector. + + + Creates a vector from a specified array. + A numeric array. + values is null. + + + Creates a vector from a specified array starting at a specified index position. + A numeric array. + The starting index position from which to create the vector. + values is null. + index is less than zero. -or- The length of values minus index is less than . + + + Copies the vector instance to a specified destination array. + The array to receive a copy of the vector values. + destination is null. + The number of elements in the current vector is greater than the number of elements available in the destination array. + + + Copies the vector instance to a specified destination array starting at a specified index position. + The array to receive a copy of the vector values. + The starting index in destination at which to begin the copy operation. + destination is null. + The number of elements in the current instance is greater than the number of elements available from startIndex to the end of the destination array. + index is less than zero or greater than the last index in destination. + + + Returns the number of elements stored in the vector. + The number of elements stored in the vector. + Access to the property getter via reflection is not supported. + + + Returns a value that indicates whether this instance is equal to a specified vector. + The vector to compare with this instance. + true if the current instance and other are equal; otherwise, false. + + + Returns a value that indicates whether this instance is equal to a specified object. + The object to compare with this instance. + true if the current instance and obj are equal; otherwise, false. The method returns false if obj is null, or if obj is a vector of a different type than the current instance. + + + Returns the hash code for this instance. + The hash code. + + + Gets the element at a specified index. + The index of the element to return. + The element at index index. + index is less than zero. -or- index is greater than or equal to . + + + Returns a vector containing all ones. + A vector containing all ones. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Returns a new vector by performing a bitwise And operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise And of left and right. + + + Returns a new vector by performing a bitwise Or operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise Or of the elements in left and right. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Returns a value that indicates whether each pair of elements in two specified vectors are equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a new vector by performing a bitwise XOr operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise XOr of the elements in left and right. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Returns a value that indicates whether any single pair of elements in the specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if any element pairs in left and right are equal. false if no element pairs are equal. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar value. + The source vector. + A scalar value. + The scaled vector. + + + Multiplies a vector by the given scalar. + The scalar value. + The source vector. + The scaled vector. + + + Returns a new vector whose elements are obtained by taking the one's complement of a specified vector's elements. + The source vector. + The one's complement vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates a given vector. + The vector to negate. + The negated vector. + + + Returns the string representation of this vector using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Returns the string representation of this vector using default formatting. + The string representation of this vector. + + + Returns the string representation of this vector using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns a vector containing all zeroes. + A vector containing all zeroes. + + + Provides a collection of static convenience methods for creating, manipulating, combining, and converting generic vectors. + + + Returns a new vector whose elements are the absolute values of the given vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The absolute value vector. + + + Returns a new vector whose values are the sum of each pair of elements from two given vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The summed vector. + + + Returns a new vector by performing a bitwise And Not operation on each pair of corresponding elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned bytes. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a double-precision floating-point vector. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of 16-bit integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of long integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of signed bytes. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a single-precision floating-point vector. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned 16-bit integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned long integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Returns a new vector by performing a bitwise And operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a new vector by performing a bitwise Or operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Creates a new single-precision vector with elements selected between two specified single-precision source vectors based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The new vector with elements selected based on the mask. + + + Creates a new double-precision vector with elements selected between two specified double-precision source vectors based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The new vector with elements selected based on the mask. + + + Creates a new vector of a specified type with elements selected between two specified source vectors of the same type based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The vector type. T can be any primitive numeric type. + The new vector with elements selected based on the mask. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector whose values are the result of dividing the first vector's elements by the corresponding elements in the second vector. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The divided vector. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The dot product. + + + Returns a new integral vector whose elements signal whether the elements in two specified double-precision vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in two specified integral vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in two specified long integer vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in two specified single-precision vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector of a specified type whose elements signal whether the elements in two specified vectors of the same type are equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether each pair of elements in the given vectors is equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left and right are equal; otherwise, false. + + + Returns a value that indicates whether any single pair of elements in the given vectors is equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element pair in left and right is equal; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are greater than their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are greater than their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are greater than their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision floating-point vector are greater than their corresponding elements in a second single-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector of a specified type are greater than their corresponding elements in the second vector of the same time. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are greater than the corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left are greater than the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is greater than the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is greater than the corresponding element in right; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one vector are greater than or equal to their corresponding elements in the single-precision floating-point second vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are greater than or equal to their corresponding elements in the second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are greater than or equal to their corresponding elements in the second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one vector are greater than or equal to their corresponding elements in the second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector of a specified type are greater than or equal to their corresponding elements in the second vector of the same type. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are greater than or equal to all the corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left are greater than or equal to the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is greater than or equal to the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is greater than or equal to the corresponding element in right; otherwise, false. + + + Gets a value that indicates whether vector operations are subject to hardware acceleration through JIT intrinsic support. + true if vector operations are subject to hardware acceleration; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are less than their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are less than their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are less than their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision vector are less than their corresponding elements in a second single-precision vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector of a specified type whose elements signal whether the elements in one vector are less than their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all of the elements in the first vector are less than their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all of the elements in left are less than the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is less than the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is less than the corresponding element in right; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are less than or equal to their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are less than or equal to their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are less or equal to their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision floating-point vector are less than or equal to their corresponding elements in a second single-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector are less than or equal to their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are less than or equal to their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all of the elements in left are less than or equal to the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is less than or equal to the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is less than or equal to the corresponding element in right; otherwise, false. + + + Returns a new vector whose elements are the maximum of each pair of elements in the two given vectors. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The maximum vector. + + + Returns a new vector whose elements are the minimum of each pair of elements in the two given vectors. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The minimum vector. + + + Returns a new vector whose values are a scalar value multiplied by each of the values of a specified vector. + The scalar value. + The vector. + The vector type. T can be any primitive numeric type. + The scaled vector. + + + Returns a new vector whose values are the product of each pair of elements in two specified vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The product vector. + + + Returns a new vector whose values are the values of a specified vector each multiplied by a scalar value. + The vector. + The scalar value. + The vector type. T can be any primitive numeric type. + The scaled vector. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector whose elements are the negation of the corresponding element in the specified vector. + The source vector. + The vector type. T can be any primitive numeric type. + The negated vector. + + + Returns a new vector whose elements are obtained by taking the one's complement of a specified vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a new vector whose elements are the square roots of a specified vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The square root vector. + + + Returns a new vector whose values are the difference between the elements in the second vector and their corresponding elements in the first vector. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The difference vector. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector by performing a bitwise exclusive Or (XOr) operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Represents a vector with two single-precision floating-point values. + + + Creates a new object whose two elements have the same value. + The value to assign to both elements. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of the vector. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 2 elements are equal to one. + A vector whose two elements are equal to one (that is, it returns the vector (1,1). + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns the reflection of a vector off a surface that has the specified normal. + The source vector. + The normal of the surface being reflected off. + The reflected vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a vector by a specified 3x2 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a vector normal by the given 3x2 matrix. + The source vector. + The matrix. + The transformed vector. + + + Transforms a vector normal by the given 4x4 matrix. + The source vector. + The matrix. + The transformed vector. + + + Gets the vector (1,0). + The vector (1,0). + + + Gets the vector (0,1). + The vector (0,1). + + + The X component of the vector. + + + + The Y component of the vector. + + + + Returns a vector whose 2 elements are equal to zero. + A vector whose two elements are equal to zero (that is, it returns the vector (0,0). + + + Represents a vector with three single-precision floating-point values. + + + Creates a new object whose three elements have the same value. + The value to assign to all three elements. + + + Creates a new object from the specified object and the specified value. + The vector with two elements. + The additional value to assign to the field. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the cross product of two vectors. + The first vector. + The second vector. + The cross product. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of this vector object. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 3 elements are equal to one. + A vector whose three elements are equal to one (that is, it returns the vector (1,1,1). + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns the reflection of a vector off a surface that has the specified normal. + The source vector. + The normal of the surface being reflected off. + The reflected vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a vector normal by the given 4x4 matrix. + The source vector. + The matrix. + The transformed vector. + + + Gets the vector (1,0,0). + The vector (1,0,0). + + + Gets the vector (0,1,0). + The vector (0,1,0).. + + + Gets the vector (0,0,1). + The vector (0,0,1). + + + The X component of the vector. + + + + The Y component of the vector. + + + + The Z component of the vector. + + + + Gets a vector whose 3 elements are equal to zero. + A vector whose three elements are equal to zero (that is, it returns the vector (0,0,0). + + + Represents a vector with four single-precision floating-point values. + + + Creates a new object whose four elements have the same value. + The value to assign to all four elements. + + + Constructs a new object from the specified object and a W component. + The vector to use for the X, Y, and Z components. + The W component. + + + Creates a new object from the specified object and a Z and a W component. + The vector to use for the X and Y components. + The Z component. + The W component. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of this vector object. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 4 elements are equal to one. + Returns . + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a four-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a four-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a three-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a two-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a two-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a three-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Gets the vector (0,0,0,1). + The vector (0,0,0,1). + + + Gets the vector (1,0,0,0). + The vector (1,0,0,0). + + + Gets the vector (0,1,0,0). + The vector (0,1,0,0).. + + + Gets a vector whose 4 elements are equal to zero. + The vector (0,0,1,0). + + + The W component of the vector. + + + + The X component of the vector. + + + + The Y component of the vector. + + + + The Z component of the vector. + + + + Gets a vector whose 4 elements are equal to zero. + A vector whose four elements are equal to zero (that is, it returns the vector (0,0,0,0). + + + \ No newline at end of file diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard2.0/System.Numerics.Vectors.dll b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard2.0/System.Numerics.Vectors.dll new file mode 100644 index 0000000..ba0aa0c Binary files /dev/null and b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard2.0/System.Numerics.Vectors.dll differ diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard2.0/System.Numerics.Vectors.xml b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard2.0/System.Numerics.Vectors.xml new file mode 100644 index 0000000..b8c2f94 --- /dev/null +++ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/netstandard2.0/System.Numerics.Vectors.xml @@ -0,0 +1,2597 @@ + + + + System.Numerics.Vectors + + + + Represents a 3x2 matrix. + + + Creates a 3x2 matrix from the specified components. + The value to assign to the first element in the first row. + The value to assign to the second element in the first row. + The value to assign to the first element in the second row. + The value to assign to the second element in the second row. + The value to assign to the first element in the third row. + The value to assign to the second element in the third row. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values of value1 and value2. + + + Creates a rotation matrix using the given rotation in radians. + The amount of rotation, in radians. + The rotation matrix. + + + Creates a rotation matrix using the specified rotation in radians and a center point. + The amount of rotation, in radians. + The center point. + The rotation matrix. + + + Creates a scaling matrix from the specified X and Y components. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The scaling matrix. + + + Creates a scaling matrix that scales uniformly with the specified scale with an offset from the specified center. + The uniform scale to use. + The center offset. + The scaling matrix. + + + Creates a scaling matrix that is offset by a given center point. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The center point. + The scaling matrix. + + + Creates a scaling matrix that scales uniformly with the given scale. + The uniform scale to use. + The scaling matrix. + + + Creates a scaling matrix from the specified vector scale. + The scale to use. + The scaling matrix. + + + Creates a scaling matrix from the specified vector scale with an offset from the specified center point. + The scale to use. + The center offset. + The scaling matrix. + + + Creates a skew matrix from the specified angles in radians. + The X angle, in radians. + The Y angle, in radians. + The skew matrix. + + + Creates a skew matrix from the specified angles in radians and a center point. + The X angle, in radians. + The Y angle, in radians. + The center point. + The skew matrix. + + + Creates a translation matrix from the specified 2-dimensional vector. + The translation position. + The translation matrix. + + + Creates a translation matrix from the specified X and Y components. + The X position. + The Y position. + The translation matrix. + + + Returns a value that indicates whether this instance and another 3x2 matrix are equal. + The other matrix. + true if the two matrices are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Calculates the determinant for this matrix. + The determinant. + + + Returns the hash code for this instance. + The hash code. + + + Gets the multiplicative identity matrix. + The multiplicative identify matrix. + + + Inverts the specified matrix. The return value indicates whether the operation succeeded. + The matrix to invert. + When this method returns, contains the inverted matrix if the operation succeeded. + true if matrix was converted successfully; otherwise, false. + + + Indicates whether the current matrix is the identity matrix. + true if the current matrix is the identity matrix; otherwise, false. + + + Performs a linear interpolation from one matrix to a second matrix based on a value that specifies the weighting of the second matrix. + The first matrix. + The second matrix. + The relative weighting of matrix2. + The interpolated matrix. + + + The first element of the first row. + + + + The second element of the first row. + + + + The first element of the second row. + + + + The second element of the second row. + + + + The first element of the third row. + + + + The second element of the third row. + + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values. + + + Returns a value that indicates whether the specified matrices are equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether the specified matrices are not equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this matrix. + The string representation of this matrix. + + + Gets or sets the translation component of this matrix. + The translation component of the current instance. + + + Represents a 4x4 matrix. + + + Creates a object from a specified object. + A 3x2 matrix. + + + Creates a 4x4 matrix from the specified components. + The value to assign to the first element in the first row. + The value to assign to the second element in the first row. + The value to assign to the third element in the first row. + The value to assign to the fourth element in the first row. + The value to assign to the first element in the second row. + The value to assign to the second element in the second row. + The value to assign to the third element in the second row. + The value to assign to the third element in the second row. + The value to assign to the first element in the third row. + The value to assign to the second element in the third row. + The value to assign to the third element in the third row. + The value to assign to the fourth element in the third row. + The value to assign to the first element in the fourth row. + The value to assign to the second element in the fourth row. + The value to assign to the third element in the fourth row. + The value to assign to the fourth element in the fourth row. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values of value1 and value2. + + + Creates a spherical billboard that rotates around a specified object position. + The position of the object that the billboard will rotate around. + The position of the camera. + The up vector of the camera. + The forward vector of the camera. + The created billboard. + + + Creates a cylindrical billboard that rotates around a specified axis. + The position of the object that the billboard will rotate around. + The position of the camera. + The axis to rotate the billboard around. + The forward vector of the camera. + The forward vector of the object. + The billboard matrix. + + + Creates a matrix that rotates around an arbitrary vector. + The axis to rotate around. + The angle to rotate around axis, in radians. + The rotation matrix. + + + Creates a rotation matrix from the specified Quaternion rotation value. + The source Quaternion. + The rotation matrix. + + + Creates a rotation matrix from the specified yaw, pitch, and roll. + The angle of rotation, in radians, around the Y axis. + The angle of rotation, in radians, around the X axis. + The angle of rotation, in radians, around the Z axis. + The rotation matrix. + + + Creates a view matrix. + The position of the camera. + The target towards which the camera is pointing. + The direction that is "up" from the camera's point of view. + The view matrix. + + + Creates an orthographic perspective matrix from the given view volume dimensions. + The width of the view volume. + The height of the view volume. + The minimum Z-value of the view volume. + The maximum Z-value of the view volume. + The orthographic projection matrix. + + + Creates a customized orthographic projection matrix. + The minimum X-value of the view volume. + The maximum X-value of the view volume. + The minimum Y-value of the view volume. + The maximum Y-value of the view volume. + The minimum Z-value of the view volume. + The maximum Z-value of the view volume. + The orthographic projection matrix. + + + Creates a perspective projection matrix from the given view volume dimensions. + The width of the view volume at the near view plane. + The height of the view volume at the near view plane. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a perspective projection matrix based on a field of view, aspect ratio, and near and far view plane distances. + The field of view in the y direction, in radians. + The aspect ratio, defined as view space width divided by height. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + fieldOfView is less than or equal to zero. -or- fieldOfView is greater than or equal to . nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a customized perspective projection matrix. + The minimum x-value of the view volume at the near view plane. + The maximum x-value of the view volume at the near view plane. + The minimum y-value of the view volume at the near view plane. + The maximum y-value of the view volume at the near view plane. + The distance to the near view plane. + The distance to the far view plane. + The perspective projection matrix. + nearPlaneDistance is less than or equal to zero. -or- farPlaneDistance is less than or equal to zero. -or- nearPlaneDistance is greater than or equal to farPlaneDistance. + + + Creates a matrix that reflects the coordinate system about a specified plane. + The plane about which to create a reflection. + A new matrix expressing the reflection. + + + Creates a matrix for rotating points around the X axis. + The amount, in radians, by which to rotate around the X axis. + The rotation matrix. + + + Creates a matrix for rotating points around the X axis from a center point. + The amount, in radians, by which to rotate around the X axis. + The center point. + The rotation matrix. + + + The amount, in radians, by which to rotate around the Y axis from a center point. + The amount, in radians, by which to rotate around the Y-axis. + The center point. + The rotation matrix. + + + Creates a matrix for rotating points around the Y axis. + The amount, in radians, by which to rotate around the Y-axis. + The rotation matrix. + + + Creates a matrix for rotating points around the Z axis. + The amount, in radians, by which to rotate around the Z-axis. + The rotation matrix. + + + Creates a matrix for rotating points around the Z axis from a center point. + The amount, in radians, by which to rotate around the Z-axis. + The center point. + The rotation matrix. + + + Creates a scaling matrix from the specified vector scale. + The scale to use. + The scaling matrix. + + + Creates a uniform scaling matrix that scale equally on each axis. + The uniform scaling factor. + The scaling matrix. + + + Creates a scaling matrix with a center point. + The vector that contains the amount to scale on each axis. + The center point. + The scaling matrix. + + + Creates a uniform scaling matrix that scales equally on each axis with a center point. + The uniform scaling factor. + The center point. + The scaling matrix. + + + Creates a scaling matrix from the specified X, Y, and Z components. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The value to scale by on the Z axis. + The scaling matrix. + + + Creates a scaling matrix that is offset by a given center point. + The value to scale by on the X axis. + The value to scale by on the Y axis. + The value to scale by on the Z axis. + The center point. + The scaling matrix. + + + Creates a matrix that flattens geometry into a specified plane as if casting a shadow from a specified light source. + The direction from which the light that will cast the shadow is coming. + The plane onto which the new matrix should flatten geometry so as to cast a shadow. + A new matrix that can be used to flatten geometry onto the specified plane from the specified direction. + + + Creates a translation matrix from the specified 3-dimensional vector. + The amount to translate in each axis. + The translation matrix. + + + Creates a translation matrix from the specified X, Y, and Z components. + The amount to translate on the X axis. + The amount to translate on the Y axis. + The amount to translate on the Z axis. + The translation matrix. + + + Creates a world matrix with the specified parameters. + The position of the object. + The forward direction of the object. + The upward direction of the object. Its value is usually [0, 1, 0]. + The world matrix. + + + Attempts to extract the scale, translation, and rotation components from the given scale, rotation, or translation matrix. The return value indicates whether the operation succeeded. + The source matrix. + When this method returns, contains the scaling component of the transformation matrix if the operation succeeded. + When this method returns, contains the rotation component of the transformation matrix if the operation succeeded. + When the method returns, contains the translation component of the transformation matrix if the operation succeeded. + true if matrix was decomposed successfully; otherwise, false. + + + Returns a value that indicates whether this instance and another 4x4 matrix are equal. + The other matrix. + true if the two matrices are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Calculates the determinant of the current 4x4 matrix. + The determinant. + + + Returns the hash code for this instance. + The hash code. + + + Gets the multiplicative identity matrix. + Gets the multiplicative identity matrix. + + + Inverts the specified matrix. The return value indicates whether the operation succeeded. + The matrix to invert. + When this method returns, contains the inverted matrix if the operation succeeded. + true if matrix was converted successfully; otherwise, false. + + + Indicates whether the current matrix is the identity matrix. + true if the current matrix is the identity matrix; otherwise, false. + + + Performs a linear interpolation from one matrix to a second matrix based on a value that specifies the weighting of the second matrix. + The first matrix. + The second matrix. + The relative weighting of matrix2. + The interpolated matrix. + + + The first element of the first row. + + + + The second element of the first row. + + + + The third element of the first row. + + + + The fourth element of the first row. + + + + The first element of the second row. + + + + The second element of the second row. + + + + The third element of the second row. + + + + The fourth element of the second row. + + + + The first element of the third row. + + + + The second element of the third row. + + + + The third element of the third row. + + + + The fourth element of the third row. + + + + The first element of the fourth row. + + + + The second element of the fourth row. + + + + The third element of the fourth row. + + + + The fourth element of the fourth row. + + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Adds each element in one matrix with its corresponding element in a second matrix. + The first matrix. + The second matrix. + The matrix that contains the summed values. + + + Returns a value that indicates whether the specified matrices are equal. + The first matrix to compare. + The second matrix to care + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether the specified matrices are not equal. + The first matrix to compare. + The second matrix to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the matrix that results from scaling all the elements of a specified matrix by a scalar factor. + The matrix to scale. + The scaling value to use. + The scaled matrix. + + + Returns the matrix that results from multiplying two matrices together. + The first matrix. + The second matrix. + The product matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Negates the specified matrix by multiplying all its values by -1. + The matrix to negate. + The negated matrix. + + + Subtracts each element in a second matrix from its corresponding element in a first matrix. + The first matrix. + The second matrix. + The matrix containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this matrix. + The string representation of this matrix. + + + Transforms the specified matrix by applying the specified Quaternion rotation. + The matrix to transform. + The rotation t apply. + The transformed matrix. + + + Gets or sets the translation component of this matrix. + The translation component of the current instance. + + + Transposes the rows and columns of a matrix. + The matrix to transpose. + The transposed matrix. + + + Represents a three-dimensional plane. + + + Creates a object from a specified four-dimensional vector. + A vector whose first three elements describe the normal vector, and whose defines the distance along that normal from the origin. + + + Creates a object from a specified normal and the distance along the normal from the origin. + The plane's normal vector. + The plane's distance from the origin along its normal vector. + + + Creates a object from the X, Y, and Z components of its normal, and its distance from the origin on that normal. + The X component of the normal. + The Y component of the normal. + The Z component of the normal. + The distance of the plane along its normal from the origin. + + + Creates a object that contains three specified points. + The first point defining the plane. + The second point defining the plane. + The third point defining the plane. + The plane containing the three points. + + + The distance of the plane along its normal from the origin. + + + + Calculates the dot product of a plane and a 4-dimensional vector. + The plane. + The four-dimensional vector. + The dot product. + + + Returns the dot product of a specified three-dimensional vector and the normal vector of this plane plus the distance () value of the plane. + The plane. + The 3-dimensional vector. + The dot product. + + + Returns the dot product of a specified three-dimensional vector and the vector of this plane. + The plane. + The three-dimensional vector. + The dot product. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns a value that indicates whether this instance and another plane object are equal. + The other plane. + true if the two planes are equal; otherwise, false. + + + Returns the hash code for this instance. + The hash code. + + + The normal vector of the plane. + + + + Creates a new object whose normal vector is the source plane's normal vector normalized. + The source plane. + The normalized plane. + + + Returns a value that indicates whether two planes are equal. + The first plane to compare. + The second plane to compare. + true if value1 and value2 are equal; otherwise, false. + + + Returns a value that indicates whether two planes are not equal. + The first plane to compare. + The second plane to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the string representation of this plane object. + A string that represents this object. + + + Transforms a normalized plane by a 4x4 matrix. + The normalized plane to transform. + The transformation matrix to apply to plane. + The transformed plane. + + + Transforms a normalized plane by a Quaternion rotation. + The normalized plane to transform. + The Quaternion rotation to apply to the plane. + A new plane that results from applying the Quaternion rotation. + + + Represents a vector that is used to encode three-dimensional physical rotations. + + + Creates a quaternion from the specified vector and rotation parts. + The vector part of the quaternion. + The rotation part of the quaternion. + + + Constructs a quaternion from the specified components. + The value to assign to the X component of the quaternion. + The value to assign to the Y component of the quaternion. + The value to assign to the Z component of the quaternion. + The value to assign to the W component of the quaternion. + + + Adds each element in one quaternion with its corresponding element in a second quaternion. + The first quaternion. + The second quaternion. + The quaternion that contains the summed values of value1 and value2. + + + Concatenates two quaternions. + The first quaternion rotation in the series. + The second quaternion rotation in the series. + A new quaternion representing the concatenation of the value1 rotation followed by the value2 rotation. + + + Returns the conjugate of a specified quaternion. + The quaternion. + A new quaternion that is the conjugate of value. + + + Creates a quaternion from a vector and an angle to rotate about the vector. + The vector to rotate around. + The angle, in radians, to rotate around the vector. + The newly created quaternion. + + + Creates a quaternion from the specified rotation matrix. + The rotation matrix. + The newly created quaternion. + + + Creates a new quaternion from the given yaw, pitch, and roll. + The yaw angle, in radians, around the Y axis. + The pitch angle, in radians, around the X axis. + The roll angle, in radians, around the Z axis. + The resulting quaternion. + + + Divides one quaternion by a second quaternion. + The dividend. + The divisor. + The quaternion that results from dividing value1 by value2. + + + Calculates the dot product of two quaternions. + The first quaternion. + The second quaternion. + The dot product. + + + Returns a value that indicates whether this instance and another quaternion are equal. + The other quaternion. + true if the two quaternions are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Gets a quaternion that represents no rotation. + A quaternion whose values are (0, 0, 0, 1). + + + Returns the inverse of a quaternion. + The quaternion. + The inverted quaternion. + + + Gets a value that indicates whether the current instance is the identity quaternion. + true if the current instance is the identity quaternion; otherwise, false. + + + Calculates the length of the quaternion. + The computed length of the quaternion. + + + Calculates the squared length of the quaternion. + The length squared of the quaternion. + + + Performs a linear interpolation between two quaternions based on a value that specifies the weighting of the second quaternion. + The first quaternion. + The second quaternion. + The relative weight of quaternion2 in the interpolation. + The interpolated quaternion. + + + Returns the quaternion that results from multiplying two quaternions together. + The first quaternion. + The second quaternion. + The product quaternion. + + + Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor. + The source quaternion. + The scalar value. + The scaled quaternion. + + + Reverses the sign of each component of the quaternion. + The quaternion to negate. + The negated quaternion. + + + Divides each component of a specified by its length. + The quaternion to normalize. + The normalized quaternion. + + + Adds each element in one quaternion with its corresponding element in a second quaternion. + The first quaternion. + The second quaternion. + The quaternion that contains the summed values of value1 and value2. + + + Divides one quaternion by a second quaternion. + The dividend. + The divisor. + The quaternion that results from dividing value1 by value2. + + + Returns a value that indicates whether two quaternions are equal. + The first quaternion to compare. + The second quaternion to compare. + true if the two quaternions are equal; otherwise, false. + + + Returns a value that indicates whether two quaternions are not equal. + The first quaternion to compare. + The second quaternion to compare. + true if value1 and value2 are not equal; otherwise, false. + + + Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor. + The source quaternion. + The scalar value. + The scaled quaternion. + + + Returns the quaternion that results from multiplying two quaternions together. + The first quaternion. + The second quaternion. + The product quaternion. + + + Subtracts each element in a second quaternion from its corresponding element in a first quaternion. + The first quaternion. + The second quaternion. + The quaternion containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Reverses the sign of each component of the quaternion. + The quaternion to negate. + The negated quaternion. + + + Interpolates between two quaternions, using spherical linear interpolation. + The first quaternion. + The second quaternion. + The relative weight of the second quaternion in the interpolation. + The interpolated quaternion. + + + Subtracts each element in a second quaternion from its corresponding element in a first quaternion. + The first quaternion. + The second quaternion. + The quaternion containing the values that result from subtracting each element in value2 from its corresponding element in value1. + + + Returns a string that represents this quaternion. + The string representation of this quaternion. + + + The rotation component of the quaternion. + + + + The X value of the vector component of the quaternion. + + + + The Y value of the vector component of the quaternion. + + + + The Z value of the vector component of the quaternion. + + + + Represents a single vector of a specified numeric type that is suitable for low-level optimization of parallel algorithms. + The vector type. T can be any primitive numeric type. + + + Creates a vector whose components are of a specified type. + The numeric type that defines the type of the components in the vector. + + + Creates a vector from a specified array. + A numeric array. + values is null. + + + Creates a vector from a specified array starting at a specified index position. + A numeric array. + The starting index position from which to create the vector. + values is null. + index is less than zero. -or- The length of values minus index is less than . + + + Copies the vector instance to a specified destination array. + The array to receive a copy of the vector values. + destination is null. + The number of elements in the current vector is greater than the number of elements available in the destination array. + + + Copies the vector instance to a specified destination array starting at a specified index position. + The array to receive a copy of the vector values. + The starting index in destination at which to begin the copy operation. + destination is null. + The number of elements in the current instance is greater than the number of elements available from startIndex to the end of the destination array. + index is less than zero or greater than the last index in destination. + + + Returns the number of elements stored in the vector. + The number of elements stored in the vector. + Access to the property getter via reflection is not supported. + + + Returns a value that indicates whether this instance is equal to a specified vector. + The vector to compare with this instance. + true if the current instance and other are equal; otherwise, false. + + + Returns a value that indicates whether this instance is equal to a specified object. + The object to compare with this instance. + true if the current instance and obj are equal; otherwise, false. The method returns false if obj is null, or if obj is a vector of a different type than the current instance. + + + Returns the hash code for this instance. + The hash code. + + + Gets the element at a specified index. + The index of the element to return. + The element at index index. + index is less than zero. -or- index is greater than or equal to . + + + Returns a vector containing all ones. + A vector containing all ones. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Returns a new vector by performing a bitwise And operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise And of left and right. + + + Returns a new vector by performing a bitwise Or operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise Or of the elements in left and right. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Returns a value that indicates whether each pair of elements in two specified vectors are equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a new vector by performing a bitwise XOr operation on each of the elements in two vectors. + The first vector. + The second vector. + The vector that results from the bitwise XOr of the elements in left and right. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Reinterprets the bits of the specified vector into a vector of type . + The vector to reinterpret. + The reinterpreted vector. + + + Returns a value that indicates whether any single pair of elements in the specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if any element pairs in left and right are equal. false if no element pairs are equal. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar value. + The source vector. + A scalar value. + The scaled vector. + + + Multiplies a vector by the given scalar. + The scalar value. + The source vector. + The scaled vector. + + + Returns a new vector whose elements are obtained by taking the one's complement of a specified vector's elements. + The source vector. + The one's complement vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates a given vector. + The vector to negate. + The negated vector. + + + Returns the string representation of this vector using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Returns the string representation of this vector using default formatting. + The string representation of this vector. + + + Returns the string representation of this vector using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns a vector containing all zeroes. + A vector containing all zeroes. + + + Provides a collection of static convenience methods for creating, manipulating, combining, and converting generic vectors. + + + Returns a new vector whose elements are the absolute values of the given vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The absolute value vector. + + + Returns a new vector whose values are the sum of each pair of elements from two given vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The summed vector. + + + Returns a new vector by performing a bitwise And Not operation on each pair of corresponding elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned bytes. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a double-precision floating-point vector. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of 16-bit integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of long integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of signed bytes. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a single-precision floating-point vector. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned 16-bit integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Reinterprets the bits of a specified vector into those of a vector of unsigned long integers. + The source vector. + The vector type. T can be any primitive numeric type. + The reinterpreted vector. + + + Returns a new vector by performing a bitwise And operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a new vector by performing a bitwise Or operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Creates a new single-precision vector with elements selected between two specified single-precision source vectors based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The new vector with elements selected based on the mask. + + + Creates a new double-precision vector with elements selected between two specified double-precision source vectors based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The new vector with elements selected based on the mask. + + + Creates a new vector of a specified type with elements selected between two specified source vectors of the same type based on an integral mask vector. + The integral mask vector used to drive selection. + The first source vector. + The second source vector. + The vector type. T can be any primitive numeric type. + The new vector with elements selected based on the mask. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector whose values are the result of dividing the first vector's elements by the corresponding elements in the second vector. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The divided vector. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The dot product. + + + Returns a new integral vector whose elements signal whether the elements in two specified double-precision vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in two specified integral vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in two specified long integer vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in two specified single-precision vectors are equal. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector of a specified type whose elements signal whether the elements in two specified vectors of the same type are equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether each pair of elements in the given vectors is equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left and right are equal; otherwise, false. + + + Returns a value that indicates whether any single pair of elements in the given vectors is equal. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element pair in left and right is equal; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are greater than their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are greater than their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are greater than their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision floating-point vector are greater than their corresponding elements in a second single-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector of a specified type are greater than their corresponding elements in the second vector of the same time. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are greater than the corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left are greater than the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is greater than the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is greater than the corresponding element in right; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one vector are greater than or equal to their corresponding elements in the single-precision floating-point second vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are greater than or equal to their corresponding elements in the second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are greater than or equal to their corresponding elements in the second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one vector are greater than or equal to their corresponding elements in the second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector of a specified type are greater than or equal to their corresponding elements in the second vector of the same type. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are greater than or equal to all the corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all elements in left are greater than or equal to the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is greater than or equal to the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is greater than or equal to the corresponding element in right; otherwise, false. + + + Gets a value that indicates whether vector operations are subject to hardware acceleration through JIT intrinsic support. + true if vector operations are subject to hardware acceleration; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are less than their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are less than their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are less than their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision vector are less than their corresponding elements in a second single-precision vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector of a specified type whose elements signal whether the elements in one vector are less than their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all of the elements in the first vector are less than their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all of the elements in left are less than the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is less than the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is less than the corresponding element in right; otherwise, false. + + + Returns a new integral vector whose elements signal whether the elements in one double-precision floating-point vector are less than or equal to their corresponding elements in a second double-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new integral vector whose elements signal whether the elements in one integral vector are less than or equal to their corresponding elements in a second integral vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new long integer vector whose elements signal whether the elements in one long integer vector are less or equal to their corresponding elements in a second long integer vector. + The first vector to compare. + The second vector to compare. + The resulting long integer vector. + + + Returns a new integral vector whose elements signal whether the elements in one single-precision floating-point vector are less than or equal to their corresponding elements in a second single-precision floating-point vector. + The first vector to compare. + The second vector to compare. + The resulting integral vector. + + + Returns a new vector whose elements signal whether the elements in one vector are less than or equal to their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a value that indicates whether all elements in the first vector are less than or equal to their corresponding elements in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if all of the elements in left are less than or equal to the corresponding elements in right; otherwise, false. + + + Returns a value that indicates whether any element in the first vector is less than or equal to the corresponding element in the second vector. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + true if any element in left is less than or equal to the corresponding element in right; otherwise, false. + + + Returns a new vector whose elements are the maximum of each pair of elements in the two given vectors. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The maximum vector. + + + Returns a new vector whose elements are the minimum of each pair of elements in the two given vectors. + The first vector to compare. + The second vector to compare. + The vector type. T can be any primitive numeric type. + The minimum vector. + + + Returns a new vector whose values are a scalar value multiplied by each of the values of a specified vector. + The scalar value. + The vector. + The vector type. T can be any primitive numeric type. + The scaled vector. + + + Returns a new vector whose values are the product of each pair of elements in two specified vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The product vector. + + + Returns a new vector whose values are the values of a specified vector each multiplied by a scalar value. + The vector. + The scalar value. + The vector type. T can be any primitive numeric type. + The scaled vector. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector whose elements are the negation of the corresponding element in the specified vector. + The source vector. + The vector type. T can be any primitive numeric type. + The negated vector. + + + Returns a new vector whose elements are obtained by taking the one's complement of a specified vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Returns a new vector whose elements are the square roots of a specified vector's elements. + The source vector. + The vector type. T can be any primitive numeric type. + The square root vector. + + + Returns a new vector whose values are the difference between the elements in the second vector and their corresponding elements in the first vector. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The difference vector. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns a new vector by performing a bitwise exclusive Or (XOr) operation on each pair of elements in two vectors. + The first vector. + The second vector. + The vector type. T can be any primitive numeric type. + The resulting vector. + + + Represents a vector with two single-precision floating-point values. + + + Creates a new object whose two elements have the same value. + The value to assign to both elements. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of the vector. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 2 elements are equal to one. + A vector whose two elements are equal to one (that is, it returns the vector (1,1). + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns the reflection of a vector off a surface that has the specified normal. + The source vector. + The normal of the surface being reflected off. + The reflected vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a vector by a specified 3x2 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a vector normal by the given 3x2 matrix. + The source vector. + The matrix. + The transformed vector. + + + Transforms a vector normal by the given 4x4 matrix. + The source vector. + The matrix. + The transformed vector. + + + Gets the vector (1,0). + The vector (1,0). + + + Gets the vector (0,1). + The vector (0,1). + + + The X component of the vector. + + + + The Y component of the vector. + + + + Returns a vector whose 2 elements are equal to zero. + A vector whose two elements are equal to zero (that is, it returns the vector (0,0). + + + Represents a vector with three single-precision floating-point values. + + + Creates a new object whose three elements have the same value. + The value to assign to all three elements. + + + Creates a new object from the specified object and the specified value. + The vector with two elements. + The additional value to assign to the field. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the cross product of two vectors. + The first vector. + The second vector. + The cross product. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of this vector object. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 3 elements are equal to one. + A vector whose three elements are equal to one (that is, it returns the vector (1,1,1). + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns the reflection of a vector off a surface that has the specified normal. + The source vector. + The normal of the surface being reflected off. + The reflected vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a vector normal by the given 4x4 matrix. + The source vector. + The matrix. + The transformed vector. + + + Gets the vector (1,0,0). + The vector (1,0,0). + + + Gets the vector (0,1,0). + The vector (0,1,0).. + + + Gets the vector (0,0,1). + The vector (0,0,1). + + + The X component of the vector. + + + + The Y component of the vector. + + + + The Z component of the vector. + + + + Gets a vector whose 3 elements are equal to zero. + A vector whose three elements are equal to zero (that is, it returns the vector (0,0,0). + + + Represents a vector with four single-precision floating-point values. + + + Creates a new object whose four elements have the same value. + The value to assign to all four elements. + + + Constructs a new object from the specified object and a W component. + The vector to use for the X, Y, and Z components. + The W component. + + + Creates a new object from the specified object and a Z and a W component. + The vector to use for the X and Y components. + The Z component. + The W component. + + + Creates a vector whose elements have the specified values. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + The value to assign to the field. + + + Returns a vector whose elements are the absolute values of each of the specified vector's elements. + A vector. + The absolute value vector. + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Restricts a vector between a minimum and a maximum value. + The vector to restrict. + The minimum value. + The maximum value. + The restricted vector. + + + Copies the elements of the vector to a specified array. + The destination array. + array is null. + The number of elements in the current instance is greater than in the array. + array is multidimensional. + + + Copies the elements of the vector to a specified array starting at a specified index position. + The destination array. + The index at which to copy the first element of the vector. + array is null. + The number of elements in the current instance is greater than in the array. + index is less than zero. -or- index is greater than or equal to the array length. + array is multidimensional. + + + Computes the Euclidean distance between the two given points. + The first point. + The second point. + The distance. + + + Returns the Euclidean distance squared between two specified points. + The first point. + The second point. + The distance squared. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector resulting from the division. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The vector that results from the division. + + + Returns the dot product of two vectors. + The first vector. + The second vector. + The dot product. + + + Returns a value that indicates whether this instance and another vector are equal. + The other vector. + true if the two vectors are equal; otherwise, false. + + + Returns a value that indicates whether this instance and a specified object are equal. + The object to compare with the current instance. + true if the current instance and obj are equal; otherwise, false```. If <code data-dev-comment-type="paramref">obj</code> isnull, the method returnsfalse`. + + + Returns the hash code for this instance. + The hash code. + + + Returns the length of this vector object. + The vector's length. + + + Returns the length of the vector squared. + The vector's length squared. + + + Performs a linear interpolation between two vectors based on the given weighting. + The first vector. + The second vector. + A value between 0 and 1 that indicates the weight of value2. + The interpolated vector. + + + Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The maximized vector. + + + Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors. + The first vector. + The second vector. + The minimized vector. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiplies a vector by a specified scalar. + The vector to multiply. + The scalar value. + The scaled vector. + + + Multiplies a scalar value by a specified vector. + The scaled value. + The vector. + The scaled vector. + + + Negates a specified vector. + The vector to negate. + The negated vector. + + + Returns a vector with the same direction as the specified vector, but with a length of one. + The vector to normalize. + The normalized vector. + + + Gets a vector whose 4 elements are equal to one. + Returns . + + + Adds two vectors together. + The first vector to add. + The second vector to add. + The summed vector. + + + Divides the first vector by the second. + The first vector. + The second vector. + The vector that results from dividing left by right. + + + Divides the specified vector by a specified scalar value. + The vector. + The scalar value. + The result of the division. + + + Returns a value that indicates whether each pair of elements in two specified vectors is equal. + The first vector to compare. + The second vector to compare. + true if left and right are equal; otherwise, false. + + + Returns a value that indicates whether two specified vectors are not equal. + The first vector to compare. + The second vector to compare. + true if left and right are not equal; otherwise, false. + + + Multiplies two vectors together. + The first vector. + The second vector. + The product vector. + + + Multiples the specified vector by the specified scalar value. + The vector. + The scalar value. + The scaled vector. + + + Multiples the scalar value by the specified vector. + The vector. + The scalar value. + The scaled vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The vector that results from subtracting right from left. + + + Negates the specified vector. + The vector to negate. + The negated vector. + + + Returns a vector whose elements are the square root of each of a specified vector's elements. + A vector. + The square root vector. + + + Subtracts the second vector from the first. + The first vector. + The second vector. + The difference vector. + + + Returns the string representation of the current instance using default formatting. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements. + A or that defines the format of individual elements. + The string representation of the current instance. + + + Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. + A or that defines the format of individual elements. + A format provider that supplies culture-specific formatting information. + The string representation of the current instance. + + + Transforms a four-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a four-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a three-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a two-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Transforms a two-dimensional vector by the specified Quaternion rotation value. + The vector to rotate. + The rotation to apply. + The transformed vector. + + + Transforms a three-dimensional vector by a specified 4x4 matrix. + The vector to transform. + The transformation matrix. + The transformed vector. + + + Gets the vector (0,0,0,1). + The vector (0,0,0,1). + + + Gets the vector (1,0,0,0). + The vector (1,0,0,0). + + + Gets the vector (0,1,0,0). + The vector (0,1,0,0).. + + + Gets a vector whose 4 elements are equal to zero. + The vector (0,0,1,0). + + + The W component of the vector. + + + + The X component of the vector. + + + + The Y component of the vector. + + + + The Z component of the vector. + + + + Gets a vector whose 4 elements are equal to zero. + A vector whose four elements are equal to zero (that is, it returns the vector (0,0,0,0). + + + \ No newline at end of file diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarinios10/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarinios10/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarinmac20/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarinmac20/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarintvos10/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarintvos10/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarinwatchos10/_._ b/middleware/packages/System.Numerics.Vectors.4.4.0/ref/xamarinwatchos10/_._ new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/useSharedDesignerContext.txt b/middleware/packages/System.Numerics.Vectors.4.4.0/useSharedDesignerContext.txt new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Numerics.Vectors.4.4.0/version.txt b/middleware/packages/System.Numerics.Vectors.4.4.0/version.txt new file mode 100644 index 0000000..f35e2ed --- /dev/null +++ b/middleware/packages/System.Numerics.Vectors.4.4.0/version.txt @@ -0,0 +1 @@ +8321c729934c0f8be754953439b88e6e1c120c24 diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/.signature.p7s b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/.signature.p7s new file mode 100644 index 0000000..a7fbb73 Binary files /dev/null and b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/.signature.p7s differ diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/LICENSE.TXT b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/LICENSE.TXT new file mode 100644 index 0000000..fa3121d --- /dev/null +++ b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/LICENSE.TXT @@ -0,0 +1,23 @@ +The MIT License (MIT) + +Copyright (c) .NET Foundation and Contributors + +All rights reserved. + +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. diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/System.Runtime.CompilerServices.Unsafe.4.5.2.nupkg b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/System.Runtime.CompilerServices.Unsafe.4.5.2.nupkg new file mode 100644 index 0000000..4f464e1 Binary files /dev/null and b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/System.Runtime.CompilerServices.Unsafe.4.5.2.nupkg differ diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/THIRD-PARTY-NOTICES.TXT b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/THIRD-PARTY-NOTICES.TXT new file mode 100644 index 0000000..207a2a7 --- /dev/null +++ b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/THIRD-PARTY-NOTICES.TXT @@ -0,0 +1,309 @@ +.NET Core uses third-party libraries or other resources that may be +distributed under licenses different than the .NET Core software. + +In the event that we accidentally failed to list a required notice, please +bring it to our attention. Post an issue or email us: + + dotnet@microsoft.com + +The attached notices are provided for information only. + +License notice for Slicing-by-8 +------------------------------- + +http://sourceforge.net/projects/slicing-by-8/ + +Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + + +This software program is licensed subject to the BSD License, available at +http://www.opensource.org/licenses/bsd-license.html. + + +License notice for Unicode data +------------------------------- + +http://www.unicode.org/copyright.html#License + +Copyright © 1991-2017 Unicode, Inc. All rights reserved. +Distributed under the Terms of Use in http://www.unicode.org/copyright.html. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Unicode data files and any associated documentation +(the "Data Files") or Unicode software and any associated documentation +(the "Software") to deal in the Data Files or Software +without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, and/or sell copies of +the Data Files or Software, and to permit persons to whom the Data Files +or Software are furnished to do so, provided that either +(a) this copyright and permission notice appear with all copies +of the Data Files or Software, or +(b) this copyright and permission notice appear in associated +Documentation. + +THE DATA FILES AND SOFTWARE ARE 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 OF THIRD PARTY RIGHTS. +IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS +NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL +DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THE DATA FILES OR SOFTWARE. + +Except as contained in this notice, the name of a copyright holder +shall not be used in advertising or otherwise to promote the sale, +use or other dealings in these Data Files or Software without prior +written authorization of the copyright holder. + +License notice for Zlib +----------------------- + +https://github.com/madler/zlib +http://zlib.net/zlib_license.html + +/* zlib.h -- interface of the 'zlib' general purpose compression library + version 1.2.11, January 15th, 2017 + + Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +*/ + +License notice for Mono +------------------------------- + +http://www.mono-project.com/docs/about-mono/ + +Copyright (c) .NET Foundation Contributors + +MIT License + +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. + +License notice for International Organization for Standardization +----------------------------------------------------------------- + +Portions (C) International Organization for Standardization 1986: + Permission to copy in any form is granted for use with + conforming SGML systems and applications as defined in + ISO 8879, provided this notice is included in all copies. + +License notice for Intel +------------------------ + +"Copyright (c) 2004-2006 Intel Corporation - All Rights Reserved + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this +list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License notice for Xamarin and Novell +------------------------------------- + +Copyright (c) 2015 Xamarin, Inc (http://www.xamarin.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. + +Copyright (c) 2011 Novell, Inc (http://www.novell.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. + +Third party notice for W3C +-------------------------- + +"W3C SOFTWARE AND DOCUMENT NOTICE AND LICENSE +Status: This license takes effect 13 May, 2015. +This work is being provided by the copyright holders under the following license. +License +By obtaining and/or copying this work, you (the licensee) agree that you have read, understood, and will comply with the following terms and conditions. +Permission to copy, modify, and distribute this work, with or without modification, for any purpose and without fee or royalty is hereby granted, provided that you include the following on ALL copies of the work or portions thereof, including modifications: +The full text of this NOTICE in a location viewable to users of the redistributed or derivative work. +Any pre-existing intellectual property disclaimers, notices, or terms and conditions. If none exist, the W3C Software and Document Short Notice should be included. +Notice of any changes or modifications, through a copyright statement on the new code or document such as "This software or document includes material copied from or derived from [title and URI of the W3C document]. Copyright © [YEAR] W3C® (MIT, ERCIM, Keio, Beihang)." +Disclaimers +THIS WORK IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENT WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS. +COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENT. +The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the work without specific, written prior permission. Title to copyright in this work will at all times remain with copyright holders." + +License notice for Bit Twiddling Hacks +-------------------------------------- + +Bit Twiddling Hacks + +By Sean Eron Anderson +seander@cs.stanford.edu + +Individually, the code snippets here are in the public domain (unless otherwise +noted) — feel free to use them however you please. The aggregate collection and +descriptions are © 1997-2005 Sean Eron Anderson. The code and descriptions are +distributed in the hope that they will be useful, but WITHOUT ANY WARRANTY and +without even the implied warranty of merchantability or fitness for a particular +purpose. + +License notice for Brotli +-------------------------------------- + +Copyright (c) 2009, 2010, 2013-2016 by the Brotli Authors. + +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. + +compress_fragment.c: +Copyright (c) 2011, Google Inc. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +""AS IS"" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +decode_fuzzer.c: +Copyright (c) 2015 The Chromium Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +""AS IS"" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." + diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.dll b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.dll new file mode 100644 index 0000000..19ec356 Binary files /dev/null and b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.dll differ diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.xml b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.xml new file mode 100644 index 0000000..84c0213 --- /dev/null +++ b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard1.0/System.Runtime.CompilerServices.Unsafe.xml @@ -0,0 +1,200 @@ + + + System.Runtime.CompilerServices.Unsafe + + + + Contains generic, low-level functionality for manipulating pointers. + + + Adds an element offset to the given reference. + The reference to add the offset to. + The offset to add. + The type of reference. + A new reference that reflects the addition of offset to pointer. + + + Adds an element offset to the given reference. + The reference to add the offset to. + The offset to add. + The type of reference. + A new reference that reflects the addition of offset to pointer. + + + Adds a byte offset to the given reference. + The reference to add the offset to. + The offset to add. + The type of reference. + A new reference that reflects the addition of byte offset to pointer. + + + Determines whether the specified references point to the same location. + The first reference to compare. + The second reference to compare. + The type of reference. + true if left and right point to the same location; otherwise, false. + + + Casts the given object to the specified type. + The object to cast. + The type which the object will be cast to. + The original object, casted to the given type. + + + Reinterprets the given reference as a reference to a value of type TTo. + The reference to reinterpret. + The type of reference to reinterpret.. + The desired type of the reference. + A reference to a value of type TTo. + + + Returns a pointer to the given by-ref parameter. + The object whose pointer is obtained. + The type of object. + A pointer to the given value. + + + Reinterprets the given location as a reference to a value of type T. + The location of the value to reference. + The type of the interpreted location. + A reference to a value of type T. + + + Determines the byte offset from origin to target from the given references. + The reference to origin. + The reference to target. + The type of reference. + Byte offset from origin to target i.e. target - origin. + + + Copies a value of type T to the given location. + The location to copy to. + A reference to the value to copy. + The type of value to copy. + + + Copies a value of type T to the given location. + The location to copy to. + A pointer to the value to copy. + The type of value to copy. + + + Copies bytes from the source address to the destination address. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Copies bytes from the source address to the destination address. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Copies bytes from the source address to the destination address +without assuming architecture dependent alignment of the addresses. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Copies bytes from the source address to the destination address +without assuming architecture dependent alignment of the addresses. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Initializes a block of memory at the given location with a given initial value. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Initializes a block of memory at the given location with a given initial value. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Initializes a block of memory at the given location with a given initial value +without assuming architecture dependent alignment of the address. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Initializes a block of memory at the given location with a given initial value +without assuming architecture dependent alignment of the address. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Reads a value of type T from the given location. + The location to read from. + The type to read. + An object of type T read from the given location. + + + Reads a value of type T from the given location +without assuming architecture dependent alignment of the addresses. + The location to read from. + The type to read. + An object of type T read from the given location. + + + Reads a value of type T from the given location +without assuming architecture dependent alignment of the addresses. + The location to read from. + The type to read. + An object of type T read from the given location. + + + Returns the size of an object of the given type parameter. + The type of object whose size is retrieved. + The size of an object of type T. + + + Subtracts an element offset from the given reference. + The reference to subtract the offset from. + The offset to subtract. + The type of reference. + A new reference that reflects the subraction of offset from pointer. + + + Subtracts an element offset from the given reference. + The reference to subtract the offset from. + The offset to subtract. + The type of reference. + A new reference that reflects the subraction of offset from pointer. + + + Subtracts a byte offset from the given reference. + The reference to subtract the offset from. + + The type of reference. + A new reference that reflects the subraction of byte offset from pointer. + + + Writes a value of type T to the given location. + The location to write to. + The value to write. + The type of value to write. + + + Writes a value of type T to the given location +without assuming architecture dependent alignment of the addresses. + The location to write to. + The value to write. + The type of value to write. + + + Writes a value of type T to the given location +without assuming architecture dependent alignment of the addresses. + The location to write to. + The value to write. + The type of value to write. + + + \ No newline at end of file diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll new file mode 100644 index 0000000..9d99613 Binary files /dev/null and b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll differ diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.xml b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.xml new file mode 100644 index 0000000..84c0213 --- /dev/null +++ b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/ref/netstandard2.0/System.Runtime.CompilerServices.Unsafe.xml @@ -0,0 +1,200 @@ + + + System.Runtime.CompilerServices.Unsafe + + + + Contains generic, low-level functionality for manipulating pointers. + + + Adds an element offset to the given reference. + The reference to add the offset to. + The offset to add. + The type of reference. + A new reference that reflects the addition of offset to pointer. + + + Adds an element offset to the given reference. + The reference to add the offset to. + The offset to add. + The type of reference. + A new reference that reflects the addition of offset to pointer. + + + Adds a byte offset to the given reference. + The reference to add the offset to. + The offset to add. + The type of reference. + A new reference that reflects the addition of byte offset to pointer. + + + Determines whether the specified references point to the same location. + The first reference to compare. + The second reference to compare. + The type of reference. + true if left and right point to the same location; otherwise, false. + + + Casts the given object to the specified type. + The object to cast. + The type which the object will be cast to. + The original object, casted to the given type. + + + Reinterprets the given reference as a reference to a value of type TTo. + The reference to reinterpret. + The type of reference to reinterpret.. + The desired type of the reference. + A reference to a value of type TTo. + + + Returns a pointer to the given by-ref parameter. + The object whose pointer is obtained. + The type of object. + A pointer to the given value. + + + Reinterprets the given location as a reference to a value of type T. + The location of the value to reference. + The type of the interpreted location. + A reference to a value of type T. + + + Determines the byte offset from origin to target from the given references. + The reference to origin. + The reference to target. + The type of reference. + Byte offset from origin to target i.e. target - origin. + + + Copies a value of type T to the given location. + The location to copy to. + A reference to the value to copy. + The type of value to copy. + + + Copies a value of type T to the given location. + The location to copy to. + A pointer to the value to copy. + The type of value to copy. + + + Copies bytes from the source address to the destination address. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Copies bytes from the source address to the destination address. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Copies bytes from the source address to the destination address +without assuming architecture dependent alignment of the addresses. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Copies bytes from the source address to the destination address +without assuming architecture dependent alignment of the addresses. + The destination address to copy to. + The source address to copy from. + The number of bytes to copy. + + + Initializes a block of memory at the given location with a given initial value. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Initializes a block of memory at the given location with a given initial value. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Initializes a block of memory at the given location with a given initial value +without assuming architecture dependent alignment of the address. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Initializes a block of memory at the given location with a given initial value +without assuming architecture dependent alignment of the address. + The address of the start of the memory block to initialize. + The value to initialize the block to. + The number of bytes to initialize. + + + Reads a value of type T from the given location. + The location to read from. + The type to read. + An object of type T read from the given location. + + + Reads a value of type T from the given location +without assuming architecture dependent alignment of the addresses. + The location to read from. + The type to read. + An object of type T read from the given location. + + + Reads a value of type T from the given location +without assuming architecture dependent alignment of the addresses. + The location to read from. + The type to read. + An object of type T read from the given location. + + + Returns the size of an object of the given type parameter. + The type of object whose size is retrieved. + The size of an object of type T. + + + Subtracts an element offset from the given reference. + The reference to subtract the offset from. + The offset to subtract. + The type of reference. + A new reference that reflects the subraction of offset from pointer. + + + Subtracts an element offset from the given reference. + The reference to subtract the offset from. + The offset to subtract. + The type of reference. + A new reference that reflects the subraction of offset from pointer. + + + Subtracts a byte offset from the given reference. + The reference to subtract the offset from. + + The type of reference. + A new reference that reflects the subraction of byte offset from pointer. + + + Writes a value of type T to the given location. + The location to write to. + The value to write. + The type of value to write. + + + Writes a value of type T to the given location +without assuming architecture dependent alignment of the addresses. + The location to write to. + The value to write. + The type of value to write. + + + Writes a value of type T to the given location +without assuming architecture dependent alignment of the addresses. + The location to write to. + The value to write. + The type of value to write. + + + \ No newline at end of file diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/useSharedDesignerContext.txt b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/useSharedDesignerContext.txt new file mode 100644 index 0000000..e69de29 diff --git a/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/version.txt b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/version.txt new file mode 100644 index 0000000..7558087 --- /dev/null +++ b/middleware/packages/System.Runtime.CompilerServices.Unsafe.4.5.2/version.txt @@ -0,0 +1 @@ +02b11eeee1fbc5f3ef43a1452fe07efd25fa1715 diff --git a/middleware/packages/sqlite-net-pcl.1.8.116/.signature.p7s b/middleware/packages/sqlite-net-pcl.1.8.116/.signature.p7s new file mode 100644 index 0000000..0731611 Binary files /dev/null and b/middleware/packages/sqlite-net-pcl.1.8.116/.signature.p7s differ diff --git a/middleware/packages/sqlite-net-pcl.1.8.116/LICENSE.txt b/middleware/packages/sqlite-net-pcl.1.8.116/LICENSE.txt new file mode 100644 index 0000000..4d5af2b --- /dev/null +++ b/middleware/packages/sqlite-net-pcl.1.8.116/LICENSE.txt @@ -0,0 +1,21 @@ +Copyright (c) Krueger Systems, Inc. + +All rights reserved. + +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. diff --git a/middleware/packages/sqlite-net-pcl.1.8.116/Logo-low.png b/middleware/packages/sqlite-net-pcl.1.8.116/Logo-low.png new file mode 100644 index 0000000..f3ae124 Binary files /dev/null and b/middleware/packages/sqlite-net-pcl.1.8.116/Logo-low.png differ diff --git a/middleware/packages/sqlite-net-pcl.1.8.116/sqlite-net-pcl.1.8.116.nupkg b/middleware/packages/sqlite-net-pcl.1.8.116/sqlite-net-pcl.1.8.116.nupkg new file mode 100644 index 0000000..cf1fe73 Binary files /dev/null and b/middleware/packages/sqlite-net-pcl.1.8.116/sqlite-net-pcl.1.8.116.nupkg differ diff --git a/middleware/zdhsys.sln b/middleware/zdhsys.sln new file mode 100644 index 0000000..909c510 --- /dev/null +++ b/middleware/zdhsys.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.33801.447 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "zdhsys", "zdhsys\zdhsys.csproj", "{A1F84281-829C-453E-8C89-15EB8446B1CD}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "JsonClassGeneratorLib", "JsonCSharpClassGeneratorLib\JsonClassGeneratorLib.csproj", "{7BEF7EAA-DE37-40FB-BD33-3DEF0685031F}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {A1F84281-829C-453E-8C89-15EB8446B1CD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {A1F84281-829C-453E-8C89-15EB8446B1CD}.Debug|Any CPU.Build.0 = Debug|Any CPU + {A1F84281-829C-453E-8C89-15EB8446B1CD}.Release|Any CPU.ActiveCfg = Release|Any CPU + {A1F84281-829C-453E-8C89-15EB8446B1CD}.Release|Any CPU.Build.0 = Release|Any CPU + {7BEF7EAA-DE37-40FB-BD33-3DEF0685031F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7BEF7EAA-DE37-40FB-BD33-3DEF0685031F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7BEF7EAA-DE37-40FB-BD33-3DEF0685031F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7BEF7EAA-DE37-40FB-BD33-3DEF0685031F}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {0082BE1E-FCFD-4FF5-A05F-C1A51176CFCB} + EndGlobalSection +EndGlobal diff --git a/middleware/zdhsys/App.config b/middleware/zdhsys/App.config new file mode 100644 index 0000000..3916e0e --- /dev/null +++ b/middleware/zdhsys/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/middleware/zdhsys/App.xaml b/middleware/zdhsys/App.xaml new file mode 100644 index 0000000..7e42512 --- /dev/null +++ b/middleware/zdhsys/App.xaml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/middleware/zdhsys/App.xaml.cs b/middleware/zdhsys/App.xaml.cs new file mode 100644 index 0000000..48a208e --- /dev/null +++ b/middleware/zdhsys/App.xaml.cs @@ -0,0 +1,225 @@ +using System; +using System.Net; +using System.Threading.Tasks; +using System.Windows; +using System.Linq; +using zdhsys; +using Newtonsoft.Json; +using System.IO; +using System.Text; +using System.Windows.Shapes; +using Newtonsoft.Json.Linq; + +namespace zdhsys +{ + public partial class App : Application + { + private HttpListener _listener; + private Task _serverTask; + internal ExperimentData experimentData { get; private set; } + + protected override void OnStartup(StartupEventArgs e) + { + base.OnStartup(e); + + // 启动HTTP服务器 + StartHttpServer(); + } + + private void StartHttpServer() + { + _listener = new HttpListener(); + _listener.Prefixes.Add("http://*:50000/"); + _listener.Start(); + + _serverTask = Task.Run(() => HandleRequests()); + } + + private async Task HandleRequests() + { + while (_listener.IsListening) + { + var context = await _listener.GetContextAsync(); + ProcessRequest(context); + } + } + + private void ProcessRequest(HttpListenerContext context) + { + try + { + var request = context.Request; + var response = context.Response; + + // 处理路由 + if (request.Url.AbsolutePath == "/" && request.HttpMethod == "GET") + { + var responseString = "{\"message\": \"Welcome to AI robot platform API!\"}"; + var buffer = System.Text.Encoding.UTF8.GetBytes(responseString); + + response.ContentType = "application/json"; + response.ContentLength64 = buffer.Length; + response.OutputStream.Write(buffer, 0, buffer.Length); + } + else if (request.Url.AbsolutePath == "/sendScheme2RobotPlatform" && request.HttpMethod == "POST") + { + try + { + using (var reader = new System.IO.StreamReader(request.InputStream, request.ContentEncoding)) + { + var json = reader.ReadToEnd(); + Console.WriteLine("Received JSON data:"); + Console.WriteLine(json); + + // 更新实验数据 + experimentData = JsonConvert.DeserializeObject(json); + Console.WriteLine("Experiment data updated:"); + Console.WriteLine($"Task ID: {experimentData.TaskId}"); + Console.WriteLine($"Experiment Name: {experimentData.ExperimentName}"); + + // 创建任务ID文件夹 + string currentDirectory = Directory.GetCurrentDirectory(); + string directoryPath = System.IO.Path.Combine(System.IO.Path.GetDirectoryName(System.IO.Path.GetDirectoryName(currentDirectory)), "PLdata", experimentData.TaskId); + Directory.CreateDirectory(directoryPath); + string jsonFilePath = System.IO.Path.Combine(directoryPath, "scheme.json"); + + try + { + // 将 JSON 字符串解析为 JObject + var jsonObject = JObject.Parse(json); + + // 将对象序列化为格式化的 JSON 字符串(缩进为 2) + string formattedJson = jsonObject.ToString(Formatting.Indented); + + // 将格式化的 JSON 写入文件 + File.WriteAllText(jsonFilePath, formattedJson); + + Console.WriteLine($"JSON 已成功写入文件:{jsonFilePath}"); + } + catch (Exception ex) + { + Console.WriteLine($"发生错误:{ex.Message}"); + } + + var responseString = "{\"status\": \"success\", \"message\": \"Experiment data updated\"}"; + var buffer = System.Text.Encoding.UTF8.GetBytes(responseString); + + response.ContentType = "application/json"; + response.ContentLength64 = buffer.Length; + response.OutputStream.Write(buffer, 0, buffer.Length); + } + } + catch (Exception ex) + { + response.StatusCode = (int)HttpStatusCode.BadRequest; + var errorResponse = new { error = ex.Message }; + var buffer = System.Text.Encoding.UTF8.GetBytes(Newtonsoft.Json.JsonConvert.SerializeObject(errorResponse)); + response.OutputStream.Write(buffer, 0, buffer.Length); + } + } + else if (request.Url.AbsolutePath == "/getPLdata" && request.HttpMethod == "GET") + { + try + { + // 获取taskid参数 + string taskId = experimentData.TaskId; + string currentDirectory = Directory.GetCurrentDirectory(); + + // 如果 taskId 为空,则尝试从 PLdata 文件夹中获取最新的日期文件夹 + if (string.IsNullOrEmpty(taskId)) + { + string plDataPath = System.IO.Path.Combine(System.IO.Path.GetDirectoryName(System.IO.Path.GetDirectoryName(currentDirectory)), "PLdata"); + + // 检查 PLdata 文件夹是否存在 + if (!Directory.Exists(plDataPath)) + { + Console.WriteLine("PLdata directory does not exist."); + return; + } + + // 获取 PLdata 文件夹中的所有子文件夹 + var directories = Directory.GetDirectories(plDataPath) + .Where(dir => DateTime.TryParse(System.IO.Path.GetFileName(dir), out _)) // 确保文件夹名是有效的日期格式 + .Select(dir => new { Path = dir, Date = DateTime.Parse(System.IO.Path.GetFileName(dir)) }) + .OrderByDescending(x => x.Date) // 按日期降序排序 + .ToList(); + + if (directories.Any()) + { + // 取最新日期的文件夹名称作为 taskId + taskId = System.IO.Path.GetFileName(directories.First().Path); + Console.WriteLine($"Latest taskid from folder: {taskId}"); + } + else + { + Console.WriteLine("No valid date folders found in PLdata."); + return; + } + } + + // 构建路径 + string directoryPath = System.IO.Path.Combine(System.IO.Path.GetDirectoryName(System.IO.Path.GetDirectoryName(currentDirectory)), "PLdata", taskId); + Console.WriteLine($"Constructed directory path: {directoryPath}"); + + // 检查目录是否存在 + if (!Directory.Exists(directoryPath)) + { + response.StatusCode = (int)HttpStatusCode.NotFound; + var errorResponse = new { error = "Task directory not found" }; + var buffer = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(errorResponse)); + response.OutputStream.Write(buffer, 0, buffer.Length); + return; + } + + // 获取最新的txt文件 + var files = Directory.GetFiles(directoryPath, "*.TXT") + .Select(f => new FileInfo(f)) + .OrderByDescending(f => f.LastWriteTime) + .ToList(); + + if (files.Count == 0) + { + response.StatusCode = (int)HttpStatusCode.NotFound; + var errorResponse = new { error = "No TXT files found" }; + var buffer = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(errorResponse)); + response.OutputStream.Write(buffer, 0, buffer.Length); + return; + } + + // 读取最新文件内容 + string latestFileContent = File.ReadAllText(files[0].FullName); + + // 发送响应 + var responseBuffer = Encoding.UTF8.GetBytes(latestFileContent); + response.ContentType = "text/plain"; + response.ContentLength64 = responseBuffer.Length; + response.OutputStream.Write(responseBuffer, 0, responseBuffer.Length); + } + catch (Exception ex) + { + response.StatusCode = (int)HttpStatusCode.InternalServerError; + var errorResponse = new { error = ex.Message }; + var buffer = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(errorResponse)); + response.OutputStream.Write(buffer, 0, buffer.Length); + } + } + else + { + response.StatusCode = (int)HttpStatusCode.NotFound; + } + } + finally + { + context.Response.OutputStream.Close(); + } + } + + protected override void OnExit(ExitEventArgs e) + { + // 关闭HTTP服务器 + _listener?.Stop(); + _listener?.Close(); + base.OnExit(e); + } + } +} diff --git a/middleware/zdhsys/Bean/DeviceFields.cs b/middleware/zdhsys/Bean/DeviceFields.cs new file mode 100644 index 0000000..f8c7b5a --- /dev/null +++ b/middleware/zdhsys/Bean/DeviceFields.cs @@ -0,0 +1,9 @@ +namespace zdhsys.Bean +{ + public class DeviceFields + { + public int index; + public DeviceInfoModel dim; + public DeviceFieldsModel dfm; + } +} diff --git a/middleware/zdhsys/Bean/DeviceFieldsModel.cs b/middleware/zdhsys/Bean/DeviceFieldsModel.cs new file mode 100644 index 0000000..01cf975 --- /dev/null +++ b/middleware/zdhsys/Bean/DeviceFieldsModel.cs @@ -0,0 +1,33 @@ +using SQLite; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + public class DeviceFieldsModel + { + //[PrimaryKey, AutoIncrement] + public int Id { get; set; } + /// + /// 字段名称 + /// + public string FieldsName { get; set; } + /// + /// 字段内容 + /// + public string FieldsContent { get; set; } + + ///// + ///// 所属设备 + ///// + //public int DeviceId { get; set; } + + ///// + ///// 所属组设备 + ///// + //public int DeviceGroupId { get; set; } + } +} diff --git a/middleware/zdhsys/Bean/DeviceGroupInfoModel.cs b/middleware/zdhsys/Bean/DeviceGroupInfoModel.cs new file mode 100644 index 0000000..9de1632 --- /dev/null +++ b/middleware/zdhsys/Bean/DeviceGroupInfoModel.cs @@ -0,0 +1,94 @@ +using SQLite; +using System; +using System.Collections.Generic; + +namespace zdhsys.Bean +{ + public class DeviceGroupInfoModel + { + /// + /// 表ID + /// + [PrimaryKey, AutoIncrement] + public int Id { get; set; } + /// + /// 设备类别 + /// + public int DeviceType { get; set; } + /// + /// 设备组ID --通讯用的 + /// + public string DeviceId { get; set; } + /// + /// 设备组名称 + /// + public string DeviceName { get; set; } + /// + /// 标签名称 + /// + public string TagName { get; set; } + /// + /// 标签单位 + /// + public string TagUnit { get; set; } + /// + /// 坐标位置:X + /// + public float X { get; set; } + /// + /// 坐标位置:Y + /// + public float Y { get; set; } + /// + /// 坐标位置:Z + /// + public float Z { get; set; } + /// + /// 设备大小:长 + /// + public float L { get; set; } + /// + /// 设备大小:宽 + /// + public float W { get; set; } + /// + /// 设备大小:高 + /// + public float H { get; set; } + + /// + /// 操作物体种类:大瓶子0 小瓶子1 + /// + public int Bottole { get; set; } + + /// + /// 创建时间 + /// + public long CreateTime { get; set; } + + /// + /// 设备可操作 + /// + public List Dfms; + + /// + /// 设备可操作JSON字符串 + /// + public string FieldJson { get; set; } + + /// + /// 当前余量 + /// + public string Remain { get; set; } + + /// + /// 设备状态 1 正常 其它故障 + /// + public int DeviceStatus { get; set; } + /// + /// 通信协议 =GlobalEnum.UnitDeviceType + /// + public string Protocol { get; set; } + + } +} diff --git a/middleware/zdhsys/Bean/DeviceInfoModel.cs b/middleware/zdhsys/Bean/DeviceInfoModel.cs new file mode 100644 index 0000000..dca4f30 --- /dev/null +++ b/middleware/zdhsys/Bean/DeviceInfoModel.cs @@ -0,0 +1,124 @@ +using SQLite; +using System.Collections.Generic; + +namespace zdhsys.Bean +{ + public class DeviceInfoModel + { + /// + /// 表ID + /// + [PrimaryKey, AutoIncrement] + public int Id { get; set; } + /// + /// 设备类别 0反应类设备 1转移类设备 + /// + public int DeviceType { get; set; } + /// + /// 设备ID --通讯用的 + /// + public string DeviceId { get; set; } + /// + /// 所属设备组ID + /// + public string DeviceGroupId { get; set; } + /// + /// 设备名称 + /// + public string DeviceName { get; set; } + /// + /// 标签名称 + /// + public string TagName { get; set; } + /// + /// 标签单位 + /// + public string TagUnit { get; set; } + /// + /// 坐标位置:X + /// + public float X { get; set; } + /// + /// 坐标位置:Y + /// + public float Y { get; set; } + /// + /// 坐标位置:Z + /// + public float Z { get; set; } + /// + /// 设备大小:长 + /// + public float L { get; set; } + /// + /// 设备大小:宽 + /// + public float W { get; set; } + /// + /// 设备大小:高 + /// + public float H { get; set; } + /// + /// 操作物体种类:大瓶子0 小瓶子1 + /// + public int Bottole { get; set; } + + /// + /// 创建时间 + /// + public long CreateTime { get; set; } + + /// + /// 设备可操作 --不生成数据库字段 + /// + public List Dfms; + + /// + /// 设备可操作JSON字符串 + /// + public string FieldJson { get; set; } + /// + /// 点位信息 + /// + public string PointJson { get; set; } + + /// + /// 排序 + /// + public int Sort { get; set; } + + #region 下面是其它字段。是从设备上读取上来的。 + + /// + /// 当前余量 + /// + public string Remain { get; set; } + + /// + /// 设备状态 1 正常 其它故障 + /// + public int DeviceStatus { get; set; } + + /// + /// PCR值 + /// + public string PCR { get; set; } + + /// + /// 浓度 + /// + public string Concentration { get; set; } + + /// + /// 密度 + /// + public string Density { get; set; } + + /// + /// 重量 + /// + public string Weight { get; set; } + + #endregion + } +} diff --git a/middleware/zdhsys/Bean/FlowModel.cs b/middleware/zdhsys/Bean/FlowModel.cs new file mode 100644 index 0000000..cd458b8 --- /dev/null +++ b/middleware/zdhsys/Bean/FlowModel.cs @@ -0,0 +1,35 @@ +using SQLite; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + public class FlowModel + { + [PrimaryKey, AutoIncrement] + public int Id { get; set; } + /// + /// 流程名称 + /// + public string FlowName { get; set; } + /// + /// 流程编号 + /// + public string FlowNO { get; set; } + /// + /// 创建时间 + /// + public long CreateTime { get; set; } + /// + /// 流程状态 0正常 1禁用 + /// + public int Status { get; set; } + /// + /// 流程详情 + /// + public string FlowJson { get; set; } + } +} diff --git a/middleware/zdhsys/Bean/OptionFieldsModel.cs b/middleware/zdhsys/Bean/OptionFieldsModel.cs new file mode 100644 index 0000000..51422a5 --- /dev/null +++ b/middleware/zdhsys/Bean/OptionFieldsModel.cs @@ -0,0 +1,31 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + /// + /// 子配方字段 + /// + public class OptionFieldsModel + { + /// + /// 设备ID + /// + public int Id { get; set; } + /// + /// 设备编号 + /// + public string DeviceId { get; set; } + /// + /// 设备标签名 + /// + public string TagName { get; set; } + /// + /// 数值 + /// + public string TagValue { get; set; } + } +} diff --git a/middleware/zdhsys/Bean/OptionFieldsModel2.cs b/middleware/zdhsys/Bean/OptionFieldsModel2.cs new file mode 100644 index 0000000..5e520f6 --- /dev/null +++ b/middleware/zdhsys/Bean/OptionFieldsModel2.cs @@ -0,0 +1,41 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + /// + /// 子配方字段 + /// + public class OptionFieldsModel2 + { + /// + /// 设备ID + /// + public int Id { get; set; } + /// + /// 设备编号 + /// + public string DeviceId { get; set; } + /// + /// 设备标签名 + /// + public string TagName { get; set; } + /// + /// 数值 + /// + public string TagValue { get; set; } + + /// + /// 是否是子配方 + /// + public bool IsSub { get; set; } + /// + /// 子配方ID + /// + public int SubId { get; set; } + + } +} diff --git a/middleware/zdhsys/Bean/OptionModel.cs b/middleware/zdhsys/Bean/OptionModel.cs new file mode 100644 index 0000000..ce057ba --- /dev/null +++ b/middleware/zdhsys/Bean/OptionModel.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + public class OptionModel + { + public string Column1 { get; set; } + public string Column2 { get; set; } + public string Column3 { get; set; } + public string Column4 { get; set; } + } +} diff --git a/middleware/zdhsys/Bean/Options.cs b/middleware/zdhsys/Bean/Options.cs new file mode 100644 index 0000000..422fc27 --- /dev/null +++ b/middleware/zdhsys/Bean/Options.cs @@ -0,0 +1,36 @@ +using SQLite; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + public class Options + { + [PrimaryKey, AutoIncrement] + public int Id { get; set; } + /// + /// 配方名称 + /// + public string OptionName { get; set; } + /// + /// 创建时间 + /// + public long CreateTime { get; set; } + /// + /// 配方状态 0正常 1已作废 + /// + public int Status { get; set; } + /// + /// 配方详情 + /// + public string OptionJson { get; set; } + /// + /// 使用流程 + /// + public int FlowId { get; set; } + + } +} diff --git a/middleware/zdhsys/Bean/RobotInfoModel.cs b/middleware/zdhsys/Bean/RobotInfoModel.cs new file mode 100644 index 0000000..f38ea0d --- /dev/null +++ b/middleware/zdhsys/Bean/RobotInfoModel.cs @@ -0,0 +1,23 @@ +using SQLite; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + public class RobotInfoModel + { + [PrimaryKey, AutoIncrement] + public int Id { get; set; } + /// + /// 机械臂IP + /// + public string RobotIP { get; set; } + /// + /// 机械臂PORT + /// + public string RobotPort { get; set; } + } +} diff --git a/middleware/zdhsys/Bean/SubOptionModel.cs b/middleware/zdhsys/Bean/SubOptionModel.cs new file mode 100644 index 0000000..739b306 --- /dev/null +++ b/middleware/zdhsys/Bean/SubOptionModel.cs @@ -0,0 +1,36 @@ +using SQLite; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace zdhsys.Bean +{ + public class SubOptionModel + { + [PrimaryKey, AutoIncrement] + public int Id { get; set; } + + /// + /// 子配方名称 + /// + public string SubOptionName { get; set; } + + /// + /// 创建时间 + /// + public long CreateTime { get; set; } + + /// + /// 配方状态 0正常 1已作废 + /// + public int Status { get; set; } + + /// + /// 标签集合JSON + /// + public string OptionJson { get; set; } + + } +} diff --git a/middleware/zdhsys/Control/ClearDevice.xaml b/middleware/zdhsys/Control/ClearDevice.xaml new file mode 100644 index 0000000..8474a42 --- /dev/null +++ b/middleware/zdhsys/Control/ClearDevice.xaml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + diff --git a/middleware/zdhsys/Control/ClearDevice.xaml.cs b/middleware/zdhsys/Control/ClearDevice.xaml.cs new file mode 100644 index 0000000..795fbda --- /dev/null +++ b/middleware/zdhsys/Control/ClearDevice.xaml.cs @@ -0,0 +1,36 @@ +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 zdhsys.Control +{ + /// + /// ClearDevice.xaml 的交互逻辑 + /// + public partial class ClearDevice : UserControl + { + public ClearDevice() + { + InitializeComponent(); + } + public void SetUI(string name,string status,string path) + { + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + img.Source = bitmapImage; + lbName.Content = name; + lbStatus.Content = status; + } + } +} diff --git a/middleware/zdhsys/Control/ColorButton.xaml b/middleware/zdhsys/Control/ColorButton.xaml new file mode 100644 index 0000000..ee43952 --- /dev/null +++ b/middleware/zdhsys/Control/ColorButton.xaml @@ -0,0 +1,13 @@ + + + + + diff --git a/middleware/zdhsys/Control/ColorButton.xaml.cs b/middleware/zdhsys/Control/ColorButton.xaml.cs new file mode 100644 index 0000000..802e166 --- /dev/null +++ b/middleware/zdhsys/Control/ColorButton.xaml.cs @@ -0,0 +1,52 @@ +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 zdhsys.Control +{ + /// + /// ColorButton.xaml 的交互逻辑 + /// + public partial class ColorButton : UserControl + { + public ColorButton() + { + InitializeComponent(); + } + public event RoutedEventHandler Click; + + public bool isCheck = false; + public void SetUI(string hexColor) + { + Color color = (Color)ColorConverter.ConvertFromString(hexColor); + SolidColorBrush brush = new SolidColorBrush(color); + gd.Background = brush; + } + public void SetIsCheck(bool flag) + { + isCheck = flag; + lb_gou.Visibility = isCheck ? Visibility.Visible : Visibility.Hidden; + } + + private void UserControl_MouseLeftButtonDown(object sender, MouseButtonEventArgs e) + { + //isCheck = !isCheck; + //lb_gou.Visibility = isCheck ? Visibility.Visible : Visibility.Hidden; + if (Click != null) + { + Click.Invoke(this, e); + } + } + } +} diff --git a/middleware/zdhsys/Control/DevButton.xaml b/middleware/zdhsys/Control/DevButton.xaml new file mode 100644 index 0000000..da56584 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton.xaml @@ -0,0 +1,27 @@ + + + + + + + diff --git a/middleware/zdhsys/Control/DevButton.xaml.cs b/middleware/zdhsys/Control/DevButton.xaml.cs new file mode 100644 index 0000000..21d2276 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton.xaml.cs @@ -0,0 +1,82 @@ +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 zdhsys.Control +{ + /// + /// DevButton.xaml 的交互逻辑 + /// + public partial class DevButton : UserControl + { + public DevButton() + { + InitializeComponent(); + } + + Image img; + Label tbk; + public event RoutedEventHandler Click; + + /// + /// 设置按钮样式 + /// + /// 按钮背景色 + /// 按钮边框色 + /// 图标相对路径 + /// 按钮文本颜色 + /// 按钮文本 + public void SetUI(string hexBG,string hexBd,string path,string hexTxt,string txt) + { + Color color = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush = new SolidColorBrush(color); + bd.Background = brush; + + Color color1 = (Color)ColorConverter.ConvertFromString(hexBd); + SolidColorBrush brush1 = new SolidColorBrush(color1); + bd.BorderBrush = brush1; + + img = btn.Template.FindName("img", btn) as Image; + tbk = btn.Template.FindName("tbk", btn) as Label; + + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + img.Source = bitmapImage; + + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tbk.Content = txt; + + btn.Click += Btn_Click; + } + /// + /// 按钮单击事件传递 + /// + /// + /// + private void Btn_Click(object sender, RoutedEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + + private void UserControl_MouseDoubleClick(object sender, MouseButtonEventArgs e) + { + + } + } +} diff --git a/middleware/zdhsys/Control/DevButton0.xaml b/middleware/zdhsys/Control/DevButton0.xaml new file mode 100644 index 0000000..225f362 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton0.xaml @@ -0,0 +1,20 @@ + + + + + + + diff --git a/middleware/zdhsys/Control/DevButton0.xaml.cs b/middleware/zdhsys/Control/DevButton0.xaml.cs new file mode 100644 index 0000000..e3c5926 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton0.xaml.cs @@ -0,0 +1,71 @@ +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 zdhsys.Control +{ + /// + /// DevButton.xaml 的交互逻辑 + /// + public partial class DevButton0 : UserControl + { + public DevButton0() + { + InitializeComponent(); + } + + Label tbk; + public event RoutedEventHandler Click; + + /// + /// 设置按钮样式 + /// + /// 按钮背景色 + /// 按钮边框色 + /// 图标相对路径 + /// 按钮文本颜色 + /// 按钮文本 + public void SetUI(string hexBG,string hexBd,string hexTxt,string txt) + { + Color color = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush = new SolidColorBrush(color); + bd.Background = brush; + + Color color1 = (Color)ColorConverter.ConvertFromString(hexBd); + SolidColorBrush brush1 = new SolidColorBrush(color1); + bd.BorderBrush = brush1; + + tbk = btn.Template.FindName("tbk", btn) as Label; + + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tbk.Content = txt; + + btn.Click += Btn_Click; + } + /// + /// 按钮单击事件传递 + /// + /// + /// + private void Btn_Click(object sender, RoutedEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + } +} diff --git a/middleware/zdhsys/Control/DevButton1.xaml b/middleware/zdhsys/Control/DevButton1.xaml new file mode 100644 index 0000000..e9d33d5 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton1.xaml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevButton1.xaml.cs b/middleware/zdhsys/Control/DevButton1.xaml.cs new file mode 100644 index 0000000..b6af569 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton1.xaml.cs @@ -0,0 +1,72 @@ +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 zdhsys.Control +{ + /// + /// DevButton.xaml 的交互逻辑 + /// + public partial class DevButton1 : UserControl + { + public DevButton1() + { + InitializeComponent(); + } + + public event RoutedEventHandler Click; + + /// + /// 设置按钮样式 + /// + /// 按钮背景色 + /// 按钮边框色 + /// 图标相对路径 + /// 按钮文本颜色 + /// 按钮文本 + public void SetUI(string hexBG,string hexBd,string path,string hexTxt,string txt) + { + Color color = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush = new SolidColorBrush(color); + bd.Background = brush; + + Color color1 = (Color)ColorConverter.ConvertFromString(hexBd); + SolidColorBrush brush1 = new SolidColorBrush(color1); + bd.BorderBrush = brush1; + + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + if (img != null) + { + img.Source = bitmapImage; + } + + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + if (tbk != null) + { + tbk.Foreground = brush2; + tbk.Content = txt; + } + } + + private void UserControl_MouseLeftButtonDown(object sender, MouseButtonEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + } +} diff --git a/middleware/zdhsys/Control/DevButton2.xaml b/middleware/zdhsys/Control/DevButton2.xaml new file mode 100644 index 0000000..2a8ab96 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton2.xaml @@ -0,0 +1,18 @@ + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevButton2.xaml.cs b/middleware/zdhsys/Control/DevButton2.xaml.cs new file mode 100644 index 0000000..c758a04 --- /dev/null +++ b/middleware/zdhsys/Control/DevButton2.xaml.cs @@ -0,0 +1,62 @@ +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 zdhsys.Control +{ + /// + /// DevButton.xaml 的交互逻辑 + /// + public partial class DevButton2 : UserControl + { + public DevButton2() + { + InitializeComponent(); + } + + public event RoutedEventHandler Click; + + public string Text; + + /// + /// 设置按钮样式 + /// + /// 按钮背景色 + /// 按钮边框色 + /// 图标相对路径 + /// 按钮文本颜色 + /// 按钮文本 + public void SetUI(string path,string hexTxt,string txt) + { + Text = txt; + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + img.Source = bitmapImage; + + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tbk.Content = txt; + + } + + private void UserControl_MouseLeftButtonDown(object sender, MouseButtonEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + } +} diff --git a/middleware/zdhsys/Control/DevDevice.xaml b/middleware/zdhsys/Control/DevDevice.xaml new file mode 100644 index 0000000..507423a --- /dev/null +++ b/middleware/zdhsys/Control/DevDevice.xaml @@ -0,0 +1,20 @@ + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevDevice.xaml.cs b/middleware/zdhsys/Control/DevDevice.xaml.cs new file mode 100644 index 0000000..868abe4 --- /dev/null +++ b/middleware/zdhsys/Control/DevDevice.xaml.cs @@ -0,0 +1,82 @@ +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; +using zdhsys.Popup; +using zdhsys.Unitils; + +namespace zdhsys.Control +{ + /// + /// DevDevice.xaml 的交互逻辑 + /// + public partial class DevDevice : UserControl + { + public DevDevice() + { + InitializeComponent(); + } + + public string DevName = ""; + + public void SetUI(string devName,string path) + { + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + img.Source = bitmapImage; + dev_name.Content = devName; + DevName = devName; + } + + HomeDeviceInfo info; + + private void UserControl_MouseLeftButtonDown(object sender, MouseButtonEventArgs e) + { + if (info != null) + { + info.Close(); + info = null; + } + else + { + Point p = GlobalUnitils.GetScreenPosition(this); + Console.WriteLine(p.X + " - " + p.Y); + info = new HomeDeviceInfo(p); + info.Show(); + } + } + + private void UserControl_MouseEnter(object sender, MouseEventArgs e) + { + if (info != null) + { + info.Close(); + info = null; + } + Point p = GlobalUnitils.GetScreenPosition(this); + //Console.WriteLine(p.X + " - " + p.Y); + info = new HomeDeviceInfo(p); + info.SetUI(DevName, "断开", "POS", "无"); + info.Show(); + } + + private void UserControl_MouseLeave(object sender, MouseEventArgs e) + { + if (info != null) + { + info.Close(); + info = null; + } + } + } +} diff --git a/middleware/zdhsys/Control/DevLiquid.xaml b/middleware/zdhsys/Control/DevLiquid.xaml new file mode 100644 index 0000000..00ef78f --- /dev/null +++ b/middleware/zdhsys/Control/DevLiquid.xaml @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevLiquid.xaml.cs b/middleware/zdhsys/Control/DevLiquid.xaml.cs new file mode 100644 index 0000000..ded9aaf --- /dev/null +++ b/middleware/zdhsys/Control/DevLiquid.xaml.cs @@ -0,0 +1,54 @@ +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 zdhsys.Control +{ + /// + /// DevLiquid.xaml 的交互逻辑 + /// + public partial class DevLiquid : UserControl + { + public DevLiquid() + { + InitializeComponent(); + } + + public void SetUI(int num, string path, string name, string status, string temp, string time,string daogui) + { + double wid = ActualWidth; + double wids = wid / (num + 1); + Console.WriteLine("wids=" + wids); + for (int i = 0; i < num; i++) + { + DevDevice newButton = new DevDevice(); + int index = i + 1; + newButton.SetUI("设备" + index, path); + // 在 Grid 的列定义中增加一个新列 + //gd.ColumnDefinitions.Add(new ColumnDefinition() { Width = GridLength.Auto }); + gd.ColumnDefinitions.Add(new ColumnDefinition() { Width = new GridLength(wids) }); + + // 将新按钮添加到 Grid 的新列 + Grid.SetColumn(newButton, i); + gd.Children.Add(newButton); + } + + lbName.Content = name; + lbStatus.Content = status; + lbTemp.Content = !string.IsNullOrEmpty(temp) ? temp + "℃" : ""; + lbTime.Content = time; + lbDaogui.Content = daogui; + } + } +} diff --git a/middleware/zdhsys/Control/DevOperation.xaml b/middleware/zdhsys/Control/DevOperation.xaml new file mode 100644 index 0000000..924747e --- /dev/null +++ b/middleware/zdhsys/Control/DevOperation.xaml @@ -0,0 +1,20 @@ + + + + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevOperation.xaml.cs b/middleware/zdhsys/Control/DevOperation.xaml.cs new file mode 100644 index 0000000..0c37f42 --- /dev/null +++ b/middleware/zdhsys/Control/DevOperation.xaml.cs @@ -0,0 +1,68 @@ +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 zdhsys.Control +{ + /// + /// DevOperation.xaml 的交互逻辑 + /// + public partial class DevOperation : UserControl + { + public DevOperation() + { + InitializeComponent(); + } + public event RoutedEventHandler Click_Details; + public event RoutedEventHandler Click_Update; + public event RoutedEventHandler Click_Delete; + public object obj; + private void UserControl_Loaded(object sender, RoutedEventArgs e) + { + btn_details.SetUI("\\Image\\details.png", "#027AFF", "详情"); + btn_del.SetUI("\\Image\\delete.png", "#FF0000", "删除"); + btn_edit.SetUI("\\Image\\edit.png", "#027AFF", "修改"); + + btn_details.Click += Btn_Click; + btn_del.Click += Btn_Click; + btn_edit.Click += Btn_Click; + } + + private void Btn_Click(object sender, RoutedEventArgs e) + { + DevButton2 btn = sender as DevButton2; + if(btn.Text == "详情") + { + if (Click_Details != null) + { + Click_Details.Invoke(this, e); + } + } + else if (btn.Text == "修改") + { + if (Click_Update != null) + { + Click_Update.Invoke(this, e); + } + } + else if (btn.Text == "删除") + { + if (Click_Delete != null) + { + Click_Delete.Invoke(this, e); + } + } + } + } +} diff --git a/middleware/zdhsys/Control/DevOperation2.xaml b/middleware/zdhsys/Control/DevOperation2.xaml new file mode 100644 index 0000000..638c574 --- /dev/null +++ b/middleware/zdhsys/Control/DevOperation2.xaml @@ -0,0 +1,18 @@ + + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevOperation2.xaml.cs b/middleware/zdhsys/Control/DevOperation2.xaml.cs new file mode 100644 index 0000000..4d8209d --- /dev/null +++ b/middleware/zdhsys/Control/DevOperation2.xaml.cs @@ -0,0 +1,58 @@ +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 zdhsys.Control +{ + /// + /// DevOperation.xaml 的交互逻辑 + /// + public partial class DevOperation2 : UserControl + { + public DevOperation2() + { + InitializeComponent(); + } + public event RoutedEventHandler Click_Update; + public event RoutedEventHandler Click_Delete; + public object obj; + private void UserControl_Loaded(object sender, RoutedEventArgs e) + { + btn_del.SetUI("\\Image\\delete.png", "#FF0000", "删除"); + btn_edit.SetUI("\\Image\\edit.png", "#027AFF", "修改"); + + btn_del.Click += Btn_Click; + btn_edit.Click += Btn_Click; + } + + private void Btn_Click(object sender, RoutedEventArgs e) + { + DevButton2 btn = sender as DevButton2; + if (btn.Text == "修改") + { + if (Click_Update != null) + { + Click_Update.Invoke(this, e); + } + } + else if (btn.Text == "删除") + { + if (Click_Delete != null) + { + Click_Delete.Invoke(this, e); + } + } + } + } +} diff --git a/middleware/zdhsys/Control/DevOperation3.xaml b/middleware/zdhsys/Control/DevOperation3.xaml new file mode 100644 index 0000000..66b8296 --- /dev/null +++ b/middleware/zdhsys/Control/DevOperation3.xaml @@ -0,0 +1,18 @@ + + + + + + + + + + diff --git a/middleware/zdhsys/Control/DevOperation3.xaml.cs b/middleware/zdhsys/Control/DevOperation3.xaml.cs new file mode 100644 index 0000000..c59f8e7 --- /dev/null +++ b/middleware/zdhsys/Control/DevOperation3.xaml.cs @@ -0,0 +1,60 @@ +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 zdhsys.Control +{ + /// + /// DevOperation.xaml 的交互逻辑 + /// + public partial class DevOperation3 : UserControl + { + public DevOperation3() + { + InitializeComponent(); + } + public event RoutedEventHandler Click_Up; + public event RoutedEventHandler Click_Down; + public object obj; + private readonly string move_up = "上移"; + private readonly string move_down = "下移"; + private void UserControl_Loaded(object sender, RoutedEventArgs e) + { + btn_del.SetUI("\\Image\\move_up.png", "#FF0000", move_up); + btn_edit.SetUI("\\Image\\move_down.png", "#027AFF", move_down); + + btn_del.Click += Btn_Click; + btn_edit.Click += Btn_Click; + } + + private void Btn_Click(object sender, RoutedEventArgs e) + { + DevButton2 btn = sender as DevButton2; + if (btn.Text == move_up) + { + if (Click_Up != null) + { + Click_Up.Invoke(this, e); + } + } + else if (btn.Text == move_down) + { + if (Click_Down != null) + { + Click_Down.Invoke(this, e); + } + } + } + } +} diff --git a/middleware/zdhsys/Control/DevPaging.xaml b/middleware/zdhsys/Control/DevPaging.xaml new file mode 100644 index 0000000..afd01c1 --- /dev/null +++ b/middleware/zdhsys/Control/DevPaging.xaml @@ -0,0 +1,38 @@ + + + + + + diff --git a/middleware/zdhsys/Control/DevpButton.xaml.cs b/middleware/zdhsys/Control/DevpButton.xaml.cs new file mode 100644 index 0000000..76bd8ad --- /dev/null +++ b/middleware/zdhsys/Control/DevpButton.xaml.cs @@ -0,0 +1,189 @@ +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 zdhsys.Control +{ + /// + /// DevpButton.xaml 的交互逻辑 + /// + public partial class DevpButton : UserControl + { + public DevpButton() + { + InitializeComponent(); + } + + private bool flag = false; // 是否选中 + private bool max = true; // 是大,还是小 + // 按钮文本 + public string btnName = "主页"; + + Image img; + Image img2; + TextBlock tbk; + // 把单击事件传出去。 + public event RoutedEventHandler Click; + + // 配色 + string hex1 = "#98A3FE"; + string hex2 = "#FFFFFF"; + string hex3 = "#465785"; + private static string basePath = "\\Image\\menu\\"; + // 白色ICO + string imgPath = basePath + "主页.png"; + // 黑色ICO + string imgPath2 = basePath + "主页2.png"; + + // 封装主菜单所有ICO切换 + public void Set_Name(string name) + { + InitUI(); + btnName = name; + switch (btnName) + { + case "主页": + imgPath = basePath + "主页.png"; + imgPath2 = basePath + "主页2.png"; + break; + case "配方管理": + imgPath = basePath + "配方.png"; + imgPath2 = basePath + "配方2.png"; + break; + case "流程管理": + imgPath = basePath + "流程.png"; + imgPath2 = basePath + "流程2.png"; + break; + case "设备管理": + imgPath = basePath + "设备.png"; + imgPath2 = basePath + "设备2.png"; + break; + case "数据管理": + imgPath = basePath + "数据.png"; + imgPath2 = basePath + "数据2.png"; + break; + } + updateUI(hex2, hex3, imgPath2); + } + + + // 大小按钮单击事件 + private void btn_Click(object sender, RoutedEventArgs e) + { + flag = true; + if (flag) + { + if (max) + updateUI(hex1, hex2, imgPath); + else + updateUI2(hex1, imgPath); + } + else + { + if (max) + updateUI(hex2, hex3, imgPath2); + else + updateUI2(hex2, imgPath2); + } + if(Click != null) + Click.Invoke(this, e); + } + + // 更新大按钮界面 + private void updateUI(string hexValue, string hex, string path) + { + Color color = (Color)ColorConverter.ConvertFromString(hexValue); + SolidColorBrush brush = new SolidColorBrush(color); + btn.Background = brush; + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + img.Source = bitmapImage; + Color color2 = (Color)ColorConverter.ConvertFromString(hex); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tbk.Text = btnName; + // 这里加长一点,与其它4个中文的文本长度对齐。 + if(btnName == "主页") + { + tbk.Text = "主页" + '\u00A0' + '\u00A0' + '\u00A0' + '\u00A0' + '\u00A0' + '\u00A0' + '\u00A0'; + } + tbk.FontSize = 15; + tbk.FontFamily = new FontFamily("Microsoft YaHei"); + tbk.FontWeight = FontWeights.Bold; + } + // 更新小按钮界面 + private void updateUI2(string hexValue, string path) + { + Color color = (Color)ColorConverter.ConvertFromString(hexValue); + SolidColorBrush brush = new SolidColorBrush(color); + btn2.Background = brush; + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + img2.Source = bitmapImage; + } + + // 取消选中状态 + public void setFocus(bool check) + { + flag = check; + if (flag) + { + if (max) + updateUI(hex1, hex2, imgPath); + else + updateUI2(hex1, imgPath); + } + else + { + if (max) + updateUI(hex2, hex3, imgPath2); + else + updateUI2(hex2, imgPath2); + } + } + + // 设置大小状态 + public void setCollapsed(bool see) + { + if (see) + { + this.Width = 150; + btn.Visibility = Visibility.Visible; + btn2.Visibility = Visibility.Collapsed; + max = true; + } + else + { + this.Width = 25; + btn.Visibility = Visibility.Collapsed; + btn2.Visibility = Visibility.Visible; + max = false; + } + setFocus(flag); + } + + private void InitUI() + { + // 找出控件里面子控件 + img = btn.Template.FindName("img", btn) as Image; + img2 = btn2.Template.FindName("img2", btn2) as Image; + tbk = btn.Template.FindName("tbk", btn) as TextBlock; + + //小状态的按钮,先隐藏。 这里注意:如果在代码里面写了隐藏,上面的img2就会找不到。为null + //只能先获取对象,后做隐藏处理。 + btn2.Visibility = Visibility.Collapsed; + + } + } +} diff --git a/middleware/zdhsys/Control/FlowButton.xaml b/middleware/zdhsys/Control/FlowButton.xaml new file mode 100644 index 0000000..fd71cbc --- /dev/null +++ b/middleware/zdhsys/Control/FlowButton.xaml @@ -0,0 +1,18 @@ + + + + + + + + + diff --git a/middleware/zdhsys/Control/FlowButton.xaml.cs b/middleware/zdhsys/Control/FlowButton.xaml.cs new file mode 100644 index 0000000..1c75ab4 --- /dev/null +++ b/middleware/zdhsys/Control/FlowButton.xaml.cs @@ -0,0 +1,97 @@ +using System; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Controls.Primitives; +using System.Windows.Input; +using System.Windows.Media; + +namespace zdhsys.Control +{ + /// + /// DevButton.xaml 的交互逻辑 + /// + public partial class FlowButton : UserControl + { + public FlowButton() + { + InitializeComponent(); + } + + public event RoutedEventHandler Click; + public object obj; + public long ID; + + /// + /// 设置按钮样式 + /// + /// 按钮背景色 + /// 按钮边框色 + /// 按钮文本颜色 + /// 按钮文本 + public void SetUI(string hexBG, string hexBd, string hexTxt, string txt) + { + Color color = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush = new SolidColorBrush(color); + bd.Background = brush; + + Color color1 = (Color)ColorConverter.ConvertFromString(hexBd); + SolidColorBrush brush1 = new SolidColorBrush(color1); + bd.BorderBrush = brush1; + + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tbk.Content = txt; + } + + + private void UserControl_MouseDoubleClick(object sender, MouseButtonEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + + #region 拖动 + + //private bool isDragging; + //private Point startPoint; + //protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e) + //{ + // base.OnMouseLeftButtonDown(e); + + // isDragging = true; + // startPoint = e.GetPosition(this); + // bd.CaptureMouse(); + //} + + //protected override void OnMouseMove(MouseEventArgs e) + //{ + // base.OnMouseMove(e); + + // if (isDragging) + // { + // Point endPoint = e.GetPosition(this); + // double offsetX = endPoint.X - startPoint.X; + // double offsetY = endPoint.Y - startPoint.Y; + + // translateTransform.X += offsetX; + // translateTransform.Y += offsetY; + + // startPoint = endPoint; + // } + //} + + //protected override void OnMouseLeftButtonUp(MouseButtonEventArgs e) + //{ + // base.OnMouseLeftButtonUp(e); + + // isDragging = false; + + // bd.ReleaseMouseCapture(); + //} + + #endregion + } +} diff --git a/middleware/zdhsys/Control/FlowButton2.xaml b/middleware/zdhsys/Control/FlowButton2.xaml new file mode 100644 index 0000000..317574e --- /dev/null +++ b/middleware/zdhsys/Control/FlowButton2.xaml @@ -0,0 +1,19 @@ + + + + + + + + + diff --git a/middleware/zdhsys/Control/FlowButton2.xaml.cs b/middleware/zdhsys/Control/FlowButton2.xaml.cs new file mode 100644 index 0000000..9283699 --- /dev/null +++ b/middleware/zdhsys/Control/FlowButton2.xaml.cs @@ -0,0 +1,302 @@ +using System; +using System.Collections.Generic; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Controls.Primitives; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Shapes; +using zdhsys.Unitils; + +namespace zdhsys.Control +{ + /// + /// DevButton.xaml 的交互逻辑 + /// + public partial class FlowButton2 : UserControl + { + public FlowButton2() + { + InitializeComponent(); + //ID = GlobalUnitils.GetNowTime(DateTime.Now); + } + + public event RoutedEventHandler Click; + /// + /// 绑定设备实体用 + /// + public object obj; + /// + /// 流程ID。 因为会有设备重复的情况,不适合使用设备的ID做为唯一 + /// + public long ID; + //背景颜色 + public string tempHexBG = ""; + //边框颜色 + public string tempHexBd = ""; + //字体颜色 + public string tempHexTxt = ""; + //文本内容 + public string tempTxt = ""; + //操作指令 + public int CMD = 0; + + /// + /// 设置按钮样式 + /// + /// 按钮背景色 + /// 按钮边框色 + /// 按钮文本颜色 + /// 按钮文本 + public void SetUI(string hexBG, string hexBd, string hexTxt, string txt) + { + tempHexBG = hexBG; + tempHexBd = hexBd; + tempHexTxt = hexTxt; + tempTxt = txt; + Color color = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush = new SolidColorBrush(color); + bd.Background = brush; + Color color1 = (Color)ColorConverter.ConvertFromString(hexBd); + SolidColorBrush brush1 = new SolidColorBrush(color1); + bd.BorderBrush = brush1; + + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tbk.Content = txt; + } + /// + /// 设置背景色和边框颜色 + /// + /// + public void SetBackColor(string hexBG) + { + tempHexBG = hexBG; + tempHexBd = hexBG; + Color color = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush = new SolidColorBrush(color); + bd.Background = brush; + + Color color1 = (Color)ColorConverter.ConvertFromString(hexBG); + SolidColorBrush brush1 = new SolidColorBrush(color1); + bd.BorderBrush = brush1; + } + /// + /// 设置字体颜色 + /// + /// + public void SetForeColor(string hexTxt) + { + Color color2 = (Color)ColorConverter.ConvertFromString(hexTxt); + SolidColorBrush brush2 = new SolidColorBrush(color2); + tbk.Foreground = brush2; + tempHexTxt = hexTxt; + } + /// + /// 设置显示文本内容 + /// + /// + public void SetText(string txt) + { + tbk.Content = txt; + } + + /// + /// 返回控件的内部坐标 + /// + /// + public Point getPoint() + { + Point p = new Point(0, 0) + { + X = startPoint.X - translateTransform.X, + Y = startPoint.Y - translateTransform.Y + }; + return p; + } + /// + /// 获取当前单击位置是否有画线的情况 + /// + /// + public string getEllipse() + { + Point p = getPoint(); + for (int i = 0; i < ps.Count; i++) + { + if (ps[i].Data.FillContains(p)) + { + //Console.WriteLine($" ellipse name={ps[i].Name}"); + return ps[i].Name; + } + } + return ""; + } + /// + /// 返回当前控件的相对坐标 + /// + /// + public Point getTranslateTransform() + { + return new Point(translateTransform.X, translateTransform.Y); + } + /// + /// 设置当前控件的相对坐标 + /// + /// + public void SetTranslateTransform(Point p) + { + translateTransform.X += p.X; + translateTransform.Y += p.Y; + } + + #region 拖动 + //是否拖拽 + private bool isDragging; + /// + /// 当前单击坐标 + /// + public Point startPoint; + /// + /// 单击圆的位置名称 + /// + public string clickName; + /// + /// 鼠标按下 + /// + /// + protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e) + { + base.OnMouseLeftButtonDown(e); + startPoint = e.GetPosition(this); + bool flag = false; + Point p = new Point(0, 0) + { + X = startPoint.X - translateTransform.X, + Y = startPoint.Y - translateTransform.Y + }; + //过滤掉4个圆。点击这4个圆,不移动当前控件。 + for (int i = 0; i < ps.Count; i++) + { + if (ps[i].Data.FillContains(p)) + { + flag = true; + break; + } + } + if (!flag) + { + isDragging = true; + _ = bd.CaptureMouse(); + } + } + /// + /// 鼠标移动 + /// + /// + protected override void OnMouseMove(MouseEventArgs e) + { + base.OnMouseMove(e); + + if (isDragging) + { + Point endPoint = e.GetPosition(this); + double offsetX = endPoint.X - startPoint.X; + double offsetY = endPoint.Y - startPoint.Y; + + translateTransform.X += offsetX; + translateTransform.Y += offsetY; + + startPoint = endPoint; + } + } + /// + /// 鼠标松开 + /// + /// + protected override void OnMouseLeftButtonUp(MouseButtonEventArgs e) + { + base.OnMouseLeftButtonUp(e); + isDragging = false; + startPoint = e.GetPosition(this); + bd.ReleaseMouseCapture(); + } + + #endregion + /// + /// 保存4个圆的路径。用于判断是否点击了这些圆,哪个圆 + /// + private static List ps = new List(); + + private void UserControl_Loaded(object sender, RoutedEventArgs e) + { + ps.Add(AddEllipse("left", new Point(7, 40))); + ps.Add(AddEllipse("top", new Point(60, 7))); + ps.Add(AddEllipse("right", new Point(113, 40))); + ps.Add(AddEllipse("bottom", new Point(60, 73))); + } + /// + /// 返回左上右下的圆心坐标。可用于主界面画线的时候用到 + /// + /// + /// + public Point getStartPointByName(string name) + { + if (name == "left") + { + return new Point(7, 40); + } + else if (name == "top") + { + return new Point(60, 7); + } + else if (name == "right") + { + return new Point(113, 40); + } + else + { + return new Point(60, 73); + } + } + /// + /// 添加圆型路径 + /// + /// + /// + /// + private Path AddEllipse(string name, Point p) + { + // 创建圆形路径 + Path path = new Path + { + Stroke = new SolidColorBrush(Color.FromArgb(255, 2, 122, 255)), + StrokeThickness = 2, + Fill = new SolidColorBrush(Color.FromArgb(255, 255, 255, 255)) + }; + EllipseGeometry ellipse = new EllipseGeometry + { + Center = p, // 设置圆心坐标 + RadiusX = 6, // 半径 + RadiusY = 6 + }; + path.Data = ellipse; + path.Name = name; + // 添加路径到 Grid + _ = gd.Children.Add(path); + return path; + } + /// + /// 右键编辑 + /// + /// + /// + private void UserControl_MouseRightButtonDown(object sender, MouseButtonEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + } +} diff --git a/middleware/zdhsys/Control/ImageButton.xaml b/middleware/zdhsys/Control/ImageButton.xaml new file mode 100644 index 0000000..b5c95fd --- /dev/null +++ b/middleware/zdhsys/Control/ImageButton.xaml @@ -0,0 +1,14 @@ + + + + + diff --git a/middleware/zdhsys/Control/ImageButton.xaml.cs b/middleware/zdhsys/Control/ImageButton.xaml.cs new file mode 100644 index 0000000..fca5e89 --- /dev/null +++ b/middleware/zdhsys/Control/ImageButton.xaml.cs @@ -0,0 +1,47 @@ +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 zdhsys.Control +{ + /// + /// ImageButton.xaml 的交互逻辑 + /// + public partial class ImageButton : UserControl + { + public ImageButton() + { + InitializeComponent(); + } + public event RoutedEventHandler Click; + private void UserControl_MouseLeftButtonDown(object sender, MouseButtonEventArgs e) + { + if (Click != null) + { + Click.Invoke(this, e); + } + } + + public void SetUI(string path) + { + Uri imageUri = new Uri(AppDomain.CurrentDomain.BaseDirectory + path); + BitmapImage bitmapImage = new BitmapImage(imageUri); + if (img != null) + { + img.Source = bitmapImage; + } + } + + } +} diff --git a/middleware/zdhsys/Control/MyControl.xaml b/middleware/zdhsys/Control/MyControl.xaml new file mode 100644 index 0000000..680d014 --- /dev/null +++ b/middleware/zdhsys/Control/MyControl.xaml @@ -0,0 +1,16 @@ + + + + + + + diff --git a/middleware/zdhsys/Control/MyControl.xaml.cs b/middleware/zdhsys/Control/MyControl.xaml.cs new file mode 100644 index 0000000..4819f83 --- /dev/null +++ b/middleware/zdhsys/Control/MyControl.xaml.cs @@ -0,0 +1,84 @@ +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 zdhsys.Control +{ + /// + /// MyControl.xaml 的交互逻辑 + /// + public partial class MyControl : UserControl + { + public MyControl() + { + InitializeComponent(); + } + + private bool isDragging; + private Point startPoint; + protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e) + { + base.OnMouseLeftButtonDown(e); + + isDragging = true; + startPoint = e.GetPosition(this); + + myLabel.CaptureMouse(); + } + + protected override void OnMouseMove(MouseEventArgs e) + { + base.OnMouseMove(e); + + if (isDragging) + { + //Point endPoint = e.GetPosition(this); + Point endPoint = e.GetPosition((UIElement)Parent); + //if (endPoint.X < 15 || endPoint.Y < 1) return; + double offsetX = endPoint.X - startPoint.X; + double offsetY = endPoint.Y - startPoint.Y; + + double left = Canvas.GetLeft(this) + translateTransform.X; + double top = Canvas.GetTop(this) + translateTransform.Y; + double width = ActualWidth; + double height = ActualHeight; + + Console.WriteLine($"坐标: ({left}, {top}), 大小: {width} x {height}"); + if (left < 0) + { + translateTransform.X += Math.Abs(left); + return; + } + if (top < -10) + { + translateTransform.Y += Math.Abs(top) - 10; + return; + } + translateTransform.X += offsetX; + translateTransform.Y += offsetY; + Console.WriteLine("endPoint=" + endPoint.X + "," + endPoint.Y); + startPoint = endPoint; + } + } + + protected override void OnMouseLeftButtonUp(MouseButtonEventArgs e) + { + base.OnMouseLeftButtonUp(e); + + isDragging = false; + + myLabel.ReleaseMouseCapture(); + } + } +} diff --git a/middleware/zdhsys/Control/OptionTab.xaml b/middleware/zdhsys/Control/OptionTab.xaml new file mode 100644 index 0000000..c47d385 --- /dev/null +++ b/middleware/zdhsys/Control/OptionTab.xaml @@ -0,0 +1,18 @@ + + + + + + + + + + diff --git a/middleware/zdhsys/Control/OptionTab.xaml.cs b/middleware/zdhsys/Control/OptionTab.xaml.cs new file mode 100644 index 0000000..1084c09 --- /dev/null +++ b/middleware/zdhsys/Control/OptionTab.xaml.cs @@ -0,0 +1,69 @@ +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 zdhsys.Control +{ + /// + /// OptionTab.xaml 的交互逻辑 + /// + public partial class OptionTab : UserControl + { + public OptionTab() + { + InitializeComponent(); + } + + public event RoutedEventHandler Click_Option; + public event RoutedEventHandler Click_SubOption; + + public string str_1 = "小瓶"; + public string str_2 = "大瓶"; + + private void UserControl_Loaded(object sender, RoutedEventArgs e) + { + btn_Option.SetUI(str_1); + btn_Option.Click += Btn_Click; + btn_Option.SetCheck(true); + + + btn_SubOption.SetUI(str_2); + btn_SubOption.Click += Btn_Click; + btn_SubOption.SetCheck(false); + } + + private void Btn_Click(object sender, RoutedEventArgs e) + { + TabButton tab = sender as TabButton; + if (tab.Text == str_1) + { + btn_Option.SetCheck(true); + btn_SubOption.SetCheck(false); + if (Click_Option != null) + { + Click_Option.Invoke(this, e); + } + } + else if (tab.Text == str_2) + { + btn_Option.SetCheck(false); + btn_SubOption.SetCheck(true); + if (Click_SubOption != null) + { + Click_SubOption.Invoke(this, e); + } + } + } + } +} diff --git a/middleware/zdhsys/Control/SwitchButton.xaml b/middleware/zdhsys/Control/SwitchButton.xaml new file mode 100644 index 0000000..fbe0c4f --- /dev/null +++ b/middleware/zdhsys/Control/SwitchButton.xaml @@ -0,0 +1,24 @@ + + + + + + + + + +