Wednesday, April 6, 2011

Wear Can You Buy Hunter Boots In Ontario

Events, Exceptions and Errors (CLASS)

Good afternoon, this entry will talk about what these events, systematic oversight or programming errors and what can be produced in the system I am developing.


Events.
"Events are the middle class and interact with others or with the user, are responsible to notify that something has happened and to handle it one way or another. The way to handle events in OOP is called transmitter / receiver, also called dispatcher / listener or just dispatcher / listener.
In this pair, the first part (the issuer) will launch the event, while the second is responsible for receiving and handling as needed. The first part will be up to us (the developers of the class) and the second is the responsibility of the user of the class (in principle, us). "



An event applicable I think my project can be a listener in class product so that when the user adds the price of a message that the product has been successfully added.


Exceptions.
"An exception is an object that is generated automatically when an incidental event that prevents normal operation of the program:
- Divide by zero
- No
find a particular file - Use a Null Pointer instead of a reference
an object generated object "exception" contains information about the event occurred and transmits this information to the method from which generated the exception. The occurrence of these exceptional situations cause uncontrolled termination of the program or application. "



An exception in my program can order the product data within a try / catch and if the type of user-entered data does not match the set (a char instead of int, an int instead of float) to send a message that says the data type specified was not correct.

Errors.
"In computing, a fatal error is an error that causes a program crashes (closes). Usually when this happens, data processing that the program was lost.
A fatal error is usually the case in the following cases: * Attempt
make an illegal instruction.
* It has agreed to codes or invalid data.
* The privilege level of an operation is invalid.
* A program is trying to divide by zero (in some systems that follow the standard IEEE floating point, this division produces an infinity and not a fatal error).



There are also other errors, fatal errors system, such as the blue screen of death Windows.




Bibliographic sources and some tutorials with examples.
http://www.alegsa.com.ar/Dic/error% 20fatal.php
http://www.slideshare.net/sgvargas/manejo-de-eventos- en-java-presentation
http://vcalpena.wordpress.com/4-excepciones/
http://heinsohn.wikidot.com/articulos:lineamientos-excepciones
http://www.javadabbadoo.org/cursos/infosintesis.net/javase/paqawt/selectorcolores / paso03javaObserver.html

0 comments:

Post a Comment