Add methods to SheetInterface
The SheetInterface was missing methods common to all Sheets (getIndex, getName, isActive, isVisible).
This commit is contained in:
parent
40ee386edd
commit
cd3d98fb1a
@ -51,4 +51,12 @@ class Sheet implements SheetInterface
|
|||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return bool Always TRUE as the only sheet is always visible
|
||||||
|
*/
|
||||||
|
public function isVisible()
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -8,9 +8,27 @@ namespace Box\Spout\Reader;
|
|||||||
interface SheetInterface
|
interface SheetInterface
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Returns an iterator to iterate over the sheet's rows.
|
* @return IteratorInterface Iterator to iterate over the sheet's rows.
|
||||||
*
|
|
||||||
* @return IteratorInterface
|
|
||||||
*/
|
*/
|
||||||
public function getRowIterator();
|
public function getRowIterator();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return int Index of the sheet
|
||||||
|
*/
|
||||||
|
public function getIndex();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return string Name of the sheet
|
||||||
|
*/
|
||||||
|
public function getName();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return bool Whether the sheet was defined as active
|
||||||
|
*/
|
||||||
|
public function isActive();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return bool Whether the sheet is visible
|
||||||
|
*/
|
||||||
|
public function isVisible();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user