|
| 1 | +//Disable missing XML comments. |
| 2 | +#pragma warning disable CS1591 |
| 3 | + |
| 4 | +using CSharpToJavaScript.Utils; |
| 5 | +using System; |
| 6 | +using System.Collections; |
| 7 | +using System.Collections.Generic; |
| 8 | +using System.Reflection; |
| 9 | + |
| 10 | +namespace CSharpToJavaScript.APIs.JS; |
| 11 | + |
| 12 | +//https://262.ecma-international.org/14.0/#sec-array-objects |
| 13 | +[To(ToAttribute.Default)] |
| 14 | +public partial class Array : ArrayPrototype |
| 15 | +{ |
| 16 | + [To(ToAttribute.FirstCharToLowerCase)] |
| 17 | + public static ArrayPrototype Prototype { get; } = new(); |
| 18 | + |
| 19 | + [To(ToAttribute.FirstCharToLowerCase)] |
| 20 | + public int Length { get; } = 0; |
| 21 | + public Array(params dynamic[] values) |
| 22 | + { |
| 23 | + throw new System.NotImplementedException(); |
| 24 | + } |
| 25 | + //Todo! Function for mapfn? |
| 26 | + [To(ToAttribute.FirstCharToLowerCase)] |
| 27 | + public static Array From(dynamic items, Action<dynamic>? mapfn = null, dynamic? thisArg = null) |
| 28 | + { |
| 29 | + throw new System.NotImplementedException(); |
| 30 | + } |
| 31 | + [To(ToAttribute.FirstCharToLowerCase)] |
| 32 | + public static bool IsArray(dynamic arg) |
| 33 | + { |
| 34 | + throw new System.NotImplementedException(); |
| 35 | + } |
| 36 | + [To(ToAttribute.FirstCharToLowerCase)] |
| 37 | + public static Array Of(params dynamic[] items) |
| 38 | + { |
| 39 | + throw new System.NotImplementedException(); |
| 40 | + } |
| 41 | +} |
| 42 | + |
| 43 | +[To(ToAttribute.FirstCharToLowerCase)] |
| 44 | +public partial class ArrayPrototype : FunctionPrototype |
| 45 | +{ |
| 46 | + public ArrayPrototype() { } |
| 47 | + public dynamic? At(int index) |
| 48 | + { |
| 49 | + throw new System.NotImplementedException(); |
| 50 | + } |
| 51 | + public Array CopyWithin(dynamic target, int start,int end = 0) |
| 52 | + { |
| 53 | + throw new System.NotImplementedException(); |
| 54 | + } |
| 55 | + public List<dynamic> Entries() |
| 56 | + { |
| 57 | + throw new System.NotImplementedException(); |
| 58 | + } |
| 59 | + public bool Every(Action callbackfn, dynamic? thisArg = null ) |
| 60 | + { |
| 61 | + throw new System.NotImplementedException(); |
| 62 | + } |
| 63 | + public Array Fill(dynamic value, int start = 0, int end = 0 ) |
| 64 | + { |
| 65 | + throw new System.NotImplementedException(); |
| 66 | + } |
| 67 | + public Array Filter(Action callbackfn, dynamic? thisArg = null) |
| 68 | + { |
| 69 | + throw new System.NotImplementedException(); |
| 70 | + } |
| 71 | + public dynamic? Find(Action predicate, dynamic? thisArg = null) |
| 72 | + { |
| 73 | + throw new System.NotImplementedException(); |
| 74 | + } |
| 75 | + public int FindIndex(Action predicate, dynamic? thisArg = null) |
| 76 | + { |
| 77 | + throw new System.NotImplementedException(); |
| 78 | + } |
| 79 | + public dynamic? FindLast(Action predicate, dynamic? thisArg = null) |
| 80 | + { |
| 81 | + throw new System.NotImplementedException(); |
| 82 | + } |
| 83 | + public int FindLastIndex(Action predicate, dynamic? thisArg = null) |
| 84 | + { |
| 85 | + throw new System.NotImplementedException(); |
| 86 | + } |
| 87 | + public Array Flat(int depth = 1 ) |
| 88 | + { |
| 89 | + throw new System.NotImplementedException(); |
| 90 | + } |
| 91 | + public Array FlatMap(Action mapperFunction, dynamic? thisArg = null) |
| 92 | + { |
| 93 | + throw new System.NotImplementedException(); |
| 94 | + } |
| 95 | + public GlobalObject.Undefined ForEach(Action callbackfn, dynamic? thisArg = null) |
| 96 | + { |
| 97 | + throw new System.NotImplementedException(); |
| 98 | + } |
| 99 | + public bool Includes(dynamic searchElement, int fromIndex = 0) |
| 100 | + { |
| 101 | + throw new System.NotImplementedException(); |
| 102 | + } |
| 103 | + public int IndexOf(dynamic searchElement, int fromIndex = 0) |
| 104 | + { |
| 105 | + throw new System.NotImplementedException(); |
| 106 | + } |
| 107 | + public string Join(string separator = ",") |
| 108 | + { |
| 109 | + throw new System.NotImplementedException(); |
| 110 | + } |
| 111 | + public List<dynamic> Keys() |
| 112 | + { |
| 113 | + throw new System.NotImplementedException(); |
| 114 | + } |
| 115 | + public int LastIndexOf(dynamic searchElement, int fromIndex = 0) |
| 116 | + { |
| 117 | + throw new System.NotImplementedException(); |
| 118 | + } |
| 119 | + public Array Map(Action callbackfn,dynamic? thisArg = null ) |
| 120 | + { |
| 121 | + throw new System.NotImplementedException(); |
| 122 | + } |
| 123 | + public dynamic Pop() |
| 124 | + { |
| 125 | + throw new System.NotImplementedException(); |
| 126 | + } |
| 127 | + public int Push(params dynamic[] tems ) |
| 128 | + { |
| 129 | + throw new System.NotImplementedException(); |
| 130 | + } |
| 131 | + public dynamic Reduce(Action callbackfn, dynamic? initialValue = null) |
| 132 | + { |
| 133 | + throw new System.NotImplementedException(); |
| 134 | + } |
| 135 | + public dynamic ReduceRight(Action callbackfn, dynamic? initialValue = null) |
| 136 | + { |
| 137 | + throw new System.NotImplementedException(); |
| 138 | + } |
| 139 | + public Array Reverse() |
| 140 | + { |
| 141 | + throw new System.NotImplementedException(); |
| 142 | + } |
| 143 | + public dynamic? Shift() |
| 144 | + { |
| 145 | + throw new System.NotImplementedException(); |
| 146 | + } |
| 147 | + public Array Slice(int start = 0, int end = 0 ) |
| 148 | + { |
| 149 | + throw new System.NotImplementedException(); |
| 150 | + } |
| 151 | + public bool Some(Action callbackfn, dynamic? thisArg = null ) |
| 152 | + { |
| 153 | + throw new System.NotImplementedException(); |
| 154 | + } |
| 155 | + public Array Sort(Action comparefn ) |
| 156 | + { |
| 157 | + throw new System.NotImplementedException(); |
| 158 | + } |
| 159 | + public Array Splice(int start, int deleteCount, params dynamic[] items ) |
| 160 | + { |
| 161 | + throw new System.NotImplementedException(); |
| 162 | + } |
| 163 | + public string ToLocaleString(dynamic? reserved1 = null, dynamic? reserved2 = null) |
| 164 | + { |
| 165 | + throw new System.NotImplementedException(); |
| 166 | + } |
| 167 | + public Array ToReversed() |
| 168 | + { |
| 169 | + throw new System.NotImplementedException(); |
| 170 | + } |
| 171 | + public Array ToSorted(Action comparefn ) |
| 172 | + { |
| 173 | + throw new System.NotImplementedException(); |
| 174 | + } |
| 175 | + public Array ToSpliced(int start, int skipCount,params dynamic[] items ) |
| 176 | + { |
| 177 | + throw new System.NotImplementedException(); |
| 178 | + } |
| 179 | + public string ToString() |
| 180 | + { |
| 181 | + throw new System.NotImplementedException(); |
| 182 | + } |
| 183 | + public int Unshift(params dynamic[] items ) |
| 184 | + { |
| 185 | + throw new System.NotImplementedException(); |
| 186 | + } |
| 187 | + public List<dynamic> Values() |
| 188 | + { |
| 189 | + throw new System.NotImplementedException(); |
| 190 | + } |
| 191 | + public Array With(int index, dynamic value ) |
| 192 | + { |
| 193 | + throw new System.NotImplementedException(); |
| 194 | + |
| 195 | + } |
| 196 | +} |
0 commit comments