Package org.pentaho.di.core.spreadsheet
Interface KWorkbook
-
- All Superinterfaces:
AutoCloseable
public interface KWorkbook extends AutoCloseable
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
close()
Close the workbook fileint
getNumberOfSheets()
KSheet
getSheet(int sheetNr)
Get a sheet in the workbook by indexKSheet
getSheet(String sheetName)
Get a sheet with a certain name in a workbook.String
getSheetName(int sheetNr)
Get a sheet name in the workbook by indexString[]
getSheetNames()
-
-
-
Method Detail
-
getSheet
KSheet getSheet(String sheetName)
Get a sheet with a certain name in a workbook.- Parameters:
sheetName
- The name of the sheet.- Returns:
- The sheet or null if the sheet was not found.
-
getSheetNames
String[] getSheetNames()
- Returns:
- The array of sheet names in the workbook
-
close
void close()
Close the workbook file- Specified by:
close
in interfaceAutoCloseable
-
getNumberOfSheets
int getNumberOfSheets()
- Returns:
- The number of sheets in the workbook
-
getSheet
KSheet getSheet(int sheetNr)
Get a sheet in the workbook by index- Parameters:
sheetNr
- The sheet number to get- Returns:
- The selected sheet
-
getSheetName
String getSheetName(int sheetNr)
Get a sheet name in the workbook by index- Parameters:
sheetNr
- The sheet number to get- Returns:
- The selected sheet's name
-
-