1using System.Globalization;
22 private static readonly Dictionary<string, CultureInfo>
s_Cultures =
new Dictionary<string, CultureInfo>();
35 return d.
ToString(CultureInfo.InvariantCulture);
44 CultureInfo.InvariantCulture;
46 return d.ToString(format.
Value, defaultCulture);
57 out CultureInfo? cultureInfo
60 return d.ToString(format.
Value, cultureInfo);
63 cultureInfo = CultureInfo.CreateSpecificCulture(culture.
Value);
66 return d.ToString(format.
Value, cultureInfo);
Exposes the BadScript Runtime Functionality to Consumers.
Implements Number Extensions.
override void AddExtensions(BadInteropExtensionProvider provider)
static readonly Dictionary< string, CultureInfo > s_Cultures
Culture Info Cache.
static BadObject NumberToString(BadExecutionContext ctx, decimal d, IReadOnlyList< BadObject > args)
Formats a number to a string.
The Execution Context. Every execution of a script needs a context the script is running in....
BadScope Scope
The Root Scope of the Context.
Gets thrown by the runtime.
Public Extension API for the BS2 Runtime.
void RegisterObject(Type t, string propName, BadObject obj)
Registers the specified extension for the specified type.
Interop Function taking an array of arguments.
The Base Class for all BadScript Objects.
override string ToString()
Returns a String Representation of this Object.
Provides function parameter info.
Helper Class that Builds a Native Class from a Prototype.
static BadClassPrototype GetNative(string name)
Returns a Native Class Prototype for the given Native Type.
Implements the Interface for Native Strings.
new string Value
The String Value.
Contains Common Interop Extensions for the BadScript2 Runtime.
Contains the Error Objects for the BadScript2 Language.
Contains the Interop Function Classes for the BadScript2 Language.
Contains the Interop Abstractions and Implementations for the BadScript2 Language.
Contains Runtime Function Objects.
Contains the Native Runtime Objects.
Contains Runtime Type Objects.
Contains the Runtime Objects.
Contains the Runtime Implementation.