Table of Contents

Class UrlSearchParams

Namespace
AngleSharp.Dom
Assembly
AngleSharp.dll

Represents a list of query parameters.

[DomName("URLSearchParams")]
[DomExposed("Window")]
[DomExposed("Worker")]
public class UrlSearchParams
Inheritance
UrlSearchParams
Inherited Members
Extension Methods

Constructors

UrlSearchParams()

Creates a new instance.

[DomConstructor]
public UrlSearchParams()

UrlSearchParams(string)

Creates a new instance filled from the provided string.

[DomConstructor]
public UrlSearchParams(string init)

Parameters

init string

Methods

Append(string, string)

Appends another value for the given search param name.

[DomName("append")]
public void Append(string name, string value)

Parameters

name string

The name of the param.

value string

The value of the param.

Delete(string)

Deletes the values of the search param name.

[DomName("delete")]
public void Delete(string name)

Parameters

name string

The name of the param.

Get(string)

Gets the first value of the given search param name, if any.

[DomName("get")]
public string? Get(string name)

Parameters

name string

The name of the param.

Returns

string

The value of the param, if any.

GetAll(string)

Gets all values for the given search param name.

[DomName("getAll")]
public string[] GetAll(string name)

Parameters

name string

The name of the param.

Returns

string[]

The list with all stored values.

Has(string)

Checks if a search param with the given name exists.

[DomName("has")]
public bool Has(string name)

Parameters

name string

The name of the param.

Returns

bool

True if such a param exists, otherwise false.

Set(string, string)

Sets the given search param.

[DomName("set")]
public void Set(string name, string value)

Parameters

name string

The name of the param.

value string

The value of the param.

Sort()

Sorts the underlying list.

[DomName("sort")]
public void Sort()

ToString()

public override string ToString()

Returns

string