Share via


Shell.Utilities.QueryStringBuilder.js

 

Applies To: Windows Azure Pack

Provides methods for constructing, modifying, and formatting a data query string.

Widgets

None.

Types

Shell.Utilities.QueryStringBuilder(queryString)

Name

Type

Description

queryString

string

String to initialize parameters with.

Properties

None

Methods

Name

Description

Returns

Parameters

Shell.Utilities.QueryStringBuilder.containsKey

Determines if a given key exists in the parameter array.

Boolean

key (String): The key name to look for.

Shell.Utilities.QueryStringBuilder.getParameters

Gets an array of current parameters. Each entry is in the form of {key, value}.

Array of Key/Value pairs.

None.

Shell.Utilities.QueryStringBuilder.getValue

Gets the value of a given key or returns a default value if key is not found.

String

key (String): The key name to look for.

defaultValue (String): Value to return if key is not found.

Shell.Utilities.QueryStringBuilder.remove

Removes parameters with given keys from the parameter array.

Object

arg (Array): The key names to remove.

Shell.Utilities.QueryStringBuilder.set

Adds or updates parameters.

Object

params (Object): Object whose properties will be set as parameters.

Shell.Utilities.QueryStringBuilder.toString

Formats the parameters into query string.

String

includeLeadingQuestionMark (Boolean): Whether to include a leading question mark.

See Also

Windows Azure Pack Extension Shell Library Reference