- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 97 for clone (0.85 sec)
-
guava/src/com/google/common/collect/ImmutableEnumSet.java
} } /* * Notes on EnumSet and <E extends Enum<E>>: * * This class isn't an arbitrary ForwardingImmutableSet because we need to * know that calling {@code clone()} during deserialization will return an * object that no one else has a reference to, allowing us to guarantee * immutability. Hence, we support only {@link EnumSet}. */ private final transient EnumSet<E> delegate;
Java - Registered: Fri Apr 05 12:43:09 GMT 2024 - Last Modified: Mon Apr 01 16:15:01 GMT 2024 - 4.5K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/Helpers.java
@GwtCompatible(emulated = true) @ElementTypesAreNonnullByDefault public class Helpers { // Clone of Objects.equal static boolean equal(@Nullable Object a, @Nullable Object b) { return a == b || (a != null && a.equals(b)); } // Clone of Lists.newArrayList public static <E extends @Nullable Object> List<E> copyToList(Iterable<? extends E> elements) {
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Mon Feb 26 19:46:10 GMT 2024 - 17.7K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
oos.writeObject(o); oos.flush(); oos.close(); ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(bos.toByteArray())); T clone = (T) ois.readObject(); assertSame(o.getClass(), clone.getClass()); return clone; } catch (Throwable t) { threadUnexpectedException(t); return null; } }
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Thu Feb 22 17:15:24 GMT 2024 - 37.7K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/io/ByteSourceTest.java
private static final ByteSource BROKEN_CLOSE_SOURCE = new TestByteSource(new byte[10], CLOSE_THROWS); private static final ByteSource BROKEN_OPEN_SOURCE = new TestByteSource(new byte[10], OPEN_THROWS); private static final ByteSource BROKEN_READ_SOURCE = new TestByteSource(new byte[10], READ_THROWS); private static final ByteSink BROKEN_CLOSE_SINK = new TestByteSink(CLOSE_THROWS);
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 16.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/io/ByteSourceTest.java
private static final ByteSource BROKEN_CLOSE_SOURCE = new TestByteSource(new byte[10], CLOSE_THROWS); private static final ByteSource BROKEN_OPEN_SOURCE = new TestByteSource(new byte[10], OPEN_THROWS); private static final ByteSource BROKEN_READ_SOURCE = new TestByteSource(new byte[10], READ_THROWS); private static final ByteSink BROKEN_CLOSE_SINK = new TestByteSink(CLOSE_THROWS);
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 16.9K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/MinimalCollection.java
MinimalCollection(Class<? super @NonNull E> type, boolean allowNulls, E... contents) { // TODO: consider making it shuffle the contents to test iteration order. this.contents = Platform.clone(contents); this.type = type; this.allowNulls = allowNulls; if (!allowNulls) { for (Object element : contents) { if (element == null) { throw new NullPointerException();
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Wed Feb 21 16:49:06 GMT 2024 - 3.8K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableSortedSet.java
* @since 3.0 */ public static <E extends Comparable<? super E>> ImmutableSortedSet<E> copyOf(E[] elements) { return construct(Ordering.natural(), elements.length, elements.clone()); } /** * Returns an immutable sorted set containing the given elements sorted by their natural ordering. * When multiple elements are equivalent according to {@code compareTo()}, only the first one
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Wed May 01 18:44:57 GMT 2024 - 36.9K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
oos.writeObject(o); oos.flush(); oos.close(); ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(bos.toByteArray())); T clone = (T) ois.readObject(); assertSame(o.getClass(), clone.getClass()); return clone; } catch (Throwable t) { threadUnexpectedException(t); return null; } }
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Thu Feb 22 17:15:24 GMT 2024 - 37.2K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/primitives/UnsignedBytesTest.java
UnsignedBytes.lexicographicalComparatorJavaImpl())) { for (int trials = 10; trials-- > 0; ) { byte[] left = new byte[1 + rnd.nextInt(32)]; rnd.nextBytes(left); byte[] right = left.clone(); assertThat(comparator.compare(left, right)).isEqualTo(0); int i = rnd.nextInt(left.length); left[i] ^= (byte) (1 + rnd.nextInt(255));
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Tue Feb 20 17:00:05 GMT 2024 - 13.4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/reflect/TypesTest.java
.asList() .containsExactlyElementsIn(asList(expected.getBounds())) .inOrder(); } /** * Working with arrays requires defensive code. Verify that we clone the type array for both input * and output. */ public void testNewParameterizedTypeImmutability() { Type[] typesIn = {String.class, Integer.class};
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Thu Feb 22 17:15:24 GMT 2024 - 14.8K bytes - Viewed (0)