LoginSignup
0
0

More than 3 years have passed since last update.

MVCモデル

Last updated at Posted at 2020-03-27

MVCモデル

M...Model(モデル)

Javaクラス
アプリケーションの処理(計算処理等)、データ格納

V...View(ビュー)

JPSファイル
画面表示

C...Controller(コントローラー)

サーブレットクラス
要求の受け取り、処理実行依頼(Model)、結果表示依頼(View)

転送処理

フォワード

処理を他のサーブレットクラス、JPSクラスに移す(内部)
URLがリクエスト時の状態

記述
RequestDispatcher dispatcher = request.getRequestDispatcher("フォワード先");
dispatcher.forward(request, response);

リダイレクト

処理を他のサーブレットクラス、JPSクラスに移す(外部)
URLがリダイレクト先のものに変更

記述
response.sendReddirect("リダイレクト先のURL");
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0