Java源码示例:org.jeecgframework.poi.excel.annotation.ExcelEntity

示例1
/**
 * 判断是否不要在这个excel操作中
 * @param field
 * @param targetId
 * @return
 */
public static boolean isNotUserExcelUserThis(Field field, String targetId) {
	boolean boo = true;
	if(field.getAnnotation(ExcelIgnore.class)!=null){
		boo = true;
	}else if(boo&&field.getAnnotation(ExcelCollection.class)!=null
			&&isUseInThis(field.getAnnotation(ExcelCollection.class).exportName(),targetId)){
		boo = false;
	}else if(boo&&field.getAnnotation(Excel.class)!=null
			&&isUseInThis(field.getAnnotation(Excel.class).exportName(),targetId)){
		boo = false;
	}else if(boo&&field.getAnnotation(ExcelEntity.class)!=null
			&&isUseInThis(field.getAnnotation(ExcelEntity.class).exportName(),targetId)){
		boo = false;
	}
	return boo;
}
 
示例2
/**
 * 判断是否不要在这个excel操作中
 * 
 * @param
 * @param field
 * @param targetId
 * @return
 */
public static boolean isNotUserExcelUserThis(List<String> exclusionsList, Field field, String targetId) {
	boolean boo = true;
	if (field.getAnnotation(ExcelIgnore.class) != null) {
		boo = true;
	} else if (boo && field.getAnnotation(ExcelCollection.class) != null && isUseInThis(field.getAnnotation(ExcelCollection.class).name(), targetId) && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(ExcelCollection.class).name()))) {
		boo = false;
	} else if (boo && field.getAnnotation(Excel.class) != null && isUseInThis(field.getAnnotation(Excel.class).name(), targetId) && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(Excel.class).name()))) {
		boo = false;
	} else if (boo && field.getAnnotation(ExcelEntity.class) != null && isUseInThis(field.getAnnotation(ExcelEntity.class).name(), targetId) && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(ExcelEntity.class).name()))) {
		boo = false;
	}
	return boo;
}
 
示例3
/**
 * 判断是否不要在这个excel操作中
 * 
 * @param
 * @param field
 * @param targetId
 * @return
 */
public static boolean isNotUserExcelUserThis(List<String> exclusionsList, Field field, String targetId) {
	boolean boo = true;
	if (field.getAnnotation(ExcelIgnore.class) != null) {
		boo = true;
	} else if (boo && field.getAnnotation(ExcelCollection.class) != null && isUseInThis(field.getAnnotation(ExcelCollection.class).name(), targetId) && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(ExcelCollection.class).name()))) {
		boo = false;
	} else if (boo && field.getAnnotation(Excel.class) != null && isUseInThis(field.getAnnotation(Excel.class).name(), targetId) && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(Excel.class).name()))) {
		boo = false;
	} else if (boo && field.getAnnotation(ExcelEntity.class) != null && isUseInThis(field.getAnnotation(ExcelEntity.class).name(), targetId) && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(ExcelEntity.class).name()))) {
		boo = false;
	}
	return boo;
}
 
示例4
/**
 * 判断是否不要在这个excel操作中
 * 
 * @param
 * @param field
 * @param targetId
 * @return
 */
public static boolean isNotUserExcelUserThis(List<String> exclusionsList, Field field,
                                             String targetId) {
    boolean boo = true;
    if (field.getAnnotation(ExcelIgnore.class) != null) {
        boo = true;
    } else if (boo
               && field.getAnnotation(ExcelCollection.class) != null
               && isUseInThis(field.getAnnotation(ExcelCollection.class).name(), targetId)
               && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(
                   ExcelCollection.class).name()))) {
        boo = false;
    } else if (boo
               && field.getAnnotation(Excel.class) != null
               && isUseInThis(field.getAnnotation(Excel.class).name(), targetId)
               && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(
                   Excel.class).name()))) {
        boo = false;
    } else if (boo
               && field.getAnnotation(ExcelEntity.class) != null
               && isUseInThis(field.getAnnotation(ExcelEntity.class).name(), targetId)
               && (exclusionsList == null || !exclusionsList.contains(field.getAnnotation(
                   ExcelEntity.class).name()))) {
        boo = false;
    }
    return boo;
}