Пример #1
0
            public Selection([NotNull] EnvDTE.TextDocument textDocument, [NotNull] string line, [CanBeNull] EnvDTE.FileCodeModel codeModel)
            {
                Contract.Requires(textDocument != null);
                Contract.Requires(line != null);

                _textDocument = textDocument;
                _line         = line;
                _codeModel    = codeModel;
            }
 public int CreateFileCodeModel(
     string fileName,
     object parent,
     out EnvDTE.FileCodeModel ppFileCodeModel
     )
 {
     ppFileCodeModel = ProjectCodeModel.GetOrCreateFileCodeModel(fileName, parent);
     return(VSConstants.S_OK);
 }
Пример #3
0
        public override int CreateFileCodeModel(string fileName, object parent, out EnvDTE.FileCodeModel ppFileCodeModel)
        {
            var codeModelCache = ProjectCodeModel.GetCodeModelCache();

            if (codeModelCache == null)
            {
                ppFileCodeModel = null;
                return(VSConstants.E_FAIL);
            }

            ppFileCodeModel = codeModelCache.GetOrCreateFileCodeModel(fileName, parent).Handle;
            return(VSConstants.S_OK);
        }
Пример #4
0
 public Selection([NotNull] EnvDTE.TextDocument textDocument, [NotNull] string line, [CanBeNull] EnvDTE.FileCodeModel codeModel)
 {
     _textDocument = textDocument;
     Line          = line;
     _codeModel    = codeModel;
 }
 public abstract int CreateFileCodeModel(string fileName, object parent, out EnvDTE.FileCodeModel ppFileCodeModel);
 internal FileCodeModelInfo(EnvDTE.FileCodeModel codeModel, uint itemId)
 {
     this.codeModel = codeModel;
     this.itemId    = itemId;
 }