When must a function throw an exception, Software Engineering

Assignment Help:

When must a function throw an exception?

A function must throw an exception when it's not able to fulfil its promise.

As soon as function detects a problem which prevents it from fulfilling its promise, it must throw an exception. If function is able to handle problem, recover itself and deliver promise, the exception shouldn't be thrown.

If an event occurs very frequently then exception handling isn't the best way to deal with it. It requires proper fixation.

 


Related Discussions:- When must a function throw an exception

Explain a variable, Explain a variable? "Variables" are data items in a ...

Explain a variable? "Variables" are data items in a program whose values can change.

What condition exists after performing validation testing, What are the con...

What are the conditions exists after performing validation testing? After performing the validation testing there two situations arise. The function or performance characterist

List the process maturity levels in seis cmm, List the process maturity lev...

List the process maturity levels in SEIs CMM. Level 1: Initial - Few processes are explained and individual efforts are taken. Level 2: Repeatable - To track cost schedul

The spiral model of software development, The spiral model of software deve...

The spiral model of software development Contains project risks evaluation during every iteration

What is cocomo model, What is COCOMO model? COnstructive COst MOdel is ...

What is COCOMO model? COnstructive COst MOdel is a cost model, which provides the estimate of number of man-months it will take to make the software product.

What are the elements of design model, What are the elements of design mode...

What are the elements of design model? i. Data design ii. Component-level design iii. Interface design iv. Architectural design

SDLC model, What is the advantage of using prototype software development m...

What is the advantage of using prototype software development model instead of waterfall model?

What is a software project test plan, What is a software project test plan?...

What is a software project test plan? A test plan is the master document that having all details pertaining to testing of the application. Its contents include: - Testing sc

What is system testing, What is System Testing System Testing : This t...

What is System Testing System Testing : This testing focuses on validating the product with respect to software specification Document. Methods like function testing (using Bl

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd