Loads outline from provided outline hash.

@param array   $hash Outline hash
@param integer $line Outline definition line

@return OutlineNode
970793
protected function loadOutlineHash(array $hash, $line = 0)
    {
        $hash = array_merge(
            array(
                'title' => null,
                'tags' => array(),
                'keyword' => 'Scenario Outline',
                'line' => $line,
                'steps' => array(),
                'examples' => array(),
            ),
            $hash
        );

        $steps = $this->loadStepsHash($hash['steps']);

        if (isset($hash['examples']['keyword'])) {
            $examplesKeyword = $hash['examples']['keyword'];
            unset($hash['examples']['keyword']);
        } else {
            $examplesKeyword = 'Examples';
        }

        $examples = new ExampleTableNode($hash['examples'], $examplesKeyword);

        return new OutlineNode($hash['title'], $hash['tags'], $steps, $examples, $hash['keyword'], $hash['line']);
    }
796810
public function fromHash($hash)
    {
        if ($hash === null) {
            return $this->getEmptyValue();
        }

        if (isset($hash['text'])) {
            return new Value($hash['link'], $hash['text']);
        }

        return new Value($hash['link']);
    }
763876
public function setHash($hash)
    {
        if (!is_string($hash)) {
            throw new \InvalidArgumentException(
                'An invalid $hash was passed to Identicon. ' .
                'A binary string was expected.');
        }
        if (strlen($hash) < 6) {
            throw new \InvalidArgumentException(
                'An invalid $hash was passed to Identicon. ' . 
                'The hash was expected to contain at least 6 bytes.');
        }
        
        $this->hash = $hash;
        $this->value = null;
        $this->valueSet = false;
        return $this;
    }
1356199
public function urlHash($hash = null, $withHash = true)
    {
        if ($hash) {
            $this->set('urlHash', ltrim($hash, '#'));
        }

        $hash = $this->get('urlHash', '');

        return $withHash && !empty($hash) ? '#' . $hash : $hash;
    }
229501
public function addNode($hash, $node)
    {
        $vertex = new stdClass();

        $vertex->hash           = $hash;
        $vertex->state          = self::NOT_VISITED;
        $vertex->value          = $node;
        $vertex->dependencyList = [];

        $this->nodeList[$hash] = $vertex;
    }
891088
private function getStreamHash($stream, $hash = 'md5')
    {
        $hc = hash_init($hash);
        hash_update_stream($hc, $stream);
        return hash_final($hc);
    }
1301220
private function _make_hash(): string
  {
    $args = \func_get_args();
    if ( (\count($args) === 1) && \is_array($args[0]) ){
      $args = $args[0];
    }
    $st = '';
    foreach ( $args as $a ){
      $st .= \is_array($a) ? serialize($a) : '--'.$a.'--';
    }
    return $this->hash_contour.md5($st).$this->hash_contour;
  }
1280290
public function byName($hash) {
		if($this->loaded == false) {
			$this->items = $this->getReferences();
			$this->loaded = true;
		}
		// The item might not be in the list because of the limit, try to find
		// in an older version and add it to the list.
		if(!isset($this->items[$hash])) {
			$repository = new Gitonomy\Git\Repository($this->project->LocalCVSPath);
			$commit = new Gitonomy\Git\Commit($repository, $hash);
			$this->items[$hash] = DNCommit::create($commit, $this->project, $this->data);
		};

		return $this->items[$hash];
	}
872741
public static function Serialize($hash){
		if(is_null($hash))
			return null;
		$res=Array();
		$keys=array_keys($hash);
		$i=-1;
		$len=sizeof($keys);
		while(++$i<$len)
			$res[]=new PhpWsdlHash($keys[$i],$hash[$keys[$i]]);
		return $res;
	}
937282
public function retrieve ($hash)
    {
        $colHash = $this->columns['hash'];
        $colExpires = $this->columns['expires'];
        $colToken = $this->columns['token'];

        $sql = "SELECT `{$colToken}`, `{$colExpires}` FROM `{$this->table}` WHERE `{$colHash}` = ? LIMIT 1";
        $st = $this->pdo->prepare($sql);
        $st->execute([hex2bin($hash)]);
        $row = $st->fetch(PDO::FETCH_ASSOC);
        $st->closeCursor();

        if (is_array($row)) {
            return new AccessToken($row[$colToken], DateTime::createFromFormat('U', $row[$colExpires]));
        } else {
            return null;
        }
    }
398339
public function getByHash($hash)
    {

        foreach($this->fs as $file){
            if($file->getHash() == $hash){
                return $file;
            }
        }

    }
126307
def load_branches
      Hash[@grit_repo.branches.map { |b| [b.name, b.commit.id] }]
    end
142535
public function getInfoByHash($hash)
       {
            $index = array_search($hash, $this->map, true);
            if (false !== $index) {
                return $this->getInfoByKey($index);
            }
       }
1096814
function (hash) {
            var iframe = this._iframe;
            if (!iframe) {
                return;
            }
            hash = hash || "";
            if (this._currentIframeHashString != hash) {
                var src = ['javascript:document.open();'];
                src.push('document.write(\"<script type=\\\"text/javascript\\\">');
                if (Aria.domain) {
                    src.push('document.domain=\\\"' + Aria.domain + '\\\";');
                }
                src.push('if (parent.' + this.$classpath + '){parent.' + this.$classpath
                        + '.polledIframeHashString=\\\"' + hash + '\\\";}');
                src.push("</script>\");");
                src.push('document.close();');
                iframe.src = src.join("");
                this._currentIframeHashString = hash;
            }
        }
1009011
public function path($hash) {
		return $this->convEncOut($this->_path($this->convEncIn($this->decode($hash))));
	}
1181672
public function getDataFromHash($hash)
	{
		$data   = [];
		$fields = $this->fields[$hash];
		foreach ($fields as $source => $ids)
		{
			$result  = [];
			$results = $this->results[$source];
			foreach ($ids as $id)
			{
				$result[$id] = $results[$id];
			}
			$data[$source] = $result;
		}

		return $data;
	}
450165
public function draw($hash)
    {
        $index = 0;
        $tiles = $this->tiles;
        $tileSize = $this->tileSize;
        $tile = $this->tile;
        $tile->allocate($tileSize);
        $br = $tileSize * ($tiles - 1);
        $offsets = array(
            // x, y, innerMoveX, innerMoveY, outerMoveX, outerMoveY
            // corners and sides
            array(0, 0, 0, 1, 1, 0),
            array($br, 0, -1, 0, 0, 1),
            array($br, $br, 0, -1, -1, 0),
            array(0, $br, 1, 0, 0, -1),
            // opposite sides
            array($br, 0, 0, 1, -1, 0),
            array($br, $br, -1, 0, 0, -1),
            array(0, $br, 0, -1, 1, 0),
            array(0, 0, 1, 0, 0, 1),
        );
        if (!$this->image) {
            $this->image = $image = imagecreatetruecolor($tileSize * $tiles, $tileSize * $tiles);
            $this->white = imagecolorallocate($image, 255, 255, 255);
        }
        $image = $this->image;
        $white = $this->white;
        $xEnd = ($tiles + 1) >> 1;
        $xMid = ($xEnd + 1) >> 1;
        $center = ($tiles & 1) ? ($tiles >> 1) : -1;
        $numColors = $this->colors;
        assert('$this->getMinimumHashLength() <= strlen($hash)');
        $colors = array();
        for ($i = 0; $i < $numColors; $i++) {
            $r = hexdec(substr($hash, $index, 2)); $index += 2;
            $g = hexdec(substr($hash, $index, 2)); $index += 2;
            $b = hexdec(substr($hash, $index, 2)); $index += 2;
            $colors[] = $tile->getColor($r, $g, $b);
        }
        $baseColor = hexdec($hash[$index++]);
        $colorPattern = hexdec($hash[$index++]);
        $type = hexdec($hash[$index++]);
        for ($x = 0; $x < $xEnd; $x++) {
            $xOffsets = $offsets;
            for ($y = 0; $y <= $x; $y++) {
                $color = $baseColor;
                if ($colorPattern & 1) {
                    $color++;
                }
                if ($colorPattern & 2) {
                    $color += $x;
                }
                if ($colorPattern & 4) {
                    $color += $y;
                }
                if ($colorPattern & 8) {
                    $color += $x <= $xMid;
                }
                $type += hexdec($hash[$index++]);
                $tileImage = $tile->draw($type, $colors[$color % $numColors]);
                for ($i = 0; $i < 8; $i++) {
                    if ($i == 4 && ($y == $x || $x == 0)) {
                        break;
                    }
                    $offset = $xOffsets[$i];
                    if ($i < 4 || $x != $center) {
                        if ($i == 4) {
                            imageflip($tileImage, IMG_FLIP_HORIZONTAL);
                        }
                        imagecopy($image, $tileImage, $offset[0], $offset[1], 0, 0, $tileSize, $tileSize);
                        if ($x == $center && $y == $center) {
                            break;
                        }
                        if ($i != 7) {
                            $tileImage = imagerotate($tileImage, 270, $white);
                        }
                    }
                    $xOffsets[$i][0] += $offset[2] * $tileSize;
                    $xOffsets[$i][1] += $offset[3] * $tileSize;
                }
            }
            for ($i = 0; $i < 8; $i++) {
                $offsets[$i][0] += $offsets[$i][4] * $tileSize;
                $offsets[$i][1] += $offsets[$i][5] * $tileSize;
            }
        }
        return $this;
    }