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

What is cyclomatic complexity, What is cyclomatic complexity? Cyclomati...

What is cyclomatic complexity? Cyclomatic complexity is software metric that provides the quantitative measure of logical difficulty of the program. The Cyclomatic complexit

Explain basis path testing, Explain Basis Path Testing? Ans) Basis path ...

Explain Basis Path Testing? Ans) Basis path testing is a white-box method. It permits the design and definition of a basis set of execution paths. The test cases created from th

Show the cost drivers used in cocomo model, Q. Show the cost drivers used i...

Q. Show the cost drivers used in COCOMO model? A variety of attributes of cost drivers used in COCOMO model are: 1. Physical attributes : These are worried with required

What is constructive cost model, Q. What is Constructive Cost Model? CO...

Q. What is Constructive Cost Model? COCOMO model denotes Constructive Cost Model. It is an empirical model basis on project experience. It is well-documented and independent mo

Operation of the clue-less system, A player with an active turn must make a...

A player with an active turn must make a valid move with their character or pass their turn. As a first move in the game, the player can move to the hallway that is adjacent to the

List the pre-requisites for white-box testing, List the pre-requisites for ...

List the pre-requisites for white-box testing The pre-requisites for white-box testing are same to that of black-box testing with one main difference: - During white-box tes

Write down the schema to represent the current system state, Question: ...

Question: Consider the University modular degree scheme where students choose a selection of modules from a large menu. Here we have the basic types [PERSON, MODULE], the set o

Explain sci, What is SCI? Software Configuration Item is information th...

What is SCI? Software Configuration Item is information that is carried as part of the software engineering process.

Explain the types of software testing, Explain the types of software testin...

Explain the types of software testing. Unit testing Integration testing System testing User-acceptance testing End-to-End testing Exception testing

What transform mapping refers, What transform mapping refers? The trans...

What transform mapping refers? The transform mapping is a bundle of design steps applied on the DFD in order to map the transformed flow characteristics into specific architect

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