compiler 重构

This commit is contained in:
AriaLyy
2017-09-07 21:43:47 +08:00
parent ac99cc581f
commit 3574531d8d
31 changed files with 1103 additions and 912 deletions

View File

@@ -16,6 +16,7 @@
package com.arialyy.compiler;
import com.arialyy.annotations.Download;
import com.arialyy.annotations.DownloadGroup;
import com.arialyy.annotations.Upload;
import com.google.auto.service.AutoService;
import java.util.LinkedHashSet;
@@ -53,17 +54,24 @@ import javax.lang.model.element.TypeElement;
annotataions.add(Download.onTaskRunning.class.getCanonicalName());
annotataions.add(Download.onTaskStart.class.getCanonicalName());
annotataions.add(Download.onTaskStop.class.getCanonicalName());
//下载任务的注解
annotataions.add(Download.onPre.class.getCanonicalName());
annotataions.add(Download.onNoSupportBreakPoint.class.getCanonicalName());
annotataions.add(Download.onTaskCancel.class.getCanonicalName());
annotataions.add(Download.onTaskComplete.class.getCanonicalName());
annotataions.add(Download.onTaskFail.class.getCanonicalName());
annotataions.add(Download.onTaskPre.class.getCanonicalName());
annotataions.add(Download.onTaskResume.class.getCanonicalName());
annotataions.add(Download.onTaskRunning.class.getCanonicalName());
annotataions.add(Download.onTaskStart.class.getCanonicalName());
annotataions.add(Download.onTaskStop.class.getCanonicalName());
//下载任务的注解
annotataions.add(DownloadGroup.onPre.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskCancel.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskComplete.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskFail.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskPre.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskResume.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskRunning.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskStart.class.getCanonicalName());
annotataions.add(DownloadGroup.onTaskStop.class.getCanonicalName());
//任务组子任务的注解
annotataions.add(DownloadGroup.onSubTaskPre.class.getCanonicalName());
annotataions.add(DownloadGroup.onSubTaskCancel.class.getCanonicalName());
annotataions.add(DownloadGroup.onSubTaskComplete.class.getCanonicalName());
annotataions.add(DownloadGroup.onSubTaskFail.class.getCanonicalName());
annotataions.add(DownloadGroup.onSubTaskRunning.class.getCanonicalName());
annotataions.add(DownloadGroup.onSubTaskStart.class.getCanonicalName());
annotataions.add(DownloadGroup.onSubTaskStop.class.getCanonicalName());
//上传任务的注解
annotataions.add(Upload.onPre.class.getCanonicalName());
annotataions.add(Upload.onNoSupportBreakPoint.class.getCanonicalName());
@@ -86,6 +94,7 @@ import javax.lang.model.element.TypeElement;
mHandler.clean();
mHandler.handleDownload(roundEnv);
mHandler.handleDownloadGroup(roundEnv);
mHandler.handleDownloadGroupSub(roundEnv);
mHandler.handleUpload(roundEnv);
mHandler.createProxyFile();
return true;