net.kldp.beat.action
Class ActionInvoker

java.lang.Object
  extended by net.kldp.beat.action.ActionInvoker

public class ActionInvoker
extends java.lang.Object

컨트롤러 클래스를 실행하는 클래스 입니다.


Field Summary
private  java.lang.Object action
           
private  java.lang.reflect.Method afterMethod
           
private  java.lang.reflect.Method beforeMethod
           
private  java.lang.reflect.Method resultBeforeMethod
           
 
Constructor Summary
ActionInvoker(java.lang.Object action)
           
 
Method Summary
private  void classifyMethods(java.lang.reflect.Method[] methods)
          Action클래스안에서의 특별한 메서드들을 분류합니다.
 java.lang.String execute()
          컨트롤러 클래스의 execute 메서드를 실행합니다.
 void executeAfter()
          컨트롤러 클래스에 @After 어노테이션으로 설정되어 있는 메서드를 실행합니다.
 void executeBefore()
          컨트롤러 클래스에 @Before 어노테이션으로 설정되어 있는 메서드를 실행합니다.
 void executeBeforeResult()
          컨트롤러 클래스에 @BeforeResult 어노테이션으로 설정되어 있는 메서드를 실행합니다.
private  void invokeMethod(java.lang.reflect.Method method)
          리턴값이 void인 메서드를 실행합니다.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

action

private java.lang.Object action

beforeMethod

private java.lang.reflect.Method beforeMethod

resultBeforeMethod

private java.lang.reflect.Method resultBeforeMethod

afterMethod

private java.lang.reflect.Method afterMethod
Constructor Detail

ActionInvoker

public ActionInvoker(java.lang.Object action)
Method Detail

classifyMethods

private void classifyMethods(java.lang.reflect.Method[] methods)
Action클래스안에서의 특별한 메서드들을 분류합니다. 이들 메서드는 Before, BeforResult, After를 선언한 메서드입니다.

Parameters:
methods -

execute

public java.lang.String execute()
                         throws ActionExecuteException
컨트롤러 클래스의 execute 메서드를 실행합니다.

Returns:
Throws:
ActionExecuteException

executeBefore

public void executeBefore()
                   throws ActionExecuteException
컨트롤러 클래스에 @Before 어노테이션으로 설정되어 있는 메서드를 실행합니다.

Throws:
ActionExecuteException

executeAfter

public void executeAfter()
                  throws ActionExecuteException
컨트롤러 클래스에 @After 어노테이션으로 설정되어 있는 메서드를 실행합니다.

Throws:
ActionExecuteException

executeBeforeResult

public void executeBeforeResult()
                         throws ActionExecuteException
컨트롤러 클래스에 @BeforeResult 어노테이션으로 설정되어 있는 메서드를 실행합니다.

Throws:
ActionExecuteException

invokeMethod

private void invokeMethod(java.lang.reflect.Method method)
                   throws ActionExecuteException
리턴값이 void인 메서드를 실행합니다.

Parameters:
method -
Throws:
ActionExecuteException