\Amelaye\BioPHP\Domain\Parser\Service ParseBlocksManager

Class ParseBlocksManager A BLOCKS entry describes an ungapped conserved region of a protein family, not a sequence, so this class exposes plain scalars rather than the Sequence/Feature entities of ParseDbAbstractManager.

Summary

Methods
Properties
Constants
__construct
getFormat
isEntryStart
isEntryEnd
getEntryId
parseDataFile
getId
getAccession
getDistMin
getDistMax
getDescription
getAaTriplet
No public properties found
No public constants found
No protected methods found
No protected properties found
No protected constants found
parseAccession
id
accession
distMin
distMax
description
aaTriplet
No private constants found

Properties

$id

$id : string

Type

string —

$accession

$accession : string

Type

string —

$distMin

$distMin : int

Type

int —

$distMax

$distMax : int

Type

int —

$description

$description : string

Type

string —

$aaTriplet

$aaTriplet : string

Type

string —

Methods

__construct()

__construct() : mixed

Constructor.

Returns

mixed —

getFormat()

getFormat() : string

The name this format is known by in the collection records and in DatabaseParserFactory.

Returns

string —

isEntryStart()

isEntryStart(string  $sLine) : bool

Tells whether a line opens a new BLOCKS entry.

Parameters

string $sLine

The line to analyze

Returns

bool —

isEntryEnd()

isEntryEnd(string  $sLine) : bool

Tells whether a line closes a BLOCKS entry.

Parameters

string $sLine

The line to analyze

Returns

bool —

getEntryId()

getEntryId(array  $aFlines, string  $sLine) : string

Extracts the identifier uniquely naming a BLOCKS entry, read from its AC line.

Parameters

array $aFlines

The whole file, buffered

string $sLine

The line opening the entry

Returns

string —

parseDataFile()

parseDataFile(array  $aFlines) : \Amelaye\BioPHP\Domain\Sequence\Entity\Sequence

Parses a BLOCKS data file and populates this manager's fields.

Parameters

array $aFlines

The lines the script has to parse

Throws

\Exception

Returns

\Amelaye\BioPHP\Domain\Sequence\Entity\Sequence —

$oSequence

getId()

getId() : string

Returns

string —

getAccession()

getAccession() : string

Returns

string —

getDistMin()

getDistMin() : int

Minimum distance, in residues, from the previous block of the family.

Returns

int —

getDistMax()

getDistMax() : int

Maximum distance, in residues, from the previous block of the family.

Returns

int —

getDescription()

getDescription() : string

Returns

string —

getAaTriplet()

getAaTriplet() : string

Returns

string —

parseAccession()

parseAccession(string  $sData) : void

Reads the AC line, which carries the accession then the distance range to the previous block.

Example: AC IPB002128C; distance from previous block=(30,31)

Parameters

string $sData

The AC line, tag stripped

Returns

void —