title: Try/Catch in Constructor
body: <pre><code>public class MyClass{
  
      private String url;
      private static InputSource is;
  
      public MyClass(String link){
          this.url=link;
          try {
              is = new InputSource();
              is.setEncoding("UTF-8");
              is.setByteStream(new URL(url).openStream());
          } catch (Exception e) {
              Logger.debug(e);
          }
      }
  }
  </code></pre>
  
  <p>I have three methods and I'am using <code>InputSource</code> in all methods. So I want to create one <code>InputSource</code> with constructor and use it in all methods. How can I do it? Does anyone have any idea? Should I use try-cath block in constructor?</p>