示例#1
0
 internal OleDbObjectReader(OleDbDataStore dataStore, OleDbDataReader reader, Type mappedType, bool polymorphic)
 {
     this.dataStore = dataStore;
     this.reader = reader;
     this.polymorphic = polymorphic;
     this.MappedType = mappedType;
 }
 public override DataStore CreateDataStore()
 {
     OleDbDataStore dataStore = new Inform.OleDb.OleDbDataStore();
     dataStore.Connection.ConnectionString = @"Provider=Microsoft.Jet.OLEDB.4.0;User Id=Admin;" +
         @"Data source= D:\work\cvsroot\FluentComponents\Inform\db\Inform.mdb;Mode=ReadWrite;";
     return dataStore;
 }
示例#3
0
        /// <summary>
        /// Creates the command.
        /// </summary>
        public OleDbDataAccessCommand(OleDbDataStore dataStore, string cmdText)
        {
            Console.WriteLine(cmdText);Console.WriteLine();

            this.dataStore = dataStore;
            this.command = new OleDbCommand(cmdText);
        }
示例#4
0
        /// <summary>
        /// Creates the command as a specific command type.
        /// </summary>
        public OleDbDataAccessCommand(OleDbDataStore dataStore, string cmdText, System.Data.CommandType commandType)
        {
            Console.WriteLine(cmdText);Console.WriteLine();

            this.dataStore = dataStore;
            this.command = new OleDbCommand(cmdText);
            this.command.CommandType = commandType;
        }
示例#5
0
        public OleDbObjectAccessCommand(OleDbDataStore dataStore, Type dynamicType, string cmdText, bool polymorphic, CommandType commandType)
        {
            this.dataStore = dataStore;
            this.cmdText = cmdText;
            this.polymorphic = polymorphic;
            this.dynamicType = dynamicType;
            this.commandType = commandType;

            if(commandType == CommandType.Text){
                command = new OleDbDataAccessCommand(dataStore, dataStore.DataStorageManager.CreateQuery(dynamicType, cmdText, polymorphic), commandType);
            } else {
                command = new OleDbDataAccessCommand(dataStore, cmdText, commandType);
            }
        }
示例#6
0
 public OleDbObjectAccessCommand(OleDbDataStore dataStore, Type dynamicType, string filter, bool polymorphic)
     : this(dataStore, dynamicType, filter, false, CommandType.Text)
 {
 }
示例#7
0
 public OleDbObjectAccessCommand(OleDbDataStore dataStore, Type dynamicType, string filter)
     : this(dataStore, dynamicType, filter, false)
 {
 }
 /// <summary>
 /// Creates a new SqlFindObject Command.
 /// </summary>
 /// <param name="storeProcedureName">The name of the stored procedure to call.</param>
 public OleDbFindCollectionCommand(OleDbDataStore dataStore, Type dynamicType, string filter, bool polymorphic)
     : base(dataStore, dynamicType, filter, polymorphic)
 {
 }
 /// <summary>
 /// Creates a new SqlFindCollectionCommand Command.
 /// </summary>
 /// <param name="storeProcedureName">The name of the stored procedure to call.</param>
 /// <param name="dynamicObjectType">The type of object to populate dynamically.</param>
 public OleDbFindCollectionCommand(OleDbDataStore dataStore,  Type dynamicType, String cmdText, CommandType commandType)
     : base(dataStore, dynamicType, cmdText, false, commandType)
 {
 }
示例#10
0
 /// <summary>
 /// Creates a new SqlFindCollectionCommand Command.
 /// </summary>
 /// <param name="storeProcedureName">The name of the stored procedure to call.</param>
 /// <param name="dynamicObjectType">The type of object to populate dynamically.</param>
 public OleDbFindCollectionCommand(OleDbDataStore dataStore, Type dynamicType, String filter )
     : base(dataStore, dynamicType, filter)
 {
 }
示例#11
0
 public OleDbDataStorageManager(OleDbDataStore dataStore)
     : base(dataStore)
 {
     AddDefaultPropertyMappingsTypes();
 }
示例#12
0
 /// <summary>
 /// Creates a new SqlFindObject Command.
 /// </summary>
 /// <param name="dynamicObjectType">The type of object to populate dynamically.</param>
 public OleDbFindObjectCommand(OleDbDataStore dataStore, Type dynamicType, string cmdText, bool polymorphic, System.Data.CommandType commandType)
 {
     this.dataStore = dataStore;
     this.m_command = new OleDbObjectAccessCommand(dataStore, dynamicType, cmdText, polymorphic, commandType);
 }
示例#13
0
 /// <summary>
 /// Creates a new SqlFindObject Command.
 /// </summary>
 public OleDbFindObjectCommand(OleDbDataStore dataStore, Type dynamicType, string filter, bool polymorphic)
     : this(dataStore, dynamicType, filter, polymorphic, CommandType.Text)
 {
 }