Ejemplo n.º 1
0
        public override CDLLHintInfo copy()
        {
            var ret = new CDLLNumericRangeValueHintInfo(key_, name_, desc_, min_, max_, def_);

            ret.value_ = value_;
            return(ret);
        }
Ejemplo n.º 2
0
        public static CDLLHintInfo decode(CEncodedObjectInputBufferI bin)
        {
            string tag = bin.thisTag();
            Dictionary <string, string> attr = bin.getAttributes();

            CDLLHintInfo ret = null;

            switch (tag)
            {
            case BOOL_TYPE:
                ret = new CDLLBoolHintInfo(attr, bin);
                break;

            case NAME_VALUE_SET:
                ret = new CDLLNameValueHintInfo(attr, bin);
                break;

            case NUMERIC_RANGE_VALUE_TYPE:
                ret = new CDLLNumericRangeValueHintInfo(attr, bin);
                break;

            case NUMERIC_VALUE_TYPE:
                ret = new CDLLNumericValueHintInfo(attr, bin);
                break;

            case STRING_VALUE_TYPE:
                ret = new CDLLStringValueHintInfo(attr, bin);
                break;

            case FILE_VALUE_TYPE:
                ret = new CDLLFileValueHintInfo(attr, bin);
                break;

            case CONTAINER_TYPE:
                ret = new CDLLContainerHintInfo(attr, bin);
                break;

            case LOCKED_CONTAINER_TYPE:
                ret = new CDLLLockableHintInfo(attr, bin);
                break;

            case RADIO_CONTAINER_TYPE:
                ret = new CDLLRadioContainerHintInfo(attr, bin);
                break;

            default:
                throw new Exception("Unknown decode type " + tag);
            }
            bin.endTag(tag);
            return(ret);
        }