This commit is contained in:
Alexey Kudravtsev
2013-10-04 15:43:47 +04:00
parent f4e2842b93
commit 119fcb023f
2 changed files with 5 additions and 4 deletions
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2012 JetBrains s.r.o.
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -233,7 +233,8 @@ public class ContainerUtilRt {
}
/**
* Optimized toArray() as opposed to the {@link java.util.Collections#emptyList()}.
* A variant of {@link java.util.Collections#emptyList()},
* except that {@link #toArray()} here does not create garbage <code>new Object[0]</code> constantly.
*/
private static class EmptyList<T> extends AbstractList<T> implements RandomAccess {
private static final EmptyList INSTANCE = new EmptyList();
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2009 JetBrains s.r.o.
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -19,7 +19,7 @@ import java.util.Enumeration;
import java.util.NoSuchElementException;
/**
* Copy of java.util.StringTokenizer with getCurrentPosition method.
* Copy of {@link java.util.StringTokenizer} with added {@link #getCurrentPosition()} and {@link #reset(String)} methods.
*/
public class StringTokenizer implements Enumeration<String> {
private int currentPosition;