public static Integer[] getPermissions(int permission){
        ArrayList<Integer> perns = new ArrayList<>();
        if(hasPermission(permission, ADMINISTRATIVE_PERSONNEL)) perns.add(ADMINISTRATIVE_PERSONNEL);
        if(hasPermission(permission, PROFESSOR)) perns.add(PROFESSOR);
        if(hasPermission(permission, SYSTEM_ADMIN)) perns.add(SYSTEM_ADMIN);
        if(hasPermission(permission, EXTRA_FLAG)) perns.add(EXTRA_FLAG);
        
        return  (Integer[]) perns.toArray(new Integer[perns.size()]);
    }