RemoteParam (Apache Hadoop HDFS-RBF 3.5.0 API)
Description: declaration: package: org.apache.hadoop.hdfs.server.federation.router, class: RemoteParam

Package org.apache.hadoop.hdfs.server.federation.router

# Class RemoteParam

java.lang.Object
org.apache.hadoop.hdfs.server.federation.router.RemoteParam

public class RemoteParam extends Object
A dynamically assignable parameter that is location-specific.

There are 2 ways this mapping is determined:

- Default: Uses the RemoteLocationContext's destination
- Map: Uses the value of the RemoteLocationContext key provided in the parameter map.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `RemoteParam()`
  Constructs a default remote parameter.
  `RemoteParam(Map<? extends RemoteLocationContext,? extends Object> map)`
  Constructs a map based remote parameter.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Object`
  `getParameterForContext(RemoteLocationContext context)`
  Determine the appropriate value for this parameter based on the location.
  `String`
  `toString()`

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

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

- ## Constructor Details

  - ### RemoteParam

    public RemoteParam()
    Constructs a default remote parameter. Always maps the value to the destination of the provided RemoteLocationContext.

  - ### RemoteParam

    public RemoteParam(Map<? extends RemoteLocationContext,? extends Object> map)
    Constructs a map based remote parameter. Determines the value using the provided RemoteLocationContext as a key into the map.
    Parameters:
      `map` - Map with RemoteLocationContext keys.

- ## Method Details

  - ### getParameterForContext

    public Object getParameterForContext(RemoteLocationContext context)
    Determine the appropriate value for this parameter based on the location.
    Parameters:
      `context` - Context identifying the location.
    Returns:
      A parameter specific to this location.

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`