nakanilog

おぼえておきたい事をざっくりとメモするブログ

Java

try-with-resources文(try~chatchにおけるリソース解放処理の効率的な書き方)

Java SE 7 よりtry~chatchにおけるリソース解放処理を簡素に記述できるようになった。 <try-with-resources文を使わない場合>FileInputStream fs = null; try { fs = new FileInputStream(filePath); (ファイル処理)} catch (IOException e) { e.printS…

Tomcat開発環境構築メモ

1)Eclipse(Pleiades All in One パッケージ)のダウンロード Pleiades 公式サイト(http://mergedoc.sourceforge.jp/) 今回ダウンロードしたのは Pleiades All in One 4.7.2.v20171225(Java Windows 64bit Full Edition) ※Full Edition は JDK、Tomcat…

プロパティの定義方法(property)

Java SE 7 より簡素に定義できるようになったプロパティ public class MyBean { public property String name1; // 読み書き可能なプロパティ public property String name2 get; // 読み取り専用 public property String name3 set; // 書き込み専用 public…