|
NOTA: La traducción de esta documentación es un esfuerzo personal y voluntario, no es un documento oficial de Sun Microsystems
ni Oracle ni está patrocinado por ninguna de estas empresas. Los documentos originales (en inglés) están disponibles en:
http://java.sun.com/docs/books/tutorial/.
Dirija cualquier comentario, petición, felicitación, etc. a tutorialesjava_@RROBA_codexion.com. |
Si desea ayudar a mantener en funcionamiento esta web, colaborar con la traducción de estos documentos o necesita que se traduzca algĂșn capĂtulo en concreto puede realizar una donación directa mediante Paypal:
|
Parameters are to applets what command-line arguments are to applications. They allow the user to customize the applet's operation. By defining parameters, you can increase your applet's flexibility, making your applet work in multiple situations without recoding and recompiling it.
The next few pages discuss parameters from the applet programmer's point of view. To learn about the user view of parameters, see Specifiying Parameters.
When implementing parameters, you must answer four questions:
- What should the applet let the user configure?
- What should the parameters be named?
- What kind of value should each parameter take?
- What should the default value of each parameter be?
Applets get the user-defined values of parameters by calling the
AppletgetParametermethod.
By implementing the
getParameterInfomethod, applets provide information that browsers can use to help the user set parameter values.