- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 171 for Hooks (0.12 sec)
-
tests/hooks_test.go
product2 := Product3{Name: "Product", Price: 0} DB.Session(&gorm.Session{SkipHooks: true}).Create(&product2) if product2.Price != 0 { t.Errorf("invalid price after create without hooks, got %+v", product2) } } func TestHooksForSlice(t *testing.T) { DB.Migrator().DropTable(&Product3{}) DB.AutoMigrate(&Product3{}) products := []*Product3{ {Name: "Product-1", Price: 100},
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sat Feb 18 01:20:29 GMT 2023 - 15.9K bytes - Viewed (0) -
scripts/mkdocs_hooks.py
Sebastián RamÃrez <******@****.***> 1698179166 +0400
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Oct 24 20:26:06 GMT 2023 - 5.1K bytes - Viewed (0) -
istioctl/pkg/injector/injector-list.go
if err != nil { return err } sort.Slice(hooks, func(i, j int) bool { return hooks[i].Name < hooks[j].Name }) return printHooks(cmd.OutOrStdout(), nslist, hooks, injectedImages) }, } return cmd } func filterSystemNamespaces(nss []corev1.Namespace, istioNamespace string) []corev1.Namespace { filtered := make([]corev1.Namespace, 0) for _, ns := range nss {
Go - Registered: Wed May 08 22:53:08 GMT 2024 - Last Modified: Thu Jan 04 03:08:06 GMT 2024 - 10.4K bytes - Viewed (0) -
.pre-commit-config.yaml
# See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks default_language_version: python: python3.10 repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.4.0 hooks: - id: check-added-large-files - id: check-toml - id: check-yaml args: - --unsafe - id: end-of-file-fixer - id: trailing-whitespace
Others - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 737 bytes - Viewed (0) -
pdm_build.py
import os from typing import Any, Dict, List from pdm.backend.hooks import Context TIANGOLO_BUILD_PACKAGE = os.getenv("TIANGOLO_BUILD_PACKAGE", "fastapi") def pdm_build_initialize(context: Context) -> None: metadata = context.config.metadata # Get custom config for the current package, from the env var config: Dict[str, Any] = context.config.data["tool"]["tiangolo"][ "_internal-slim-build"
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Apr 30 06:38:13 GMT 2024 - 1.7K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java
private final List<Thread> hooks = Lists.newArrayList(); @Override synchronized void addShutdownHook(Thread hook) { hooks.add(hook); } synchronized void shutdown() throws InterruptedException { for (Thread hook : hooks) { hook.start(); } for (Thread hook : hooks) { hook.join(); } } }
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 28.2K bytes - Viewed (3) -
android/guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java
private final List<Thread> hooks = Lists.newArrayList(); @Override synchronized void addShutdownHook(Thread hook) { hooks.add(hook); } synchronized void shutdown() throws InterruptedException { for (Thread hook : hooks) { hook.start(); } for (Thread hook : hooks) { hook.join(); } } }
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 28.2K bytes - Viewed (0) -
istioctl/pkg/tag/revision.go
} func Webhooks(ctx context.Context, client kube.CLIClient) ([]admitv1.MutatingWebhookConfiguration, error) { hooks, err := client.Kube().AdmissionregistrationV1().MutatingWebhookConfigurations().List(ctx, metav1.ListOptions{}) if err != nil { return []admitv1.MutatingWebhookConfiguration{}, err } return hooks.Items, nil } func renderWithDefault(s, def string) string { if s != "" { return s } return def
Go - Registered: Wed May 08 22:53:08 GMT 2024 - Last Modified: Sat Jan 28 13:16:05 GMT 2023 - 4.5K bytes - Viewed (0) -
callbacks/create.go
package callbacks import ( "fmt" "reflect" "strings" "gorm.io/gorm" "gorm.io/gorm/clause" "gorm.io/gorm/schema" "gorm.io/gorm/utils" ) // BeforeCreate before create hooks func BeforeCreate(db *gorm.DB) { if db.Error == nil && db.Statement.Schema != nil && !db.Statement.SkipHooks && (db.Statement.Schema.BeforeSave || db.Statement.Schema.BeforeCreate) { callMethod(db, func(value interface{}, tx *gorm.DB) (called bool) {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Apr 08 03:29:55 GMT 2024 - 12.5K bytes - Viewed (0) -
tests/transaction_test.go
return tx2.Scan(&User{}).Error }) }) if err != nil { t.Error(err) } // method with hooks err = DB.Transaction(func(tx1 *gorm.DB) error { // callMethod do tx2 := tx1.Find(&User{}).Session(&gorm.Session{NewDB: true}) // trx in hooks return tx2.Transaction(func(tx3 *gorm.DB) error { return tx3.Where("user_id", user.ID).Delete(&Account{}).Error }) })
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sat Jun 10 13:05:19 GMT 2023 - 10.9K bytes - Viewed (0)