Class ProxyChannelFactory


  • public class ProxyChannelFactory
    extends Object
    • Constructor Detail

      • ProxyChannelFactory

        public ProxyChannelFactory()
    • Method Detail

      • createSpscProxy

        public static <E> ProxyChannel<E> createSpscProxy​(int capacity,
                                                          Class<E> iFace,
                                                          WaitStrategy waitStrategy)
        Create a default single producer single consumer (SPSC) proxy channel.
        Parameters:
        capacity - The minimum capacity for unprocessed invocations the channel should support
        iFace - Interface the proxy must implement
        waitStrategy - A wait strategy to be invoked when the backing data structure is full
        Returns:
        A proxy channel instance
      • createMpscProxy

        public static <E> ProxyChannel<E> createMpscProxy​(int capacity,
                                                          Class<E> iFace,
                                                          WaitStrategy waitStrategy)
        Create a default multi producer single consumer (MPSC) proxy channel.
        Parameters:
        capacity - The minimum capacity for unprocessed invocations the channel should support
        iFace - Interface the proxy must implement
        waitStrategy - A wait strategy to be invoked when the backing data structure is full
        Returns:
        A proxy channel instance
      • createProxy

        public static <E> ProxyChannel<E> createProxy​(int capacity,
                                                      Class<E> iFace,
                                                      WaitStrategy waitStrategy,
                                                      Class<? extends ProxyChannelRingBuffer> backendType)
        Create a proxy channel using a user supplied back end.
        Parameters:
        capacity - The minimum capacity for unprocessed invocations the channel should support
        iFace - Interface the proxy must implement
        waitStrategy - A wait strategy to be invoked when the backing data structure is full
        backendType - The back end type, the proxy will inherit from this channel type. The back end type must define a constructor with signature: (int capacity, int primitiveMessageSize, int referenceMessageSize)
        Returns:
        A proxy channel instance