Afrikaans
Akan
Amharic
Arabic
Armenian
Azerbaijani
Basque
Belarusian
Bemba
Bengali
Bihari
Bosnian
Breton
Bulgarian
Cambodian
Catalan
Cebuano
Cherokee
Chichewa
Chinese (Simplified)
Chinese (Traditional)
Corsican
Croatian
Czech
Danish
Dutch
English
Esperanto
Estonian
Ewe
Faroese
Filipino
Finnish
French
Frisian
Ga
Galician
Georgian
German
Greek
Guarani
Gujarati
Haitian Creole
Hausa
Hawaiian
Hebrew
Hindi
Hmong
Icelandic
Igbo
Indonesian
Interlingua
Irish
Italian
Japanese
Javanese
Kannada
Kazakh
Kinyarwanda
Kirundi
Kongo
Krio (Sierra Leone)
Kurdish
Kurdish (Soranî)
Kyrgyz
Laothian
Latin
Latvian
Lingala
Lithuanian
Lozi
Luganda
Luo
Luxembourgish
Macedonian
Malagasy
Malay
Malayalam
Maltese
Maori
Marathi
Mauritian Creole
Moldavian
Mongolian
Myanmar (Burmese)
Montenegrin
Nepali
Nigerian Pidgin
Northern Sotho
Norwegian
Norwegian (Nynorsk)
Occitan
Oriya
Oromo
Pashto
Persian
Polish
Portuguese (Brazil)
Portuguese (Portugal)
Punjabi
Quechua
Romanian
Romansh
Runyakitara
Russian
Samoan
Scots Gaelic
Serbian
Serbo-Croatian
Sesotho
Setswana
Seychellois Creole
Shona
Sindhi
Sinhalese
Slovak
Slovenian
Somali
Spanish
Spanish (Latin American)
Sundanese
Swahili
Swedish
Tajik
Tamil
Tatar
Telugu
Thai
Tigrinya
Tonga
Tshiluba
Tumbuka
Turkish
Turkmen
Twi
Uighur
Ukrainian
Urdu
Uzbek
Vietnamese
Welsh
Wolof
Xhosa
Yiddish
Yoruba
Zulu
The last step is to bulletproof the application, in other words, working to make sure the application
doesn't fail or crash no matter what.
All right, let's run the up.
And the first vulnerability in the opposite, the user enters a blank name or phone number.
The constructor is going to throw in a legal argument exception once again, this is an unchecked exception
because it occurs during the runtime, but under no circumstance should be let the application crash.
If we get an unchecked exception, that means there's something wrong or there's something missing in
your code.
And what's missing in this case is code that anticipates a scenario where the user may enter a blank
name or phone number, so we'll say if name DOT is blank or if the number they pass on is blank.
Then we'll just print the input you provided is not valid registration, f�ilte.
Otherwise, we can add the contact.
If you run the app.
Good.
But another illegal argument exception crashes the app if the user enter the phone number, that's less
than five characters.
Once again, an unchecked exception implies we're missing something in the code.
And all we gotta do is check if the phone number is less than five characters, then we're going to
tell the user that their input is not valid.
And with this final line of code, proud to say that we're all finished.
Just like that, our application is bulletproof, no matter what the user throws at you, the application
is free of bugs and it's never going to crash.
It can process any input and respond accordingly.
In the end, exception handling, which involves catching checked exceptions and fixing unchecked exceptions,
is the key to building bulletproof applications.
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.