@@ -90,60 +90,6 @@ public void call(Object... args) {
90
90
}
91
91
}
92
92
93
- /**
94
- * Extracts a method reference to the Observer's {@link Observer#onNext onNext} method in the form of an
95
- * {@link Action1}.
96
- * <p>Java 8: observer::onNext</p>
97
- *
98
- * @param observer
99
- * the {@link Observer} to use
100
- * @return an action which calls observer's {@code onNext} method.
101
- */
102
- public static <T > Action1 <T > onNextFrom (final Observer <T > observer ) {
103
- return new Action1 <T >() {
104
- @ Override
105
- public void call (T t1 ) {
106
- observer .onNext (t1 );
107
- }
108
- };
109
- }
110
-
111
- /**
112
- * Extracts a method reference to the Observer's {@link Observer#onError(java.lang.Throwable) onError}
113
- * method in the form of an {@link Action1}.
114
- * <p>Java 8: observer::onError</p>
115
- *
116
- * @param observer
117
- * the {@link Observer} to use
118
- * @return an action which calls observer's {@code onError} method.
119
- */
120
- public static <T > Action1 <Throwable > onErrorFrom (final Observer <T > observer ) {
121
- return new Action1 <Throwable >() {
122
- @ Override
123
- public void call (Throwable t1 ) {
124
- observer .onError (t1 );
125
- }
126
- };
127
- }
128
-
129
- /**
130
- * Extracts a method reference to the Observer's {@link Observer#onCompleted() onCompleted} method in the
131
- * form of an {@link Action0}.
132
- * <p>Java 8: observer::onCompleted</p>
133
- *
134
- * @param observer
135
- * the {@link Observer} to use
136
- * @return an action which calls observer's {@code onCompleted} method.
137
- */
138
- public static <T > Action0 onCompletedFrom (final Observer <T > observer ) {
139
- return new Action0 () {
140
- @ Override
141
- public void call () {
142
- observer .onCompleted ();
143
- }
144
- };
145
- }
146
-
147
93
/**
148
94
* Converts an {@link Action0} to a function that calls the action and returns {@code null}.
149
95
*
0 commit comments