Exemplo n.º 1
0
        public static XamlParseError MismatchedVersionSDKType(ITextLocation lineInformation, IType childType, FrameworkName frameworkName)
        {
            string str           = (string)(frameworkName.Identifier == "Silverlight" ? (object)frameworkName.Identifier : (object)"Windows Presentation Framework") + (object)" " + (string)(object)frameworkName.Version.Major;
            string messageFormat = string.Format((IFormatProvider)CultureInfo.CurrentCulture, StringTable.MismatchedVersionSDKType, (object)childType.Name, (object)childType.RuntimeAssembly.Name, (object)str);

            return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.MismatchedType, lineInformation, messageFormat));
        }
Exemplo n.º 2
0
 public static XamlParseError MemberNotRoutedEvent(ITextLocation lineInformation, IMemberId memberId)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.MemberNotRoutedEvent, lineInformation, StringTable.ParserMemberNotRoutedEvent, memberId.Name));
 }
Exemplo n.º 3
0
 public static XamlParseError PropertyIsNotWritable(ITextLocation lineInformation, IPropertyId propertyKey)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.PropertyIsNotWritable, lineInformation, StringTable.ParserPropertyIsNotWritable, propertyKey.Name));
 }
Exemplo n.º 4
0
 public static XamlParseError NestedPropertiesNotSupported(ITextLocation lineInformation, string propertyName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.NestedPropertiesNotSupported, lineInformation, StringTable.ParserNestedPropertiesNotSupported, propertyName));
 }
Exemplo n.º 5
0
 public static XamlParseError InaccessibleType(ITextLocation lineInformation, string typeName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.InaccessibleType, lineInformation, StringTable.ParserInaccessibleType, typeName));
 }
Exemplo n.º 6
0
 public static XamlParseError UnrecognizedPlatformTypeName(ITextLocation lineInformation, bool isSilverlightProject, string typeName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnrecognizedTypeName, lineInformation, StringTable.ParserUnrecognizedPlatformTypeName, isSilverlightProject ? StringTable.ParserSilverlightPlatformName : StringTable.ParserWPFPlatformName, typeName));
 }
Exemplo n.º 7
0
 public static XamlParseError InvalidClassName(ITextLocation lineInformation, string typeName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Warning, XamlErrorCode.InvalidClassName, lineInformation, StringTable.ParserInvalidClassName, typeName));
 }
Exemplo n.º 8
0
 public static XamlParseError MultipleRootElements(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.MultipleRootElements, lineInformation, StringTable.ParserMultipleRootElements));
 }
Exemplo n.º 9
0
 public static XamlParseError UnexpectedPositionalArgument(ITextLocation lineInformation, string argumentName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnexpectedPositionalArgument, lineInformation, StringTable.ParserUnexpectedPositionalArgument, argumentName));
 }
Exemplo n.º 10
0
 public static XamlParseError MissingArgumentName(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.MissingArgumentName, lineInformation, StringTable.ParserMissingArgumentName));
 }
Exemplo n.º 11
0
 public static XamlParseError ParentTypeDoesNotSupportChildren(ITextLocation lineInformation, ITypeId parentType)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.ParentTypeDoesNotSupportChildren, lineInformation, StringTable.ParserParentTypeDoesNotSupportChildren, parentType.Name));
 }
Exemplo n.º 12
0
 public static XamlParseError NoRootElement(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.NoRootElement, lineInformation, StringTable.ParserNoRootElement));
 }
Exemplo n.º 13
0
 public static XamlParseError MissingDictionaryKey(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.MissingDictionaryKey, lineInformation, StringTable.ParserMissingDictionaryKey));
 }
Exemplo n.º 14
0
 public static XamlParseError AttachedPropertyDoesNotApply(ITextLocation lineInformation, IProperty propertyKey)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.AttachedPropertyDoesNotApply, lineInformation, StringTable.ParserAttachedPropertyDoesNotApply, propertyKey.Name, propertyKey.TargetType.Name));
 }
Exemplo n.º 15
0
 public static XamlParseError TypeInitializationException(ITextLocation lineInformation, ITypeId typeId, string message)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.TypeInitializationException, lineInformation, StringTable.ParserTypeInitializationException, typeId.Name, message));
 }
Exemplo n.º 16
0
 public static XamlParseError UnknownError(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnknownError, lineInformation, StringTable.ParserUnknownError));
 }
Exemplo n.º 17
0
 public static XamlParseError InvalidMarkupExtensionArguments(ITextLocation lineInformation, string markupExtensionName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.InvalidMarkupExtensionArguments, lineInformation, StringTable.ParserInvalidMarkupExtensionArguments, markupExtensionName));
 }
Exemplo n.º 18
0
 public static XamlParseError UnexpectedCharacter(ITextLocation lineInformation, char c)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnexpectedCharacter, lineInformation, StringTable.ParserUnexpectedCharacter, c.ToString()));
 }
Exemplo n.º 19
0
 public static XamlParseError NoDefaultNamespace(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.NoDefaultNamespace, lineInformation, StringTable.ParserNoDefaultNamespace));
 }
Exemplo n.º 20
0
 public static XamlParseError InvalidPropertyPathSyntax(ITextLocation lineInformation, string propertyPath)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.InvalidPropertyPathSyntax, lineInformation, StringTable.ParserInvalidPropertyPathSyntax, propertyPath));
 }
Exemplo n.º 21
0
 public static XamlParseError DuplicateXmlnsPrefix(ITextLocation lineInformation, XmlnsPrefix prefix)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.DuplicateXmlnsPrefix, lineInformation, StringTable.ParserDuplicateXmlnsPrefix, prefix.Value));
 }
Exemplo n.º 22
0
 public static XamlParseError InvalidClrNamespaceUri(ITextLocation lineInformation, string uriValue)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.InvalidClrNamespaceUri, lineInformation, StringTable.ParserInvalidClrNamespaceUri, uriValue));
 }
Exemplo n.º 23
0
 public static XamlParseError UnrecognizedTypeName(ITextLocation lineInformation, XmlNamespace xmlNamespace, string typeName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnrecognizedTypeName, lineInformation, StringTable.ParserUnrecognizedTypeName, xmlNamespace.Value, typeName));
 }
Exemplo n.º 24
0
 public static XamlParseError InvalidXmlSpace(ITextLocation lineInformation, string value)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.InvalidXmlSpace, lineInformation, StringTable.ParserInvalidXmlSpace, value));
 }
Exemplo n.º 25
0
 public static XamlParseError InnerTypesNotSupported(ITextLocation lineInformation, string typeName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.InnerTypesNotSupported, lineInformation, StringTable.ParserInnerTypesNotSupported, typeName));
 }
Exemplo n.º 26
0
 public static XamlParseError UnexpectedRootType(ITextLocation lineInformation, ITypeId expectedType)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnexpectedRootType, lineInformation, StringTable.ParserUnexpectedRootType, expectedType.Name));
 }
Exemplo n.º 27
0
 public static XamlParseError UnrecognizedOrInaccessibleMember(ITextLocation lineInformation, string memberName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.UnrecognizedOrInaccessibleMember, lineInformation, StringTable.ParserUnrecognizedOrInaccessibleMember, memberName));
 }
Exemplo n.º 28
0
 public static XamlParseError CDataNotSupported(ITextLocation lineInformation)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.CDataNotSupported, lineInformation, StringTable.ParserCDataNotSupported));
 }
Exemplo n.º 29
0
 public static XamlParseError CannotDetermineMemberTargetType(ITextLocation lineInformation, string memberName)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.CannotDetermineMemberTargetType, lineInformation, StringTable.ParserCannotDetermineMemberTargetType, memberName));
 }
Exemplo n.º 30
0
 public static XamlParseError MemberNotDependencyProperty(ITextLocation lineInformation, IMemberId memberId)
 {
     return(XamlParseErrors.NewParseError(XamlErrorSeverity.Error, XamlErrorCode.MemberNotDependencyProperty, lineInformation, StringTable.ParserMemberNotDependencyProperty, memberId.Name));
 }