mirror of https://github.com/alibaba/easyexcel
jipengfei.jpf
6 years ago
9 changed files with 90 additions and 52 deletions
@ -0,0 +1,28 @@
|
||||
package com.alibaba.easyexcel.test.model; |
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty; |
||||
import com.alibaba.excel.metadata.BaseRowModel; |
||||
|
||||
public class BaseReadModel extends BaseRowModel { |
||||
@ExcelProperty(index = 0) |
||||
protected String str; |
||||
|
||||
@ExcelProperty(index = 1) |
||||
protected Float ff; |
||||
public String getStr() { |
||||
return str; |
||||
} |
||||
|
||||
|
||||
public void setStr(String str) { |
||||
this.str = str; |
||||
} |
||||
|
||||
public Float getFf() { |
||||
return ff; |
||||
} |
||||
|
||||
public void setFf(Float ff) { |
||||
this.ff = ff; |
||||
} |
||||
} |
@ -0,0 +1,28 @@
|
||||
package com.alibaba.easyexcel.test.model; |
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty; |
||||
import com.alibaba.excel.metadata.BaseRowModel; |
||||
|
||||
public class BaseWriteModel extends BaseRowModel { |
||||
@ExcelProperty(value = {"表头1","表头1","表头31"},index = 0) |
||||
protected String p1; |
||||
|
||||
@ExcelProperty(value = {"表头1","表头1","表头32"},index = 1) |
||||
protected String p2; |
||||
|
||||
public String getP1() { |
||||
return p1; |
||||
} |
||||
|
||||
public void setP1(String p1) { |
||||
this.p1 = p1; |
||||
} |
||||
|
||||
public String getP2() { |
||||
return p2; |
||||
} |
||||
|
||||
public void setP2(String p2) { |
||||
this.p2 = p2; |
||||
} |
||||
} |
Loading…
Reference in new issue