Promise.then

Registers the specified fulfillment and rejection handlers. If the promise is already resolved, they are called as soon as possible (but not immediately).

  1. Promise!(Unpromise!R, F) then(R delegate(A) nothrow onFulfilled, R delegate(E) nothrow onRejected)
    class Promise(T, E : Throwable = Exception)
    nothrow
    Promise!(Unpromise!R, F)
    then
    (
    R
    F = E
    )
    (
    R delegate
    (
    A
    )
    nothrow
    onFulfilled
    ,
    R delegate
    (
    E
    )
    nothrow
    onRejected = null
    )
  2. Promise!(CommonType!(Unpromise!R, T), F) then(typeof(null) onFulfilled, R delegate(E) nothrow onRejected)

Meta