conform to the new CreateGetRelationshipMethod API

This commit is contained in:
Michael Becker 2025-10-06 00:21:16 -04:00
parent 0a07991485
commit 5351fe7735
2 changed files with 4 additions and 4 deletions

View File

@ -247,7 +247,7 @@ public class MethodsModule : MiniOmsModule
SystemAttributeRoutine sr = srb.CreateSystemAttributeRoutine(KnownInstanceGuids.SystemAttributeRoutines.GetRuntimeVersion, new Func<Oms, OmsContext, object?>(delegate (Oms oms, OmsContext context) { return oms.RuntimeVersion.ToString(); }));
mb.CreateGetAttributeBySystemRoutineMethod(c_OMS.GetHandle(), "get", "Runtime Version", null, true, KnownInstanceGuids.Methods.GetAttributeBySystemRoutine.OMS__get__Runtime_Version, oms.GetInstance(KnownAttributeGuids.Text.Value), sr);
mb.CreateGetRelationshipMethod(c_Instance.GetHandle(), "get", "Parent Class", AccessModifier.Public, false, KnownInstanceGuids.Methods.GetRelationship.Instance__get__Parent_Class, oms.GetInstance(KnownRelationshipGuids.Instance__for__Class));
mb.CreateGetRelationshipMethod(c_Instance.GetHandle(), "get", "Parent Class", AccessModifier.Public, KnownInstanceGuids.Methods.GetRelationship.Instance__get__Parent_Class, oms.GetInstance(KnownRelationshipGuids.Instance__for__Class));
InstanceHandle a_Seed = oms.CreateInstanceOf(oms.GetInstance(KnownInstanceGuids.Classes.NumericAttribute), KnownAttributeGuids.Numeric.Seed);
oms.SetAttributeValue(a_Seed, a_Name, "Seed");

View File

@ -57,7 +57,7 @@ public class GetReferencedAttributeTests : MethodTestsBase
GetAttributeMethod Test_Class__get__Name = builder.CreateGetAttributeMethod(c_TestClass, "get", "Name", a_Name);
GetRelationshipMethod Test_Class_2__get__Test_Class_2__for__Test_Class = builder.CreateGetRelationshipMethod(c_TestClass2, "get", "Test Class 2.for Test Class", AccessModifier.Public, false, r_Test_Class_2__for__Test_Class);
GetRelationshipMethod Test_Class_2__get__Test_Class_2__for__Test_Class = builder.CreateGetRelationshipMethod(c_TestClass2, "get", "Test Class 2.for Test Class", AccessModifier.Public, r_Test_Class_2__for__Test_Class);
ReturnInstanceSetMethodBinding Test_Class_2__get__parent_Test_Class__ramb = Test_Class_2__get__Test_Class_2__for__Test_Class.CreateMethodBinding(Oms);
@ -109,7 +109,7 @@ public class GetReferencedAttributeTests : MethodTestsBase
Oms.AssignRelationship(i_Nurse1, r_Nurse__has__Patient, new InstanceHandle[] { i_Patient1, i_Patient2, i_Patient3 });
GetRelationshipMethod Nurse__get__Patients = builder.CreateGetRelationshipMethod(c_Nurse, "get", "Nurse.has Patient", AccessModifier.Public, false, r_Nurse__has__Patient);
GetRelationshipMethod Nurse__get__Patients = builder.CreateGetRelationshipMethod(c_Nurse, "get", "Nurse.has Patient", AccessModifier.Public, r_Nurse__has__Patient);
ReturnInstanceSetMethodBinding Nurse__get__Patients_rsmb = Nurse__get__Patients.CreateMethodBinding(Oms);
GetReferencedAttributeMethod ih_GRA = builder.CreateGetReferencedAttributeMethod(c_Nurse, "get", "Patient Acuity Levels Sum", AccessModifier.Public, false, a_Acuity, Nurse__get__Patients_rsmb, Patient__get__Acuity_ramb, Oms.GetInstance(KnownInstanceGuids.AccumulationFunctions.Sum));
@ -166,7 +166,7 @@ public class GetReferencedAttributeTests : MethodTestsBase
Oms.AssignRelationship(i_Nurse1, r_Nurse__has__Patient, new InstanceHandle[] { i_Patient1, i_Patient2, i_Patient3 });
GetRelationshipMethod Nurse__get__Patients = builder.CreateGetRelationshipMethod(c_Nurse, "get", "Nurse.has Patient", AccessModifier.Public, false, r_Nurse__has__Patient);
GetRelationshipMethod Nurse__get__Patients = builder.CreateGetRelationshipMethod(c_Nurse, "get", "Nurse.has Patient", AccessModifier.Public, r_Nurse__has__Patient);
ReturnInstanceSetMethodBinding Nurse__get__Patients_rsmb = Nurse__get__Patients.CreateMethodBinding(Oms);
GetReferencedAttributeMethod ih_GRA = builder.CreateGetReferencedAttributeMethod(c_Nurse, "get", "Patient Acuity Levels Average", AccessModifier.Public, false, a_Acuity, Nurse__get__Patients_rsmb, Patient__get__Acuity_ramb, Oms.GetInstance(KnownInstanceGuids.AccumulationFunctions.Average));