- What is an applet?- Applet is a dynamic and interactive program that runs inside a web page displayed by a java capable browser.
- What is the difference between applications and applets?- a)Application must be run on local machine whereas applet needs no explicit installation on local machine. b)Application must be run explicitly within a java-compatible virtual machine whereas applet loads and runs itself automatically in a java-enabled browser. d)Application starts execution with its main method whereas applet starts execution with its init method. e)Application can run with or without graphical user interface whereas applet must run within a graphical user interface.
- How does applet recognize the height and width?- Using getParameters() method.
- When do you use codebase in applet?- When the applet class file is not in the same directory, codebase is used.
- What is the lifecycle of an applet?- init() method - Can be called when an applet is first loaded start() method - Can be called each time an applet is started. paint() method - Can be called when the applet is minimized or maximized. stop() method - Can be used when the browser moves off the applet’s page. destroy() method - Can be called when the browser is finished with the applet.
- How do you set security in applets?- using setSecurityManager() method
- What is an event and what are the models available for event handling?- An event is an event object that describes a state of change in a source. In other words, event occurs when an action is generated, like pressing button, clicking mouse, selecting a list, etc. There are two types of models for handling events and they are: a) event-inheritance model and b) event-delegation model
- What are the advantages of the model over the event-inheritance model?- The event-delegation model has two advantages over the event-inheritance model. They are: a)It enables event handling by objects other than the ones that generate the events. This allows a clean separation between a component’s design and its use. b)It performs much better in applications where many events are generated. This performance improvement is due to the fact that the event-delegation model does not have to be repeatedly process unhandled events as is the case of the event-inheritance.
- What is source and listener?- source : A source is an object that generates an event. This occurs when the internal state of that object changes in some way. listener : A listener is an object that is notified when an event occurs. It has two major requirements. First, it must have been registered with one or more sources to receive notifications about specific types of events. Second, it must implement methods to receive and process these notifications.
- What is adapter class?- An adapter class provides an empty implementation of all methods in an event listener interface. Adapter classes are useful when you want to receive and process only some of the events that are handled by a particular event listener interface. You can define a new class to act listener by extending one of the adapter classes and implementing only those events in which you are interested. For example, the MouseMotionAdapter class has two methods, mouseDragged()and mouseMoved(). The signatures of these empty are exactly as defined in the MouseMotionListener interface. If you are interested in only mouse drag events, then you could simply extend MouseMotionAdapter and implement mouseDragged() .
- What is meant by controls and what are different types of controls in AWT?- Controls are components that allow a user to interact with your application and the AWT supports the following types of controls: Labels, Push Buttons, Check Boxes, Choice Lists, Lists, Scrollbars, Text Components. These controls are subclasses of Component.
- What is the difference between choice and list?- A Choice is displayed in a compact form that requires you to pull it down to see the list of available choices and only one item may be selected from a choice. A List may be displayed in such a way that several list items are visible and it supports the selection of one or more list items.
- What is the difference between scrollbar and scrollpane?- A Scrollbar is a Component, but not a Container whereas Scrollpane is a Container and handles its own events and perform its own scrolling.
- What is a layout manager and what are different types of layout managers available in java AWT?- A layout manager is an object that is used to organize components in a container. The different layouts are available are FlowLayout, BorderLayout, CardLayout, GridLayout and GridBagLayout.
- How are the elements of different layouts organized?- FlowLayout: The elements of a FlowLayout are organized in a top to bottom, left to right fashion. BorderLayout: The elements of a BorderLayout are organized at the borders (North, South, East and West) and the center of a container. CardLayout: The elements of a CardLayout are stacked, on top of the other, like a deck of cards. GridLayout: The elements of a GridLayout are of equal size and are laid out using the square of a grid. GridBagLayout: The elements of a GridBagLayout are organized according to a grid. However, the elements are of different size and may occupy more than one row or column of the grid. In addition, the rows and columns may have different sizes.
Good Post! Thank you so much for sharing this pretty post, it was so good to read and useful to improve my knowledge as updated one, keep blogging…
ReplyDeleteRegards,
SAS Training in Chennai|SAS Course in Chennai
Excellent post!!! The future of .net application development is on positive note. It offers huge career prospects for talented professionals all over the world. Training on .net technology will ensure good salary package. Best DOT NET Training in Chennai
ReplyDeleteThanks for your article on Android technology. Android is an open source platform that allows developers to create stunning website loaded with various advanced features and functionalities. Android Training in Chennai | Android Course in Chennai
ReplyDeleteI am reading ur post from the beginning, it was so interesting to read & i feel thanks to you for posting such a good blog, keep updates regularly.
ReplyDeleteRegards,
Regards,
CCNA Training in Chennai | CCNA Training Institute in Chennai | Best CCNA Training in Chennai
Best blog..Android Training in Chennai | Best Android Training in Chennai | Android Training
ReplyDeleteReally a great blog.This interview questions was really helpful.
ReplyDeleteRegards,
Spring Training in Chennai | Hibernate Training in Chennai | Struts Training in Chennai
Nice post!! Thanks for sharing this information and keep updating us.
ReplyDeleteOracle BI Obiee Training Institute in Delhi
MySQL Training in Delhi
Oracle Apps Training Institute in Delhi
Good and nice blog post, thanks for sharing your information.. it is very useful to me.. keep rocks and updating..
ReplyDeleteJava Training in chennai | Java Training institute in chennai
Thanks for sharing informative article. Download Windows 7 ultimate for free from getintopc. It helps you to explore full functionality of windows operating system.
ReplyDeleteMuch obliged to you for sharing this magnificent blog. It will enhance my insight about JAVA systems. This blog will find out about JAVA ideas. Likewise, it will enhance my programming ability.
ReplyDeleteSpring Training in Chennai | Spring framework Training | Spring framework Certification | Spring Hibernate Training in Chennai
Very nice post here thanks for it .I always like and such a super contents of these post.Excellent and very cool idea and great content of different kinds of the valuable information's.
ReplyDeleteMindmajix Idq Training
To improve Knowledge about the latest and vital technology would increase one's self esteem to the core at the time of lagging confidence.The content presented here is quite resembling the same. You have done a great job by sharing this in here.
ReplyDeletesap abap programming training
Some us know all relating to the compelling medium you present powerful steps on this blog and therefore strongly encourage contribution from other ones on this subject while our own child is truly discovering a great deal. Have fun with the remaining portion of the year.
ReplyDeletesafety courses in chennai
Thanks for sharing informative. The Way of Your article presentation is very effective and very easy to understand about the process. Thank you keep update with your blogs Asperina Technosoft
ReplyDeleteI love the information you provide here and can’t wait to take a look when I get home.
ReplyDeleteoccupational health and safety course in chennai
I believe there are many more pleasurable opportunities ahead for individuals that looked at your site.
ReplyDeleteAzure Training in Chennai
Your blog very helped me to grow my skills and thank you for sharing this variety of wonderful informative blogs.
ReplyDeleteSoft Skills Training in Chennai
soft skills training institutes in chennai
Appium Training in Chennai
Best Appium Training institute in Chennai
Excel Training in Chennai
Pega Training in Chennai
Social Media Marketing Courses in Chennai
Embedded System Course Chennai
Linux Training in Chennai
Tableau Training in Chennai
Spark Training in Chennai
Oracle Training in Chennai
Excellent post. It will be definitely helpful for many people. Keep posting like this.
ReplyDeleteWeb Designing course in Velachery
Web Designing course in Anna Nagar
Web Designing course in Tambaram
Web Designing course in T Nagar
Web Designing course in Thiruvanmiyur
Web Designing course in Vadapalani
Web Designing course in Adyar
Web Designing course in Porur
Web Designing course in OMR
thanks for sharing devops online training
ReplyDelete