Skip to content
This repository
tree: 37775aada3
Fetching contributors…

Cannot retrieve contributors at this time

file 429 lines (343 sloc) 11.32 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429
// String.cs
// Script#/Libraries/CoreLib
// This source code is subject to terms and conditions of the Apache License, Version 2.0.
//

using System.ComponentModel;
using System.Runtime.CompilerServices;

namespace System {

    /// <summary>
    /// Equivalent to the String type in Javascript.
    /// </summary>
[IgnoreNamespace]
[Imported]
    public sealed class String {

        /// <summary>
        /// An empty zero-length string.
        /// </summary>
[PreserveCase]
        public static readonly String Empty = "";

        /// <summary>
        /// The number of characters in the string.
        /// </summary>
[IntrinsicProperty]
        public int Length {
            get {
                return 0;
            }
        }

        /// <summary>
        /// Retrieves the character at the specified position.
        /// </summary>
        /// <param name="index">The specified 0-based position.</param>
        /// <returns>The character within the string.</returns>
[IntrinsicProperty]
        public char this[int index] {
            get {
                return '\0';
            }
        }

        /// <summary>
        /// Retrieves the character at the specified position.
        /// </summary>
        /// <param name="index">The specified 0-based position.</param>
        /// <returns>The character within the string.</returns>
        public char CharAt(int index) {
            return '\0';
        }

        /// <summary>
        /// Retrieves the character code of the character at the specified position.
        /// </summary>
        /// <param name="index">The specified 0-based position.</param>
        /// <returns>The character code of the character within the string.</returns>
        public int CharCodeAt(int index) {
            return 0;
        }

        public static int Compare(string s1, string s2) {
            return 0;
        }

        public static int Compare(string s1, string s2, bool ignoreCase) {
            return 0;
        }

        public int CompareTo(string s) {
            return 0;
        }

        public int CompareTo(string s, bool ignoreCase) {
            return 0;
        }

        public static string Concat(string s1, string s2) {
            return null;
        }

        public static string Concat(string s1, string s2, string s3) {
            return null;
        }

        public static string Concat(string s1, string s2, string s3, string s4) {
            return null;
        }

        /// <summary>
        /// Concatenates a set of individual strings into a single string.
        /// </summary>
        /// <param name="strings">The sequence of strings</param>
        /// <returns>The concatenated string.</returns>
        public static string Concat(params string[] strings) {
            return null;
        }

[EditorBrowsable(EditorBrowsableState.Never)]
        public static string Concat(object o1, object o2) {
            return null;
        }

[EditorBrowsable(EditorBrowsableState.Never)]
        public static string Concat(object o1, object o2, object o3) {
            return null;
        }

[EditorBrowsable(EditorBrowsableState.Never)]
        public static string Concat(object o1, object o2, object o3, object o4) {
            return null;
        }

[EditorBrowsable(EditorBrowsableState.Never)]
        public static string Concat(params object[] o) {
            return null;
        }

        /// <summary>
        /// Returns the unencoded version of a complete encoded URI.
        /// </summary>
        /// <returns>The unencoded string.</returns>
[ScriptName("decodeURI")]
        public string DecodeUri() {
            return null;
        }

        /// <summary>
        /// Returns the unencoded version of a single part or component of an encoded URI.
        /// </summary>
        /// <returns>The unencoded string.</returns>
[ScriptName("decodeURIComponent")]
        public string DecodeUriComponent() {
            return null;
        }

        /// <summary>
        /// Encodes the complete URI.
        /// </summary>
        /// <returns>The encoded string.</returns>
[ScriptName("encodeURI")]
        public string EncodeUri() {
            return null;
        }

        /// <summary>
        /// Encodes a single part or component of a URI.
        /// </summary>
        /// <returns>The encoded string.</returns>
[ScriptName("encodeURIComponent")]
        public string EncodeUriComponent() {
            return null;
        }

        /// <summary>
        /// Determines if the string ends with the specified character.
        /// </summary>
        /// <param name="ch">The character to test for.</param>
        /// <returns>true if the string ends with the character; false otherwise.</returns>
        public bool EndsWith(char ch) {
            return false;
        }

        /// <summary>
        /// Determines if the string ends with the specified substring or suffix.
        /// </summary>
        /// <param name="suffix">The string to test for.</param>
        /// <returns>true if the string ends with the suffix; false otherwise.</returns>
        public bool EndsWith(string suffix) {
            return false;
        }

        /// <summary>
        /// Determines if the strings are equal.
        /// </summary>
        /// <returns>true if the string s1 = s2; false otherwise.</returns>
        public static bool Equals(string s1, string s2, bool ignoreCase) {
            return false;
        }

        /// <summary>
        /// Encodes a string by replacing punctuation, spaces etc. with their escaped equivalents.
        /// </summary>
        /// <returns>The escaped string.</returns>
        public string Escape() {
            return null;
        }

        public static string Format(string format, params object[] values) {
            return null;
        }

        public static string FromChar(char ch, int count) {
            return null;
        }

        public static string FromCharCode(params int[] charCodes) {
            return null;
        }

        public string HtmlDecode() {
            return null;
        }

        public string HtmlEncode() {
            return null;
        }

        public int IndexOf(char ch) {
            return 0;
        }

        public int IndexOf(string subString) {
            return 0;
        }

        public int IndexOf(char ch, int startIndex) {
            return 0;
        }

        public int IndexOf(string subString, int startIndex) {
            return 0;
        }

        public int IndexOfAny(char[] ch) {
            return 0;
        }

        public int IndexOfAny(char[] ch, int startIndex) {
            return 0;
        }

        public int IndexOfAny(char[] ch, int startIndex, int count) {
            return 0;
        }

        public string Insert(int index, string value) {
            return null;
        }

        public static bool IsNullOrEmpty(string s) {
            return false;
        }

        public static bool IsNullOrWhiteSpace(string s) {
            return false;
        }

        public int LastIndexOf(Char ch) {
            return 0;
        }

        public int LastIndexOf(string subString) {
            return 0;
        }

        public int LastIndexOf(char ch, int startIndex) {
            return 0;
        }

        public int LastIndexOf(string subString, int startIndex) {
            return 0;
        }

        public int LastIndexOfAny(char[] ch) {
            return 0;
        }

        public int LastIndexOfAny(char[] ch, int startIndex) {
            return 0;
        }

        public int LastIndexOfAny(char[] ch, int startIndex, int count) {
            return 0;
        }

        public int LocaleCompare(string string2) {
            return 0;
        }

        public static string LocaleFormat(string format, params object[] values) {
            return null;
        }

        public string[] Match(RegularExpression regex) {
            return null;
        }

        public string PadLeft(int totalWidth) {
            return null;
        }

        public string PadLeft(int totalWidth, char ch) {
            return null;
        }

        public string PadRight(int totalWidth) {
            return null;
        }

        public string PadRight(int totalWidth, char ch) {
            return null;
        }

        public string Remove(int index) {
            return null;
        }

        public string Remove(int index, int count) {
            return null;
        }

        public string Replace(string oldText, string replaceText) {
            return null;
        }

        public string ReplaceFirst(string oldText, string replaceText) {
            return null;
        }

        public string ReplaceRegex(RegularExpression regex, string replaceText) {
            return null;
        }

        public string ReplaceRegex(RegularExpression regex, StringReplaceCallback callback) {
            return null;
        }

        public int Search(RegularExpression regex) {
            return 0;
        }

        public string[] Split(char ch) {
            return null;
        }

        public string[] Split(string separator) {
            return null;
        }

        public string[] Split(char ch, int limit) {
            return null;
        }

        public string[] Split(string separator, int limit) {
            return null;
        }

        public string[] Split(RegularExpression regex) {
            return null;
        }

        public string[] Split(RegularExpression regex, int limit) {
            return null;
        }

        public bool StartsWith(char ch) {
            return false;
        }

        public bool StartsWith(string prefix) {
            return false;
        }

        public string Substr(int startIndex) {
            return null;
        }

        public string Substr(int startIndex, int length) {
            return null;
        }

        public string Substring(int startIndex) {
            return null;
        }

        public string Substring(int startIndex, int endIndex) {
            return null;
        }

        public string ToLocaleLowerCase() {
            return null;
        }

        public string ToLocaleUpperCase() {
            return null;
        }

        public string ToLowerCase() {
            return null;
        }

        public string ToUpperCase() {
            return null;
        }

        public string Trim() {
            return null;
        }

        public string TrimStart() {
            return null;
        }

        public string TrimEnd() {
            return null;
        }

        /// <summary>
        /// Decodes a string by replacing escaped parts with their equivalent textual representation.
        /// </summary>
        /// <returns>The unescaped string.</returns>
        public string Unescape() {
            return null;
        }

        /// <internalonly />
        public static bool operator ==(string s1, string s2) {
            return false;
        }

        /// <internalonly />
        public static bool operator !=(string s1, string s2) {
            return false;
        }
    }
}
Something went wrong with that request. Please try again.