Write a back–end class called TUTTable and save it in a file called TUTTable.cpp. This class must have the following structure: Private Members Data Type Name Description TUTCell cTableData[ ][ ] This member will store the cells of the table. It must contain 30 rows and each row should be able to store 100 cells. int cNumberOfRows This member will store the number of rows that contain data. int cNumberOfColumns This member will store the number of columns that contain data. Public Methods Return Type Method Signature Description TUTTable() A constructor that must initialise the cNumberOfColumns and cNumberOfRows to zero. TUTTable(const TUTTable &refTable) A copy constructor that must copy the data from the received class to its data members. At the beginning of this method insert the following debug instruction: if (Debug::ACTIVE) {Debug::log("TUTTable","TUTTable","BEGIN of method");} At the end of this method insert the following debug instruction: if (Debug::ACTIVE) {Debug::log("TUTTable","TUTTable","END of method");} TUTTable(int numberOfColumns) A constructor that must initialise the cNumberOfColumns member to the received value. This constructor must also initialise cNumberOfRows to zero. int getNumberOfRows() int getNumberOfColumns() void addRow(TUTCell rowData[]) This method must copy the cells in the rowArray[] into the cTableData[ ][ ] array. At the beginning and end of this method insert similar debug instructions as those in the copy constructor. Also insert a debug instruction that will display the data content of each cell as it is added to the cTableDatap[][] array. TUTCell getCellAt(int row, int col) A constructor that must return the cell located at index position (row, col)

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter10: Introduction To Inheritance
Section: Chapter Questions
Problem 1GZ
icon
Related questions
Question

Write a back–end class called TUTTable and save it in a file called TUTTable.cpp. This class must have the following structure:
Private Members
Data Type Name Description
TUTCell cTableData[ ][ ] This member will store the cells of the table. It must contain 30 rows and each row should
be able to store 100 cells.
int cNumberOfRows This member will store the number of rows that contain data.
int cNumberOfColumns This member will store the number of columns that contain data.
Public Methods
Return Type Method Signature Description
TUTTable() A constructor that must initialise the cNumberOfColumns and
cNumberOfRows to zero.
TUTTable(const TUTTable &refTable) A copy constructor that must copy the data from the received class to its data
members.
At the beginning of this method insert the following debug instruction:
if (Debug::ACTIVE) {Debug::log("TUTTable","TUTTable","BEGIN of
method");}

At the end of this method insert the following debug instruction:
if (Debug::ACTIVE) {Debug::log("TUTTable","TUTTable","END of method");}
TUTTable(int numberOfColumns) A constructor that must initialise the cNumberOfColumns member to the
received value. This constructor must also initialise cNumberOfRows to zero.
int getNumberOfRows()
int getNumberOfColumns()
void addRow(TUTCell rowData[]) This method must copy the cells in the rowArray[] into the cTableData[ ][ ]
array.
At the beginning and end of this method insert similar debug instructions as
those in the copy constructor. Also insert a debug instruction that will display
the data content of each cell as it is added to the cTableDatap[][] array.
TUTCell getCellAt(int row, int col) A constructor that must return the cell located at index position (row, col)

Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Unreferenced Objects
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage