public final class SuidHelper extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T> T |
copyEntity(Object from,
T to)
将to在from有的属性,都复制到to中.
|
static <T> List<T> |
copyListEntity(List<?> fromList,
Class<T> toClassType) |
static <T> Map<String,Object> |
entityToMap(T entity)
将entity实体转为Map,字段为serialVersionUID,JoinTable,Ignore,值为null,将被忽略.
|
static String |
parseFirstColumn(List<String[]> list)
将List
|
static <T> List<T> |
parseToEntity(List<String[]> list,
int startRow,
int endRow,
String[] fieldName,
T entity)
将List里的字符数组转成entity结构.Convert the character array in the list to entity structure.
|
static <T> List<T> |
parseToEntity(List<String[]> list,
int startRow,
int endRow,
String fieldNames,
T entity)
将List里的字符数组转成entity结构.Convert the character array in the list to entity structure.
|
static <T> List<T> |
parseToEntity(List<String[]> list,
int startRow,
String[] fieldName,
T entity)
将List里的字符数组转成entity结构.Convert the character array in the list to entity structure.
|
static <T> List<T> |
parseToEntity(List<String[]> list,
int startRow,
String fieldNames,
T entity)
将List里的字符数组转成entity结构.Convert the character array in the list to entity structure.
|
public static String parseFirstColumn(List<String[]> list)
list - Listpublic static <T> List<T> parseToEntity(List<String[]> list, int startRow, String fieldNames, T entity)
list - 需要转换的字符数组List.List of character arrays to be converted.startRow - 开始行.start row.fieldNames - 字段名(多个用逗号隔开).Field names (multiple separated by commas).entity - 要转成的结构.the structure to be transformed into.public static <T> List<T> parseToEntity(List<String[]> list, int startRow, int endRow, String fieldNames, T entity)
list - 需要转换的字符数组List.List of character arrays to be converted.startRow - 开始行.start row.endRow - 结束行.end row.fieldNames - 字段名(多个用逗号隔开).Field names (multiple separated by commas).entity - 要转成的结构.the structure to be transformed into.public static <T> List<T> parseToEntity(List<String[]> list, int startRow, String[] fieldName, T entity)
list - 需要转换的字符数组List.List of character arrays to be converted.startRow - 开始行.start row.fieldName - 字段名数组.field name array.entity - 要转成的结构.the structure to be transformed into.public static <T> List<T> parseToEntity(List<String[]> list, int startRow, int endRow, String[] fieldName, T entity)
list - 需要转换的字符数组List.List of character arrays to be converted.startRow - 开始行.start row.endRow - 结束行.end row.fieldName - 字段名数组.field name array.entity - 要转成的结构.the structure to be transformed into.public static <T> T copyEntity(Object from, T to)
from - to - public static <T> Map<String,Object> entityToMap(T entity)
entity - 需要转为Map的entity实体Copyright © 2024. All rights reserved.