org.gitana.platform.support

## Class ResultMapImpl<V>

- java.lang.Object
- - java.util.AbstractMap<K,V>
  - - java.util.HashMap<K,V>
    - - java.util.LinkedHashMap<String,V>
      - - org.gitana.platform.support.ResultMapImpl<V>

All Implemented Interfaces:
  Serializable, Cloneable, Map<String,V>, Paginated, ResultMap<V>

    public class ResultMapImpl<V>
    extends LinkedHashMap<String,V>
    implements ResultMap<V>

Author:
  uzi
See Also:
  Serialized Form

### Nested Class Summary

### Nested classes/interfaces inherited from class java.util.AbstractMap

`AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>`

### Nested classes/interfaces inherited from interface java.util.Map

`Map.Entry<K,V>`

### Constructor Summary

Constructors
Constructor and Description
`ResultMapImpl()`
`ResultMapImpl(int offset, int totalRows)`
`ResultMapImpl(Map<String,V> map)`
`ResultMapImpl(Pagination pagination, int totalRows)`

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `adjustOffset(int newOffset)`
`void` `adjustTotalRows(int newTotalRows)`
`List<V>` `asList()`
`List<String>` `keyList()`
`int` `offset()`
`int` `totalRows()`

### Methods inherited from class java.util.LinkedHashMap

`clear, containsValue, entrySet, forEach, get, getOrDefault, keySet, removeEldestEntry, replaceAll, values`

### Methods inherited from class java.util.HashMap

`clone, compute, computeIfAbsent, computeIfPresent, containsKey, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, size`

### Methods inherited from class java.util.AbstractMap

`equals, hashCode, toString`

### Methods inherited from class java.lang.Object

`finalize, getClass, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface java.util.Map

`clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values`

### Methods inherited from interface org.gitana.platform.support.Paginated

`size`

### Constructor Detail

#### ResultMapImpl

    public ResultMapImpl()

#### ResultMapImpl

    public ResultMapImpl(Map<String,V> map)

#### ResultMapImpl

    public ResultMapImpl(int offset,
                         int totalRows)

#### ResultMapImpl

    public ResultMapImpl(Pagination pagination,
                         int totalRows)

### Method Detail

#### totalRows

    public int totalRows()

Specified by:
  `totalRows` in interface `Paginated`
Specified by:
  `totalRows` in interface `ResultMap<V>`
Returns:
  total number of rows available in the database

#### offset

    public int offset()

Specified by:
  `offset` in interface `Paginated`
Specified by:
  `offset` in interface `ResultMap<V>`
Returns:
  the offset into the database results

#### keyList

    public List<String> keyList()

Specified by:
  `keyList` in interface `ResultMap<V>`
Returns:
  a thread-safe copy of the keys of this map

#### asList

    public List<V> asList()

Specified by:
  `asList` in interface `ResultMap<V>`
Returns:
  values as a list

#### adjustOffset

    public void adjustOffset(int newOffset)

#### adjustTotalRows

    public void adjustTotalRows(int newTotalRows)