@Override
    public boolean process(Set<? extends TypeElement> set, RoundEnvironment roundEnvironment) {
        Collection<? extends Element> annotatedElements =
                roundEnvironment.getElementsAnnotatedWith(XposedHook.class);
        List<TypeElement> types = new ImmutableList.Builder<TypeElement>()
                .addAll(ElementFilter.typesIn(annotatedElements))
                .build();

        hooks.clear();
        for (TypeElement type : types) {
            processType(type);
        }

        if (!hooks.isEmpty()) {
            Collections.sort(hooks);
            generateSourceFile();
            Logger.debug("process" + set + "@" + roundEnvironment);
        }

        return true;
    }
Created by guohao4 on 2017/9/6.
Email: Tornaco@163.com
android/annotation_processors/xposed_hook_compiler/src/main/java/github/tornaco/permission/compiler/XposedHookCompiler.java