Esempio n. 1
0
        public DdbPropertyInfo(PropertyInfo propertyInfo, string attributeName, DynamoDbAttributeType attributeType, DdbConverter <T> converter, DynamoDbContextMetadata metadata) : base(propertyInfo, attributeName, attributeType)
        {
            Converter = converter;

            Get = EmitMemberAccessor.CreatePropertyGetter <T>(propertyInfo);
            Set = propertyInfo.SetMethod != null?EmitMemberAccessor.CreatePropertySetter <T>(propertyInfo) : null;

            RuntimeClassInfo = metadata.GetOrAddClassInfo(propertyInfo.PropertyType, converter);
        }
Esempio n. 2
0
 internal abstract DdbPropertyInfo CreateDdbPropertyInfo(PropertyInfo propertyInfo, string attributeName, DynamoDbAttributeType attributeType, DynamoDbContextMetadata dynamoDbContextMetadata);
 public DynamoDbPropertyAttribute(string name, DynamoDbAttributeType attributeType) : this(name, null, attributeType)
 {
 }
 public DynamoDbPropertyAttribute(string name, Type?ddbConverterType, DynamoDbAttributeType attributeType)
 {
     Name             = name;
     DdbConverterType = ddbConverterType;
     AttributeType    = attributeType;
 }
        internal sealed override DdbPropertyInfo CreateDdbPropertyInfo(PropertyInfo propertyInfo, string attributeName, DynamoDbAttributeType attributeType, DynamoDbContextMetadata dynamoDbContextMetadata)
        {
            Debug.Fail("We should never get here.");

            throw new InvalidOperationException();
        }