Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add j2cl specializers for Doubles.min/max, Floats.min/max, Ints.min/m…
…ax, and Shorts.min/max. RELNOTES=n/a ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=304448129
- Loading branch information
1 parent
d86c850
commit c34f584
Showing
32 changed files
with
364 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
android/guava/src/com/google/common/primitives/DoublesMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import com.google.common.annotations.GwtCompatible; | ||
|
||
/** | ||
* Holder for web specializations of methods of {@code Doubles}. Intended to be empty for regular | ||
* version. | ||
*/ | ||
@GwtCompatible(emulated = true) | ||
abstract class DoublesMethodsForWeb {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
android/guava/src/com/google/common/primitives/FloatsMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import com.google.common.annotations.GwtCompatible; | ||
|
||
/** | ||
* Holder for web specializations of methods of {@code Floats}. Intended to be empty for regular | ||
* version. | ||
*/ | ||
@GwtCompatible(emulated = true) | ||
abstract class FloatsMethodsForWeb {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
android/guava/src/com/google/common/primitives/IntsMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import com.google.common.annotations.GwtCompatible; | ||
|
||
/** | ||
* Holder for web specializations of methods of {@code Ints}. Intended to be empty for regular | ||
* version. | ||
*/ | ||
@GwtCompatible(emulated = true) | ||
abstract class IntsMethodsForWeb {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
android/guava/src/com/google/common/primitives/ShortsMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import com.google.common.annotations.GwtCompatible; | ||
|
||
/** | ||
* Holder for web specializations of methods of {@code Shorts}. Intended to be empty for regular | ||
* version. | ||
*/ | ||
@GwtCompatible(emulated = true) | ||
abstract class ShortsMethodsForWeb {} |
28 changes: 28 additions & 0 deletions
28
...com/google/common/primitives/super/com/google/common/primitives/DoublesMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import jsinterop.annotations.JsMethod; | ||
import jsinterop.annotations.JsPackage; | ||
|
||
/** Web specializations for {@link Doubles} methods. */ | ||
abstract class DoublesMethodsForWeb { | ||
|
||
@JsMethod(name = "Math.min", namespace = JsPackage.GLOBAL) | ||
public static native double min(double... array); | ||
|
||
@JsMethod(name = "Math.max", namespace = JsPackage.GLOBAL) | ||
public static native double max(double... array); | ||
} |
28 changes: 28 additions & 0 deletions
28
.../com/google/common/primitives/super/com/google/common/primitives/FloatsMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import jsinterop.annotations.JsMethod; | ||
import jsinterop.annotations.JsPackage; | ||
|
||
/** Web specializations for {@link Floats} methods. */ | ||
abstract class FloatsMethodsForWeb { | ||
|
||
@JsMethod(name = "Math.min", namespace = JsPackage.GLOBAL) | ||
public static native float min(float... array); | ||
|
||
@JsMethod(name = "Math.max", namespace = JsPackage.GLOBAL) | ||
public static native float max(float... array); | ||
} |
28 changes: 28 additions & 0 deletions
28
...er/com/google/common/primitives/super/com/google/common/primitives/IntsMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import jsinterop.annotations.JsMethod; | ||
import jsinterop.annotations.JsPackage; | ||
|
||
/** Web specializations for {@link Ints} methods. */ | ||
abstract class IntsMethodsForWeb { | ||
|
||
@JsMethod(name = "Math.min", namespace = JsPackage.GLOBAL) | ||
public static native int min(int... array); | ||
|
||
@JsMethod(name = "Math.max", namespace = JsPackage.GLOBAL) | ||
public static native int max(int... array); | ||
} |
28 changes: 28 additions & 0 deletions
28
.../com/google/common/primitives/super/com/google/common/primitives/ShortsMethodsForWeb.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (C) 2020 The Guava Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | ||
* in compliance with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software distributed under the License | ||
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express | ||
* or implied. See the License for the specific language governing permissions and limitations under | ||
* the License. | ||
*/ | ||
|
||
package com.google.common.primitives; | ||
|
||
import jsinterop.annotations.JsMethod; | ||
import jsinterop.annotations.JsPackage; | ||
|
||
/** Web specializations for {@link Shorts} methods. */ | ||
abstract class ShortsMethodsForWeb { | ||
|
||
@JsMethod(name = "Math.min", namespace = JsPackage.GLOBAL) | ||
public static native short min(short... array); | ||
|
||
@JsMethod(name = "Math.max", namespace = JsPackage.GLOBAL) | ||
public static native short max(short... array); | ||
} |
Oops, something went wrong.