package cn.cslg.report.common.core.annotation;

import java.lang.reflect.Method;

public class AnnotationParse {

    public static int[] permissionParse(Method method) throws Exception {
        if(method.isAnnotationPresent(Permission.class)){
            Permission annotation = method.getAnnotation(Permission.class);
            return annotation.roles();
        }
        return null;
    }
}
