ParagonIE\Halite\Structure\Node::getData PHP Method

getData() public method

Get the data
public getData ( ) : string
return string
    public function getData() : string
    {
        return $this->data;
    }

Usage Example

Example #1
0
 public function testHash()
 {
     $stringData = \random_bytes(32);
     $hash = \Sodium\crypto_generichash($stringData);
     $node = new Node($stringData);
     $this->assertSame($stringData, $node->getData());
     $this->assertSame($hash, $node->getHash(true));
 }