高度なカスタマイズ > Info*Engine ユーザーガイド > Info*Engine JSP ページ > 例外の検出 > try/catch ブロックの使用
  
try/catch ブロックの使用
スクリプトレット内で try/catch ブロックを使用して、JSP の特定の部分で例外を検出できます。これは、unit タグまたは failure タグを使用した例外処理と似ていますが、これらのタグを使用する場合よりも、例外処理をプログラム的に行うことができます。以下に例を示します。
<%
try {
%>
<!-- webject or task invocations -->
<%
// catch statement appropriate given the contents of this block
} catch ( AdapterException ae ) {
  //handle the adapter exception
} catch ( IDPartialResultsException partial ) {
  // extract and display the partial results
}
// etc.
%>