code: private List<DependencyError> checkAllowedSection(final Dependencies dependencies, final Package<DependsOn> allowedPkg,
              final ClassInfo classInfo) {
  
          final List<DependencyError> errors = new ArrayList<DependencyError>();
  
          final Iterator<String> it = classInfo.getImports().iterator();
          while (it.hasNext()) {
              final String importedPkg = it.next();
              if (!importedPkg.equals(allowedPkg.getName()) && !dependencies.isAlwaysAllowed(importedPkg)) {
                  final DependsOn dep = Utils.findAllowedByName(allowedPkg.getDependencies(), importedPkg);
                  if (dep == null) {
                      errors.add(new DependencyError(classInfo.getName(), importedPkg, allowedPkg.getComment()));
                  }
              }
          }
          return errors;
  
      }
docs: Checks the dependencies for a package from the "allowed" section.
  
  @param dependencies
  Dependency definition to use.
  @param allowedPkg
  Package with allowed imports.
  @param classInfo
  Information extracted from the class.
  
  @return List of errors - may be empty but is never <code>null</code>.