예제 #1
0
        public IOutliningSource GetOutliningSource(ITextSnapshot snapshot)
        {
            if (snapshot != null)
            {
                // Create an outlining source based on the parse data
                var source = new JsonOutliningSource(snapshot);

                // Translate the data to the desired snapshot, which could be slightly newer than the parsed source
                source.TranslateTo(snapshot);

                return source;
            }
            return null;
        }
예제 #2
0
        public IOutliningSource GetOutliningSource(ITextSnapshot snapshot)
        {
            if (snapshot != null)
            {
                // Create an outlining source based on the parse data
                var source = new JsonOutliningSource(snapshot);

                // Translate the data to the desired snapshot, which could be slightly newer than the parsed source
                source.TranslateTo(snapshot);

                return(source);
            }
            return(null);
        }