protected virtual IAbstractDirective ProcessDirective(DothtmlDirectiveNode directiveNode)
        {
            if (string.Equals(ParserConstants.ImportNamespaceDirective, directiveNode.Name) || string.Equals(ParserConstants.ResourceNamespaceDirective, directiveNode.Name))
            {
                return(ProcessImportDirective(directiveNode));
            }

            return(treeBuilder.BuildDirective(directiveNode));
        }
示例#2
0
        protected virtual IAbstractDirective ProcessDirective(DothtmlDirectiveNode directiveNode)
        {
            if (string.Equals(ParserConstants.ImportNamespaceDirective, directiveNode.Name) || string.Equals(ParserConstants.ResourceNamespaceDirective, directiveNode.Name))
            {
                return(ProcessImportDirective(directiveNode));
            }
            else if (string.Equals(ParserConstants.ViewModelDirectiveName, directiveNode.Name, StringComparison.OrdinalIgnoreCase))
            {
                return(ProcessViewModelDirective(directiveNode));
            }
            else if (string.Equals(ParserConstants.BaseTypeDirective, directiveNode.Name, StringComparison.OrdinalIgnoreCase))
            {
                return(ProcessBaseTypeDirective(directiveNode));
            }

            return(treeBuilder.BuildDirective(directiveNode));
        }