Class JsUtility
Java Script utility methods.
Inheritance
Inherited Members
Namespace:GoogleMaps.Utils
Assembly:GoogleMaps.dll
Syntax
public static class JsUtility
Properties
NumberFormat
Gets the number format.
Declaration
public static NumberFormatInfo NumberFormat { get; }
Property Value
Type | Description |
---|---|
System.Globalization.NumberFormatInfo | The number format. |
Methods
CreateSerializer()
Creates the serializer.
Declaration
public static JavaScriptSerializer CreateSerializer()
Returns
Type | Description |
---|---|
System.Web.Script.Serialization.JavaScriptSerializer |
Encode(Boolean)
Converts the specified value.
Declaration
public static string Encode(bool value)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | value | if set to |
Returns
Type | Description |
---|---|
System.String |
Encode(Double)
Converts the specified value.
Declaration
public static string Encode(double value)
Parameters
Type | Name | Description |
---|---|---|
System.Double | value | The value. |
Returns
Type | Description |
---|---|
System.String |
Encode(Color)
Converts the specified value.
Declaration
public static string Encode(Color value)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | value | The value. |
Returns
Type | Description |
---|---|
System.String |
Encode(Single)
Converts the specified value.
Declaration
public static string Encode(float value)
Parameters
Type | Name | Description |
---|---|---|
System.Single | value | The value. |
Returns
Type | Description |
---|---|
System.String |
Encode(String)
Encodes the specified value.
Declaration
public static string Encode(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.String |
EncodeJsFunction(String)
Encodes the js function.
Declaration
public static string EncodeJsFunction(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.String |
GetConverters()
Gets the converters.
Declaration
public static IEnumerable<JavaScriptConverter> GetConverters()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Web.Script.Serialization.JavaScriptConverter> |
IsUndefined(String)
Determines whether the specified value is undefined.
Declaration
public static bool IsUndefined(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Boolean |
|
ToBoolean(String)
Toes the boolean.
Declaration
public static bool ToBoolean(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Boolean |
ToByte(String)
Toes the byte.
Declaration
public static byte ToByte(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Byte |
ToColor(String)
Toes the color.
Declaration
public static Color ToColor(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Drawing.Color |
ToDecimal(String)
Toes the decimal.
Declaration
public static decimal ToDecimal(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Decimal |
ToDouble(String)
Decodes the specified value.
Declaration
public static double ToDouble(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Double |
ToInt(String)
Toes the int.
Declaration
public static int ToInt(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Int32 |
ToLong(String)
Toes the long.
Declaration
public static long ToLong(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Int64 |
ToShort(String)
Toes the short.
Declaration
public static short ToShort(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Int16 |
ToSingle(String)
Toes the single.
Declaration
public static float ToSingle(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
Returns
Type | Description |
---|---|
System.Single |
TryParsePoint(String, out Double, out Double)
Tries the parse point.
Declaration
public static bool TryParsePoint(string value, out double lat, out double lng)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | The value. |
System.Double | lat | The lat. |
System.Double | lng | The LNG. |
Returns
Type | Description |
---|---|
System.Boolean |