org.apache.synapse.commons.throttle.core.factory

## Class CallerContextFactory

- java.lang.Object
- - org.apache.synapse.commons.throttle.core.factory.CallerContextFactory

-     public class CallerContextFactory
      extends java.lang.Object

  Factory for creating a CallerContext

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `CallerContextFactory()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static CallerContext` | `createCaller(int throttletype, java.lang.String id)` To create a CallerContext(the run time data holder for a remote caller) for the given throttle type.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### CallerContextFactory

          public CallerContextFactory()

  - ### Method Detail

    - #### createCaller

          public static CallerContext createCaller(int throttletype,
                                                   java.lang.String id)
                                            throws ThrottleException

      To create a CallerContext(the run time data holder for a remote caller) for the given throttle type. Needs to provide the ID(ip | domain) of the remote caller (ip/domain according to the policy)
      Parameters:
        `throttletype` - - The type of the throttle
        `id` - - The id of the caller
      Returns:
        caller - The corresponding caller context for the given throttle type
      Throws:
        `ThrottleException` - - Throws for if the throttle type is unknown

Copyright © 2005-2022 Apache Software Foundation. All Rights Reserved.