Example #1
0
        public ConnectionModelProxy(object obj, IBackendContext backendContext)
        {
            instance     = obj;
            instanceType = instance.GetType();

            Context = backendContext;
        }
        public VariableModelProxy(object obj, IBackendContext backendContext)
        {
            instance = obj;
            instanceType = instance.GetType();

            Context = backendContext;
        }
        public CredentialModelProxy(object obj, IBackendContext backendContext)
        {
            instance = obj;
            instanceType = instance.GetType();

            Context = backendContext;
        }
Example #4
0
        public VariableModelProxy(object obj, IBackendContext backendContext)
        {
            instance     = obj;
            instanceType = instance.GetType();

            Context = backendContext;
        }
Example #5
0
        public JobModelProxy(object obj, IBackendContext backendContext)
        {
            instance     = obj;
            instanceType = instance.GetType();

            Result  = new List <JobOutput>();
            Context = backendContext;
        }
 public ResourceContainer(string title, object tag, string icon, IBackendContext context)
 {
     Title   = title;
     Tag     = tag;
     Icon    = icon;
     Context = context;
     _items  = new ObservableCollection <ResourceContainer>();
 }
Example #7
0
        public SmaService(IBackendContext context, BackendConnection connectionData)
        {
            _connectionData = connectionData;
            _backendContext = context;

            _viewModelsCache = new Dictionary<object, object>();
            _runbookRunningCache = new Dictionary<Guid, bool>();
        }
Example #8
0
        public JobModelProxy(object obj, IBackendContext backendContext)
        {
            instance = obj;
            instanceType = instance.GetType();

            Result = new List<JobOutput>();
            Context = backendContext;
        }
 public ResourceContainer(string title, object tag, string icon, IBackendContext context)
 {
     Title = title;
     Tag = tag;
     Icon = icon;
     Context = context;
     _items = new ObservableCollection<ResourceContainer>();
 }
Example #10
0
 public AzureRMService(IBackendContext context, BackendConnection connectionData)
 {
     _backendContext = context;
     _connectionData = connectionData;
     _tokens = new Dictionary<Guid, List<AccessToken>>();
     _output = IoC.Get<IOutput>();
     _jobCache = new Dictionary<Guid, Microsoft.Azure.Management.Automation.Models.Job>();
     _testJobCache = new Dictionary<Guid, TestJob>();
 }
Example #11
0
        public CompletionProvider(IBackendContext backendContext, LanguageContext languageContext)
        {
            _languageContext    = languageContext;
            _backendContext     = backendContext;
            _snippetsCollection = AppContext.Resolve <ISnippetsCollection>();

            _runspace = RunspaceFactory.CreateRunspace();
            _runspace.Open();
        }
        public CompletionProvider(IBackendContext backendContext, LanguageContext languageContext)
        {
            _languageContext = languageContext;
            _backendContext = backendContext;
            _snippetsCollection = AppContext.Resolve<ISnippetsCollection>();

            _runspace = RunspaceFactory.CreateRunspace();
            _runspace.Open();
        }
Example #13
0
        public DocumentationWindow(IBackendContext backendContext)
        {
            InitializeComponent();
            DataContext = new DocumentationViewModel(backendContext);

            (DataContext as DocumentationViewModel).OnFinished += delegate(object sender, EventArgs e)
            {
                Close();
            };
        }
        public DocumentationWindow(IBackendContext backendContext)
        {
            InitializeComponent();
            DataContext = new DocumentationViewModel(backendContext);

            (DataContext as DocumentationViewModel).OnFinished += delegate (object sender, EventArgs e)
            {
                Close();
            };
        }
        public CompletionProviderOriginal(IBackendContext backendContext, LanguageContext languageContext)
        {
            _languageContext = languageContext;
            _backendContext  = backendContext;

            _powershell          = PowerShell.Create();
            _powershell.Runspace = RunspaceFactory.CreateRunspace();
            _powershell.Runspace.ThreadOptions = PSThreadOptions.UseNewThread;
            _powershell.Runspace.Open();

            Keywords = new List <ICompletionEntry>();
            Runbooks = new List <ICompletionEntry>();
        }
        public CompletionProviderOriginal(IBackendContext backendContext, LanguageContext languageContext)
        {
            _languageContext = languageContext;
            _backendContext = backendContext;

            _powershell = PowerShell.Create();
            _powershell.Runspace = RunspaceFactory.CreateRunspace();
            _powershell.Runspace.ThreadOptions = PSThreadOptions.UseNewThread;
            _powershell.Runspace.Open();

            Keywords = new List<ICompletionEntry>();
            Runbooks = new List<ICompletionEntry>();
        }
Example #17
0
        public AzureService(IBackendContext context, BackendConnection connectionData)
        {
            _backendContext = context;
            _connectionData = connectionData;

            if (_certificate == null)
            {
                if (String.IsNullOrEmpty(_connectionData.AzureCertificateThumbprint))
                {
                    throw new ApplicationException("Azure Service is enabled but no certificate has been chosen or generated. Please correct this by editing your Azure connection.");
                }

                _certificate = CertificateManager.FindCertificate(_connectionData.AzureCertificateThumbprint);
                _webRequestHandler = new WebRequestHandler();
                _webRequestHandler.ClientCertificates.Add(_certificate);
                _httpClient = new HttpClient(_webRequestHandler);
            }
        }
 public DocumentationManager(IBackendContext backendContext)
 {
     _backendContext = backendContext;
     _statusManager  = AppContext.Resolve <IStatusManager>();
 }
 public DocumentationManager(IBackendContext backendContext)
 {
     _backendContext = backendContext;
     _statusManager = AppContext.Resolve<IStatusManager>();
 }
Example #20
0
 public ContextUpdatedEventArgs(IBackendContext context)
 {
     Context = context;
 }
 public DocumentationViewModel(IBackendContext backendContext)
 {
     _backendContext = backendContext;
     ButtonText = "Start";
 }
Example #22
0
 public ContextUpdatedEventArgs(IBackendContext context)
 {
     Context = context;
 }
 public DocumentationViewModel(IBackendContext backendContext)
 {
     _backendContext = backendContext;
     ButtonText      = "Start";
 }