public WinterDimension(Building building, DimensionInfo info) : base("Maps/" + info.MapName + Math.Max(1, info.DimensionImplementation.CurrentStage()), info.MapName)
        {
            this.building               = building;
            this.info                   = info;
            seasonOverride              = "winter";
            isOutdoors.Value            = true;
            ignoreDebrisWeather.Value   = true;
            ignoreOutdoorLighting.Value = true;
            punishmentStage             = info.DimensionImplementation.CurrentStage() == 5 && openedPresents[5].Count() == 0 ? 3 : 0;
            info.DimensionImplementation.StageChanged += StageChanged_UpdateStage;

            // Initialize presents
            if (building.modData.ContainsKey(modData_openedPresents))
            {
                openedPresents = JsonConvert.DeserializeObject <Dictionary <int, HashSet <Point> > >(building.modData[modData_openedPresents]);
            }
            if (building.modData.ContainsKey(modData_randomPresents))
            {
                presents[6] = JsonConvert.DeserializeObject <Dictionary <Point, int> >(building.modData[modData_randomPresents]);
            }
            if (building.modData.ContainsKey(modData_stageOpened))
            {
                daysPlayedAtStageOpen = Convert.ToUInt32(building.modData[modData_stageOpened]);
            }
            else
            {
                daysPlayedAtStageOpen = Game1.stats.DaysPlayed;
                building.modData[modData_stageOpened] = Convert.ToString(daysPlayedAtStageOpen);
            }
            if (info.DimensionImplementation.CurrentStage() > 0)
            {
                updatePresents();
            }

            Utility.Helper.ConsoleCommands.Add("winter", "", (a, b) =>
            {
                var days = (uint)1;
                if (b.Length == 1)
                {
                    days = Convert.ToUInt32(b[0]);
                }
                //daysPlayedAtStageOpen -= days;
                Game1.stats.DaysPlayed += days;
                DayUpdate(Game1.dayOfMonth);
            });
            Utility.Helper.ConsoleCommands.Add("santa", "", (a, b) =>
            {
                Game1.addMail(mail_santaLetter, true, true);
                StageChanged_UpdateStage(this, new DimensionStageChangedArgs(5, 6));
            });
        }
Exemple #2
0
        private void writeDimensionInfo(DimensionInfo info)
        {
            _writer.WriteStartElement(SubElements.Dimension);
            if (info.Length != 0)
            {
                _writer.WriteAttribute(Attributes.Length, info.Length);
            }
            if (info.LowerBound != 0)
            {
                _writer.WriteAttribute(Attributes.LowerBound, info.LowerBound);
            }

            _writer.WriteEndElement();
        }
        protected override void RefreshTree()
        {
            base.RefreshTree();

            if (CubeInfo != null)
            {
                // Если задано уникальное имя измерения, то создаем для данного измерения узел
                if (!String.IsNullOrEmpty(DimensionUniqueName))
                {
                    DimensionInfo info = CubeInfo.GetDimension(DimensionUniqueName);
                    if (info != null)
                    {
                        if (!String.IsNullOrEmpty(HierarchyUniqueName))
                        {
                            HierarchyInfo hierarchyInfo = info.GetHierarchy(HierarchyUniqueName);
                            if (hierarchyInfo != null)
                            {
                                HierarchyTreeNode hierarchyNode = AddHierarchyNode(null, hierarchyInfo);
                                CreateLevels(hierarchyNode, hierarchyInfo, false);
                                hierarchyNode.IsExpanded = true;
                                return;
                            }
                            else
                            {
                                LogManager.LogError(this, String.Format(Localization.MetadataResponseException_HierarchyByUniqueName_InDimension_NotFound, HierarchyUniqueName, DimensionUniqueName));
                            }
                        }
                        else
                        {
                            DimensionTreeNode dimNode = AddDimensionNode(null, info);
                            CreateHierarchies(dimNode, info, true);
                            dimNode.IsExpanded = true;
                            return;
                        }
                    }
                    else
                    {
                        LogManager.LogError(this, String.Format(Localization.MetadataResponseException_DimensionByUniqueName_InCube_NotFound, DimensionUniqueName, CubeName));
                    }
                }

                // Отображаем все измерения
                CreateDimensions(null, CubeInfo, true);
            }
        }
        private ArrayInfo GetArrayInfo(Type arrayType)
        {
            // Caching is unacceptable, as an array of type string can have different bounds
            var info = new ArrayInfo();

            // Fill the dimension infos
            for (var dimension = 0; dimension < GetRank(arrayType); dimension++)
            {
                var dimensionInfo = new DimensionInfo
                {
                    Length     = GetLength(dimension, arrayType),
                    LowerBound = GetLowerBound(dimension, arrayType)
                };
                info.DimensionInfos.Add(dimensionInfo);
            }

            return(info);
        }
        private bool tryLoadDimension(DirectoryInfo worldFolder, Dimensions dimensionType, out DimensionInfo dimension)
        {
            dimension = new DimensionInfo(dimensionType);

            var folderName = DimensionTranslations.Items[dimensionType].Folder;
            var folder     = worldFolder.GetDirectories(folderName);

            if (!folder.Any())
            {
                return(false);
            }

            var regionFolder = folder.First().GetDirectories("region");

            if (!regionFolder.Any())
            {
                return(false);
            }

            dimension.Size = folder.First().GetSize();
            return(true);
        }
        private void writeDimensionInfo(DimensionInfo info)
        {
            // Length
            _writer.WriteNumber(info.Length);

            // LowerBound
            _writer.WriteNumber(info.LowerBound);
        }
 private void readDimensionInfo(IList<DimensionInfo> dimensionInfos)
 {
     var info = new DimensionInfo();
     info.Length = _reader.GetAttributeAsInt(Attributes.Length);
     info.LowerBound = _reader.GetAttributeAsInt(Attributes.LowerBound);
     dimensionInfos.Add(info);
 }
Exemple #8
0
        public static void Load()
        {
            int      axleCount;
            DateTime time;

            //找出该列车的探测时间和轴数
            //采用数据的优先级为 AEI -> 探伤 -> 几何尺寸 -> 擦伤
            if (AeiFile != null)
            {
                var a = AeiInfo.Create(AeiFile);
                axleCount = a.AxleCount;
                time      = a.Time;
            }
            else if (InspectionFile != null)
            {
                var ins = InspectionInfo.Create(InspectionFile);
                axleCount = ins.Formations.Count * 32;
                time      = DateTime.ParseExact(ins.Time, "yyyyMMddHHmmss", null);
            }
            else if (DimensionFile != null)
            {
                var dim = DimensionInfo.Create(DimensionFile);
                axleCount = dim.BaseInfo.AxleCount;
                time      = DateTime.ParseExact(dim.BaseInfo.DetectionTime, "yyyyMMddHHmmss", null);
            }
            else if (ScrapeFile != null)
            {
                var scr = ScrapeInfo.Create(ScrapeFile);
                axleCount = scr.AxleCnt;
                time      = DateTime.ParseExact(scr.Time, "yyyyMMddHHmmss", null);
            }
            else
            {
                throw new Exception("AEI,探伤,几何尺寸,擦伤报文均不存在,无法入库");
            }
            if (axleCount >= 22 && axleCount <= 42)
            {
                axleCount = 32;
            }
            else if (axleCount > 42 && axleCount <= 74)
            {
                axleCount = 64;
            }
            ScrapeInfo     scrape;
            DimensionInfo  dimension;
            AeiInfo        aei;
            InspectionInfo inspection;

            if (ScrapeFile is null)
            {
                scrape = ScrapeInfo.CreateDefault(axleCount, time);
            }
            else
            {
                scrape = ScrapeInfo.Create(ScrapeFile);
            }
            if (AeiFile is null)
            {
                aei = AeiInfo.CreateDefault(axleCount, time);
            }
            else
            {
                aei = AeiInfo.Create(AeiFile);
            }
            if (DimensionFile is null)
            {
                dimension = DimensionInfo.CreateDefault(axleCount, time);
            }
            else
            {
                dimension = DimensionInfo.Create(DimensionFile);
            }
            if (InspectionFile is null)
            {
                inspection = InspectionInfo.CreateDefault(axleCount, time);
            }
            else
            {
                inspection = InspectionInfo.Create(InspectionFile);
            }
            var loader = new Uploader(scrape, dimension, inspection, aei);

            loader.Insert();


            Clear();
        }
Exemple #9
0
        public void GetBudgetDimensionInfo()
        {
            DynamicObjectCollection objects = this.dyRptScheme["DimensionEntity"] as DynamicObjectCollection;

            this.dicDimensionInfo.Clear();
            this.dicDimensionField.Clear();
            int num = 1;

            foreach (DynamicObject obj2 in objects)
            {
                DynamicObject obj3 = obj2["DimensionID"] as DynamicObject;
                if (((obj3 != null) && (Convert.ToString(obj3["BaseDataType_Id"]) != "BM_BUDGETCALENDAR")) && (Convert.ToString(obj3["BaseDataType_Id"]) != "BM_DEPTORG"))
                {
                    string        str    = Convert.ToString(obj3["Category"]);
                    string        formId = Convert.ToString(obj3["BaseDataType_Id"]);
                    int           key    = Convert.ToInt32(obj3["Id"]);
                    DimensionInfo info   = new DimensionInfo {
                        Id              = key,
                        Name            = Convert.ToString(obj3["Name"]),
                        Category        = str,
                        DataControlType = 1
                    };
                    if (str == "10")
                    {
                        formId               = "BOS_ASSISTANTDATA_SELECT";
                        info.PKFieldName     = "FEntryID";
                        info.TableName       = "T_BAS_ASSISTANTDATAENTRY";
                        info.NumberFieldName = "FNUMBER";
                        info.NameFieldName   = "FDATAVALUE";
                        info.NameTableName   = "T_BAS_ASSISTANTDATAENTRY_L";
                    }
                    else
                    {
                        info.FormId = formId;
                        BusinessInfo demensionMetaData = this.GetDemensionMetaData(formId);
                        info.PKFieldName = demensionMetaData.GetForm().PkFieldName;
                        string nameFieldKey = demensionMetaData.GetForm().NameFieldKey;
                        if (!string.IsNullOrWhiteSpace(nameFieldKey))
                        {
                            info.NameFieldName = nameFieldKey;
                            if (demensionMetaData.GetField(nameFieldKey) is MultiLangTextField)
                            {
                                info.NameTableName = demensionMetaData.GetField(nameFieldKey).TableName + "_L";
                            }
                            else
                            {
                                info.NameTableName = demensionMetaData.GetField(nameFieldKey).TableName;
                            }
                        }
                        info.NumberFieldName = demensionMetaData.GetForm().NumberFieldKey;
                        info.TableName       = demensionMetaData.GetField(demensionMetaData.GetForm().NumberFieldKey).TableName;
                        int baseDataType = ServiceHelper.GetService <IOrganizationService>().GetBaseDataType(base.Context, formId);
                        if (baseDataType == 2)
                        {
                            string masterPKFieldName = demensionMetaData.GetForm().MasterPKFieldName;
                            if (!string.IsNullOrWhiteSpace(masterPKFieldName))
                            {
                                info.DataControlType   = baseDataType;
                                info.MasterIDFieldName = masterPKFieldName;
                            }
                        }
                    }
                    if (this.filterParameter.DicDimissionFilter.ContainsKey(key))
                    {
                        info.IsShowField = true;
                        string str5 = string.Format("FDIMENSIONID{0}", num);
                        string str6 = string.Format("FDIMENSIONNAME{0}", num);
                        info.ShowFieldId   = str5;
                        info.ShowFieldName = str6;
                        this.dicDimensionField.Add(str5, str6);
                        num++;
                    }
                    else
                    {
                        info.IsShowField = false;
                    }
                    this.dicDimensionInfo.Add(key, info);
                }
            }
        }
        private ArrayInfo getArrayInfo(Type arrayType)
        {
            // Caching is innacceptable, as an array of type string can have different bounds

            var info = new ArrayInfo();

            // Fill the dimension infos
            for (int dimension = 0; dimension < getRank(arrayType); dimension++)
            {
                var dimensionInfo = new DimensionInfo();
                dimensionInfo.Length = getLength(dimension, arrayType);
                dimensionInfo.LowerBound = getLowerBound(dimension, arrayType);
                info.DimensionInfos.Add(dimensionInfo);
            }


            return info;
        }
 public UnimplementedDimension(Building building, DimensionInfo info) : base("Maps/Shed2", info.DisplayName)
 {
 }
 protected override void CreateHierarchies(CustomTreeNode parentNode, DimensionInfo dimension, bool createLevels)
 {
     // Не создаем узлы для уровней
     base.CreateHierarchies(parentNode, dimension, false);
 }
Exemple #13
0
        private ArrayInfo getArrayInfo()
        {
            var info = new ArrayInfo();

            // Fill the dimension infos
            for (int dimension = 0; dimension < getRank(); dimension++)
            {
                var dimensionInfo = new DimensionInfo();
                dimensionInfo.Length = getLength(dimension);
                dimensionInfo.LowerBound = getLowerBound(dimension);
                info.DimensionInfos.Add(dimensionInfo);
            }

            return info;
        }
Exemple #14
0
 public EasterEggDimensionImplementation(DimensionInfo info, Item item, int dimensionIndex) : base(info, item, dimensionIndex)
 {
 }
        private void writeDimensionInfo(DimensionInfo info)
        {
            _writer.WriteStartElement(SubElements.Dimension);
            if (info.Length != 0)
            {
                _writer.WriteAttribute(Attributes.Length, info.Length);
            }
            if (info.LowerBound != 0)
            {
                _writer.WriteAttribute(Attributes.LowerBound, info.LowerBound);
            }

            _writer.WriteEndElement();
        }
        private void readDimensionInfo(IList<DimensionInfo> dimensionInfos)
        {
            var info = new DimensionInfo();
            info.Length = _reader.ReadNumber();
            info.LowerBound = _reader.ReadNumber();

            dimensionInfos.Add(info);
        }
        public ResultOnDemandPickupRequest_Type1 SendUpsService(string ShipperName, string ShipperAddress, string ShipperCityCode, string ShipperAreaCode, string ShipperPhoneNumber, string ShipperEMail)
        {
            if (!string.IsNullOrEmpty(ShipperCityCode) && !string.IsNullOrEmpty(ShipperAreaCode))
            {
                CreateShipmentSoapClient cssc = new CreateShipmentSoapClient();

                OnDemandPickupRequestInfo_Type1 PickupRequestInfo = new OnDemandPickupRequestInfo_Type1(); //Session ile birlikte gönderilecek class

                BoxType            boxType             = new BoxType();
                BoxType[]          _boxtypeDizi        = new BoxType[1];
                ShipmentInfo_Type3 _shipmentInfo_Type3 = new ShipmentInfo_Type3();

                UpsServiceLogin UpsServiceLogin = new UpsServiceLogin();

                //Casper Bina Bilgilerini axaptanın veritabanından SP ile aldık..
                BussinesLogicCasper        BLL             = new BussinesLogicCasper();
                List <UpsCompanyInfoClass> CompanyInfoList = (List <UpsCompanyInfoClass>)BLL.GetConpanyInfo().Result; // SP'den gelen veriler...


                PickupRequestInfo.LabelSource      = 1;
                PickupRequestInfo.PickupRequestDay = DateTime.Now.AddDays(1);
                boxType.BoxTypeCode = 1;
                boxType.BoxCount    = 1;
                _boxtypeDizi[0]     = boxType;
                PickupRequestInfo.RequestedBoxList = _boxtypeDizi;

                _shipmentInfo_Type3.ShipperName              = ShipperName;
                _shipmentInfo_Type3.ShipperAddress           = ShipperAddress;
                _shipmentInfo_Type3.ShipperCityCode          = Convert.ToInt32(ShipperCityCode); //il
                _shipmentInfo_Type3.ShipperAreaCode          = Convert.ToInt32(ShipperAreaCode); //ilçe
                _shipmentInfo_Type3.ShipperPhoneNumber       = ShipperPhoneNumber;
                _shipmentInfo_Type3.ShipperMobilePhoneNumber = ShipperPhoneNumber;
                _shipmentInfo_Type3.ShipperEMail             = ShipperEMail;
                _shipmentInfo_Type3.ConsigneeAccountNumber   = "8576EE";
                _shipmentInfo_Type3.ConsigneeName            = CompanyInfoList.FirstOrDefault().UNVAN;
                _shipmentInfo_Type3.ConsigneeAddress         = CompanyInfoList.FirstOrDefault().ADRES;
                _shipmentInfo_Type3.ConsigneeCityCode        = Convert.ToInt32(CompanyInfoList.FirstOrDefault().ilKodu);
                _shipmentInfo_Type3.ConsigneeAreaCode        = Convert.ToInt32(CompanyInfoList.FirstOrDefault().ilceKodu);
                _shipmentInfo_Type3.NumberOfPackages         = 1;
                _shipmentInfo_Type3.ServiceLevel             = 3; //3 - DOM. STANDARD
                _shipmentInfo_Type3.PaymentType              = 1; //[1=Consignee 2=Shipper 4=Thirt Party]
                _shipmentInfo_Type3.PackageType              = "K";

                DimensionInfo[] dimension = new DimensionInfo[1];
                DimensionInfo   dim       = new DimensionInfo();

                dim.Height             = 1;
                dim.Length             = 1;
                dim.Width              = 1;
                dim.DescriptionOfGoods = "";
                dim.Weight             = 1;

                dimension[0] = dim;
                _shipmentInfo_Type3.PackageDimensions = dimension;


                PickupRequestInfo.ShipmentInfo = _shipmentInfo_Type3;

                ResultOnDemandPickupRequest_Type1 result;
                result = cssc.OnDemandPickupRequest_Type1(UpsServiceLogin.Login().SessionID, PickupRequestInfo);

                return(result);
            }
            else
            {
                return(null);
            }
        }
Exemple #18
0
        /// <summary>
        /// Возвращает список кубов
        /// </summary>
        /// <returns></returns>
        public CubeDefInfo  GetCubeMetadata(String cubeName, MetadataQueryType type)
        {
            try
            {
                System.Diagnostics.Trace.TraceInformation("{0} Ranet.Olap.Core.Providers.OlapMetadataProvider Getting Cube '{1}' Metadata Started",
                                                          DateTime.Now.ToString(), cubeName);

                CubeDef cube = FindCube(cubeName);
                if (cube != null)
                {
                    CubeDefInfo cube_info = InfoHelper.CreateCubeInfo(cube);
                    foreach (Dimension dim in cube.Dimensions)
                    {
                        DimensionInfo dim_info = InfoHelper.CreateDimensionInfo(dim);
                        cube_info.Dimensions.Add(dim_info);

                        foreach (Hierarchy hierarchy in dim.Hierarchies)
                        {
                            HierarchyInfo hier_info = InfoHelper.CreateHierarchyInfo(hierarchy);
                            dim_info.Hierarchies.Add(hier_info);

                            foreach (Level level in hierarchy.Levels)
                            {
                                LevelInfo level_info = InfoHelper.CreateLevelInfo(level);
                                hier_info.Levels.Add(level_info);
                            }

                            //AdomdConnection conn = GetConnection(ConnectionString);

                            //// Для каждой иерархии пытаемся определить элемент, который имеет тип MemberTypeEnum.All
                            //try
                            //{
                            //    AdomdRestrictionCollection restrictions = new AdomdRestrictionCollection();
                            //    restrictions.Add("CATALOG_NAME", conn.Database);
                            //    restrictions.Add("CUBE_NAME", OlapHelper.ConvertToNormalStyle(cubeName));
                            //    restrictions.Add("DIMENSION_UNIQUE_NAME", dim.UniqueName);
                            //    restrictions.Add("HIERARCHY_UNIQUE_NAME", hierarchy.UniqueName);
                            //    restrictions.Add("MEMBER_TYPE", 2/*MemberTypeEnum.All*/);

                            //    DataSet ds = conn.GetSchemaDataSet("MDSCHEMA_MEMBERS", restrictions);
                            //    if (ds != null && ds.Tables.Count > 0 && ds.Tables[0].Rows.Count > 0)
                            //    {
                            //        DataTable table = ds.Tables[0];
                            //        if (table.Columns.Contains("MEMBER_UNIQUE_NAME"))
                            //        {
                            //            object obj = ds.Tables[0].Rows[0]["MEMBER_UNIQUE_NAME"];
                            //            if (obj != null)
                            //                hier_info.Custom_AllMemberUniqueName = obj.ToString();
                            //        }
                            //    }
                            //}catch
                            //{
                            //}

                            //// Для каждой иерархии пытаемся определить элемент, который имеет тип MemberTypeEnum.Unknown
                            //try
                            //{
                            //    AdomdRestrictionCollection restrictions = new AdomdRestrictionCollection();
                            //    restrictions.Add("CATALOG_NAME", conn.Database);
                            //    restrictions.Add("CUBE_NAME", OlapHelper.ConvertToNormalStyle(cubeName));
                            //    restrictions.Add("DIMENSION_UNIQUE_NAME", dim.UniqueName);
                            //    restrictions.Add("HIERARCHY_UNIQUE_NAME", hierarchy.UniqueName);
                            //    restrictions.Add("MEMBER_TYPE", 0 /*MemberTypeEnum.Unknown.All*/);

                            //    DataSet ds = conn.GetSchemaDataSet("MDSCHEMA_MEMBERS", restrictions);
                            //    if (ds != null && ds.Tables.Count > 0 && ds.Tables[0].Rows.Count > 0)
                            //    {
                            //        DataTable table = ds.Tables[0];
                            //        if (table.Columns.Contains("MEMBER_UNIQUE_NAME"))
                            //        {
                            //            object obj = ds.Tables[0].Rows[0]["MEMBER_UNIQUE_NAME"];
                            //            if (obj != null)
                            //                hier_info.Custom_UnknownMemberUniqueName = obj.ToString();
                            //        }
                            //    }
                            //}
                            //catch
                            //{
                            //}
                        }
                    }

                    foreach (Kpi kpi in cube.Kpis)
                    {
                        KpiInfo kpi_info = InfoHelper.CreateKpiInfo(kpi);
                        cube_info.Kpis.Add(kpi_info);
                    }

                    foreach (Measure measure in cube.Measures)
                    {
                        MeasureInfo measure_info = InfoHelper.CreateMeasureInfo(measure);
                        cube_info.Measures.Add(measure_info);
                    }

                    foreach (NamedSet set in cube.NamedSets)
                    {
                        NamedSetInfo set_info = InfoHelper.CreateNamedSetInfo(set);
                        cube_info.NamedSets.Add(set_info);
                    }

                    if (type == MetadataQueryType.GetCubeMetadata_AllMembers)
                    {
                        AdomdConnection conn = GetConnection();
                        // Для каждой иерархии пытаемся определить элемент, который имеет тип MemberTypeEnum.All
                        try
                        {
                            AdomdRestrictionCollection restrictions = new AdomdRestrictionCollection();
                            restrictions.Add("CATALOG_NAME", conn.Database);
                            restrictions.Add("CUBE_NAME", OlapHelper.ConvertToNormalStyle(cubeName));
                            restrictions.Add("MEMBER_TYPE", 2 /*MemberTypeEnum.All*/);

                            DataSet ds = conn.GetSchemaDataSet("MDSCHEMA_MEMBERS", restrictions);
                            if (ds != null && ds.Tables.Count > 0 && ds.Tables[0].Rows.Count > 0)
                            {
                                DataTable table = ds.Tables[0];
                                if (table.Columns.Contains("MEMBER_UNIQUE_NAME") &&
                                    table.Columns.Contains("HIERARCHY_UNIQUE_NAME") &&
                                    table.Columns.Contains("DIMENSION_UNIQUE_NAME"))
                                {
                                    foreach (DataRow row in ds.Tables[0].Rows)
                                    {
                                        String dimension_UniqueName = row["DIMENSION_UNIQUE_NAME"] != null ? row["DIMENSION_UNIQUE_NAME"].ToString() : String.Empty;
                                        String hierarchy_UniqueName = row["HIERARCHY_UNIQUE_NAME"] != null ? row["HIERARCHY_UNIQUE_NAME"].ToString() : String.Empty;
                                        String member_UniqueName    = row["MEMBER_UNIQUE_NAME"] != null ? row["MEMBER_UNIQUE_NAME"].ToString() : String.Empty;

                                        if (!String.IsNullOrEmpty(dimension_UniqueName) &&
                                            !String.IsNullOrEmpty(hierarchy_UniqueName) &&
                                            !String.IsNullOrEmpty(member_UniqueName))
                                        {
                                            DimensionInfo dimension = cube_info.GetDimension(dimension_UniqueName);
                                            if (dimension != null)
                                            {
                                                HierarchyInfo hierarchy = dimension.GetHierarchy(hierarchy_UniqueName);
                                                if (hierarchy != null)
                                                {
                                                    hierarchy.Custom_AllMemberUniqueName = member_UniqueName;
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                        catch (Exception ex)
                        {
                            //throw ex;
                        }
                    }

                    cube_info.MeasureGroups = GetMeasureGroups(cubeName);

                    return(cube_info);
                }

                return(null);
            }
            finally {
                System.Diagnostics.Trace.TraceInformation("{0} Ranet.Olap.Core.Providers.OlapMetadataProvider Getting Cube '{1}' Metadata Completed",
                                                          DateTime.Now.ToString(), cubeName);
            }
        }
 private static void readDimensionInfo(XmlReader reader, ICollection<DimensionInfo> infos)
 {
     var info = new DimensionInfo();
     info.Length = getLengthAttribute(reader);
     info.LowerBound = getLowerBoundAttribute(reader);
     infos.Add(info);
 }