0
나는 execute()
, read()
및 write()
의 세 가지 메서드가있는 LoginAction
클래스를 가지고 있습니다. 나는 이러한 방법을 호출하기위한 다음 단계를 쓴 내 struts.xml에서Struts2에서 여러 메서드 호출하기
LoginAction l1 = new LoginAction();l1.read();l1.write(null);
execute file-----upload file from directory.
read and write------------read uploaded file and convert it into excel.
: execute 메소드 내부에서 나는 read
및 writ
사용하여 메소드를 호출하고 있습니다.
그러나 런타임에는 단 하나의 방법 (execute
메서드) 만 작동합니다. 어떻게 모든 메소드를 호출 할 수 있습니까?
내 방법은 다음과 같습니다 우리는 스트럿츠 2에서 하나의 조치를 체인 사용할 수 있습니다 이것에 대한
public String execute() throws Exception
boolean write(List<String> l1) throws Exception
public String Read() throws Exception
form tag. s:form action="login1" method="post" enctype="multipart/form-data"
namespace="/".
'execute' 메서드는 기본값입니다. –