Share via


ServicesContainer.Insert Method (Type, Int32, Object)

 

Inserts a service into the collection at the specified index.

Namespace:   System.Web.Http.Controllers
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

public void Insert(
    Type serviceType,
    int index,
    object service
)
public:
void Insert(
    Type^ serviceType,
    int index,
    Object^ service
)
member Insert : 
        serviceType:Type *
        index:int *
        service:Object -> unit
Public Sub Insert (
    serviceType As Type,
    index As Integer,
    service As Object
)

Parameters

  • index
    Type: System.Int32

    The zero-based index at which the service should be inserted. If MaxValue is passed, ensures the element is added to the end.

See Also

ServicesContainer Class
System.Web.Http.Controllers Namespace

Return to top