Return-Path: X-Original-To: apmail-any23-dev-archive@www.apache.org Delivered-To: apmail-any23-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8EBD617587 for ; Mon, 30 Mar 2015 23:31:38 +0000 (UTC) Received: (qmail 19793 invoked by uid 500); 30 Mar 2015 23:31:32 -0000 Delivered-To: apmail-any23-dev-archive@any23.apache.org Received: (qmail 19756 invoked by uid 500); 30 Mar 2015 23:31:32 -0000 Mailing-List: contact dev-help@any23.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@any23.apache.org Delivered-To: mailing list dev@any23.apache.org Received: (qmail 19743 invoked by uid 99); 30 Mar 2015 23:31:32 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 30 Mar 2015 23:31:32 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id D1CD0E1081; Mon, 30 Mar 2015 23:31:31 +0000 (UTC) From: lewismc To: dev@any23.apache.org Reply-To: dev@any23.apache.org References: In-Reply-To: Subject: [GitHub] any23 pull request: ANY23-247 FIX Attribute name itemscope associa... Content-Type: text/plain Message-Id: <20150330233131.D1CD0E1081@git1-us-west.apache.org> Date: Mon, 30 Mar 2015 23:31:31 +0000 (UTC) Github user lewismc commented on a diff in the pull request: https://github.com/apache/any23/pull/17#discussion_r27442017 --- Diff: core/src/main/java/org/apache/any23/validator/rule/MissingItemscopeAttributeValueRule.java --- @@ -0,0 +1,52 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.any23.validator.rule; + +import org.apache.any23.validator.DOMDocument; +import org.apache.any23.validator.Fix; +import org.apache.any23.validator.Rule; +import org.apache.any23.validator.RuleContext; + +/** + * This fixes missing attribute values for the 'itemscope' attribute, + * which was be associated with
nodes. + * Typically when such a snippet of XHTML is fed through the + * {@link org.apache.any23.extractor.rdfa.RDFa11Extractor}, and + * subsequently to Sesame's {@link org.semarglproject.sesame.rdf.rdfa.SesameRDFaParser}, + * it will result in the following behavior. + *
    + * {@code
    + * [Fatal Error] :23:15: Attribute name "itemscope" associated with an element type "div" must be followed by the ' = ' character.
    + * }
    + * 
+ * This Fix is an effort to mitigate against that happening. + * + */ +public class MissingItemscopeAttributeValueRule implements Fix { --- End diff -- I looked for it being registered during a single document extraction. It was my understanding that validation and fixes are registered and active as part of the extraction parameters agenda? If a vanilla SingleDocumentExtration is invoked... as per the Any23Test then by default the Fixes and Validations are activated. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. ---