Skip to content

Commit 31e32bf

Browse files
committed
Package shift from .rxjava3 to .rxjava4
1 parent d06bdbc commit 31e32bf

1,889 files changed

Lines changed: 11560 additions & 11581 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 17 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
# RxJava: Reactive Extensions for the JVM
22

33
<a href='https://github.com/ReactiveX/RxJava/actions?query=workflow%3ASnapshot'><img src='https://github.com/ReactiveX/RxJava/workflows/Snapshot/badge.svg'></a>
4-
[![codecov.io](http://codecov.io/github/ReactiveX/RxJava/coverage.svg?branch=3.x)](https://codecov.io/gh/ReactiveX/RxJava/branch/3.x)
5-
[![Maven Central](https://maven-badges.sml.io/sonatype-central/io.reactivex.rxjava3/rxjava/badge.svg)](https://maven-badges.sml.io/sonatype-central/io.reactivex.rxjava3/rxjava)
6-
[![Contribute with Gitpod](https://img.shields.io/badge/Contribute%20with-Gitpod-908a85?logo=gitpod)](https://gitpod.io/#https://github.com/ReactiveX/RxJava)
4+
[![codecov.io](http://codecov.io/github/ReactiveX/RxJava/coverage.svg?branch=4.x)](https://codecov.io/gh/ReactiveX/RxJava/branch/4.x)
5+
[![Maven Central](https://maven-badges.sml.io/sonatype-central/io.reactivex.rxjava4/rxjava/badge.svg)](https://maven-badges.sml.io/sonatype-central/io.reactivex.rxjava4/rxjava)
76
[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/ReactiveX/RxJava/badge)](https://securityscorecards.dev/viewer/?uri=github.com/ReactiveX/RxJava)
87

98
RxJava is a Java VM implementation of [Reactive Extensions](http://reactivex.io): a library for composing asynchronous and event-based programs by using observable sequences.
109

1110
It extends the [observer pattern](http://en.wikipedia.org/wiki/Observer_pattern) to support sequences of data/events and adds operators that allow you to compose sequences together declaratively while abstracting away concerns about things like low-level threading, synchronization, thread-safety and concurrent data structures.
1211

12+
#### Version 3.x ([Javadoc](http://reactivex.io/RxJava/4.x/javadoc/))
13+
14+
- TBD
15+
1316
#### Version 3.x ([Javadoc](http://reactivex.io/RxJava/3.x/javadoc/))
1417

1518
- Single dependency: [Reactive-Streams](https://github.com/reactive-streams/reactive-streams-jvm).
@@ -42,7 +45,7 @@ The [1.x version](https://github.com/ReactiveX/RxJava/tree/1.x) is end-of-life a
4245

4346
### Setting up the dependency
4447

45-
The first step is to include RxJava 3 into your project, for example, as a Gradle compile dependency:
48+
The first step is to include RxJava 4 into your project, for example, as a Gradle compile dependency:
4649

4750
```groovy
4851
implementation "io.reactivex.rxjava3:rxjava:3.x.y"
@@ -58,7 +61,7 @@ The second is to write the **Hello World** program:
5861
```java
5962
package rxjava.examples;
6063

61-
import io.reactivex.rxjava3.core.*;
64+
import io.reactivex.rxjava4.core.*;
6265

6366
public class HelloWorld {
6467
public static void main(String[] args) {
@@ -67,17 +70,17 @@ public class HelloWorld {
6770
}
6871
```
6972

70-
Note that RxJava 3 components now live under `io.reactivex.rxjava3` and the base classes and interfaces live under `io.reactivex.rxjava3.core`.
73+
Note that RxJava 3 components now live under `io.reactivex.rxjava3` and the base classes and interfaces live under `io.reactivex.rxjava4.core`.
7174

7275
### Base classes
7376

7477
RxJava 3 features several base classes you can discover operators on:
7578

76-
- [`io.reactivex.rxjava3.core.Flowable`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Flowable.html): 0..N flows, supporting Reactive-Streams and backpressure
77-
- [`io.reactivex.rxjava3.core.Observable`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Observable.html): 0..N flows, no backpressure,
78-
- [`io.reactivex.rxjava3.core.Single`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Single.html): a flow of exactly 1 item or an error,
79-
- [`io.reactivex.rxjava3.core.Completable`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Completable.html): a flow without items but only a completion or error signal,
80-
- [`io.reactivex.rxjava3.core.Maybe`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Maybe.html): a flow with no items, exactly one item or an error.
79+
- [`io.reactivex.rxjava4.core.Flowable`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Flowable.html): 0..N flows, supporting Reactive-Streams and backpressure
80+
- [`io.reactivex.rxjava4.core.Observable`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Observable.html): 0..N flows, no backpressure,
81+
- [`io.reactivex.rxjava4.core.Single`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Single.html): a flow of exactly 1 item or an error,
82+
- [`io.reactivex.rxjava4.core.Completable`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Completable.html): a flow without items but only a completion or error signal,
83+
- [`io.reactivex.rxjava4.core.Maybe`](http://reactivex.io/RxJava/3.x/javadoc/io/reactivex/rxjava3/core/Maybe.html): a flow with no items, exactly one item or an error.
8184

8285
### Some terminology
8386

@@ -160,7 +163,7 @@ Practically, this is when the body of the given example above executes.
160163
One of the common use cases for RxJava is to run some computation, network request on a background thread and show the results (or error) on the UI thread:
161164

162165
```java
163-
import io.reactivex.rxjava3.schedulers.Schedulers;
166+
import io.reactivex.rxjava4.schedulers.Schedulers;
164167

165168
Flowable.fromCallable(() -> {
166169
Thread.sleep(1000); // imitate expensive computation
@@ -533,9 +536,9 @@ APIs marked with the [`@Experimental`][experimental source link] annotation at t
533536

534537
APIs marked with the `@Deprecated` annotation at the class or method level will remain supported until the next major release, but it is recommended to stop using them.
535538

536-
#### io.reactivex.rxjava3.internal.*
539+
#### io.reactivex.rxjava4.internal.*
537540

538-
All code inside the `io.reactivex.rxjava3.internal.*` packages are considered private API and should not be relied upon at all. It can change at any time.
541+
All code inside the `io.reactivex.rxjava4.internal.*` packages are considered private API and should not be relied upon at all. It can change at any time.
539542

540543
## Full Documentation
541544

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,8 +142,8 @@ tasks.register('bundle', Bundle) {
142142
bnd('Import-Package': '!org.junit,!junit.framework,!org.mockito.*,!org.testng.*,*')
143143
bnd('Bundle-DocURL': 'https://github.com/ReactiveX/RxJava')
144144
bnd('Eclipse-ExtensibleAPI': 'true')
145-
bnd('Export-Package': '!io.reactivex.rxjava3.internal.*,io.reactivex.rxjava3.*')
146-
bnd('Bundle-SymbolicName': 'io.reactivex.rxjava3.rxjava')
145+
bnd('Export-Package': '!io.reactivex.rxjava4.internal.*,io.reactivex.rxjava4.*')
146+
bnd('Bundle-SymbolicName': 'io.reactivex.rxjava4.rxjava')
147147
bnd('Multi-Release': 'true')
148148
}
149149
}

config/checkstyle/checkstyle.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
This configuration file was written by the eclipse-cs plugin configuration editor
66
-->
77
<!--
8-
Checkstyle-Configuration: rxjava
8+
Checkstyle-Configuration: local
99
Description: none
1010
-->
1111
<module name="Checker">
@@ -27,7 +27,6 @@
2727
<property name="headerFile" value="${checkstyle.header.file}"/>
2828
</module>
2929
<module name="BeforeExecutionExclusionFileFilter">
30-
<property name="severity" value="ignore"/>
3130
<property name="fileNamePattern" value="module\-info\.java$"/>
3231
</module>
3332
</module>

config/checkstyle/suppressions.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
<suppressions>
88

9-
<suppress checks="MissingJavadocMethod" files="[\\/]main[\\/]java[\\/]io[\\/]reactivex[\\/]rxjava3[\\/]internal[\\/]"/>
10-
<suppress checks="MissingJavadocMethod" files="[\\/]jmh[\\/]java[\\/]io[\\/]reactivex[\\/]rxjava3[\\/]"/>
11-
<suppress checks="MissingJavadocMethod" files="[\\/]test[\\/]java[\\/]io[\\/]reactivex[\\/]rxjava3[\\/]"/>
9+
<suppress checks="MissingJavadocMethod,JavadocMethod" files="src/main/java/io/reactivex/rxjava4/internal/.*\.java$"/>
10+
<suppress checks="MissingJavadocMethod,JavadocMethod" files="src/test/java/.*\.java$"/>
11+
<suppress checks="MissingJavadocMethod,JavadocMethod" files="src/jmh/java/.*\.java$"/>
1212

1313
</suppressions>

gradle/javadoc_cleanup.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,25 +46,25 @@ def fixJavadocFile(file) {
4646
fileContents = fileContents.replaceAll("@Nullable</a>\\s{4,}", "@Nullable</a> ")
4747

4848
// javadoc bug: duplicates the link to @NonNull for some reason
49-
def nonNullText1 = "<a href=\"../annotations/NonNull.html\" title=\"annotation in io.reactivex.rxjava3.annotations\">@NonNull</a>"
49+
def nonNullText1 = "<a href=\"../annotations/NonNull.html\" title=\"annotation in io.reactivex.rxjava4.annotations\">@NonNull</a>"
5050

5151
fileContents = fileContents.replace(nonNullText1 + " " + nonNullText1, nonNullText1)
5252
fileContents = fileContents.replace(nonNullText1 + "\n " + nonNullText1, nonNullText1)
5353
fileContents = fileContents.replace(nonNullText1 + "\r\n " + nonNullText1, nonNullText1)
5454

55-
def nonNullText2 = "<a href=\"../../../../io/reactivex/rxjava3/annotations/NonNull.html\" title=\"annotation in io.reactivex.rxjava3.annotations\">@NonNull</a>"
55+
def nonNullText2 = "<a href=\"../../../../io/reactivex/rxjava3/annotations/NonNull.html\" title=\"annotation in io.reactivex.rxjava4.annotations\">@NonNull</a>"
5656
fileContents = fileContents.replace(nonNullText2 + " " + nonNullText2, nonNullText2)
5757
fileContents = fileContents.replace(nonNullText2 + "\n " + nonNullText2, nonNullText2)
5858
fileContents = fileContents.replace(nonNullText2 + "\r\n " + nonNullText2, nonNullText2)
5959

6060
// javadoc bug: duplicates the link to @Nullable for some reason
61-
def nullableText1 = "<a href=\"../annotations/Nullable.html\" title=\"annotation in io.reactivex.rxjava3.annotations\">@Nullable</a>"
61+
def nullableText1 = "<a href=\"../annotations/Nullable.html\" title=\"annotation in io.reactivex.rxjava4.annotations\">@Nullable</a>"
6262

6363
fileContents = fileContents.replace(nullableText1 + " " + nullableText1, nullableText1)
6464
fileContents = fileContents.replace(nullableText1 + "\n " + nullableText1, nullableText1)
6565
fileContents = fileContents.replace(nullableText1 + "\r\n " + nullableText1, nullableText1)
6666

67-
def nullableText2 = "<a href=\"../../../../io/reactivex/rxjava3/annotations/Nullable.html\" title=\"annotation in io.reactivex.rxjava3.annotations\">@Nullable</a>"
67+
def nullableText2 = "<a href=\"../../../../io/reactivex/rxjava3/annotations/Nullable.html\" title=\"annotation in io.reactivex.rxjava4.annotations\">@Nullable</a>"
6868

6969
fileContents = fileContents.replace(nullableText2 + " " + nullableText2, nullableText2)
7070
fileContents = fileContents.replace(nullableText2 + "\n " + nullableText2, nullableText2)

src/jmh/java/io/reactivex/rxjava3/core/BinaryFlatMapPerf.java renamed to src/jmh/java/io/reactivex/rxjava4/core/BinaryFlatMapPerf.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* the License for the specific language governing permissions and limitations under the License.
1212
*/
1313

14-
package io.reactivex.rxjava3.core;
14+
package io.reactivex.rxjava4.core;
1515

1616
import java.util.*;
1717
import java.util.concurrent.TimeUnit;
@@ -20,7 +20,7 @@
2020
import org.openjdk.jmh.infra.Blackhole;
2121
import org.reactivestreams.Publisher;
2222

23-
import io.reactivex.rxjava3.functions.Function;
23+
import io.reactivex.rxjava4.functions.Function;
2424

2525
@BenchmarkMode(Mode.Throughput)
2626
@Warmup(iterations = 5)

src/jmh/java/io/reactivex/rxjava3/core/BlockingGetPerf.java renamed to src/jmh/java/io/reactivex/rxjava4/core/BlockingGetPerf.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* the License for the specific language governing permissions and limitations under the License.
1212
*/
1313

14-
package io.reactivex.rxjava3.core;
14+
package io.reactivex.rxjava4.core;
1515

1616
import java.util.concurrent.TimeUnit;
1717

src/jmh/java/io/reactivex/rxjava3/core/BlockingPerf.java renamed to src/jmh/java/io/reactivex/rxjava4/core/BlockingPerf.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* the License for the specific language governing permissions and limitations under the License.
1212
*/
1313

14-
package io.reactivex.rxjava3.core;
14+
package io.reactivex.rxjava4.core;
1515

1616
import java.util.Arrays;
1717
import java.util.concurrent.TimeUnit;

src/jmh/java/io/reactivex/rxjava3/core/CallableAsyncPerf.java renamed to src/jmh/java/io/reactivex/rxjava4/core/CallableAsyncPerf.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@
1111
* the License for the specific language governing permissions and limitations under the License.
1212
*/
1313

14-
package io.reactivex.rxjava3.core;
14+
package io.reactivex.rxjava4.core;
1515

1616
import java.util.concurrent.*;
1717

1818
import org.openjdk.jmh.annotations.*;
1919
import org.openjdk.jmh.infra.Blackhole;
2020

21-
import io.reactivex.rxjava3.internal.schedulers.SingleScheduler;
22-
import io.reactivex.rxjava3.schedulers.Schedulers;
21+
import io.reactivex.rxjava4.internal.schedulers.SingleScheduler;
22+
import io.reactivex.rxjava4.schedulers.Schedulers;
2323

2424
@BenchmarkMode(Mode.Throughput)
2525
@Warmup(iterations = 5)

src/jmh/java/io/reactivex/rxjava3/core/EachTypeFlatMapPerf.java renamed to src/jmh/java/io/reactivex/rxjava4/core/EachTypeFlatMapPerf.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@
1111
* the License for the specific language governing permissions and limitations under the License.
1212
*/
1313

14-
package io.reactivex.rxjava3.core;
14+
package io.reactivex.rxjava4.core;
1515

1616
import java.util.concurrent.TimeUnit;
1717

1818
import org.openjdk.jmh.annotations.*;
1919
import org.openjdk.jmh.infra.Blackhole;
2020
import org.reactivestreams.Publisher;
2121

22-
import io.reactivex.rxjava3.functions.Function;
22+
import io.reactivex.rxjava4.functions.Function;
2323

2424
@BenchmarkMode(Mode.Throughput)
2525
@Warmup(iterations = 5)

0 commit comments

Comments
 (0)