Exemplo n.º 1
0
        public void OnInstrumentAdded(object sender, SourceInstrumentMetadata instrument)
        {
            var InstrumentSelectedDelegate = AddInstrument as EventHandler <AddInstrumentEventArgs>;

            if (InstrumentSelectedDelegate != null)
            {
                InstrumentSelectedDelegate(sender, new AddInstrumentEventArgs {
                    Instrument = instrument
                });
            }
        }
Exemplo n.º 2
0
        private void InitializeCurrentInstrument()
        {
            CurrentInstrument = new SourceInstrumentMetadata();

            switch (InstrumentFileType)
            {
            case "MSLocal":
                CurrentInstrument.RepositoryPath = CurrentMSLocalInstrument.FolderPath;
                CurrentInstrument.Symbol         = CurrentMSLocalInstrument.Symbol;
                CurrentInstrument.Range          = 60;
                CurrentInstrument.FileType       = "MSLocal";
                break;

            case "CSV":
                CurrentInstrument.RepositoryPath = CSVFilePath;
                CurrentInstrument.Symbol         = Path.GetFileNameWithoutExtension(CSVFilePath);
                CurrentInstrument.Range          = 60;
                CurrentInstrument.FileType       = "CSV";
                break;
            }
        }
 private SourceInstrumentMetadata UpdateCurrentInstrument(SourceInstrumentMetadata instrument)
 {
     return(CurrentInstrument = instrument);
 }