MVC Architecture Quiz

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to Lesson

Podcast

Play an AI-generated podcast conversation about this lesson
Download our mobile app to listen on the go
Get App

Questions and Answers

Model is the _________ of the MVC architecture.

bottom most level

Which method is used to change the name of a menu item?

  • String getLabel()
  • setLabel(String newName) (correct)
  • boolean isEnabled()
  • none of the above

GetContentPane() method belongs to which class?

  • JFrame
  • JButton
  • JApplet (correct)
  • None of this

JTabbedPane class is present in which package?

<p>javax.swing (A)</p> Signup and view all the answers

How many checkboxes can we check at a time?

<p>multiple (A)</p> Signup and view all the answers

Frame is a standard window, which is ____________________ of Window class.

<p>sub class</p> Signup and view all the answers

Which is/are the methods used in AbstractButton class?

<p>all of the above (D)</p> Signup and view all the answers

Which constructor creates a TextArea with 10 rows and 20 columns?

<p>new TextArea(10, 20) (D)</p> Signup and view all the answers

Which of the following is not a swing class?

<p>Canvas (B)</p> Signup and view all the answers

The method _______________ creates an IconImage for file c:\image\us.gif.

<p>new ImageIcon(&quot;c:\image\us.gif&quot;)</p> Signup and view all the answers

Flashcards are hidden until you start studying

Study Notes

MVC Architecture

  • Model is the bottom most level of the MVC architecture.
  • Method used to change the name of a menu item: setLabel(String newName).

AWT Components

  • The getContentPane() method belongs to the JApplet class.

JTabbedPane

  • JTabbedPane class is found in the javax.swing package.

Checkbox Selection

  • Multiple checkboxes can be checked at the same time.

Frame Class

  • Frame is a subclass of the Window class in AWT hierarchy.

AbstractButton Methods

  • Methods used in AbstractButton class include:
    • setDisabledIcon(Icon di)
    • setPressedIcon(Icon pi)
    • setRolloverIcon(Icon ri)
    • All of the above methods are valid.

TextArea Constructor

  • To create a TextArea with 10 rows and 20 columns, use: new TextArea(10, 20).

Swing Classes

  • Canvas is not a Swing class; it's part of the AWT (Abstract Window Toolkit).

ImageIcon Creation

  • The method to create an IconImage for the file c:\image\us.gif is: new ImageIcon("c:\\image\\us.gif").

Studying That Suits You

Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

Quiz Team

Related Documents

AJP MCQ 2 Copy Copy.pdf

More Like This

MVC and MVVM Patterns in Software Design
16 questions
Architectural Patterns and Their Benefits
16 questions
CMPT 270: MVC Architecture Quiz
18 questions

CMPT 270: MVC Architecture Quiz

NonViolentSerpentine2856 avatar
NonViolentSerpentine2856
Seance 8: Patron Mémento et MVC
30 questions

Seance 8: Patron Mémento et MVC

EntrancedSerendipity1806 avatar
EntrancedSerendipity1806
Use Quizgecko on...
Browser
Browser