@@ -82,7 +82,7 @@ public interface IPublisher<out T> {
8282| < a name = " 1.6" > 6 < / a > | If a `Publisher ` signals either `onError ` or `onComplete ` on a `Subscriber `, that `Subscriber `’s `Subscription ` MUST be considered cancelled . |
8383| < a name = " 1.7" > 7 < / a > | Once a terminal state has been signaled (`onError `, `onComplete `) it is REQUIRED that no further signals occur . |
8484| < a name = " 1.8" > 8 < / a > | If a `Subscription ` is cancelled its `Subscriber ` MUST eventually stop being signaled . |
85- | < a name = " 1.9" > 9 < / a > | `Publisher .Subscribe ` MUST call `OnSubscribe ` on the provided `Subscriber ` prior to any other signals to that `Subscriber ` and MUST return normally , except when the provided `Subscriber ` is `null ` in which case it MUST throw a `System .NullReferenceException ` to the caller , for all other situations [[1]](#footnote-1-1) the only legal way to signal failure (or reject the `Subscriber `) is by calling `OnError ` (after calling `OnSubscribe `). |
85+ | < a name = " 1.9" > 9 < / a > | `Publisher .Subscribe ` MUST call `OnSubscribe ` on the provided `Subscriber ` prior to any other signals to that `Subscriber ` and MUST return normally , except when the provided `Subscriber ` is `null ` in which case it MUST throw a `System .ArgumentNullException ` to the caller , for all other situations [[1]](#footnote-1-1) the only legal way to signal failure (or reject the `Subscriber `) is by calling `OnError ` (after calling `OnSubscribe `). |
8686| < a name = " 1.10" > 10 < / a > | `Publisher .Subscribe ` MAY be called as many times as wanted but MUST be with a different `Subscriber ` each time [see [2 . 12 ](#2 . 12 )]. |
8787| < a name = " 1.11" > 11 < / a > | A `Publisher ` MAY support multiple `Subscriber `s and decides whether each `Subscription ` is unicast or multicast . |
8888
@@ -113,7 +113,7 @@ public interface ISubscriber<in T> {
113113| < a name = " 2.10" > 10 < / a > | A `Subscriber ` MUST be prepared to receive an `onError ` signal with or without a preceding `Subscription .Request (long n )` call . |
114114| < a name = " 2.11" > 11 < / a > | A `Subscriber ` MUST make sure that all calls on its `OnXXX ` methods happen - before [[1 ]](#footnote - 2 - 1 ) the processing of the respective signals . I .e . the Subscriber must take care of properly publishing the signal to its processing logic . |
115115| < a name = " 2.12" > 12 < / a > | `Subscriber .OnSubscribe ` MUST be called at most once for a given `Subscriber ` (based on object equality ). |
116- | < a name = " 2.13" > 13 < / a > | Calling `OnSubscribe `, `OnNext `, `OnError ` or `OnComplete ` MUST return normally except when any provided parameter is `null ` in which case it MUST throw a `System .NullReferenceException ` to the caller , for all other situations the only legal way for a `Subscriber ` to signal failure is by cancelling its `Subscription `. In the case that this rule is violated , any associated `Subscription ` to the `Subscriber ` MUST be considered as cancelled , and the caller MUST raise this error condition in a fashion that is adequate for the runtime environment . |
116+ | < a name = " 2.13" > 13 < / a > | Calling `OnSubscribe `, `OnNext `, `OnError ` or `OnComplete ` MUST return normally except when any provided parameter is `null ` in which case it MUST throw a `System .ArgumentNullException ` to the caller , for all other situations the only legal way for a `Subscriber ` to signal failure is by cancelling its `Subscription `. In the case that this rule is violated , any associated `Subscription ` to the `Subscriber ` MUST be considered as cancelled , and the caller MUST raise this error condition in a fashion that is adequate for the runtime environment . |
117117
118118[< a name = " footnote-2-1" > 1 < / a > ] : See JMM definition of Happen - Before in section 17.4.5 . on http : // docs.oracle.com/javase/specs/jls/se7/html/jls-17.html
119119
0 commit comments