|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.context.support.ApplicationObjectSupport
org.springframework.web.context.support.WebApplicationObjectSupport
org.springframework.web.servlet.view.AbstractView
org.springframework.web.servlet.view.document.AbstractJExcelView
com.poscoict.glueframework.web.control.spring.view.GlueJExcelView
public class GlueJExcelView

JExcel 기반으로 Excel을 Export하기 위한 View Class이다.
| Nested Class Summary | |
|---|---|
class |
GlueJExcelView.JExcelFormat
JExcel의 Cell Type에 대한 정의를 가진 Class이다. |
| Field Summary | |
|---|---|
static String |
DEFAULT_DATE_FORMAT
|
| Fields inherited from class org.springframework.web.servlet.view.AbstractView |
|---|
DEFAULT_CONTENT_TYPE |
| Fields inherited from interface org.springframework.web.servlet.View |
|---|
PATH_VARIABLES, RESPONSE_STATUS_ATTRIBUTE, SELECTED_CONTENT_TYPE |
| Constructor Summary | |
|---|---|
GlueJExcelView()
|
|
| Method Summary | |
|---|---|
protected void |
buildExcelDocument(Map<String,Object> model,
jxl.write.WritableWorkbook workbook,
HttpServletRequest request,
HttpServletResponse response)
|
protected String[] |
getColumnIds(GlueContext ctx,
String sheetId)
GlueContext에서 Column Id를 가져오는 메소드이다. |
protected String |
getFileName(GlueContext ctx)
설정 값에 따라 FileName을 만들어 Return하는 메소드이다. |
protected void |
writeBody(jxl.write.WritableSheet sheet,
List<Map<String,Object>> list,
String[] columnIds)
Excel Data부를 작성하는 메소드이다. |
protected void |
writeCell(jxl.write.WritableSheet sheet,
int x,
int y,
Object data,
String comment)
한 Cell을 Write하는 메소드이다. |
protected void |
writeHeader(jxl.write.WritableSheet sheet,
String[] columnIds,
String[] columnNames)
Excel Header를 작성하는 메소드이다. |
protected void |
writeImage()
필요 시 구현. |
protected void |
writeRow(jxl.write.WritableSheet sheet,
Map<String,Object> map,
String[] columnIds,
int y)
Excel에 하나의 Row를 작성하는 메소드이다. |
protected void |
writeSheet(GlueContext ctx,
jxl.write.WritableSheet sheet,
String sheetId)
GlueContext에 SheetId로 지정한 객체을 Get하여 Excel Sheet를 Write하는 메소드이다. |
| Methods inherited from class org.springframework.web.servlet.view.document.AbstractJExcelView |
|---|
generatesDownloadContent, getTemplateSource, renderMergedOutputModel, setUrl |
| Methods inherited from class org.springframework.web.servlet.view.AbstractView |
|---|
addStaticAttribute, createMergedOutputModel, createRequestContext, createTemporaryOutputStream, exposeModelAsRequestAttributes, getAttributesMap, getBeanName, getContentType, getRequestContextAttribute, getStaticAttributes, isExposePathVariables, prepareResponse, render, setAttributes, setAttributesCSV, setAttributesMap, setBeanName, setContentType, setExposePathVariables, setRequestContextAttribute, setResponseContentType, toString, writeToResponse |
| Methods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport |
|---|
getServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContext |
| Methods inherited from class org.springframework.context.support.ApplicationObjectSupport |
|---|
getApplicationContext, getMessageSourceAccessor, initApplicationContext, requiredContextClass, setApplicationContext |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static String DEFAULT_DATE_FORMAT
| Constructor Detail |
|---|
public GlueJExcelView()
| Method Detail |
|---|
protected void buildExcelDocument(Map<String,Object> model,
jxl.write.WritableWorkbook workbook,
HttpServletRequest request,
HttpServletResponse response)
throws Exception
buildExcelDocument in class AbstractJExcelViewExceptionprotected String getFileName(GlueContext ctx)
ctx - GlueContext 객체
protected void writeSheet(GlueContext ctx,
jxl.write.WritableSheet sheet,
String sheetId)
throws Exception
ctx - GlueContext 객체sheet - WritableSheet 객체sheetId - Sheet Id로 Export하려는 Data의 Key
Exception
protected String[] getColumnIds(GlueContext ctx,
String sheetId)
ctx - GlueContext 객체sheetId - Excel의
protected void writeHeader(jxl.write.WritableSheet sheet,
String[] columnIds,
String[] columnNames)
throws Exception
sheet - WritableSheet 객체columnIds - Column Id에 대한 String[]columnNames - Column명에 대한 String[]
Exception
protected void writeBody(jxl.write.WritableSheet sheet,
List<Map<String,Object>> list,
String[] columnIds)
throws Exception
sheet - WritableSheet 객체list - Excel에 Write하려는 Data 객체columnIds - Column Id에 대한 String[]
Exception
protected void writeRow(jxl.write.WritableSheet sheet,
Map<String,Object> map,
String[] columnIds,
int y)
throws Exception
sheet - WritableSheet 객체map - Write하려는 Data Map.columnIds - Column Id에 대한 String[]y - write하려는 Line.
Exception
protected void writeCell(jxl.write.WritableSheet sheet,
int x,
int y,
Object data,
String comment)
throws Exception
sheet - WritableSheet 객체x - cell의 x 좌표 위치y - cell의 y 좌표 위치data - cell에 표기하려는 내용comment - Column Id로 null이 아닌 경우 Comment(메모)로 삽입된다.
Exceptionprotected void writeImage()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||