Seeds either the static or version controlled seeders, controlled by
the passed mode.
502801
function (mode, scope, callback) {
    var executeSeed = load('seed');
    if (scope) {
      this.internals.migrationMode = scope;
      this.internals.matching = scope;
    }

    this.internals.mode = mode || 'vc';
    return Promise.fromCallback(
      function (callback) {
        executeSeed(this.internals, this.config, callback);
      }.bind(this)
    ).asCallback(callback);
  }
482315
private final void setSeed(int seed) {

		// Annoying runtime check for initialisation of internal data
		// caused by java.util.Random invoking setSeed() during init.
		// This is unavoidable because no fields in our instance will
		// have been initialised at this point, not even if the code
		// were placed at the declaration of the member variable.
		if (mt == null) mt = new int[N];

		// ---- Begin Mersenne Twister Algorithm ----
		mt[0] = seed;
		for (mti = 1; mti < N; mti++) {
			mt[mti] = (MAGIC_FACTOR1 * (mt[mti-1] ^ (mt[mti-1] >>> 30)) + mti);
		}
		// ---- End Mersenne Twister Algorithm ----
	}
97478
def set_seed(seed: int):
    
    random.seed(seed)
    np.random.seed(seed)
    torch.random.manual_seed(seed)
1325670
public static ModifiableDBIDs randomSample(DBIDs source, int k, Long seed) {
    return randomSample(source, k, seed != null ? new Random(seed.longValue()) : new Random());
  }
384774
def setCurrentMode( self, mode ):
        
        if ( self._currentMode == mode ):
            return
        
        self._currentMode = mode
        self.updateModeSettings()
1365970
protected void seed() {
        if (!seeded.get()) {
            synchronized (random) {
                if (!seeded.get()) {
                    getLogger().debug("Seeding random number generator");
                    final GenerateRandomRequest request = new GenerateRandomRequest();
                    request.setNumberOfBytes(512);
                    final GenerateRandomResult result = getKms().generateRandom(request);
                    final ByteBuffer randomBytes = result.getPlaintext();
                    final byte[] bytes = new byte[randomBytes.remaining()];
                    randomBytes.get(bytes);
                    random.setSeed(bytes);
                    seeded.set(true);
                    getLogger().debug("Seeded random number generator");
                }
            }
        }
    }
1096326
private function registerSeederMakeCommand()
    {
        $this->app->bindShared('command.make.package.seeder', function ($app)
        {
            return new SeederMakeCommand($app['files'], $app['packages']);
        });

        $this->commands('command.make.package.seeder');
    }
347460
public void setEditMode(EditMode currentMode) {
		super.setEditMode(currentMode);
		if (controller != null) {
			controller.setEditMode(currentMode);
		}
	}
250050
public void lockRootEdge(LockMode mode) {
    Preconditions.checkState(mEntries.isEmpty());

    mEntries.add(new EdgeEntry(mInodeLockManager.lockEdge(ROOT_EDGE, mode), ROOT_EDGE));
    mLockMode = mode;
  }
215971
private function seed()
    {
        foreach ($this->input as $key => $value) {
            if (!$this->call($this->before, $value, $key)) {
                return;
            }

            yield $key => $value;

            if (!$this->call($this->after, $value, $key)) {
                return;
            }
        }
    }
1374281
private function seedContentTypes()
    {
        ContentType::firstOrCreate(['name' => 'content', 'handler' => Gzero\Cms\Handlers\Content\ContentHandler::class]);
        ContentType::firstOrCreate(['name' => 'category', 'handler' => Gzero\Cms\Handlers\Content\CategoryHandler::class]);
    }
1084159
private static function _seedRandomizer()
    {
        self::$_seeded = true;
        
        $seed = \hexdec(\bin2hex(\openssl_random_pseudo_bytes(8)));
        \mt_srand($seed);
    }
485242
public void setEditMode(final EditMode mode) {

        if (!m_modeSelect.getValue().equals(mode)) {
            m_modeSelect.setValue(mode);
        }
    }
516184
public void setActionFlags() {

        m_checkinBean.setFetchAndResetBeforeImport(m_fetchAndReset.getValue().booleanValue());
        switch (m_mode) {
            case checkOut:
                m_checkinBean.setCheckout(true);
                m_checkinBean.setResetHead(false);
                m_checkinBean.setResetRemoteHead(false);
                break;
            case checkIn:
                m_checkinBean.setCheckout(false);
                m_checkinBean.setResetHead(false);
                m_checkinBean.setResetRemoteHead(false);
                break;
            case resetHead:
                m_checkinBean.setCheckout(false);
                m_checkinBean.setResetHead(true);
                m_checkinBean.setResetRemoteHead(false);
                break;
            case resetRemoteHead:
                m_checkinBean.setCheckout(false);
                m_checkinBean.setResetHead(false);
                m_checkinBean.setResetRemoteHead(true);
                break;
            default:
                break;
        }

    }
491822
private function seedBlockTypes()
    {
        BlockType::firstOrCreate(['name' => 'basic', 'handler' => Gzero\Cms\Handlers\Block\Basic::class]);
        BlockType::firstOrCreate(['name' => 'menu', 'handler' => Gzero\Cms\Handlers\Block\Menu::class]);
        BlockType::firstOrCreate(['name' => 'slider', 'handler' => Gzero\Cms\Handlers\Block\Slider::class]);
    }
201852
public function setGuessedColumnFormatters($seeding)
    {
        $this->guessedFormatters = $this->getGuessedColumnFormatters($this->model, $seeding, true);

        if ($this->dimsavTranslatable()) {
            $this->guessDimsavFormatters($seeding);
        } else {
            $this->guessMultilingualFormatters();
        }

        $this->setGuessedPivotFormatters($seeding);
    }
346806
def run_on_changes(paths)
      if paths.any? { |path| path.match(%r{^db/migrate/(\d+).+\.rb}) } || reset?
        migrations = paths.map { |path| Migration.new(path) }
        migrate(migrations)
      elsif paths.any? { |path| path.match(%r{^db/seeds\.rb$}) }
        seed_only
      end
    end