- Sort Score
- Num 10 results
- Language All
Results 1 - 7 of 7 for POLYMORPHIC (0.06 seconds)
The search processing time has exceeded the limit. The displayed results may be partial.
-
schema/relationship.go
// OwnerType string // } func (schema *Schema) buildPolymorphicRelation(relation *Relationship, field *Field) { polymorphic := field.TagSettings["POLYMORPHIC"] relation.Polymorphic = &Polymorphic{ Value: schema.Table, } var ( typeName = polymorphic + "Type" typeId = polymorphic + "ID" ) if value, ok := field.TagSettings["POLYMORPHICTYPE"]; ok { typeName = strings.TrimSpace(value) }
Created: Sun Dec 28 09:35:17 GMT 2025 - Last Modified: Sun Nov 16 04:11:05 GMT 2025 - 23.1K bytes - Click Count (1) -
schema/relationship_test.go
Schema: "User", FieldSchema: "Toy", Polymorphic: Polymorphic{ID: "OwnerID", Type: "OwnerType", Value: "users"}, References: []Reference{ {ForeignKey: "OwnerType", ForeignSchema: "Toy", PrimaryValue: "users"}, }, }, }, }, }) }) t.Run("has one with custom polymorphic type and id", func(t *testing.T) { type Toy struct { ID int
Created: Sun Dec 28 09:35:17 GMT 2025 - Last Modified: Mon Aug 18 11:44:52 GMT 2025 - 26.5K bytes - Click Count (0) -
tests/update_has_one_test.go
} else { user.Account.UpdatedAt = user4.Account.UpdatedAt CheckUser(t, user4, user) } t.Run("Polymorphic", func(t *testing.T) { pet := Pet{Name: "create"} if err := DB.Create(&pet).Error; err != nil { t.Fatalf("errors happened when create: %v", err) } pet.Toy = Toy{Name: "Update-HasOneAssociation-Polymorphic"} if err := DB.Save(&pet).Error; err != nil { t.Fatalf("errors happened when create: %v", err) }Created: Sun Dec 28 09:35:17 GMT 2025 - Last Modified: Thu Jul 14 06:55:54 GMT 2022 - 3.6K bytes - Click Count (0) -
android/guava-tests/benchmark/com/google/common/collect/IteratorBenchmark.java
* * @author David Richter */ @NullUnmarked public class IteratorBenchmark { @Param({"0", "1", "16", "256", "4096", "65536"}) int size; // use concrete classes to remove any possible polymorphic overhead? Object[] array; ArrayList<Object> arrayList; LinkedList<Object> linkedList; @BeforeExperiment void setUp() { array = new Object[size];Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue May 13 17:27:14 GMT 2025 - 3.5K bytes - Click Count (0) -
schema/schema_test.go
References: []Reference{{"ID", "User", "UserID", "Pet", "", true}}, }, { Name: "Toys", Type: schema.HasMany, Schema: "User", FieldSchema: "Toy", Polymorphic: Polymorphic{ID: "OwnerID", Type: "OwnerType", Value: "users"}, References: []Reference{{"ID", "User", "OwnerID", "Toy", "", true}, {"", "", "OwnerType", "Toy", "users", false}}, }, {Created: Sun Dec 28 09:35:17 GMT 2025 - Last Modified: Thu Aug 28 02:57:17 GMT 2025 - 13.3K bytes - Click Count (0) -
tests/association_generics_test.go
t.Fatalf("Set Update many2many clear failed: %v", err) } else if rows != 0 { t.Fatalf("expected 0 rows affected, got %d", rows) } AssertAssociationCount(t, user, "Languages", 0, "after clear") } // Polymorphic Tools create and unlink func TestClauseAssociationSetUpdatePolymorphicTools(t *testing.T) { ctx := context.Background() user := User{Name: "TestClauseAssociationSetUpdatePolymorphicTools", Age: 25}
Created: Sun Dec 28 09:35:17 GMT 2025 - Last Modified: Fri Sep 12 05:42:26 GMT 2025 - 37.9K bytes - Click Count (0) -
doc/go_spec.html
<code>Add</code> and <code>Slice</code>. </li> </ul> <h4 id="Go_1.18">Go 1.18</h4> <p> The 1.18 release adds polymorphic functions and types ("generics") to the language. Specifically: </p> <ul> <li> The set of <a href="#Operators_and_punctuation">operators and punctuation</a> includes the new token <code>~</code>. </li>
Created: Tue Dec 30 11:13:12 GMT 2025 - Last Modified: Tue Dec 02 23:07:19 GMT 2025 - 286.5K bytes - Click Count (1)