/tutorial/external/Java/BSimple.java

http://github.com/tybor/Liberty · Java · 32 lines · 21 code · 9 blank · 2 comment · 1 complexity · 1ccf19f09a840d78956f6a154237aaea MD5 · raw file

  1. /* BSimple.java */
  2. class BSimple
  3. {
  4. public BSimple()
  5. {
  6. theInteger = 1;
  7. }
  8. public void proc( int i ) throws java.lang.Exception
  9. {
  10. java.lang.Exception e;
  11. if ( i >= 0 )
  12. {
  13. theInteger = i;
  14. }
  15. else
  16. {
  17. e = new java.lang.Exception( "exception in BSimple.proc: i=" + i + " < 0" );
  18. throw( e );
  19. }
  20. }
  21. public int theInteger;
  22. }
  23. /* End of file */