DocumentationFile

Provide information about documentation files

Internal

This class is only meant to be used within EXT:install and is not part of the TYPO3 Core API.

Table of Contents

Properties

$changelogPath  : string
all files handled in this Class need to reside inside the changelog dir this is a security measure to protect system files
$registry  : Registry
$tagsTotal  : array<string|int, mixed>

Methods

__construct()  : mixed
DocumentationFile constructor.
findDocumentationDirectories()  : array<string|int, string>
Traverse given directory, select directories
findDocumentationFiles()  : array<string|int, mixed>
Traverse given directory, select files
getListEntry()  : array<string|int, mixed>
Get main information from a .rst file
getTagsTotal()  : array<string|int, mixed>
Return full tag list
collectTagTotal()  : array<string|int, mixed>
Merge tag list
extractCategoryFromHeadline()  : string
Files contain a headline (provided as input parameter, it starts with the category string.
extractHeadline()  : string
Skip include line and markers, use the first line actually containing text
extractTags()  : array<string|int, mixed>
Add tags from file
extractTagsFromFile()  : array<string|int, mixed>
Files must contain an index entry, detailing any number of manual tags each of these tags is extracted and added to the general tag structure for the file
getDocumentationFilesForVersion()  : array<string|int, mixed>
Handle a single directory
getDocumentFinder()  : Finder
isFileIgnoredByUsersChoice()  : bool
whether that file has been removed from users view
isRelevantFile()  : bool
True if file should be considered
parseContent()  : string
parseIssueId()  : string|null
versionHasDocumentationFiles()  : bool

Properties

$changelogPath

all files handled in this Class need to reside inside the changelog dir this is a security measure to protect system files

protected string $changelogPath = ''

$tagsTotal

protected array<string|int, mixed> $tagsTotal = []

Unified array of used tags

Methods

__construct()

DocumentationFile constructor.

public __construct([Registry|null $registry = null ][, string $changelogDir = '' ]) : mixed
Parameters
$registry : Registry|null = null
$changelogDir : string = ''

findDocumentationDirectories()

Traverse given directory, select directories

public findDocumentationDirectories(string $path) : array<string|int, string>
Parameters
$path : string
Tags
throws
InvalidArgumentException
Return values
array<string|int, string>

Version directories

findDocumentationFiles()

Traverse given directory, select files

public findDocumentationFiles(string $path) : array<string|int, mixed>
Parameters
$path : string
Tags
throws
InvalidArgumentException
Return values
array<string|int, mixed>

file details of affected documentation files

getListEntry()

Get main information from a .rst file

public getListEntry(string $file) : array<string|int, mixed>
Parameters
$file : string

Absolute path to documentation file

Tags
throws
InvalidArgumentException
Return values
array<string|int, mixed>

getTagsTotal()

Return full tag list

public getTagsTotal() : array<string|int, mixed>
Return values
array<string|int, mixed>

collectTagTotal()

Merge tag list

protected collectTagTotal(iterable<string|int, mixed> $documentationFiles) : array<string|int, mixed>
Parameters
$documentationFiles : iterable<string|int, mixed>
Return values
array<string|int, mixed>

extractCategoryFromHeadline()

Files contain a headline (provided as input parameter, it starts with the category string.

protected extractCategoryFromHeadline(array<string|int, mixed> $lines) : string

This will used as a tag

Parameters
$lines : array<string|int, mixed>
Return values
string

extractHeadline()

Skip include line and markers, use the first line actually containing text

protected extractHeadline(array<string|int, mixed> $lines) : string
Parameters
$lines : array<string|int, mixed>
Return values
string

extractTags()

Add tags from file

protected extractTags(array<string|int, mixed> $file) : array<string|int, mixed>
Parameters
$file : array<string|int, mixed>

file content, each line is an array item

Return values
array<string|int, mixed>

extractTagsFromFile()

Files must contain an index entry, detailing any number of manual tags each of these tags is extracted and added to the general tag structure for the file

protected extractTagsFromFile(array<string|int, mixed> $file) : array<string|int, mixed>
Parameters
$file : array<string|int, mixed>

file content, each line is an array item

Return values
array<string|int, mixed>

extracted tags

getDocumentationFilesForVersion()

Handle a single directory

protected getDocumentationFilesForVersion(string $docDirectory) : array<string|int, mixed>
Parameters
$docDirectory : string
Return values
array<string|int, mixed>

getDocumentFinder()

protected getDocumentFinder() : Finder
Return values
Finder

isFileIgnoredByUsersChoice()

whether that file has been removed from users view

protected isFileIgnoredByUsersChoice(string $filename) : bool
Parameters
$filename : string
Return values
bool

isRelevantFile()

True if file should be considered

protected isRelevantFile(array<string|int, mixed> $fileInfo) : bool
Parameters
$fileInfo : array<string|int, mixed>
Return values
bool

parseContent()

protected parseContent(string $rstContent) : string
Parameters
$rstContent : string
Return values
string

parseIssueId()

protected parseIssueId(string $filename) : string|null
Parameters
$filename : string
Return values
string|null

versionHasDocumentationFiles()

protected versionHasDocumentationFiles(string $docDirectory, string $version) : bool
Parameters
$docDirectory : string
$version : string
Return values
bool

        
On this page

Search results