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 different recording modes, Explain different recording modes. T...

Explain different recording modes. There are two type of recording modes: context sensitive and analog. - Context Sensitive - identifies GUI objects and records operations

Explain metrics assumptions of software metrics, Explain Metrics assumption...

Explain Metrics assumptions of Software metrics Software metrics A software property can be calculated. The relationship exists among what we can measure and what we

System analysis , a) There are four steps or activities in needs engineerin...

a) There are four steps or activities in needs engineering: elicitation, specification, validation, and negotiation. Briefly explain the task of every of the four steps. Why needs

Explain capability maturity model, CAPABILITY MATURITY MODEL (CMM): CMM is...

CAPABILITY MATURITY MODEL (CMM): CMM is a strategy for recovering the software process, irrespective of the actual life cycle model used.

Explain function points, Function points: Function point calculates the fu...

Function points: Function point calculates the functionality from the user point of view, that is, on the basis of what the user request and receives in return. Thus, it deals wit

Write the problems with the cmm, Write the Problems with the CMM. Prac...

Write the Problems with the CMM. Practices associated with model levels Companies could be using practices from dissimilar levels at the same time but if all practices

Define data dictionary, Define Data Dictionary The data dictionary can ...

Define Data Dictionary The data dictionary can be explained as an organized collection of all the data elements of the system with precise and rigorous definitions so that user

Enhance the effectiveness of visual support, Question: a) Discuss which...

Question: a) Discuss which communication method/s you would use in the following situations. Justify your answer. i. Congratulating an employee on obtaining a promotion.

What are the benefits of incremental model, What are the Benefits of increm...

What are the Benefits of incremental model This model is acceptable when there is less number of person involved in the project. Technical risks can be handle with every

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