Moved MapUtil and its test class to org.jboss.netty.bootstrap because it's used only there

This commit is contained in:
Trustin Lee 2010-01-14 11:58:50 +00:00
parent 0dbea6f162
commit 23943ac256
3 changed files with 5 additions and 5 deletions

View File

@ -29,7 +29,6 @@ import org.jboss.netty.channel.ChannelPipeline;
import org.jboss.netty.channel.ChannelPipelineCoverage; import org.jboss.netty.channel.ChannelPipelineCoverage;
import org.jboss.netty.channel.ChannelPipelineFactory; import org.jboss.netty.channel.ChannelPipelineFactory;
import org.jboss.netty.util.ExternalResourceReleasable; import org.jboss.netty.util.ExternalResourceReleasable;
import org.jboss.netty.util.internal.MapUtil;
/** /**
* A helper class which initializes a {@link Channel}. This class provides * A helper class which initializes a {@link Channel}. This class provides

View File

@ -13,7 +13,7 @@
* License for the specific language governing permissions and limitations * License for the specific language governing permissions and limitations
* under the License. * under the License.
*/ */
package org.jboss.netty.util.internal; package org.jboss.netty.bootstrap;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Iterator; import java.util.Iterator;
@ -29,14 +29,14 @@ import java.util.Map;
* *
* @version $Rev$, $Date$ * @version $Rev$, $Date$
*/ */
public class MapUtil { class MapUtil {
/** /**
* Returns {@code true} if and only if the specified {@code map} is an * Returns {@code true} if and only if the specified {@code map} is an
* ordered map, like {@link LinkedHashMap} is. * ordered map, like {@link LinkedHashMap} is.
*/ */
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
public static boolean isOrderedMap(Map<?, ?> map) { static boolean isOrderedMap(Map<?, ?> map) {
Class<?> mapType = map.getClass(); Class<?> mapType = map.getClass();
if (LinkedHashMap.class.isAssignableFrom(mapType)) { if (LinkedHashMap.class.isAssignableFrom(mapType)) {
// LinkedHashMap is an ordered map. // LinkedHashMap is an ordered map.

View File

@ -13,7 +13,7 @@
* License for the specific language governing permissions and limitations * License for the specific language governing permissions and limitations
* under the License. * under the License.
*/ */
package org.jboss.netty.util.internal; package org.jboss.netty.bootstrap;
import static org.junit.Assert.*; import static org.junit.Assert.*;
@ -25,6 +25,7 @@ import java.util.Set;
import java.util.logging.Level; import java.util.logging.Level;
import java.util.logging.Logger; import java.util.logging.Logger;
import org.jboss.netty.bootstrap.MapUtil;
import org.junit.Test; import org.junit.Test;