コード例 #1
0
        /// <summary>
        ///
        /// </summary>
        /// <returns></returns>
        public override DefinitionNodeInfoBase CreateCopy()
        {
            DefinitionNodeInfoMember ret = new DefinitionNodeInfoMember();

            ret.TargetRole        = this.TargetRole;
            ret.usable            = this.usable;
            ret.isDefault         = this.isDefault;
            ret.isRequiresElement = this.isRequiresElement;


            return(ret);
        }
コード例 #2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        public override bool Equals(object obj)
        {
            DefinitionNodeInfoMember other = obj as DefinitionNodeInfoMember;

            //check the properties as we want to assume default values if it is not specified...
            //for equality purposes....
            if (this.Usable != other.Usable)
            {
                return(false);
            }
            if (this.IsDefault != other.IsDefault)
            {
                return(false);
            }
            if (this.IsRequiresElement != other.IsRequiresElement)
            {
                return(false);
            }

            return(base.Equals(obj));
        }
コード例 #3
0
        /// <summary>
        /// 
        /// </summary>
        /// <param name="isClosed"></param>
        /// <param name="isUsable"></param>
        /// <param name="isall"></param>
        /// <param name="isScenario"></param>
        /// <param name="isDefault"></param>
        /// <param name="isRequired"></param>
        /// <param name="targetRole"></param>
        /// <param name="nodeType"></param>
        /// <returns></returns>
        public static DefinitionNodeInfoBase CreateDefinitionNodeInfo(bool? isClosed,
			bool? isUsable, bool? isall, bool? isScenario,
			bool? isDefault, bool? isRequired, string targetRole,  DimensionNode.NodeType nodeType)
        {
            DefinitionNodeInfoBase ret = null;
            switch( nodeType )
            {
                case DimensionNode.NodeType.Dimension:
                    ret = new DefinitionNodeInfoDimension(targetRole);
                    break;
                case DimensionNode.NodeType.Hypercube:
                    ret = new DefinitionNodeInfoHypercube(isClosed, isall, isScenario, targetRole);
                    break;

                case DimensionNode.NodeType.Item:
                    ret = new DefinitionNodeInfoMember(isUsable, isDefault, isRequired, targetRole);
                    break;

            }

            return ret;
        }
コード例 #4
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="isClosed"></param>
        /// <param name="isUsable"></param>
        /// <param name="isall"></param>
        /// <param name="isScenario"></param>
        /// <param name="isDefault"></param>
        /// <param name="isRequired"></param>
        /// <param name="targetRole"></param>
        /// <param name="nodeType"></param>
        /// <returns></returns>
        public static DefinitionNodeInfoBase CreateDefinitionNodeInfo(bool?isClosed,
                                                                      bool?isUsable, bool?isall, bool?isScenario,
                                                                      bool?isDefault, bool?isRequired, string targetRole, DimensionNode.NodeType nodeType)
        {
            DefinitionNodeInfoBase ret = null;

            switch (nodeType)
            {
            case DimensionNode.NodeType.Dimension:
                ret = new DefinitionNodeInfoDimension(targetRole);
                break;

            case DimensionNode.NodeType.Hypercube:
                ret = new DefinitionNodeInfoHypercube(isClosed, isall, isScenario, targetRole);
                break;

            case DimensionNode.NodeType.Item:
                ret = new DefinitionNodeInfoMember(isUsable, isDefault, isRequired, targetRole);
                break;
            }

            return(ret);
        }
コード例 #5
0
        /// <summary>
        /// 
        /// </summary>
        /// <returns></returns>
        public override DefinitionNodeInfoBase CreateCopy()
        {
            DefinitionNodeInfoMember ret = new DefinitionNodeInfoMember();

            ret.TargetRole = this.TargetRole;
            ret.usable = this.usable;
            ret.isDefault = this.isDefault;
            ret.isRequiresElement = this.isRequiresElement;

            return ret;
        }