Published 15 October 2018

PoolInfoGet

Getting the block content with hash value and index number.

Parameters

Parameters:

1: PoolHash hash

2: i64 index

Type of result: PoolInfoGetResult

Operation algorithm

Operation algorithm:

We download the block with the transmitted hash value to the pool.

We set the block found boolean flag in the result structure equal to the block validity boolean flag.

If the block has been found, then we download the block, convert and save it in the result structure pool.

We set the result status equal to SUCCESS.

Data structure

The following structures are used for marshalling purposes:

PoolInfoGetResult pool information get result

APIResponse status

status

i8 code //status code

string message //status communication

bool isFound

pool transactions found boolean flag

Pool pool

pool content

Example

Example

/** PoolInfoGet begin */

 

PoolHash                  ph;

PoolInfoGetResult    pig_res;

 

try

{

         api->PoolInfoGet(pig_res, ph, 0);

}

catch (...)

{

         return 1;

}

 

pig_res.printTo(std::cout);

std::cout << std::endl << std::endl;

 

/** PoolInfoGet end */

16 Useful article

Contents