예제 #1
0
        public bool Initialize(IDataContext context)
        {
            _solution = context.GetData(JetBrains.IDE.DataConstants.SOLUTION);
            _page     = new AddDependencyPage(
                s => _parameterType = s,
                context.GetData(JetBrains.IDE.DataConstants.SOLUTION));
            var @class = GetClass(context);

            _class = @class.CreateElementPointer();
            var ctor = @class.Constructors.FirstOrDefault();

            if (ctor != null)
            {
                _ctor = ctor.CreateElementPointer();
            }
            return(true);
        }
 public bool Initialize(IDataContext context)
 {
     _solution = context.GetData(JetBrains.IDE.DataConstants.SOLUTION);
     _page = new AddDependencyPage(
         s => _parameterType = s,
         context.GetData(JetBrains.IDE.DataConstants.SOLUTION));
     var @class = GetClass(context);
     _class = @class.CreateElementPointer();
     var ctor = @class.Constructors.FirstOrDefault();
     if (ctor != null)
         _ctor = ctor.CreateElementPointer();
     return true;
 }