code: public static boolean containsUnspecifiedAttributes(Tag tag, String[] standardAttributesSorted)
      {
          for (TagAttribute attribute : tag.getAttributes().getAll())
          {
              final String name = attribute.getLocalName();
              if (Arrays.binarySearch(standardAttributesSorted, name) < 0)
              {
                  return true;
              }
          }
          return false;
      }
docs: Returns true if the given Tag contains attributes that are not
  specified in standardAttributesSorted.
  NOTE that standardAttributesSorted has to be alphabetically sorted in
  order to use binary search.
  @param tag
  @param standardAttributesSorted
  @return