Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 4,081 for find (2.44 sec)

  1. guava-testlib/src/com/google/common/collect/testing/testers/AbstractListIndexOfTester.java

      protected abstract int find(@Nullable Object o);
    
      /** Override to return "indexOf" or "lastIndexOf()" for use in failure messages. */
      protected abstract String getMethodName();
    
      @CollectionSize.Require(absent = ZERO)
      public void testFind_yes() {
        assertEquals(
            getMethodName() + "(firstElement) should return 0", 0, find(getOrderedElements().get(0)));
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Apr 20 11:19:03 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  2. tests/scopes_test.go

    	var users1, users2, users3 []User
    	DB.Scopes(NameIn1And2).Find(&users1)
    	if len(users1) != 2 {
    		t.Errorf("Should found two users's name in 1, 2, but got %v", len(users1))
    	}
    
    	DB.Scopes(NameIn1And2, NameIn2And3).Find(&users2)
    	if len(users2) != 1 {
    		t.Errorf("Should found one user's name is 2, but got %v", len(users2))
    	}
    
    	DB.Scopes(NameIn([]string{users[0].Name, users[2].Name})).Find(&users3)
    	if len(users3) != 2 {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Fri Jan 12 08:42:21 GMT 2024
    - 3.3K bytes
    - Viewed (0)
  3. tests/associations_belongs_to_test.go

    	}
    
    	CheckUser(t, user, user)
    
    	// Find
    	var user2 User
    	DB.Find(&user2, "id = ?", user.ID)
    	pointerOfUser := &user2
    	if err := DB.Model(&pointerOfUser).Association("Company").Find(&user2.Company); err != nil {
    		t.Errorf("failed to query users, got error %#v", err)
    	}
    	user2.Manager = &User{}
    	DB.Model(&user2).Association("Manager").Find(user2.Manager)
    	CheckUser(t, user2, user)
    
    	// Count
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Oct 30 09:15:49 GMT 2023
    - 9.3K bytes
    - Viewed (0)
  4. android/guava-testlib/src/com/google/common/collect/testing/testers/AbstractListIndexOfTester.java

      protected abstract int find(@Nullable Object o);
    
      /** Override to return "indexOf" or "lastIndexOf()" for use in failure messages. */
      protected abstract String getMethodName();
    
      @CollectionSize.Require(absent = ZERO)
      public void testFind_yes() {
        assertEquals(
            getMethodName() + "(firstElement) should return 0", 0, find(getOrderedElements().get(0)));
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Apr 20 11:19:03 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  5. tests/update_has_one_test.go

    		t.Fatalf("errors happened when update: %v", err)
    	}
    
    	var user2 User
    	DB.Preload("Account").Find(&user2, "id = ?", user.ID)
    	CheckUser(t, user2, user)
    
    	user.Account.Number += "new"
    	if err := DB.Save(&user).Error; err != nil {
    		t.Fatalf("errors happened when update: %v", err)
    	}
    
    	var user3 User
    	DB.Preload("Account").Find(&user3, "id = ?", user.ID)
    
    	CheckUser(t, user2, user3)
    	lastUpdatedAt := user2.Account.UpdatedAt
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Jul 14 06:55:54 GMT 2022
    - 3.6K bytes
    - Viewed (0)
  6. tests/soft_delete_test.go

    	}
    
    	sql = DB.Session(&gorm.Session{DryRun: true}).Table("user u").Select("name").Find(&User{}).Statement.SQL.String()
    	if !regexp.MustCompile(`SELECT .name. FROM user u WHERE .u.\..deleted_at. IS NULL`).MatchString(sql) {
    		t.Errorf("Table with escape character, got %v", sql)
    	}
    
    	if DB.First(&User{}, "name = ?", user.Name).Error == nil {
    		t.Errorf("Can't find a soft deleted record")
    	}
    
    	count = 0
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Wed Feb 01 06:40:55 GMT 2023
    - 5.7K bytes
    - Viewed (0)
  7. .github/DISCUSSION_TEMPLATE/questions.yml

              required: true
            - label: I used the GitHub search to find a similar question and didn't find it.
              required: true
            - label: I searched the FastAPI documentation, with the integrated search.
              required: true
            - label: I already searched in Google "How to X in FastAPI" and didn't find any information.
              required: true
    Others
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Aug 03 15:59:41 GMT 2023
    - 5.8K bytes
    - Viewed (1)
  8. cni/pkg/repair/netns.go

    	return netlink.LinkByIndex(linkIndex)
    }
    
    // getPodNetNs finds the network namespace for a given pod. There is not a great way to do this. Network namespaces live
    // under the procfs, /proc/<pid>/ns/net. In majority of cases, this is not used directly, but is rather bind mounted to
    // /var/run/netns/<name>. However, this pattern is not ubiquitous. Some platforms bind mount to other places. As we run
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Wed Dec 20 22:14:13 GMT 2023
    - 4.8K bytes
    - Viewed (0)
  9. tests/benchmark_test.go

    	user := *GetUser("bench", Config{})
    
    	for x := 0; x < b.N; x++ {
    		user.ID = 0
    		DB.Create(&user)
    	}
    }
    
    func BenchmarkFind(b *testing.B) {
    	user := *GetUser("find", Config{})
    	DB.Create(&user)
    
    	for x := 0; x < b.N; x++ {
    		DB.Find(&User{}, "id = ?", user.ID)
    	}
    }
    
    func BenchmarkScan(b *testing.B) {
    	user := *GetUser("scan", Config{})
    	DB.Create(&user)
    
    	var u User
    	b.ResetTimer()
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Wed Jun 01 03:50:57 GMT 2022
    - 1.5K bytes
    - Viewed (0)
  10. guava/src/com/google/common/base/JdkPattern.java

        }
    
        @Override
        public boolean matches() {
          return matcher.matches();
        }
    
        @Override
        public boolean find() {
          return matcher.find();
        }
    
        @Override
        public boolean find(int index) {
          return matcher.find(index);
        }
    
        @Override
        public String replaceAll(String replacement) {
          return matcher.replaceAll(replacement);
        }
    
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Fri Feb 09 15:49:48 GMT 2024
    - 2.2K bytes
    - Viewed (0)
Back to top