I've browsed the help section and have not found my answer so I'll post a question myself. I tried 'original.setModel(rows);' but get an error saying original doesn't exist. this wont take, and I've tried without the setModel() call(just cuz these things are weird like that sometimes) and nothing. Which, knowing me, is something small that I am missing. Please help me find it ;).
package com.codegym.task.task18.task1815;
import java.util.List;
/*
Table
*/
public class Solution {
public class TableInterfaceWrapper implements TableInterface{
private TableInterface tableInterface;
String headerText;
public TableInterfaceWrapper(TableInterface tableInterface){
this.tableInterface = tableInterface;
}
@Override
public void setModel(List rows) {
System.out.println(rows);
setModel(rows);
}
@Override
public String getHeaderText()
{
return tableInterface.getHeaderText().toUpperCase();
}
@Override
public void setHeaderText(String headerText)
{
tableInterface.setHeaderText(headerText);
}
}
public interface TableInterface {
void setModel(List rows);
String getHeaderText();
void setHeaderText(String HeaderText);
}
public static void main(String[] args) {
}
}