{"id":500,"date":"2019-08-21T13:43:26","date_gmt":"2019-08-21T07:58:26","guid":{"rendered":"https:\/\/bcisnotes.com\/secondsemester\/?p=500"},"modified":"2020-05-05T14:08:01","modified_gmt":"2020-05-05T08:23:01","slug":"exceptions-and-errors","status":"publish","type":"post","link":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/","title":{"rendered":"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes"},"content":{"rendered":"<h2>Exceptions And Errors<\/h2>\n<p><strong>Exceptions And Errors are described below<\/strong>.<\/p>\n<h3>Exceptions<\/h3>\n<p>An exception (or exceptional event) is a problem that arises during the execution of a program. When an\u00a0<b>Exception<\/b>\u00a0occurs the normal flow of the program is disrupted and the program\/Application terminates abnormally, which is not recommended, therefore, these exceptions are to be handled.<\/p>\n<p>An exception can occur for many different reasons. The following are some scenarios where an exception occurs.<\/p>\n<ul>\n<li>A user has entered invalid data.<\/li>\n<li>A file that needs to be opened cannot be found.<\/li>\n<li>A network connection has been lost in the middle of communications or the JVM has run out of memory.<\/li>\n<\/ul>\n<h3><strong>Errors<\/strong><\/h3>\n<p>Errors are mostly caused by the environment in which the program is running. Errors occur at runtime and not known to the compiler. All exceptions occur at runtime but checked exceptions are known to the compiler while unchecked is not. They are defined in java.lang.Error package.<\/p>\n<h3>Exceptions vs Errors<\/h3>\n<p><strong>Error:<\/strong> An Error indicates a serious problem that a reasonable application should not try to catch.<br \/>\n<strong>Exception:<\/strong>\u00a0Exception indicates conditions that a reasonable application might try to catch.<\/p>\n<h3>Exceptions Hierarchy<\/h3>\n<p>The possible exceptions in a Java program are organized in a hierarchy of exception classes. The Throwable class, which is an immediate subclass of Object, is at the root of the exception hierarchy. Throwable has two immediate subclasses: Exception and Error.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-502 size-full\" src=\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/Exception-in-java1.png\" alt=\"\" width=\"675\" height=\"490\" srcset=\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/Exception-in-java1.png 675w, https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/Exception-in-java1-300x218.png 300w\" sizes=\"(max-width: 675px) 100vw, 675px\" \/><\/p>\n<h3>Types of Exceptions<\/h3>\n<p><strong>Checked exceptions<\/strong> \u2212 A checked exception is an exception that occurs at the compile time, these are also called as compile-time exceptions. These exceptions cannot simply be ignored at the time of compilation, the programmer should take care of (handle) these exceptions.<\/p>\n<p><strong>Unchecked exceptions<\/strong>\u00a0\u2212 An unchecked exception is an exception that occurs at the time of execution. These are also called as\u00a0Runtime Exceptions. These include programming bugs, such as logic errors or improper use of an API. Runtime exceptions are ignored at the time of compilation.<\/p>\n<h3>Catching Exceptions<\/h3>\n<p>A method catches an exception using a combination of the try and catches keywords. A try\/catch block is placed around the code that might generate an exception. Code within a try\/catch block is referred to as protected code, and the syntax for using try\/catch looks like the following \u2212<br \/>\nSyntax,<\/p>\n<p>try {<br \/>\n\/\/ Protected code<br \/>\n} catch (ExceptionName e1) {<br \/>\n\/\/ Catch block<br \/>\n}<\/p>\n<p><strong>Examples<\/strong><\/p>\n<p>\/\/ File Name : ExcepTest.java<br \/>\nimport java.io.*;<\/p>\n<p>public class ExcepTest {<\/p>\n<p>public static void main(String args[]) {<br \/>\ntry {<br \/>\nint a[] = new int[2];<br \/>\nSystem.out.println(&#8220;Access element three :&#8221; + a[3]);<br \/>\n} catch (ArrayIndexOutOfBoundsException e) {<br \/>\nSystem.out.println(&#8220;Exception thrown :&#8221; + e);<br \/>\n}<br \/>\nSystem.out.println(&#8220;Out of the block&#8221;);<br \/>\n}<br \/>\n}<\/p>\n<h3>Multiple Catching<\/h3>\n<p>A try block can be followed by one or more catch blocks. Each catch block must contain a different exception handler. So, if you have to perform different tasks at the occurrence of different exceptions, use java multi-catch block.<\/p>\n<p><strong>Syntax<\/strong><\/p>\n<p>try {<br \/>\n\/\/ Protected code<br \/>\n} catch (ExceptionType1 e1) {<br \/>\n\/\/ Catch block<br \/>\n} catch (ExceptionType2 e2) {<br \/>\n\/\/ Catch block<br \/>\n} catch (ExceptionType3 e3) {<br \/>\n\/\/ Catch block<br \/>\n}<\/p>\n<p><strong>Example<\/strong><\/p>\n<p>try {<br \/>\nfile = new FileInputStream(fileName);<br \/>\nx = (byte) file.read();<br \/>\n} catch (IOException i) {<br \/>\ni.printStackTrace();<br \/>\nreturn -1;<br \/>\n} catch (FileNotFoundException f) \/\/ Not valid! {<br \/>\nf.printStackTrace();<br \/>\nreturn -1;<br \/>\n}<\/p>\n<h3>Finally Clause<\/h3>\n<p>The finally block follows a try block or a catch block. A finally block of code always executes, irrespective of occurrence of an Exception.<br \/>\nUsing a final block allows you to run any cleanup-type statements that you want to execute, no matter what happens in the protected code.<\/p>\n<p><strong>Syntax<\/strong><\/p>\n<p>try {<br \/>\n\/\/ Protected code<br \/>\n} catch (ExceptionType1 e1) {<br \/>\n\/\/ Catch block<br \/>\n} catch (ExceptionType2 e2) {<br \/>\n\/\/ Catch block<br \/>\n} catch (ExceptionType3 e3) {<br \/>\n\/\/ Catch block<br \/>\n}finally {<br \/>\n\/\/ The finally block always executes.<br \/>\n}<\/p>\n<p><strong>Example<\/strong><\/p>\n<p>public class ExcepTest {<\/p>\n<p>public static void main(String args[]) {<br \/>\nint a[] = new int[2];<br \/>\ntry {<br \/>\nSystem.out.println(&#8220;Access element three :&#8221; + a[3]);<br \/>\n} catch (ArrayIndexOutOfBoundsException e) {<br \/>\nSystem.out.println(&#8220;Exception thrown :&#8221; + e);<br \/>\n}finally {<br \/>\na[0] = 6;<br \/>\nSystem.out.println(&#8220;First element value: &#8221; + a[0]);<br \/>\nSystem.out.println(&#8220;The finally statement is executed&#8221;);<br \/>\n}<br \/>\n}<br \/>\n}<\/p>\n<h3>Throwing An Exception<\/h3>\n<p>You can throw an exception in Java by using the throw keyword. This action will cause an exception to be raised and will require the calling method to catch the exception or throw the exception to the next level in the call stack.<\/p>\n<p><strong>Throw And Throws<\/strong><\/p>\n<p>the throw keyword is used to throw an exception explicitly from any method or static block while throws keyword is used in a method declaration, denoted which exception can possibly be thrown by this method.<br \/>\nthe throw is followed by an instance while throws are followed by exception class name.<br \/>\nthe throw is used within the method whereas throws are used with the method signature.<br \/>\nYou cannot throw multiple exceptions using throw but you can declare multiple exceptions using throws one of which may or may not throw by the method.<br \/>\neg. public void method() throws IOException, SQLException{}<br \/>\nthrow statement will create an exception object but throws statement will not create an exception object.<br \/>\nthrows keyword is used to make an exception to be propagated explicitly to parent method(caller method) but when we use throw keyword and throw the exception, then it is not necessary that exception will be propagated. It may propagate if it is the unchecked exception and it may not propagate if it is checked exception.<br \/>\nthrows keyword not needed to be used for an unchecked exception to make it propagate to parent method(caller method) because they can be propagated by default but throws keyword should and must be used to handle exception in parent method if it is checked exception because checked exception can not be propagated by default.<br \/>\nUsing throw keyword you can also break a switch statement or a loop without using break keyword which cannot be performed using throws.<\/p>\n<p><strong>Analyzing Track Trace Elements<\/strong><\/p>\n<p>Trace elemental analysis can tell you. Determining trace and ultra-trace level chemical impurities, either with or without a full elemental survey analysis can address this question. Trace concentrations are typically categorized as mass fractions from 1 part per million (ppm) to 100 ppm.<\/p>\n<p><strong>Java&#8217;s Built-in Exceptions<\/strong><\/p>\n<p>Java &#8211; Built-in Exceptions. Java defines several exception classes inside the standard package java.lang. The most general of these exceptions are subclasses of the standard type RuntimeException. &#8230; Java defines several other types of exceptions that relate to its various class libraries.<\/p>\n<p>&nbsp;<\/p>\n<p><strong>Creating an Exception Subclasses<\/strong><\/p>\n<p>Although Java\u2019s built-in exceptions handle most common errors, Java\u2019s exception handling mechanism is not limited to these errors. In fact, part of the power of Java\u2019s approach to exceptions is its ability to handle exceptions that you create which correspond to errors in your own code. Creating an exception is easy. Just define a subclass of Exception (which is, of course, a subclass of Throwable). Your subclasses don\u2019t need to actually implement anything\u2014it is their existence in the type system that allows you to use them as exceptions.<\/p>\n<p>You may also like\u00a0<a href=\"https:\/\/bcisnotes.com\/secondsemester\/introduction-to-multithreading-exception-handling-and-multithreading-bcis-notes\/\">Introduction to Multithreading || Exception Handling and Multithreading || Bcis Notes<\/a><\/p>\n<div class=\"nkpwx69fac80de5c14\" ><div id=\"amzn-assoc-ad-668fe681-bdc6-49ee-a9f9-a4c2f5be29a0\"><\/div><script async src=\"\/\/z-na.amazon-adsystem.com\/widgets\/onejs?MarketPlace=US&adInstanceId=668fe681-bdc6-49ee-a9f9-a4c2f5be29a0\"><\/script><\/div><style type=\"text\/css\">\r\n@media screen and (min-width: 1201px) {\r\n.nkpwx69fac80de5c14 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 993px) and (max-width: 1200px) {\r\n.nkpwx69fac80de5c14 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 769px) and (max-width: 992px) {\r\n.nkpwx69fac80de5c14 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 768px) and (max-width: 768px) {\r\n.nkpwx69fac80de5c14 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (max-width: 767px) {\r\n.nkpwx69fac80de5c14 {\r\ndisplay: block;\r\n}\r\n}\r\n<\/style>\r\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>Exceptions And Errors Exceptions And Errors are described below. Exceptions An exception (or exceptional event) is a problem that arises during the execution of a <a class=\"mh-excerpt-more\" href=\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\" title=\"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes\">[&#8230;]<\/a><\/p>\n<\/div>","protected":false},"author":3,"featured_media":845,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Exceptions And Errors || Exceptions Handling And Multithreading ||<\/title>\n<meta name=\"description\" content=\"Both Errors and Exceptions are the subclasses of java. lang. Exceptions And Errors are described below:Exceptions:An exception (or exceptional event)\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Exceptions And Errors || Exceptions Handling And Multithreading ||\" \/>\n<meta property=\"og:description\" content=\"Both Errors and Exceptions are the subclasses of java. lang. Exceptions And Errors are described below:Exceptions:An exception (or exceptional event)\" \/>\n<meta property=\"og:url\" content=\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\" \/>\n<meta property=\"og:site_name\" content=\"BCIS NOTES\" \/>\n<meta property=\"article:published_time\" content=\"2019-08-21T07:58:26+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-05-05T08:23:01+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"340\" \/>\n\t<meta property=\"og:image:height\" content=\"230\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Jelly\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jelly\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\"},\"author\":{\"name\":\"Jelly\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/person\/e546a21bf4bd6cef9112447a5f1453f6\"},\"headline\":\"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes\",\"datePublished\":\"2019-08-21T07:58:26+00:00\",\"dateModified\":\"2020-05-05T08:23:01+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\"},\"wordCount\":1143,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#organization\"},\"image\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg\",\"articleSection\":[\"Object Oriented Programming\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\",\"url\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\",\"name\":\"Exceptions And Errors || Exceptions Handling And Multithreading ||\",\"isPartOf\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg\",\"datePublished\":\"2019-08-21T07:58:26+00:00\",\"dateModified\":\"2020-05-05T08:23:01+00:00\",\"description\":\"Both Errors and Exceptions are the subclasses of java. lang. Exceptions And Errors are described below:Exceptions:An exception (or exceptional event)\",\"breadcrumb\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage\",\"url\":\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg\",\"contentUrl\":\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg\",\"width\":340,\"height\":230,\"caption\":\"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/bcisnotes.com\/secondsemester\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#website\",\"url\":\"https:\/\/bcisnotes.com\/secondsemester\/\",\"name\":\"BCIS NOTES\",\"description\":\"Second Semester\",\"publisher\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/bcisnotes.com\/secondsemester\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#organization\",\"name\":\"BCIS NOTES\",\"url\":\"https:\/\/bcisnotes.com\/secondsemester\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/12\/cropped-2.jpg\",\"contentUrl\":\"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/12\/cropped-2.jpg\",\"width\":300,\"height\":100,\"caption\":\"BCIS NOTES\"},\"image\":{\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/person\/e546a21bf4bd6cef9112447a5f1453f6\",\"name\":\"Jelly\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/a1059d40f7ab5e57f2659e94306c6a9a?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/a1059d40f7ab5e57f2659e94306c6a9a?s=96&d=mm&r=g\",\"caption\":\"Jelly\"},\"url\":\"https:\/\/bcisnotes.com\/secondsemester\/author\/mandira\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Exceptions And Errors || Exceptions Handling And Multithreading ||","description":"Both Errors and Exceptions are the subclasses of java. lang. Exceptions And Errors are described below:Exceptions:An exception (or exceptional event)","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/","og_locale":"en_US","og_type":"article","og_title":"Exceptions And Errors || Exceptions Handling And Multithreading ||","og_description":"Both Errors and Exceptions are the subclasses of java. lang. Exceptions And Errors are described below:Exceptions:An exception (or exceptional event)","og_url":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/","og_site_name":"BCIS NOTES","article_published_time":"2019-08-21T07:58:26+00:00","article_modified_time":"2020-05-05T08:23:01+00:00","og_image":[{"width":340,"height":230,"url":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg","type":"image\/jpeg"}],"author":"Jelly","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Jelly","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#article","isPartOf":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/"},"author":{"name":"Jelly","@id":"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/person\/e546a21bf4bd6cef9112447a5f1453f6"},"headline":"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes","datePublished":"2019-08-21T07:58:26+00:00","dateModified":"2020-05-05T08:23:01+00:00","mainEntityOfPage":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/"},"wordCount":1143,"commentCount":0,"publisher":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/#organization"},"image":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage"},"thumbnailUrl":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg","articleSection":["Object Oriented Programming"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/","url":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/","name":"Exceptions And Errors || Exceptions Handling And Multithreading ||","isPartOf":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/#website"},"primaryImageOfPage":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage"},"image":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage"},"thumbnailUrl":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg","datePublished":"2019-08-21T07:58:26+00:00","dateModified":"2020-05-05T08:23:01+00:00","description":"Both Errors and Exceptions are the subclasses of java. lang. Exceptions And Errors are described below:Exceptions:An exception (or exceptional event)","breadcrumb":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#primaryimage","url":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg","contentUrl":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/08\/exception.jpg","width":340,"height":230,"caption":"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes"},{"@type":"BreadcrumbList","@id":"https:\/\/bcisnotes.com\/secondsemester\/object-oriented-programming\/exceptions-and-errors\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/bcisnotes.com\/secondsemester\/"},{"@type":"ListItem","position":2,"name":"Exceptions And Errors || Exceptions Handling And Multithreading || Bcis Notes"}]},{"@type":"WebSite","@id":"https:\/\/bcisnotes.com\/secondsemester\/#website","url":"https:\/\/bcisnotes.com\/secondsemester\/","name":"BCIS NOTES","description":"Second Semester","publisher":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/bcisnotes.com\/secondsemester\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/bcisnotes.com\/secondsemester\/#organization","name":"BCIS NOTES","url":"https:\/\/bcisnotes.com\/secondsemester\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/logo\/image\/","url":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/12\/cropped-2.jpg","contentUrl":"https:\/\/bcisnotes.com\/secondsemester\/wp-content\/uploads\/2019\/12\/cropped-2.jpg","width":300,"height":100,"caption":"BCIS NOTES"},"image":{"@id":"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/person\/e546a21bf4bd6cef9112447a5f1453f6","name":"Jelly","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bcisnotes.com\/secondsemester\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/a1059d40f7ab5e57f2659e94306c6a9a?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/a1059d40f7ab5e57f2659e94306c6a9a?s=96&d=mm&r=g","caption":"Jelly"},"url":"https:\/\/bcisnotes.com\/secondsemester\/author\/mandira\/"}]}},"_links":{"self":[{"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/posts\/500"}],"collection":[{"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/comments?post=500"}],"version-history":[{"count":3,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/posts\/500\/revisions"}],"predecessor-version":[{"id":1026,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/posts\/500\/revisions\/1026"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/media\/845"}],"wp:attachment":[{"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/media?parent=500"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/categories?post=500"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bcisnotes.com\/secondsemester\/wp-json\/wp\/v2\/tags?post=500"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}