SplFileObject::getMaxLineLen

(PHP 5 >= 5.1.0, PHP 7)

SplFileObject::getMaxLineLenGet maximum line length

˵��

public SplFileObject::getMaxLineLen ( void ) : int

Gets the maximum line length as set by SplFileObject::setMaxLineLen().

����

�˺���û�в�����

����ֵ

Returns the maximum line length if one has been set with SplFileObject::setMaxLineLen(), default is 0.

����

Example #1 SplFileObject::getMaxLineLen() example

<?php
$file 
= new SplFileObject("file.txt");
var_dump($file->getMaxLineLen());

$file->setMaxLineLen(20);
var_dump($file->getMaxLineLen());
?>

�������̵���������ڣ�

int(0)
int(20)

�μ�

  • Classname::Method()