Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.portal.common.util
Class MapAdapters

    java.lang.Object
      org.jboss.portal.common.util.MapAdapters

    public class MapAdapters

extends java.lang.Object

A collection of various map adapters.

Version:
  $Revision: 630 $
Author:
  Julien Viet

Constructor Summary
`MapAdapters()`

Method Summary
`static
`<K,V> java.util.Map<K,V>`
` | `adapt(java.util.Map<K,V[]> adapted, java.lang.Class<? extends V> type)`
`static java.util.Map<java.lang.String,java.lang.String>` | `adapt(java.util.Map<java.lang.String,java.lang.String[]> adapted)` Adapt a `Map` map as a `Map` map.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### MapAdapters

    public MapAdapters()

Method Detail

### adapt

    public static <K,V> java.util.Map<K,V> adapt(java.util.Map<K,V[]> adapted,
                                                 java.lang.Class<? extends V> type)

### adapt

    public static java.util.Map<java.lang.String,java.lang.String> adapt(java.util.Map<java.lang.String,java.lang.String[]> adapted)

  Adapt a `Map` map as a `Map` map. The adapted map must not contain null string array or zero lenght string array, if the map contains such values then the map state is considered as not valid and `IllegalStateException` can be thrown when the adapted map

  is used.

  The adapted map is writable but does not accept null values for write operations. On a put operation the adapted map will receive a put operation with a string array of length one containing the provided value.

  Parameters:
    `adapted` - the adapted map
  Returns:
    the adapter

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008. All Rights Reserved.