org.apache.hadoop.hdfs.server.common.blockaliasmap

## Class BlockAliasMap.Reader<U extends BlockAlias>

- java.lang.Object
- - org.apache.hadoop.hdfs.server.common.blockaliasmap.BlockAliasMap.Reader<U>

- All Implemented Interfaces:
    Closeable, AutoCloseable, Iterable<U>
  Direct Known Subclasses:
    LevelDBFileRegionAliasMap.LevelDBReader, TextFileRegionAliasMap.TextReader
  Enclosing class:
    BlockAliasMap<T extends BlockAlias>

      public abstract static class BlockAliasMap.Reader<U extends BlockAlias>
      extends Object
      implements Iterable<U>, Closeable

  An abstract class that is used to read `BlockAlias`es for provided blocks.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static interface` | `BlockAliasMap.Reader.Options` reader options.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Reader()`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract Optional<U>` | `resolve(org.apache.hadoop.hdfs.protocol.Block ident)`

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

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface java.lang.Iterable

      `forEach, iterator, spliterator`

    - ### Methods inherited from interface java.io.Closeable

      `close`

- - ### Constructor Detail

    - #### Reader

          public Reader()

  - ### Method Detail

    - #### resolve

          public abstract Optional<U> resolve(org.apache.hadoop.hdfs.protocol.Block ident)
                                       throws IOException

      Parameters:
        `ident` - block to resolve
      Returns:
        BlockAlias corresponding to the provided block.
      Throws:
        `IOException`

Copyright © 2008–2022 Apache Software Foundation. All rights reserved.