Question: Make an : Is for kids boolean method in eitem class Append the object details in items for kids list (if the object id for

 Make an : Is for kids boolean method in eitem class

Make an : Is for kids boolean method in eitem class

Append the object details in items for kids list (if the object id for kids then kids list will append else items will append)

Note: dont use min age in the if statement use is for kids method

the other code:

private void jComboBox1ActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: }

private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { String name= jTextField4.getText(); double price= Double.parseDouble(jTextField5.getText()); int minUserAge= Integer.parseInt(jComboBox1.getSelectedItem().toString()); boolean batt=jCheckBox1.isSelected(); Eitem item= new Eitem(name, minUserAge, price, batt); jTextArea1.append(item.toString()+" "); if (item.isForKids()){ }

From the previous exercise, add a new boolean method "isForKids" in class "EItem" that return true if the minUserAge

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!