StreamLink.NET
GlobalThrottle Method (listener, parameters)
StreamLink.NETCaplin.StreamLinkIStreamLinkProviderGlobalThrottle(ICommandListener, IThrottleParameters)
Issues a command to change the throttle level for all updates received from the Liberator.
Declaration Syntax
C#Visual BasicVisual C++
void GlobalThrottle(
	ICommandListener listener,
	IThrottleParameters parameters
)
Sub GlobalThrottle ( _
	listener As ICommandListener, _
	parameters As IThrottleParameters _
)
void GlobalThrottle(
	ICommandListener^ listener, 
	IThrottleParameters^ parameters
)
Parameters
listener (ICommandListener)
The listener that will receive the results of the throttle command.
parameters (IThrottleParameters)
The parameters of the throttle command.
Remarks
For more information on throttling see the Caplin StreamLink Overview.
Examples
CopyC#
using Caplin.StreamLink;
using Caplin.StreamLink.Authentication;
using Caplin.StreamLink.Command;

namespace StreamLinkExamples.Commands
{
    /// <summary>
    /// Set Global Throttle level
    /// </summary>
    public class GlobalThrottle
    {
        /// <summary>
        /// Example of how to throttle updates to all subjects from the Liberator.
        /// </summary>
        public static void CreateGlobalThrottleExample()
        {
            IStreamLink myStreamLink = new StreamLink();
            myStreamLink.CredentialsProvider = new PasswordCredentialsProvider("admin", "admin");

            // Connect
            myStreamLink.StreamLinkProvider.Connect();

            // set global throttle level to max
            IThrottleParameters parameters =
                myStreamLink.StreamLinkProvider.ParametersFactory.CreateThrottleParameters(ThrottleControl.Max);

            // listener called when the throttle command has finished executing
            ICommandListener listener = new ExampleCommandListener();

            myStreamLink.StreamLinkProvider.GlobalThrottle(listener, parameters);
        }

    }
}
See Also

Assembly: Caplin.StreamLink (Module: Caplin.StreamLink) Version: 5.0.23.0 (5.0.23.0)