Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(275)

Unified Diff: mojo/public/java/bindings/src/org/chromium/mojo/bindings/Callbacks.java

Issue 607933002: mojo: Fix java generator (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix findbugs and emptu package. Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: mojo/public/java/bindings/src/org/chromium/mojo/bindings/Callbacks.java
diff --git a/mojo/public/java/bindings/src/org/chromium/mojo/bindings/Callbacks.java b/mojo/public/java/bindings/src/org/chromium/mojo/bindings/Callbacks.java
index 87b9abdcd7317f6ee92a177fe99ff41eed106241..c6b14c14944df9460f6630257a2734aa8d46cd06 100644
--- a/mojo/public/java/bindings/src/org/chromium/mojo/bindings/Callbacks.java
+++ b/mojo/public/java/bindings/src/org/chromium/mojo/bindings/Callbacks.java
@@ -13,107 +13,117 @@ package org.chromium.mojo.bindings;
public interface Callbacks {
/**
- * A generic 1-argument callback.
- *
- * @param <T1> the type of argument 1.
- */
+ * A generic callback.
+ */
+ interface Callback0 {
+ /**
+ * Call the callback.
+ */
+ public void call();
+ }
+
+ /**
+ * A generic 1-argument callback.
+ *
+ * @param <T1> the type of argument 1.
+ */
interface Callback1<T1> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1);
}
/**
- * A generic 2-argument callback.
- *
- * @param <T1> the type of argument 1.
+ * A generic 2-argument callback.
+ *
+ * @param <T1> the type of argument 1.
* @param <T2> the type of argument 2.
- */
+ */
interface Callback2<T1, T2> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1, T2 arg2);
}
/**
- * A generic 3-argument callback.
- *
- * @param <T1> the type of argument 1.
+ * A generic 3-argument callback.
+ *
+ * @param <T1> the type of argument 1.
* @param <T2> the type of argument 2.
* @param <T3> the type of argument 3.
- */
+ */
interface Callback3<T1, T2, T3> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1, T2 arg2, T3 arg3);
}
/**
- * A generic 4-argument callback.
- *
- * @param <T1> the type of argument 1.
+ * A generic 4-argument callback.
+ *
+ * @param <T1> the type of argument 1.
* @param <T2> the type of argument 2.
* @param <T3> the type of argument 3.
* @param <T4> the type of argument 4.
- */
+ */
interface Callback4<T1, T2, T3, T4> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1, T2 arg2, T3 arg3, T4 arg4);
}
/**
- * A generic 5-argument callback.
- *
- * @param <T1> the type of argument 1.
+ * A generic 5-argument callback.
+ *
+ * @param <T1> the type of argument 1.
* @param <T2> the type of argument 2.
* @param <T3> the type of argument 3.
* @param <T4> the type of argument 4.
* @param <T5> the type of argument 5.
- */
+ */
interface Callback5<T1, T2, T3, T4, T5> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5);
}
/**
- * A generic 6-argument callback.
- *
- * @param <T1> the type of argument 1.
+ * A generic 6-argument callback.
+ *
+ * @param <T1> the type of argument 1.
* @param <T2> the type of argument 2.
* @param <T3> the type of argument 3.
* @param <T4> the type of argument 4.
* @param <T5> the type of argument 5.
* @param <T6> the type of argument 6.
- */
+ */
interface Callback6<T1, T2, T3, T4, T5, T6> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6);
}
/**
- * A generic 7-argument callback.
- *
- * @param <T1> the type of argument 1.
+ * A generic 7-argument callback.
+ *
+ * @param <T1> the type of argument 1.
* @param <T2> the type of argument 2.
* @param <T3> the type of argument 3.
* @param <T4> the type of argument 4.
* @param <T5> the type of argument 5.
* @param <T6> the type of argument 6.
* @param <T7> the type of argument 7.
- */
+ */
interface Callback7<T1, T2, T3, T4, T5, T6, T7> {
/**
- * Call the callback.
- */
+ * Call the callback.
+ */
public void call(T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7);
}

Powered by Google App Engine
This is Rietveld 408576698