Loads the records for this instance in a batched mode.
774183
def loadBatch(self, records):
        
        try:
            curr_batch = records[:self.batchSize()]
            next_batch = records[self.batchSize():]
            
            curr_records = list(curr_batch)
            if self._preloadColumns:
                for record in curr_records:
                    record.recordValues(self._preloadColumns)
            
            if len(curr_records) == self.batchSize():
                self.loadedRecords[object, object].emit(curr_records,
                                                        next_batch)
            else:
                self.loadedRecords[object].emit(curr_records)
        
        except ConnectionLostError:
            self.connectionLost.emit()
        
        except Interruption:
            pass
102111
def _loadBatch(self, item, batch):
        
        if self.isThreadEnabled() and batch.isThreadEnabled():
            self.loadBatchRequested.emit(batch)
            self._batchloaders.append(weakref.ref(item))
        else:
            QApplication.setOverrideCursor(Qt.WaitCursor)
            self.worker().loadRecords(batch)
            QApplication.restoreOverrideCursor()
1192098
public function requireDefaultRecords()
    {
        // Require Default Records (from parent):
        
        parent::requireDefaultRecords();
        
        // Create Default Folders:
        
        Folder::singleton()->createDefaultFolders();
        
        // Obtain App Instance:
        
        $app = self::instance();
        
        // Load Defaults:
        
        $app->loadDefaults();
        
        // Load Fixtures:
        
        $app->loadFixtures();
    }
166137
private function load()
    {
        if (\count($this->attributes)) {
            return;
        }

        $sessionBag         = $this->session->getBag($this->getSessionBagKey());
        $databaseSessionBag = $this->session->getBag($this->getDatabaseSessionBagKey());

        $this->attributes = \array_merge(
            (array) $sessionBag->get($this->getScope()),
            (array) $databaseSessionBag->get($this->getScope())
        );
    }
110550
def refresh(self, records):
        
        self._loaded = True
        
        if self.isLoading():
            return
        
        # load the information
        if RecordSet.typecheck(records):
            table = records.table()
            self.setTableType(table)
            
            if self.order():
                records.setOrder(self.order())
            
            # load specific data for this record box
            if self.specifiedColumnsOnly():
                records.setColumns(map(lambda x: x.name(),
                                       self.specifiedColumns()))
            
            # load the records asynchronously
            if self.isThreadEnabled() and table:
                try:
                    thread_enabled = table.getDatabase().isThreadEnabled()
                except AttributeError:
                    thread_enabled = False
                
                if thread_enabled:
                    # ensure we have a worker thread running
                    self.worker()
                    
                    # assign ordering based on tree table
                    if self.showTreePopup():
                        tree = self.treePopupWidget()
                        if tree.isSortingEnabled():
                            col = tree.sortColumn()
                            colname = tree.headerItem().text(col)
                            column = table.schema().column(colname)
                            
                            if column:
                                if tree.sortOrder() == Qt.AscendingOrder:
                                    sort_order = 'asc'
                                else:
                                    sort_order = 'desc'
                                
                                records.setOrder([(column.name(), sort_order)])
                    
                    self.loadRequested.emit(records)
                    return
        
        # load the records synchronously
        self.loadingStarted.emit()
        curr_record = self.currentRecord()
        self.blockSignals(True)
        self.setUpdatesEnabled(False)
        self.clear()
        use_dummy = not self.isRequired() or self.isCheckable()
        if use_dummy:
            self.addItem('')
        self.addRecords(records)
        self.setUpdatesEnabled(True)
        self.blockSignals(False)
        self.setCurrentRecord(curr_record)
        self.loadingFinished.emit()
425763
@Override
    public Object load(String batchId) {

        Object loadedArtifact;

        loadedArtifact = getArtifactById(batchId);

        if (loadedArtifact != null) {
            if (logger.isLoggable(Level.FINEST)) {
                logger.finest("load: batchId: " + batchId
                              + ", artifact: " + loadedArtifact
                              + ", artifact class: " + loadedArtifact.getClass().getCanonicalName());
            }
        }

        return loadedArtifact;
    }
858015
def records_for_rebuild(batch_size = 1000)
      transaction do
        if use_fast_batches?
          offset = 0
          while (rows = where([ "#{table_name}.id > ?", offset ]).limit(batch_size).all).any?
            offset = rows.last.id
            yield rows, offset
          end
        else
          order = "#{primary_key} ASC" # fixes #212
          0.step(self.count, batch_size) do |offset|
            yield scoped.limit(batch_size).offset(offset).order(order).all, offset
          end
        end
      end
    end
544317
def _iterate_records(self):
        
        raise_invalid_gzip = False
        empty_record = False

        while True:
            try:
                self.record = self._next_record(self.next_line)
                if raise_invalid_gzip:
                    self._raise_invalid_gzip_err()

                yield self.record

            except EOFError:
                empty_record = True

            self.read_to_end()

            if self.reader.decompressor:
                # if another gzip member, continue
                if self.reader.read_next_member():
                    continue

                # if empty record, then we're done
                elif empty_record:
                    break

                # otherwise, probably a gzip
                # containing multiple non-chunked records
                # raise this as an error
                else:
                    raise_invalid_gzip = True

            # non-gzip, so we're done
            elif empty_record:
                break

        self.close()
1160866
def load(self, callback=None, errback=None, reload=False):
        
        if not reload and self.data:
            raise RecordException('record already loaded')

        def success(result, *args):
            self._parseModel(result)
            if callback:
                return callback(self)
            else:
                return self
        return self._rest.retrieve(self.parentZone.zone,
                                   self.domain, self.type,
                                   callback=success, errback=errback)
26661
def load(self):
    
    print "Loading data for %s..." % self.getName()
    self._dataHandle = self._stream.data(
      since=self._since, until=self._until, 
      limit=self._limit, aggregate=self._aggregate
    )
    self._data = self._dataHandle.data()
    self._headers = self._dataHandle.headers()
    print "Loaded %i rows." % len(self)
1210550
protected function load()
    {
        $tables = $this->fetchTables($this->schema);
        foreach ($tables as $table) {
            $blueprint = new Blueprint($this->connection->getName(), $this->schema, $table);
            $this->fillColumns($blueprint);
            $this->fillConstraints($blueprint);
            $this->tables[$table] = $blueprint;
        }
    }
1237914
private function load()
    {
        $this->cached = [];
        $entities = $this->daoGeneric->getEntities($this->entityName);
        foreach ($entities as $one) {
            $id = $one[ETypeBase::A_ID];
            $code = $one[ETypeBase::A_CODE];
            $this->cached[$code] = $id;
        }
    }
441797
protected function loadData()
    {
        if (null === $this->data) {
            $this->statement->execute();
            $this->data = $this->statement->fetchAll(\PDO::FETCH_ASSOC);
        }
    }
517771
def loadRecord(self, domain, rtype, callback=None, errback=None):
        
        rec = Record(self, domain, rtype)
        return rec.load(callback=callback, errback=errback)
121887
public void flush() {
    try {
      ArrayList<Batch> batches = this.incomplete.all();
      int numOutstandingRecords = 0;
      for (Batch batch: batches) {
        numOutstandingRecords += batch.getRecords().size();
      }
      LOG.debug ("Flush called on {} batches with {} records total", batches.size(), numOutstandingRecords);
      for (Batch batch: batches) {
        batch.await();
      }
    } catch (Exception e) {
      LOG.error ("Error happened while flushing batches");
    }
  }
796649
def on_records(self, records):
        
        handler = self.handlers.get("on_records")
        if callable(handler):
            handler(records)
408366
function(raw_records_array) {

		var i = 0,
			count = raw_records_array.length,
			records = [];

		for (; i < count; i++) {

			records.push(this._createRecordInstance(raw_records_array[i]));

		}

		this._fire('records_loaded', {records: records});

		return records;

	}