From 544f3845f935cf64b655c153633b1bd83d794bba Mon Sep 17 00:00:00 2001 From: Ben Christensen Date: Thu, 14 Feb 2013 12:22:25 -0800 Subject: [PATCH 1/2] fix javadocs - cleanup some warnings --- rxjava-core/src/main/java/rx/Observable.java | 37 ++++++++++---------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/rxjava-core/src/main/java/rx/Observable.java b/rxjava-core/src/main/java/rx/Observable.java index b16753001de..c305f19c9a7 100644 --- a/rxjava-core/src/main/java/rx/Observable.java +++ b/rxjava-core/src/main/java/rx/Observable.java @@ -120,7 +120,7 @@ private Observable(Func1, Subscription> onSubscribe, boolean isTrust * For more information see the RxJava Wiki * * - * @param Observer + * @param observer * @return a {@link Subscription} reference that allows observers * to stop receiving notifications before the provider has finished sending them */ @@ -447,9 +447,9 @@ private static Observable _create(Func1, Subscription> func) * as appropriate, and returns a {@link Subscription} to allow canceling the subscription (if applicable) * @return an Observable that, when an {@link Observer} subscribes to it, will execute the given function */ - public static Observable create(final Object callback) { + public static Observable create(final Object func) { @SuppressWarnings("rawtypes") - final FuncN _f = Functions.from(callback); + final FuncN _f = Functions.from(func); return create(new Func1, Subscription>() { @Override @@ -509,7 +509,7 @@ public static Observable filter(Observable that, Func1 pre * * @param that * the Observable to filter - * @param predicate + * @param function * a function that evaluates the items emitted by the source Observable, returning true if they pass the filter * @return an Observable that emits only those items in the original Observable that the filter evaluates as true */ @@ -544,7 +544,7 @@ public static Observable from(Iterable iterable) { /** * Converts an Array to an Observable sequence. * - * @param iterable + * @param items * the source Array * @param * the type of items in the Array, and the type of items emitted by the resulting Observable @@ -574,7 +574,7 @@ public static Observable range(int start, int count) { *

* To convert any object into an Observable that emits that object, pass that object into the just method. *

- * This is similar to the {@link toObservable} method, except that toObservable will convert + * This is similar to the {@link #toObservable} method, except that toObservable will convert * an {@link Iterable} object into an Observable that emits each of the items in the {@link Iterable}, one * at a time, while the just method would convert the {@link Iterable} into an Observable * that emits the entire {@link Iterable} as a single item. @@ -647,9 +647,9 @@ public static Observable map(Observable sequence, Func1 func) * @return an Observable that is the result of applying the transformation function to each item * in the sequence emitted by the source Observable */ - public static Observable map(Observable sequence, final Object function) { + public static Observable map(Observable sequence, final Object func) { @SuppressWarnings("rawtypes") - final FuncN _f = Functions.from(function); + final FuncN _f = Functions.from(func); return map(sequence, new Func1() { @SuppressWarnings("unchecked") @@ -707,9 +707,9 @@ public static Observable mapMany(Observable sequence, Func1 Observable mapMany(Observable sequence, final Object function) { + public static Observable mapMany(Observable sequence, final Object func) { @SuppressWarnings("rawtypes") - final FuncN _f = Functions.from(function); + final FuncN _f = Functions.from(func); return mapMany(sequence, new Func1() { @SuppressWarnings("unchecked") @@ -726,10 +726,10 @@ public R call(T t1) { *

* * - * @param source + * @param sequence * An observable sequence of elements to project. * @return An observable sequence whose elements are the result of materializing the notifications of the given sequence. - * @see http://msdn.microsoft.com/en-us/library/hh229453(v=VS.103).aspx + * @see MSDN: Observable.Materialize */ public static Observable> materialize(final Observable sequence) { return _create(OperationMaterialize.materialize(sequence)); @@ -746,7 +746,7 @@ public static Observable> materialize(final Observable se * a list of Observables that emit sequences of items * @return an Observable that emits a sequence of elements that are the result of flattening the * output from the source list of Observables - * @see MSDN: Observable.Merge Method + * @see MSDN: Observable.Merge */ public static Observable merge(List> source) { return _create(OperationMerge.merge(source)); @@ -1003,7 +1003,7 @@ public Observable call(Exception e) { * * @param that * the source Observable - * @param resumeFunction + * @param resumeSequence * a function that returns an Observable that will take over if the source Observable * encounters an error * @return the source Observable, with its behavior modified as described @@ -1461,7 +1461,7 @@ public static Observable toObservable(Future future, long time, TimeUn *

* * - * @param iterable + * @param items * the source Array * @param * the type of items in the Array, and the type of items emitted by the resulting @@ -1612,7 +1612,7 @@ private static Observable sequenceEqual(Observable first, Observ * one source Observable * @param w1 * another source Observable - * @param reduceFunction + * @param function * a function that, when applied to an item emitted by each of the source Observables, * results in a value that will be emitted by the resulting Observable * @return an Observable that emits the zipped results @@ -1918,7 +1918,7 @@ public Observable call(T t1) { * * * @return An observable sequence whose elements are the result of materializing the notifications of the given sequence. - * @see http://msdn.microsoft.com/en-us/library/hh229453(v=VS.103).aspx + * @see MSDN: Observable.materialize */ public Observable> materialize() { return materialize(this); @@ -2050,8 +2050,7 @@ public Observable onErrorReturn(Func1 resumeFunction) { *

* You can use this to prevent errors from propagating or to supply fallback data should errors * be encountered. - * - * @param that + * * @param resumeFunction * @return the original Observable with appropriately modified behavior */ From 6dc501ac81fbd606f0d7cceae3f69f52ee4f3cd2 Mon Sep 17 00:00:00 2001 From: Ben Christensen Date: Thu, 14 Feb 2013 12:23:06 -0800 Subject: [PATCH 2/2] Add IntelliJ Idea support to Gradle build https://github.com/Netflix/RxJava/issues/143 --- language-adaptors/rxjava-clojure/build.gradle | 10 ++++++++-- language-adaptors/rxjava-groovy/build.gradle | 10 ++++++++-- language-adaptors/rxjava-jruby/build.gradle | 9 ++++++++- language-adaptors/rxjava-scala/build.gradle | 9 ++++++++- rxjava-core/build.gradle | 9 ++++++++- 5 files changed, 40 insertions(+), 7 deletions(-) diff --git a/language-adaptors/rxjava-clojure/build.gradle b/language-adaptors/rxjava-clojure/build.gradle index 0ff569c87d9..fdaa8f4857b 100644 --- a/language-adaptors/rxjava-clojure/build.gradle +++ b/language-adaptors/rxjava-clojure/build.gradle @@ -43,11 +43,17 @@ eclipse { } } +idea { + module { + // include 'provided' dependencies on the classpath + scopes.PROVIDED.plus += configurations.provided + } +} + -// setup Eclipse eclipse { classpath { - //you can tweak the classpath of the Eclipse project by adding extra configurations: + // include 'provided' dependencies on the classpath plusConfigurations += configurations.provided downloadSources = true diff --git a/language-adaptors/rxjava-groovy/build.gradle b/language-adaptors/rxjava-groovy/build.gradle index b0e21086119..3647f6af11d 100644 --- a/language-adaptors/rxjava-groovy/build.gradle +++ b/language-adaptors/rxjava-groovy/build.gradle @@ -24,13 +24,19 @@ configurations { // include 'examples' in build task build.dependsOn examplesClasses -// setup Eclipse eclipse { classpath { - //you can tweak the classpath of the Eclipse project by adding extra configurations: + // include 'provided' dependencies on the classpath plusConfigurations += configurations.provided downloadSources = true downloadJavadoc = true } +} + +idea { + module { + // include 'provided' dependencies on the classpath + scopes.PROVIDED.plus += configurations.provided + } } \ No newline at end of file diff --git a/language-adaptors/rxjava-jruby/build.gradle b/language-adaptors/rxjava-jruby/build.gradle index 17d2cb2f117..c86af4212a9 100644 --- a/language-adaptors/rxjava-jruby/build.gradle +++ b/language-adaptors/rxjava-jruby/build.gradle @@ -11,10 +11,17 @@ dependencies { eclipse { classpath { - //you can tweak the classpath of the Eclipse project by adding extra configurations: + // include 'provided' dependencies on the classpath plusConfigurations += configurations.provided downloadSources = true downloadJavadoc = true } +} + +idea { + module { + // include 'provided' dependencies on the classpath + scopes.PROVIDED.plus += configurations.provided + } } \ No newline at end of file diff --git a/language-adaptors/rxjava-scala/build.gradle b/language-adaptors/rxjava-scala/build.gradle index 25be45894de..edff7a24b1a 100644 --- a/language-adaptors/rxjava-scala/build.gradle +++ b/language-adaptors/rxjava-scala/build.gradle @@ -37,10 +37,17 @@ task test(overwrite: true, dependsOn: testClasses) << { eclipse { classpath { - //you can tweak the classpath of the Eclipse project by adding extra configurations: + // include 'provided' dependencies on the classpath plusConfigurations += configurations.provided downloadSources = true downloadJavadoc = true } +} + +idea { + module { + // include 'provided' dependencies on the classpath + scopes.PROVIDED.plus += configurations.provided + } } \ No newline at end of file diff --git a/rxjava-core/build.gradle b/rxjava-core/build.gradle index 499cae4e756..a77efe6907f 100644 --- a/rxjava-core/build.gradle +++ b/rxjava-core/build.gradle @@ -15,7 +15,7 @@ dependencies { eclipse { classpath { - //you can tweak the classpath of the Eclipse project by adding extra configurations: + // include 'provided' dependencies on the classpath plusConfigurations += configurations.provided downloadSources = true @@ -23,6 +23,13 @@ eclipse { } } +idea { + module { + // include 'provided' dependencies on the classpath + scopes.PROVIDED.plus += configurations.provided + } +} + javadoc { // we do not want the org.rx.operations package include exclude '**/operations/**'