コード例 #1
0
ファイル: AttributeFeed.cs プロジェクト: keichinger/OmniXAML
        private static NsPrefix GetNsDefinition(UnprocessedAttributeBase assignment)
        {
            if (assignment.Locator.Prefix == "xmlns")
            {
                return(new NsPrefix(assignment.Locator.PropertyName, assignment.Value));
            }
            if (assignment.Locator.PropertyName == "xmlns")
            {
                return(new NsPrefix("", assignment.Value));
            }

            throw new XamlParseException($"Cannot extract a Namespace Prefix Definition from this assignment: {assignment}");
        }
コード例 #2
0
ファイル: AttributeFeed.cs プロジェクト: modulexcite/OmniXAML
        private static NsPrefix GetNsDefinition(UnprocessedAttributeBase assignment)
        {
            if (assignment.Locator.Prefix == "xmlns")
            {
                return new NsPrefix(assignment.Locator.PropertyName, assignment.Value);
            }
            if (assignment.Locator.PropertyName == "xmlns")
            {
                return new NsPrefix("", assignment.Value);
            }

            throw new ParseException($"Cannot extract a Namespace Prefix Definition from this assignment: {assignment}");
        }