0
|
1 using System;
|
|
2 using System.Data;
|
|
3
|
|
4 namespace BLToolkit.DataAccess
|
|
5 {
|
|
6 [AttributeUsage(AttributeTargets.Property | AttributeTargets.Field, AllowMultiple = false), CLSCompliant(false)]
|
|
7 public sealed class DbTypeAttribute : Attribute
|
|
8 {
|
|
9 public DbType DbType { get; set; }
|
|
10 public int? Size { get; set; }
|
|
11
|
|
12 public DbTypeAttribute(DbType sqlDbType)
|
|
13 {
|
|
14 DbType = sqlDbType;
|
|
15 }
|
|
16
|
|
17 public DbTypeAttribute(DbType sqlDbType, int size)
|
|
18 {
|
|
19 DbType = sqlDbType;
|
|
20 Size = size;
|
|
21 }
|
|
22 }
|
|
23 }
|