Class MessageSupport

    • Field Detail

      • collaboration

        @Nonnull
        protected final it.tidalwave.actor.impl.DefaultCollaboration collaboration
    • Constructor Detail

      • MessageSupport

        protected MessageSupport()
      • MessageSupport

        protected MessageSupport​(@Nonnull
                                 Collaboration collaboration)
        Parameters:
        collaboration - the collaboration
    • Method Detail

      • send

        @Nonnull
        public Collaboration send()
        Sends this message, eventually performing a replacement (see MessageDecorator for further info).
        Returns:
        the Collaboration that this message is part of
      • sendDirectly

        @Nonnull
        public Collaboration sendDirectly()
        Sends this message directly, not performing any replacement (see MessageDecorator for further info).
        Returns:
        the Collaboration that this message is part of
      • sendLater

        @Nonnull
        public Collaboration sendLater​(@Nonnegative
                                       int delay,
                                       @Nonnull
                                       java.util.concurrent.TimeUnit timeUnit)
        Sends this message after a delay, eventually performing a replacement (see MessageDecorator for further info).
        Parameters:
        delay - the delay
        timeUnit - the TimeUnit for the delay
        Returns:
        the Collaboration that this message is part of
      • as

        @Nonnull
        public <T> T as​(@Nonnull
                        java.lang.Class<T> type)
        Returns an adapter to this object of the specified type. If the implementation can find multiple compliant adapters, only one will be returned.
        Specified by:
        as in interface As
        Type Parameters:
        T - the static type
        Parameters:
        type - the dynamic type
        Returns:
        the adapter