• Api Documentation
Show / Hide Table of Contents
  • Softadmin.Api
    • AdminMessageException
    • CustomComponent
    • ICookies
    • IEnvironment
    • IForwardState
    • IHttpHeaders
    • IParameters
    • ISessionVariables
    • ISystemSettings
    • Plugin
  • Softadmin.Api.Database
    • IDbRequest
    • IDbRequestFactory
  • Softadmin.Api.Diagnostics
    • ILogger
  • Softadmin.Api.Login
    • IUserState
    • LoginPlugin
    • PostLoginPlugin
    • PreLoginPlugin
    • UserAuthenticationPlugin
  • Softadmin.Api.Logout
    • LogoutPlugin
  • Softadmin.Api.Page
    • ICustomPage
    • PagePlugin
  • Softadmin.Api.Ui
    • IDebugWindow
    • IProgressWindow

Interface IParameters

Wraps the passing fields and parameters for a page and supplies conversion to a fixed number of types.

Namespace: Softadmin.Api
Assembly: Softadmin.Api.dll
Syntax
public interface IParameters

Methods

GetBool(String)

Gets the value of a field as a boolean value.

Declaration
bool GetBool(string name)
Parameters
Type Name Description
System.String name

The name, case insensitive.

Returns
Type Description
System.Boolean

The value of the field, converted to a boolean if necessary.

Exceptions
Type Condition
System.ArgumentException

No field found with the given name.

System.InvalidCastException

The value could not be converted to a boolean.

GetInt(String)

Gets the value of a field as an integer value.

Declaration
int GetInt(string name)
Parameters
Type Name Description
System.String name

The name, case insensitive.

Returns
Type Description
System.Int32

The value of the field, converted to an integer if necessary.

Exceptions
Type Condition
System.ArgumentException

No field found with the given name.

System.InvalidCastException

The value could not be converted to an integer.

GetString(String)

Gets the value of a field as a string value.

Declaration
string GetString(string name)
Parameters
Type Name Description
System.String name

The name, case insensitive.

Returns
Type Description
System.String

The value of the field, converted to a string if necessary.

Exceptions
Type Condition
System.ArgumentException

No field found with the given name.

TryGetBool(String, out Boolean)

Gets the value of a field as a boolean value.

Declaration
bool TryGetBool(string name, out bool value)
Parameters
Type Name Description
System.String name

The name, case insensitive.

System.Boolean value

The value of the field, converted to a boolean if necessary.

Returns
Type Description
System.Boolean

true if the field exists and could be converted.

TryGetInt(String, out Int32)

Gets the value of a field as an integer value.

Declaration
bool TryGetInt(string name, out int value)
Parameters
Type Name Description
System.String name

The name, case insensitive.

System.Int32 value

The value of the field, converted to an integer if necessary.

Returns
Type Description
System.Boolean

true if the field exists and could be converted.

TryGetString(String, out String)

Gets the value of a field as a string value.

Declaration
bool TryGetString(string name, out string value)
Parameters
Type Name Description
System.String name

The name, case insensitive.

System.String value

The value of the field, converted to a string if necessary.

Returns
Type Description
System.Boolean

true if the field exists and could be converted.

Back to top Generated by DocFX