Ejemplo n.º 1
0
        /// <summary>
        /// 생성자 (<see cref="ObjectMapper.MapProperty{TTarget}(object,System.Func{TTarget},System.Linq.Expressions.Expression{System.Func{TTarget,object}}[])" /> 을 사용하세요)
        /// </summary>
        /// <param name="src">원본 메타데이타</param>
        public MetadataValue(IMetadataValue src) : base(src) {
            //src.ShouldNotBeNull("src");

            //Value = src.Value;
            //ValueType = src.ValueType;
            //Label = src.Label;
            //Description = src.Description;
            //ExAttr = src.ExAttr;
        }
Ejemplo n.º 2
0
 /// <summary>
 /// 현재 개체가 동일한 형식의 다른 개체와 같은지 여부를 나타냅니다.
 /// </summary>
 /// <returns>
 /// 현재 개체가 <paramref name="other"/> 매개 변수와 같으면 true이고, 그렇지 않으면 false입니다.
 /// </returns>
 /// <param name="other">이 개체와 비교할 개체입니다.</param>
 public bool Equals(IMetadataValue other) {
     return (other != null) && GetHashCode().Equals(other.GetHashCode());
 }
Ejemplo n.º 3
0
        /// <summary>
        /// This resolves the metadata value by expanding IMetadataValue.
        /// </summary>
        private KeyValuePair <string, object> GetItem(KeyValuePair <string, object> item)
        {
            IMetadataValue metadataValue = item.Value as IMetadataValue;

            return(metadataValue != null ? new KeyValuePair <string, object>(item.Key, GetValue(metadataValue.Get(this))) : item);
        }
Ejemplo n.º 4
0
        /// <summary>
        /// This resolves the metadata value by recursivly expanding IMetadataValue.
        /// </summary>
        private object GetValue(object originalValue)
        {
            IMetadataValue metadataValue = originalValue as IMetadataValue;

            return(metadataValue != null?GetValue(metadataValue.Get(this)) : originalValue);
        }