public class ProteinTableModel
extends com.compomics.util.gui.tablemodels.SelfUpdatingTableModel
columnIdentifiers, dataVectorlistenerList| Constructor and Description |
|---|
ProteinTableModel()
Constructor for an empty table
|
ProteinTableModel(com.compomics.util.experiment.identification.Identification identification,
com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator,
com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider,
com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider,
com.compomics.util.experiment.biology.genes.GeneMaps geneMaps,
DisplayFeaturesGenerator displayFeaturesGenerator,
com.compomics.util.exceptions.ExceptionHandler exceptionHandler,
long[] proteinKeys)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
catchException(Exception e) |
Class |
getColumnClass(int columnIndex) |
int |
getColumnCount() |
String |
getColumnName(int column) |
static Integer |
getPreferredAccessionColumnWidth(JTable table,
int colIndex,
int margin,
Integer maxProteinKeyLength)
Gets the preferred width of the column specified by colIndex.
|
int |
getRowCount() |
Object |
getValueAt(int row,
int column) |
boolean |
isCellEditable(int rowIndex,
int columnIndex) |
boolean |
isInstantiated()
Indicates whether the table content was instantiated.
|
protected int |
loadDataForRows(ArrayList<Integer> rows,
com.compomics.util.waiting.WaitingHandler waitingHandler) |
void |
reset()
Reset the protein keys.
|
static void |
setProteinTableProperties(JTable proteinTable,
Color sparklineColor,
Color sparklineColorNotValidated,
Color sparklineColorNotFound,
Color sparklineColorDoubtful,
DecimalFormat scoreAndConfidenceDecimalFormat,
Class parentClass,
Integer maxProteinKeyLength)
Set up the properties of the protein table.
|
void |
showScores(boolean showScores)
Sets whether the scores should be displayed.
|
void |
updateDataModel(com.compomics.util.experiment.identification.Identification identification,
com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator,
com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider,
com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider,
com.compomics.util.experiment.biology.genes.GeneMaps geneMaps,
DisplayFeaturesGenerator displayFeaturesGenerator,
long[] proteinKeys)
Update the data in the table model without having to reset the whole
table model.
|
addScrollListeners, addSortListener, dataMissingAtRow, getRowNumber, getViewIndex, initiateSorter, isScrolling, isSelfUpdating, needsUpdate, resetSorting, setIsScrolling, setSelfUpdating, sortaddColumn, addColumn, addColumn, addRow, addRow, convertToVector, convertToVector, getDataVector, insertRow, insertRow, moveRow, newDataAvailable, newRowsAdded, removeRow, rowsRemoved, setColumnCount, setColumnIdentifiers, setColumnIdentifiers, setDataVector, setDataVector, setNumRows, setRowCount, setValueAtaddTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListenerpublic ProteinTableModel()
public ProteinTableModel(com.compomics.util.experiment.identification.Identification identification,
com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator,
com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider,
com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider,
com.compomics.util.experiment.biology.genes.GeneMaps geneMaps,
DisplayFeaturesGenerator displayFeaturesGenerator,
com.compomics.util.exceptions.ExceptionHandler exceptionHandler,
long[] proteinKeys)
identification - the identification containing the protein
informationidentificationFeaturesGenerator - the identification features
generator generating the features of the identificationproteinDetailsProvider - the protein details providersequenceProvider - the protein sequences providergeneMaps - the gene mapsdisplayFeaturesGenerator - the display features generator generating
the display elementsexceptionHandler - an exception handler catching exceptionsproteinKeys - the keys of the protein matches to displaypublic void updateDataModel(com.compomics.util.experiment.identification.Identification identification,
com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator,
com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider,
com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider,
com.compomics.util.experiment.biology.genes.GeneMaps geneMaps,
DisplayFeaturesGenerator displayFeaturesGenerator,
long[] proteinKeys)
identification - the identification containing the protein
informationidentificationFeaturesGenerator - the identification features
generator generating the features of the identificationproteinDetailsProvider - the protein details providersequenceProvider - the protein sequences providergeneMaps - the gene mapsdisplayFeaturesGenerator - the display features generator generating
the display elementsproteinKeys - the keys of the protein matches to displaypublic void showScores(boolean showScores)
showScores - a boolean indicating whether the scores should be
displayedpublic void reset()
public int getRowCount()
getRowCount in interface TableModelgetRowCount in class DefaultTableModelpublic int getColumnCount()
getColumnCount in interface TableModelgetColumnCount in class DefaultTableModelpublic String getColumnName(int column)
getColumnName in interface TableModelgetColumnName in class DefaultTableModelpublic Object getValueAt(int row, int column)
getValueAt in interface TableModelgetValueAt in class DefaultTableModelpublic boolean isInstantiated()
public Class getColumnClass(int columnIndex)
getColumnClass in interface TableModelgetColumnClass in class AbstractTableModelpublic boolean isCellEditable(int rowIndex,
int columnIndex)
isCellEditable in interface TableModelisCellEditable in class DefaultTableModelprotected void catchException(Exception e)
catchException in class com.compomics.util.gui.tablemodels.SelfUpdatingTableModelprotected int loadDataForRows(ArrayList<Integer> rows, com.compomics.util.waiting.WaitingHandler waitingHandler)
loadDataForRows in class com.compomics.util.gui.tablemodels.SelfUpdatingTableModelpublic static void setProteinTableProperties(JTable proteinTable, Color sparklineColor, Color sparklineColorNotValidated, Color sparklineColorNotFound, Color sparklineColorDoubtful, DecimalFormat scoreAndConfidenceDecimalFormat, Class parentClass, Integer maxProteinKeyLength)
proteinTable - the protein tablesparklineColor - the sparkline color to usesparklineColorNotValidated - the sparkline color for not validated
stuffsparentClass - the parent class used to get iconssparklineColorNotFound - the sparkline color for not found stuffssparklineColorDoubtful - the sparkline color for doubtfulscoreAndConfidenceDecimalFormat - the decimal format for score and
confidencemaxProteinKeyLength - the longest protein key to displaypublic static Integer getPreferredAccessionColumnWidth(JTable table, int colIndex, int margin, Integer maxProteinKeyLength)
table - the tablecolIndex - the colum indexmargin - the margin to addmaxProteinKeyLength - the maximal protein key lengthCopyright © 2021. All rights reserved.