Class AsyncPromise


  • public class AsyncPromise
    extends ChatConfigurationStage
    Promise abstraction. Accepts a callback which will be called when response is received.
    • Method Detail

      • then

        public void then​(Consumer<String> onResponse)
        Subscribe to the answer
        Parameters:
        onResponse - a callback that receives the string answer