private InstrumentBaseViewModel getInstBaseVM(string typeStr)
        {
            InstrumentBaseViewModel instBaseVM;

            Uri instIUri  = new Uri(PrototypeUri_.LocalPath + "prototype_" + typeStr + ".xml");
            Uri resultUri = new Uri(PrototypeUri_.LocalPath + "00000000_prototype_" + typeStr + ".xml");

            if (typeStr == "stepDownKI" || typeStr == "multiNameCDS")
            {
                InstUriInfo   instUriInfo   = new InstUriInfo("", "", instIUri);
                ResultUriInfo resultUriInfo = new ResultUriInfo("", "", resultUri);

                instBaseVM = new StandardInstBaseViewModel(instUriInfo);
                instBaseVM.ReferenceDate_ = PositionSingletonManger.referenceDate();
                instBaseVM.ResultUri_     = resultUriInfo;

                return(instBaseVM);
            }
            else
            {
                InstUriInfo instUriInfo = new InstUriInfo("", "", new Uri(""));
                instBaseVM = new NoExistInstrumentBaseViewModel(instUriInfo);
                return(instBaseVM);
            }
        }
        private InstrumentBaseViewModel getInstBaseVM(string typeStr)
        { 
            InstrumentBaseViewModel instBaseVM;

            Uri instIUri = new Uri(PrototypeUri_.LocalPath + "prototype_" + typeStr + ".xml");
            Uri resultUri = new Uri(PrototypeUri_.LocalPath + "00000000_prototype_" + typeStr + ".xml");

            if (typeStr == "stepDownKI" || typeStr == "multiNameCDS")
            {
                InstUriInfo instUriInfo = new InstUriInfo("", "", instIUri);
                ResultUriInfo resultUriInfo = new ResultUriInfo("", "", resultUri);

                instBaseVM = new StandardInstBaseViewModel(instUriInfo);
                instBaseVM.ReferenceDate_ = PositionSingletonManger.referenceDate();
                instBaseVM.ResultUri_ = resultUriInfo;

                return instBaseVM;
            }
            else
            {
                InstUriInfo instUriInfo = new InstUriInfo("", "", new Uri(""));
                instBaseVM = new NoExistInstrumentBaseViewModel(instUriInfo);
                return instBaseVM;
            }
        }
        public static ResultUriInfo CreateResultUriInfo(string itemCode, string itemType, DateTime referenceDate)
        {
            // 오면 데이터 베이스 뜯어서 존재하는지 보고 리거기서 fileName 받아서 리턴함.

            Uri uri = new Uri(ResultUri_.LocalPath + referenceDate.ToString("yyyyMMdd") + "_" + itemCode + "_" + itemType + ".xml");

            ResultUriInfo resultUri = new ResultUriInfo(itemCode, itemType, uri);

            return(resultUri);
        }
        public static ResultUriInfo CreateResultUriInfo(string itemCode, string itemType, DateTime referenceDate)
        {
            // 오면 데이터 베이스 뜯어서 존재하는지 보고 리거기서 fileName 받아서 리턴함.

            Uri uri = new Uri(ResultUri_.LocalPath + referenceDate.ToString("yyyyMMdd") + "_" + itemCode + "_" + itemType + ".xml");

            ResultUriInfo resultUri = new ResultUriInfo(itemCode, itemType, uri);

            return resultUri;
        }
Exemplo n.º 5
0
        public ResultUriInfo resultUri(FpmlSerializedCSharp.InstHirachyInfo serial_Class)
        {
            string itemCode = serial_Class.Code_.ValueStr;
            string itemType = serial_Class.Type_.ValueStr;

            Uri uri = new Uri(pathURLInfo_ + itemCode + "_" + itemType);

            ResultUriInfo resultUri = new ResultUriInfo(itemCode, itemType, uri);

            return(resultUri);
        }
        public static ResultUriInfo CreateResultUriInfo(FileInfo instFileInfo, DateTime referenceDate)
        {
            string fileName = instFileInfo.Name;
            string exeptExtensionfileName = fileName.Replace(".xml", "");

            string itemCode = exeptExtensionfileName.Substring(0, 11);
            string itemType = exeptExtensionfileName.Substring(13);

            Uri uri = new Uri(instFileInfo.FullName);

            ResultUriInfo resultUri = new ResultUriInfo(itemCode, itemType, uri);

            return(resultUri);
        }
        public static ResultUriInfo CreateResultUriInfo(FileInfo instFileInfo, DateTime referenceDate)
        {
            string fileName = instFileInfo.Name;
            string exeptExtensionfileName = fileName.Replace(".xml", "");

            string itemCode = exeptExtensionfileName.Substring(0, 11);
            string itemType = exeptExtensionfileName.Substring(13);

            Uri uri = new Uri(instFileInfo.FullName);

            ResultUriInfo resultUri = new ResultUriInfo(itemCode, itemType, uri);

            return resultUri;
        }
        public ResultUriInfo resultUri(FpmlSerializedCSharp.InstHirachyInfo serial_Class)
        {
            string itemCode = serial_Class.Code_.ValueStr;
            string itemType = serial_Class.Type_.ValueStr;

            Uri uri = new Uri(pathURLInfo_ + itemCode + "_" + itemType);

            ResultUriInfo resultUri = new ResultUriInfo(itemCode, itemType, uri);

            return resultUri;
        }