PHP_CodeSniffer
[ class tree: PHP_CodeSniffer ] [ index: PHP_CodeSniffer ] [ all elements ]

Class: Generic_Sniffs_Files_ByteOrderMarkSniff

Source Location: /PHP_CodeSniffer-2.7.1/CodeSniffer/Standards/Generic/Sniffs/Files/ByteOrderMarkSniff.php

Class Overview


Generic_Sniffs_Files_ByteOrderMarkSniff.


Author(s):

Version:

  • Release: 2.7.1

Copyright:

  • 2010-2014 mediaSELF Sp. z o.o.

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 30]
Generic_Sniffs_Files_ByteOrderMarkSniff.

A simple sniff for detecting BOMs that may corrupt application work.



[ Top ]


Class Variables

$bomDefinitions = array(
                              'UTF-8'       => 'efbbbf',
                              'UTF-16 (BE)' => 'feff',
                              'UTF-16 (LE)' => 'fffe',
                             )

[line 40]

List of supported BOM definitions.

Use encoding names as keys and hex BOM representations as values.

  • Access: public

Type:   array


[ Top ]



Method Detail

process   [line 68]

void process( PHP_CodeSniffer_File $phpcsFile, int $stackPtr)

Processes this sniff, when one of its tokens is encountered.
  • Access: public

Parameters:

PHP_CodeSniffer_File   $phpcsFile   —  The file being scanned.
int   $stackPtr   —  The position of the current token in the stack passed in $tokens.

[ Top ]

register   [line 52]

array register( )

Returns an array of tokens this test wants to listen for.
  • Access: public

[ Top ]


Documentation generated on Mon, 11 Mar 2019 14:50:41 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.