Delen via


IMeteringService Interface

Metering service API contracts

Namespace:  Microsoft.VisualStudio.Services.Commerce
Assembly:  Microsoft.TeamFoundation.Framework.Server (in Microsoft.TeamFoundation.Framework.Server.dll)

Syntax

'Declaration
Public Interface IMeteringService _
    Inherits ITeamFoundationService
public interface IMeteringService : ITeamFoundationService
public interface class IMeteringService : ITeamFoundationService
type IMeteringService =  
    interface 
        interface ITeamFoundationService 
    end
public interface IMeteringService extends ITeamFoundationService

The IMeteringService type exposes the following members.

Methods

  Name Description
Public method GetResourceStatus(TeamFoundationRequestContext, Boolean)
Public method GetResourceStatus(TeamFoundationRequestContext, ResourceName, Boolean) Returns detailed facts about specified resource.
Public method ReportUsage Sends usage information to billing pipeline. Note that this method requires the request context to be at the application level with user identity.
Public method ServiceEnd ServiceEnd is called when the Host is being Shutdown and this service should free all resources it is holding onto. (Inherited from ITeamFoundationService.)
Public method ServiceStart ServiceStart is called when the service is initialized. If the service is intialized asynchronously it must implement Service_Ready which is used to determine when the service is ready for users to access it. (Inherited from ITeamFoundationService.)
Public method SetAccountQuantity Updates account level included and maximum quantities. The new included quantity allows the usage to be free until this quantity. The new maximum quantity is the maximum billable quantity that is allowed for the account.
Public method TogglePaidBilling Toggles paid billing state for the specified account id and resource name. The specified resource must be a pay as go resource otherwise an argument exception is thrown back to the caller.

Top

See Also

Reference

Microsoft.VisualStudio.Services.Commerce Namespace