/** * @param clazz * @param reportParams * @return * @throws IllegalArgumentException * @throws IllegalAccessException Setting the report header all params * @throws ClassNotFoundException */ @SuppressWarnings("rawtypes") protected Kismiss setReportParams(Class clazz, Map<String, Object> reportParams) throws Exception { Kismiss kismiss = null; try { Annotation[] annotations = clazz.getAnnotations(); for (Annotation annotation : annotations) { if (annotation instanceof Kismiss) { kismiss = (Kismiss) annotation; setReportParams(kismiss, reportParams); setReportParams(reportParams, kismiss, kismiss.paperType()); } } } catch (Exception e) { logger.error("[Kismiss:setreportParams] Error happended => {}", e.getMessage()); throw new Exception(e); } return kismiss; }