Was this page helpful?

GetParam Extension Method

    GetParam(this XUri uri, string key, T def)

    public static T GetParam(this XUri uri, string key, T def);
    Get a typed parameter from the Uri.

    Generic Parameters

    Parameter T

    Type of the parameter.
    Constraints:
    none

    Parameters

    Name Type Description
    uri XUri Input Uri.
    key string Parameter key.
    def T Default value to return in case parameter does not exist.

    Returns

    Type: T
    Parameter value or default.

    GetParam(this XUri uri, string key, int index, T def)

    public static T GetParam(this XUri uri, string key, int index, T def);
    Get a typed parameter from the Uri.

    Generic Parameters

    Parameter T

    Type of the parameter.
    Constraints:
    none

    Parameters

    Name Type Description
    uri XUri Input Uri.
    key string Parameter key.
    index int Parameter index.
    def T Default value to return in case parameter does not exist.

    Returns

    Type: T
    Parameter value or default.
    Was this page helpful?
    Tag page
    You must login to post a comment.

    Copyright © 2011 MindTouch, Inc. Powered by