public abstract class ExcelAction extends AbstractAction
| Modifier and Type | Class and Description |
|---|---|
static class |
ExcelAction.StringUtils
Classe utilitária
|
static class |
ExcelAction.XLSFilter
Filtro que aceita arquivos cuja extensão seja xls.
|
| Modifier and Type | Field and Description |
|---|---|
Component |
owner
A janela de onde essa ação é chamada
|
changeSupport, enabledACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON| Constructor and Description |
|---|
ExcelAction(Component owner,
String title)
Construtor.
|
| Modifier and Type | Method and Description |
|---|---|
protected File |
createFileForWrite(Component owner,
String filePath)
Cria um arquivo xls para escrita.
|
protected void |
export(PoiExcel excel,
File file) |
protected String |
getExportFileName()
Obtém o nome do arquivo a ser utilizado.
|
protected String |
getFileExistsMessage(File originalFile,
File file) |
protected String |
getFileExistsTitle() |
abstract ExcelModel[] |
getModels()
Retorna os modelos
|
protected String |
getNoTitle() |
protected String |
getYesTitle() |
protected void |
handler(Throwable e) |
protected void |
openInEDT(File file) |
protected void |
runLaterInEDT(Runnable r) |
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabledequals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitactionPerformedpublic Component owner
public abstract ExcelModel[] getModels()
protected void handler(Throwable e)
e - protected void openInEDT(File file) throws IOException
file - IOExceptionprotected void export(PoiExcel excel, File file) throws IOException
excel - file - FileNotFoundExceptionIOExceptionprotected File createFileForWrite(Component owner, String filePath)
owner - a janela paifilePath - o caminho para o arquivo que se deseja criarprotected String getExportFileName()
protected String getFileExistsTitle()
protected String getFileExistsMessage(File originalFile, File file)
originalFile - file - protected String getYesTitle()
protected String getNoTitle()
protected void runLaterInEDT(Runnable r)
r - Copyright © 2019 Tecgraf/PUC-Rio. All rights reserved.