ReactiveX/RxJava

View on GitHub

Showing 657 of 1,068 total issues

Avoid too many return statements within this method.
Open

                        return;
Severity: Major
Found in src/main/java/rx/internal/producers/ProducerObserverArbiter.java - About 30 mins to fix

    Avoid too many return statements within this method.
    Open

                return false;
    Severity: Major
    Found in src/main/java/rx/observables/AsyncOnSubscribe.java - About 30 mins to fix

      Avoid too many return statements within this method.
      Open

                              return;
      Severity: Major
      Found in src/main/java/rx/subjects/ReplaySubject.java - About 30 mins to fix

        Avoid too many return statements within this method.
        Open

                        return pluggedRendering;
        Severity: Major
        Found in src/main/java/rx/exceptions/OnErrorThrowable.java - About 30 mins to fix

          Avoid too many return statements within this method.
          Open

                                  return;
          Severity: Major
          Found in src/main/java/rx/observers/SerializedObserver.java - About 30 mins to fix

            Avoid too many return statements within this method.
            Open

                                    return;
            Severity: Major
            Found in src/main/java/rx/subjects/ReplaySubject.java - About 30 mins to fix

              Avoid too many return statements within this method.
              Open

                                  return;
              Severity: Major
              Found in src/main/java/rx/subjects/ReplaySubject.java - About 30 mins to fix

                Avoid too many return statements within this method.
                Open

                        return true;
                Severity: Major
                Found in src/main/java/rx/schedulers/TimeInterval.java - About 30 mins to fix

                  Avoid too many return statements within this method.
                  Open

                              return false;
                  Severity: Major
                  Found in src/main/java/rx/schedulers/TimeInterval.java - About 30 mins to fix

                    Avoid too many return statements within this method.
                    Open

                                    return false;
                    Severity: Major
                    Found in src/main/java/rx/schedulers/TimeInterval.java - About 30 mins to fix

                      Avoid too many return statements within this method.
                      Open

                                              return;
                      Severity: Major
                      Found in src/main/java/rx/subjects/UnicastSubject.java - About 30 mins to fix

                        Avoid too many return statements within this method.
                        Open

                                    return new State<T>(terminated, b);
                        Severity: Major
                        Found in src/main/java/rx/subjects/SubjectSubscriptionManager.java - About 30 mins to fix

                          Method offer has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                              @Override
                              public boolean offer(final T e) {
                                  // local load of field to avoid repeated loads after volatile reads
                                  final AtomicReferenceArray<Object> buffer = producerBuffer;
                                  final long index = lpProducerIndex();
                          Severity: Minor
                          Found in src/main/java/rx/internal/util/atomic/SpscLinkedArrayQueue.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method onError has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                                  @Override
                                  public void onError(Throwable e) {
                                      if (done) {
                                          RxJavaHooks.onError(e);
                                          return;
                          Severity: Minor
                          Found in src/main/java/rx/internal/operators/OnSubscribeDoOnEach.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method isSelected has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                                  private boolean isSelected() {
                                      if (chosen) {
                                          return true;
                                      }
                                      if (selection.get() == this) {
                          Severity: Minor
                          Found in src/main/java/rx/internal/operators/OnSubscribeAmb.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method onNext has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                                      @Override
                                      public void onNext(TRight args) {
                                          int id;
                                          int highLeftId;
                                          synchronized (ResultSink.this) {
                          Severity: Minor
                          Found in src/main/java/rx/internal/operators/OnSubscribeJoin.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method request has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                                  @Override
                                  public void request(long n) {
                                      if (once) {
                                          return;
                                      }
                          Severity: Minor
                          Found in src/main/java/rx/internal/util/ScalarSynchronousObservable.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method add has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                                  boolean add(InnerProducer<T> producer) {
                                      if (producer == null) {
                                          throw new NullPointerException();
                                      }
                                      // the state can change so we do a CAS loop to achieve atomicity
                          Severity: Minor
                          Found in src/main/java/rx/internal/operators/OperatorPublish.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method call has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                              @Override
                              public void call(Subscriber<? super T> t) {
                                  final SerialSubscription serial = new SerialSubscription();
                          
                                  t.add(serial);

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Method accept has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                          Open

                              @SuppressWarnings("unchecked")
                              public static <T> boolean accept(Observer<? super T> o, Object n) {
                                  if (n == ON_COMPLETED_SENTINEL) {
                                      o.onCompleted();
                                      return true;
                          Severity: Minor
                          Found in src/main/java/rx/internal/operators/NotificationLite.java - About 25 mins to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Severity
                          Category
                          Status
                          Source
                          Language