org.apache.ignite.internal.managers.discovery

## Class DiscoveryMessageResultsCollector<M,R>

- java.lang.Object
- - org.apache.ignite.internal.managers.discovery.DiscoveryMessageResultsCollector<M,R>

    public abstract class DiscoveryMessageResultsCollector<M,R>
    extends Object

### Nested Class Summary

Nested Classes
`protected static class` `DiscoveryMessageResultsCollector.NodeMessage<M>`

### Field Summary

Fields
`protected GridKernalContext` `ctx`
`protected DiscoCache` `discoCache`

### Constructor Summary

Constructors
`protected` `DiscoveryMessageResultsCollector(GridKernalContext ctx)`

### Method Summary

All Methods Instance Methods Abstract Methods Concrete Methods
`protected abstract R` `createResult(Map<UUID,DiscoveryMessageResultsCollector.NodeMessage<M>> rcvd)`
`void` `init(DiscoCache discoCache)`
`void` `onMessage(UUID nodeId, M msg)`
`void` `onNodeFail(UUID nodeId)`
`protected abstract void` `onResultsCollected(R r)`
`String` `toString()`
`protected abstract boolean` `waitForNode(DiscoCache discoCache, ClusterNode node)`

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

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

### Field Detail

#### discoCache

    protected DiscoCache discoCache

#### ctx

    protected final GridKernalContext ctx

### Constructor Detail

#### DiscoveryMessageResultsCollector

    protected DiscoveryMessageResultsCollector(GridKernalContext ctx)

Parameters:
  `ctx` - Context.

### Method Detail

#### createResult

    protected abstract R createResult(Map<UUID,DiscoveryMessageResultsCollector.NodeMessage<M>> rcvd)

Parameters:
  `rcvd` - Received messages.
Returns:
  Result.

#### onResultsCollected

    protected abstract void onResultsCollected(R r)

Parameters:
  `r` - Result.

#### waitForNode

    protected abstract boolean waitForNode(DiscoCache discoCache,
                                           ClusterNode node)

Parameters:
  `discoCache` - Discovery state when discovery message was received.
  `node` - Node.
Returns:
  `True` if need wait for result from given node.

#### init

    public final void init(DiscoCache discoCache)

Parameters:
  `discoCache` - Discovery state.

#### onMessage

    public final void onMessage(UUID nodeId,
                                M msg)

Parameters:
  `nodeId` - Node ID.
  `msg` - Message.

#### onNodeFail

    public final void onNodeFail(UUID nodeId)

Parameters:
  `nodeId` - Failed node ID.

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

${current.year} Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.16.0
Release Date | : December 15 2023