- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 197 for checkArgument (0.23 sec)
-
guava-tests/benchmark/com/google/common/collect/SortedCopyBenchmark.java
* or implied. See the License for the specific language governing permissions and limitations under * the License. */ package com.google.common.collect; import static com.google.common.base.Preconditions.checkArgument; import static java.util.Collections.sort; import com.google.caliper.BeforeExperiment; import com.google.caliper.Benchmark; import com.google.caliper.Param; import java.util.ArrayList;
Registered: 2024-11-01 12:43 - Last Modified: 2024-10-30 16:15 - 3.5K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/testing/ArbitraryInstances.java
private static <T> void setImplementation(Class<T> type, Class<? extends T> implementation) { checkArgument(type != implementation, "Don't register %s to itself!", type); checkArgument( !DEFAULTS.containsKey(type), "A default value was already registered for %s", type); checkArgument( implementations.put(type, implementation) == null, "Implementation for %s was already registered",
Registered: 2024-11-01 12:43 - Last Modified: 2024-10-19 00:26 - 20.8K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/testing/ForwardingWrapperTester.java
* See the License for the specific language governing permissions and * limitations under the License. */ package com.google.common.testing; import static com.google.common.base.Preconditions.checkArgument; import static com.google.common.base.Preconditions.checkNotNull; import static com.google.common.base.Throwables.throwIfUnchecked; import static junit.framework.Assert.assertEquals; import static junit.framework.Assert.fail;
Registered: 2024-11-01 12:43 - Last Modified: 2024-10-17 13:00 - 9.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/base/PreconditionsTest.java
public class PreconditionsTest extends TestCase { public void testCheckArgument_simple_success() { checkArgument(true); } public void testCheckArgument_simple_failure() { assertThrows(IllegalArgumentException.class, () -> checkArgument(false)); } public void testCheckArgument_simpleMessage_success() { checkArgument(true, IGNORE_ME); } public void testCheckArgument_simpleMessage_failure() {
Registered: 2024-11-01 12:43 - Last Modified: 2024-09-17 18:14 - 19K bytes - Viewed (0) -
guava/src/com/google/common/net/HostAndPort.java
* of range. */ public static HostAndPort fromParts(String host, int port) { checkArgument(isValidPort(port), "Port out of range: %s", port); HostAndPort parsedHost = fromString(host); checkArgument(!parsedHost.hasPort(), "Host has a port: %s", host); return new HostAndPort(parsedHost.host, port, parsedHost.hasBracketlessColons); } /**
Registered: 2024-11-01 12:43 - Last Modified: 2024-07-22 22:02 - 11.3K bytes - Viewed (0) -
guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/MapMaker.java
* See the License for the specific language governing permissions and * limitations under the License. */ package com.google.common.collect; import static com.google.common.base.Preconditions.checkArgument; import com.google.errorprone.annotations.CanIgnoreReturnValue; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentMap; /** * MapMaker emulation. *
Registered: 2024-11-01 12:43 - Last Modified: 2024-01-23 18:43 - 1.7K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/AbstractMapBasedMultiset.java
* See the License for the specific language governing permissions and * limitations under the License. */ package com.google.common.collect; import static com.google.common.base.Preconditions.checkArgument; import static com.google.common.base.Preconditions.checkNotNull; import static com.google.common.collect.CollectPreconditions.checkNonnegative; import com.google.common.annotations.GwtCompatible;
Registered: 2024-11-01 12:43 - Last Modified: 2023-03-06 16:06 - 8.2K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/SimpleAbstractMultisetTest.java
} @Override public int add(E element, int occurrences) { checkArgument(occurrences >= 0); Integer frequency = backingMap.get(element); if (frequency == null) { frequency = 0; } if (occurrences == 0) { return frequency; } checkArgument(occurrences <= Integer.MAX_VALUE - frequency); backingMap.put(element, frequency + occurrences);
Registered: 2024-11-01 12:43 - Last Modified: 2024-10-15 17:36 - 5.6K bytes - Viewed (0) -
android/guava/src/com/google/common/graph/StandardMutableNetwork.java
checkArgument( existingIncidentNodes.equals(newIncidentNodes), REUSING_EDGE, edge, existingIncidentNodes, newIncidentNodes); return false; } NetworkConnections<N, E> connectionsU = nodeConnections.get(nodeU); if (!allowsParallelEdges()) { checkArgument(
Registered: 2024-11-01 12:43 - Last Modified: 2021-04-26 17:43 - 5.7K bytes - Viewed (0) -
android/guava/src/com/google/common/math/DoubleUtils.java
* or implied. See the License for the specific language governing permissions and limitations under * the License. */ package com.google.common.math; import static com.google.common.base.Preconditions.checkArgument; import static java.lang.Double.MAX_EXPONENT; import static java.lang.Double.MIN_EXPONENT; import static java.lang.Double.POSITIVE_INFINITY; import static java.lang.Double.doubleToRawLongBits;
Registered: 2024-11-01 12:43 - Last Modified: 2024-10-19 00:26 - 5.1K bytes - Viewed (0)