/// <summary> /// Initializes a new instance of the <see cref="DiagramController"/> class. /// </summary> internal DiagramController() { this.modelCollection = DiagramContext.DiagramObjects; this.messageCollection = DiagramContext.Messages; this.relationCollection = DiagramContext.Relations; this.Clear(); }
/// <summary>Retrieves in the calling AuditActionCollection object all AuditActionEntity objects which are related via a relation of type 'm:n' with the passed in RoleEntity.</summary> /// <param name="containingTransaction">A containing transaction, if caller is added to a transaction, or null if not.</param> /// <param name="collectionToFill">Collection to fill with the entity objects retrieved</param> /// <param name="maxNumberOfItemsToReturn"> The maximum number of items to return with this retrieval query. When set to 0, no limitations are specified.</param> /// <param name="sortClauses">The order by specifications for the sorting of the resultset. When not specified, no sorting is applied.</param> /// <param name="entityFactoryToUse">The EntityFactory to use when creating entity objects during a GetMulti() call.</param> /// <param name="roleInstance">RoleEntity object to be used as a filter in the m:n relation</param> /// <param name="prefetchPathToUse">the PrefetchPath which defines the graph of objects to fetch.</param> /// <param name="pageNumber">The page number to retrieve.</param> /// <param name="pageSize">The page size of the page to retrieve.</param> /// <returns>true if succeeded, false otherwise</returns> public bool GetMultiUsingRolesWithAuditAction(ITransaction containingTransaction, IEntityCollection collectionToFill, long maxNumberOfItemsToReturn, ISortExpression sortClauses, IEntityFactory entityFactoryToUse, IEntity roleInstance, IPrefetchPath prefetchPathToUse, int pageNumber, int pageSize) { RelationCollection relations = new RelationCollection(); relations.Add(AuditActionEntity.Relations.RoleAuditActionEntityUsingAuditActionID, "RoleAuditAction_"); relations.Add(RoleAuditActionEntity.Relations.RoleEntityUsingRoleID, "RoleAuditAction_", string.Empty, JoinHint.None); IPredicateExpression selectFilter = new PredicateExpression(); selectFilter.Add(new FieldCompareValuePredicate(roleInstance.Fields[(int)RoleFieldIndex.RoleID], ComparisonOperator.Equal)); return this.GetMulti(containingTransaction, collectionToFill, maxNumberOfItemsToReturn, sortClauses, entityFactoryToUse, selectFilter, relations, prefetchPathToUse, pageNumber, pageSize); }
public SelectList subjectAttributes(object selObjId) { if (m_subjectAttributes == null) { m_subjectAttributes = new AttributeCollection(); RelationCollection rels = new RelationCollection(AttributeEntity.Relations.ContextEntityUsingContextId); PredicateExpression pe = new PredicateExpression(ContextFields.Name == "subject"); SortExpression se = new SortExpression(AttributeFields.Name | SortOperator.Ascending); m_subjectAttributes.GetMulti(pe, 0, se, rels); } SelectList selList = new SelectList(m_subjectAttributes, "Id", "Name", selObjId); return selList; }
public IList<Auction.Domain.Donor> GetByEvent(long eventId, ref IAuctionTransaction trans) { using (var donors = new DonorCollection()) { var relations = new RelationCollection {AuctionEventDonorEntity.Relations.DonorEntityUsingDonorId}; var filter = new PredicateExpression { AuctionEventDonorFields.EventId == eventId }; donors.GetMulti(filter, relations); return donors.Select(d => new Donor() { Id = d.Id, AccountId = d.AccountId, Name = d.Name, Notes = d.Notes, Phone = d.Phone }).ToList(); } }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Events": toReturn.Add(SeminarsEntity.Relations.EventsEntityUsingEventId); break; case "OrganizationRoleUser": toReturn.Add(SeminarsEntity.Relations.OrganizationRoleUserEntityUsingOrgRoleUserId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "MedicareQuestion": toReturn.Add(MedicareGroupDependencyRuleEntity.Relations.MedicareQuestionEntityUsingQuestionId); break; case "MedicareQuestionGroup": toReturn.Add(MedicareGroupDependencyRuleEntity.Relations.MedicareQuestionGroupEntityUsingDependentGroupId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Zip_": toReturn.Add(ZipRadiusDistanceEntity.Relations.ZipEntityUsingSourceZipId); break; case "Zip": toReturn.Add(ZipRadiusDistanceEntity.Relations.ZipEntityUsingDestinationZipId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "BillingAccount": toReturn.Add(BillingAccountTestEntity.Relations.BillingAccountEntityUsingBillingAccountId); break; case "Test": toReturn.Add(BillingAccountTestEntity.Relations.TestEntityUsingTestId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Encounter": toReturn.Add(ClaimEntity.Relations.EncounterEntityUsingEncounterId); break; case "InsurancePayment": toReturn.Add(ClaimEntity.Relations.InsurancePaymentEntityUsingInsurancePaymentId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "OrderItem": toReturn.Add(ProspectActivityEntity.Relations.OrderItemEntityUsingProspectId); break; case "Test": toReturn.Add(ProspectActivityEntity.Relations.TestEntityUsingActivityId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Events": toReturn.Add(MarketingPrintOrderEventMappingEntity.Relations.EventsEntityUsingEventId); break; case "MarketingPrintOrder": toReturn.Add(MarketingPrintOrderEventMappingEntity.Relations.MarketingPrintOrderEntityUsingMarketingPrintOrderId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Lookup": toReturn.Add(RoleScopeOptionEntity.Relations.LookupEntityUsingScopeId); break; case "Role": toReturn.Add(RoleScopeOptionEntity.Relations.RoleEntityUsingRoleId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "IncidentalFindingReadingGroup": toReturn.Add(IncidentalFindingIncidentalFindingReadingGroupEntity.Relations.IncidentalFindingReadingGroupEntityUsingGroupId); break; case "IncidentalFindings": toReturn.Add(IncidentalFindingIncidentalFindingReadingGroupEntity.Relations.IncidentalFindingsEntityUsingIncidentalFindingId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "FluConsentQuestion": toReturn.Add(FluConsentTemplateQuestionEntity.Relations.FluConsentQuestionEntityUsingQuestionId); break; case "FluConsentTemplate": toReturn.Add(FluConsentTemplateQuestionEntity.Relations.FluConsentTemplateEntityUsingTemplateId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Contacts": toReturn.Add(ContactFranchiseeAccessEntity.Relations.ContactsEntityUsingContactId); break; case "Organization": toReturn.Add(ContactFranchiseeAccessEntity.Relations.OrganizationEntityUsingOrganizationId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Organization": toReturn.Add(ScheduleTemplateFranchiseeAccessEntity.Relations.OrganizationEntityUsingOrganizationId); break; case "ScheduleTemplate": toReturn.Add(ScheduleTemplateFranchiseeAccessEntity.Relations.ScheduleTemplateEntityUsingScheduleTemplateId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "CustomerProfile": toReturn.Add(CustomerSurveyEntity.Relations.CustomerProfileEntityUsingCustomerId); break; case "CustomerSurveyQuestionAnswer": toReturn.Add(CustomerSurveyEntity.Relations.CustomerSurveyQuestionAnswerEntityUsingCustomerSurveyQuestionAnswerId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "CallCenterTeam": toReturn.Add(CallCenterAgentTeamEntity.Relations.CallCenterTeamEntityUsingTeamId); break; case "OrganizationRoleUser": toReturn.Add(CallCenterAgentTeamEntity.Relations.OrganizationRoleUserEntityUsingAgentId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Country": toReturn.Add(IpcountryEntity.Relations.CountryEntityUsingCountryId); break; case "Ip": toReturn.Add(IpcountryEntity.Relations.IpEntityUsingIpid); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "OrganizationRoleUser": toReturn.Add(OrganizationRoleUserTerritoryEntity.Relations.OrganizationRoleUserEntityUsingOrganizationRoleUserId); break; case "Territory": toReturn.Add(OrganizationRoleUserTerritoryEntity.Relations.TerritoryEntityUsingTerritoryId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Events": toReturn.Add(EventHospitalFacilityEntity.Relations.EventsEntityUsingEventId); break; case "HospitalFacility": toReturn.Add(EventHospitalFacilityEntity.Relations.HospitalFacilityEntityUsingHospitalFacilityId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Coupons": toReturn.Add(TestSourceCodeDiscountEntity.Relations.CouponsEntityUsingSourceCodeId); break; case "Test": toReturn.Add(TestSourceCodeDiscountEntity.Relations.TestEntityUsingTestId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "MarketingSource": toReturn.Add(MarketingSourceTerritoryEntity.Relations.MarketingSourceEntityUsingMarketingSourceId); break; case "Territory": toReturn.Add(MarketingSourceTerritoryEntity.Relations.TerritoryEntityUsingTerritoryId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "OrderItem": toReturn.Add(ShippingOptionOrderItemEntity.Relations.OrderItemEntityUsingOrderItemId); break; case "ShippingOption": toReturn.Add(ShippingOptionOrderItemEntity.Relations.ShippingOptionEntityUsingShippingOptionId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "EventPodRoom": toReturn.Add(EventPodRoomTestEntity.Relations.EventPodRoomEntityUsingEventPodRoomId); break; case "Test": toReturn.Add(EventPodRoomTestEntity.Relations.TestEntityUsingTestId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Coupons": toReturn.Add(PaymentCouponsEntity.Relations.CouponsEntityUsingCouponId); break; case "PaymentDetails": toReturn.Add(PaymentCouponsEntity.Relations.PaymentDetailsEntityUsingPaymentDetailsId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "AccessControlObject": toReturn.Add(AccessObjectScopeOptionEntity.Relations.AccessControlObjectEntityUsingAccessControlObjectId); break; case "Lookup": toReturn.Add(AccessObjectScopeOptionEntity.Relations.LookupEntityUsingScopeId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "PhysicianProfile": toReturn.Add(PhysicianLicenseEntity.Relations.PhysicianProfileEntityUsingPhysicianId); break; case "State": toReturn.Add(PhysicianLicenseEntity.Relations.StateEntityUsingStateId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Package": toReturn.Add(TerritoryPackageEntity.Relations.PackageEntityUsingPackageId); break; case "Territory": toReturn.Add(TerritoryPackageEntity.Relations.TerritoryEntityUsingTerritoryId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "OrganizationRoleUser_": toReturn.Add(ContentEntity.Relations.OrganizationRoleUserEntityUsingModifiedBy); break; case "OrganizationRoleUser": toReturn.Add(ContentEntity.Relations.OrganizationRoleUserEntityUsingCreatedBy); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "Check": toReturn.Add(CheckPaymentEntity.Relations.CheckEntityUsingCheckId); break; case "Payment": toReturn.Add(CheckPaymentEntity.Relations.PaymentEntityUsingPaymentId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "EventActivityTemplate": toReturn.Add(EventActivityTemplateMeetingEntity.Relations.EventActivityTemplateEntityUsingEventActivityTemplateId); break; case "OrganizationRoleUser": toReturn.Add(EventActivityTemplateMeetingEntity.Relations.OrganizationRoleUserEntityUsingResponsibleOrgRoleUserId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "OrganizationRoleUser": toReturn.Add(PreApprovedPackageEntity.Relations.OrganizationRoleUserEntityUsingCreatedByOrgRoleUserId); break; case "Package": toReturn.Add(PreApprovedPackageEntity.Relations.PackageEntityUsingPackageId); break; default: break; } return(toReturn); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch (fieldName) { case "CallRoundCallQueue": toReturn.Add(CallRoundCallQueueCriteriaAssignmentEntity.Relations.CallRoundCallQueueEntityUsingCallRoundCallQueueId); break; case "HealthPlanCallQueueCriteria": toReturn.Add(CallRoundCallQueueCriteriaAssignmentEntity.Relations.HealthPlanCallQueueCriteriaEntityUsingCriteriaId); break; default: break; } return(toReturn); }
public Document[] GetLibraryDocuments(string libraryName) { List<Document> docs = new List<Document>(); PolicyDocumentCollection policyDocuments = new PolicyDocumentCollection(); RelationCollection rels = new RelationCollection(PolicyDocumentEntity.Relations.LibraryEntityUsingLibraryId); PredicateExpression pe = new PredicateExpression(LibraryFields.Name == libraryName); SortExpression se = new SortExpression(PolicyDocumentFields.Name | SortOperator.Ascending); policyDocuments.GetMulti(pe, 0, se, rels); foreach (PolicyDocumentEntity doc in policyDocuments) { Document wdoc = new Document(); wdoc.Name = doc.Name; wdoc.Id = doc.Id; docs.Add(wdoc); } return docs.ToArray(); }
/// <summary> /// Retrieves in the calling AccountCollection object all AccountEntity objects /// which are related via a relation of type 'm:n' with the passed in UserEntity. /// </summary> /// <param name="containingTransaction">A containing transaction, if caller is added to a transaction, or null if not.</param> /// <param name="collectionToFill">Collection to fill with the entity objects retrieved</param> /// <param name="maxNumberOfItemsToReturn"> The maximum number of items to return with this retrieval query. /// If the used Dynamic Query Engine supports it, 'TOP' is used to limit the amount of rows to return. When set to 0, no limitations are specified.</param> /// <param name="sortClauses">The order by specifications for the sorting of the resultset. When not specified, no sorting is applied.</param> /// <param name="entityFactoryToUse">The EntityFactory to use when creating entity objects during a GetMulti() call.</param> /// <param name="userInstance">UserEntity object to be used as a filter in the m:n relation</param> /// <param name="prefetchPathToUse">the PrefetchPath which defines the graph of objects to fetch.</param> /// <returns>true if succeeded, false otherwise</returns> public bool GetMultiUsingUserCollectionViaDonor_(ITransaction containingTransaction, IEntityCollection collectionToFill, long maxNumberOfItemsToReturn, ISortExpression sortClauses, IEntityFactory entityFactoryToUse, IEntity userInstance, IPrefetchPath prefetchPathToUse) { IEntityFields fieldsToReturn = EntityFieldsFactory.CreateEntityFieldsObject(Auction.Entities.EntityType.AccountEntity); RelationCollection relations = new RelationCollection(); relations.Add(AccountEntity.Relations.DonorEntityUsingAccountId, "Donor_"); relations.Add(DonorEntity.Relations.UserEntityUsingUpdatedBy, "Donor_", string.Empty, JoinHint.None); IPredicateExpression selectFilter = new PredicateExpression(); selectFilter.Add(new FieldCompareValuePredicate(userInstance.Fields[(int)UserFieldIndex.Id], ComparisonOperator.Equal)); return GetMulti(containingTransaction, collectionToFill, maxNumberOfItemsToReturn, sortClauses, entityFactoryToUse, selectFilter, relations, prefetchPathToUse); }
/// <summary> /// Retrieves in the calling AccountCollection object all AccountEntity objects /// which are related via a relation of type 'm:n' with the passed in RoleEntity. /// </summary> /// <param name="containingTransaction">A containing transaction, if caller is added to a transaction, or null if not.</param> /// <param name="collectionToFill">Collection to fill with the entity objects retrieved</param> /// <param name="maxNumberOfItemsToReturn"> The maximum number of items to return with this retrieval query. /// If the used Dynamic Query Engine supports it, 'TOP' is used to limit the amount of rows to return. When set to 0, no limitations are specified.</param> /// <param name="sortClauses">The order by specifications for the sorting of the resultset. When not specified, no sorting is applied.</param> /// <param name="entityFactoryToUse">The EntityFactory to use when creating entity objects during a GetMulti() call.</param> /// <param name="roleInstance">RoleEntity object to be used as a filter in the m:n relation</param> /// <param name="pageNumber">The page number to retrieve.</param> /// <param name="pageSize">The page size of the page to retrieve.</param> /// <returns>true if succeeded, false otherwise</returns> public bool GetMultiUsingRoleCollectionViaUser(ITransaction containingTransaction, IEntityCollection collectionToFill, long maxNumberOfItemsToReturn, ISortExpression sortClauses, IEntityFactory entityFactoryToUse, IEntity roleInstance, int pageNumber, int pageSize) { IEntityFields fieldsToReturn = EntityFieldsFactory.CreateEntityFieldsObject(Auction.Entities.EntityType.AccountEntity); RelationCollection relations = new RelationCollection(); relations.Add(AccountEntity.Relations.UserEntityUsingAccountId, "User_"); relations.Add(UserEntity.Relations.RoleEntityUsingRoleId, "User_", string.Empty, JoinHint.None); IPredicateExpression selectFilter = new PredicateExpression(); selectFilter.Add(new FieldCompareValuePredicate(roleInstance.Fields[(int)RoleFieldIndex.Id], ComparisonOperator.Equal)); return GetMulti(containingTransaction, collectionToFill, maxNumberOfItemsToReturn, sortClauses, entityFactoryToUse, selectFilter, relations, pageNumber, pageSize); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "AspnetUser": toReturn.Add(Relations.AspnetUsersEntityUsingUserId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static new RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Message": toReturn.Add(Relations.MessageEntityUsingMessageID); break; default: toReturn = AuditDataCoreEntity.GetRelationsForField(fieldName); break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Address": toReturn.Add(Relations.AddressEntityUsingAddressId); break; case "AddressType": toReturn.Add(Relations.AddressTypeEntityUsingAddressTypeId); break; case "BusinessEntity": toReturn.Add(Relations.BusinessEntityEntityUsingBusinessEntityId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "SalesPerson": toReturn.Add(Relations.SalesPersonEntityUsingSalesPersonId); break; default: break; } return toReturn; }
/// <summary>Retrieves in the calling ForumCollection object all ForumEntity objects which are related via a relation of type 'm:n' with the passed in UserEntity.</summary> /// <param name="containingTransaction">A containing transaction, if caller is added to a transaction, or null if not.</param> /// <param name="collectionToFill">Collection to fill with the entity objects retrieved</param> /// <param name="maxNumberOfItemsToReturn"> The maximum number of items to return with this retrieval query. When set to 0, no limitations are specified.</param> /// <param name="sortClauses">The order by specifications for the sorting of the resultset. When not specified, no sorting is applied.</param> /// <param name="entityFactoryToUse">The EntityFactory to use when creating entity objects during a GetMulti() call.</param> /// <param name="userInstance">UserEntity object to be used as a filter in the m:n relation</param> /// <param name="prefetchPathToUse">the PrefetchPath which defines the graph of objects to fetch.</param> /// <param name="pageNumber">The page number to retrieve.</param> /// <param name="pageSize">The page size of the page to retrieve.</param> /// <returns>true if succeeded, false otherwise</returns> public bool GetMultiUsingUsersWhoStartedThreads(ITransaction containingTransaction, IEntityCollection collectionToFill, long maxNumberOfItemsToReturn, ISortExpression sortClauses, IEntityFactory entityFactoryToUse, IEntity userInstance, IPrefetchPath prefetchPathToUse, int pageNumber, int pageSize) { RelationCollection relations = new RelationCollection(); relations.Add(ForumEntity.Relations.ThreadEntityUsingForumID, "Thread_"); relations.Add(ThreadEntity.Relations.UserEntityUsingStartedByUserID, "Thread_", string.Empty, JoinHint.None); IPredicateExpression selectFilter = new PredicateExpression(); selectFilter.Add(new FieldCompareValuePredicate(userInstance.Fields[(int)UserFieldIndex.UserID], ComparisonOperator.Equal)); return this.GetMulti(containingTransaction, collectionToFill, maxNumberOfItemsToReturn, sortClauses, entityFactoryToUse, selectFilter, relations, prefetchPathToUse, pageNumber, pageSize); }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "AspnetApplications": toReturn.Add(Relations.AspnetApplicationsEntityUsingApplicationId); break; case "NewsCategoryParent": toReturn.Add(Relations.NewsCategoryEntityUsingIdNewsCategoryId); break; case "NewsCategoryChildrens": toReturn.Add(Relations.NewsCategoryEntityUsingNewsCategoryId); break; case "NewsCategoryInRoles": toReturn.Add(Relations.NewsCategoryInRoleEntityUsingNewsCategoryId); break; case "NewsCategoryLocalizations": toReturn.Add(Relations.NewsCategoryLocalizationEntityUsingNewsCategoryId); break; case "NewsItems": toReturn.Add(Relations.NewsItemEntityUsingNewsCategoryId); break; case "SnRelationshipss": toReturn.Add(Relations.SnRelationshipEntityUsingNewsCategoryId); break; case "NewsCategoryTemplate": toReturn.Add(Relations.NewsCategoryTemplateEntityUsingId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "ProductInventories": toReturn.Add(Relations.ProductInventoryEntityUsingLocationId); break; case "WorkOrderRoutings": toReturn.Add(Relations.WorkOrderRoutingEntityUsingLocationId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "SupportQueue": toReturn.Add(Relations.SupportQueueEntityUsingQueueID); break; case "ClaimedByUser": toReturn.Add(Relations.UserEntityUsingClaimedByUserID); break; case "PlacedInQueueByUser": toReturn.Add(Relations.UserEntityUsingPlacedInQueueByUserID); break; case "Thread": toReturn.Add(Relations.ThreadEntityUsingThreadID); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "AspnetRole": toReturn.Add(Relations.AspnetRolesEntityUsingRoleId); break; case "NewsCategory": toReturn.Add(Relations.NewsCategoryEntityUsingNewsCategoryId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "ProductModel": toReturn.Add(Relations.ProductModelEntityUsingProductModelId); break; case "ProductSubcategory": toReturn.Add(Relations.ProductSubcategoryEntityUsingProductSubcategoryId); break; case "UnitMeasure": toReturn.Add(Relations.UnitMeasureEntityUsingSizeUnitMeasureCode); break; case "UnitMeasure_": toReturn.Add(Relations.UnitMeasureEntityUsingWeightUnitMeasureCode); break; case "BillOfMaterials": toReturn.Add(Relations.BillOfMaterialEntityUsingComponentId); break; case "BillOfMaterials_": toReturn.Add(Relations.BillOfMaterialEntityUsingProductAssemblyId); break; case "ProductCostHistories": toReturn.Add(Relations.ProductCostHistoryEntityUsingProductId); break; case "ProductDocuments": toReturn.Add(Relations.ProductDocumentEntityUsingProductId); break; case "ProductInventories": toReturn.Add(Relations.ProductInventoryEntityUsingProductId); break; case "ProductListPriceHistories": toReturn.Add(Relations.ProductListPriceHistoryEntityUsingProductId); break; case "ProductProductPhotos": toReturn.Add(Relations.ProductProductPhotoEntityUsingProductId); break; case "ProductReviews": toReturn.Add(Relations.ProductReviewEntityUsingProductId); break; case "ProductVendors": toReturn.Add(Relations.ProductVendorEntityUsingProductId); break; case "PurchaseOrderDetails": toReturn.Add(Relations.PurchaseOrderDetailEntityUsingProductId); break; case "ShoppingCartItems": toReturn.Add(Relations.ShoppingCartItemEntityUsingProductId); break; case "SpecialOfferProducts": toReturn.Add(Relations.SpecialOfferProductEntityUsingProductId); break; case "TransactionHistories": toReturn.Add(Relations.TransactionHistoryEntityUsingProductId); break; case "WorkOrders": toReturn.Add(Relations.WorkOrderEntityUsingProductId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Person": toReturn.Add(Relations.PersonEntityUsingPersonId); break; case "ArtworkToRoles": toReturn.Add(Relations.ArtworkToRoleEntityUsingRoleId); break; case "RoleToEpisodes": toReturn.Add(Relations.RoleToEpisodeEntityUsingRoleId); break; case "RoleToSeasons": toReturn.Add(Relations.RoleToSeasonEntityUsingRoleId); break; case "RoleToSeries": toReturn.Add(Relations.RoleToSeriesEntityUsingRoleId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Contact": toReturn.Add(Relations.ContactEntityUsingContactId); break; case "Employee": toReturn.Add(Relations.EmployeeEntityUsingEmployeeIdManagerId); break; case "Employees": toReturn.Add(Relations.EmployeeEntityUsingManagerId); break; case "EmployeeAddresses": toReturn.Add(Relations.EmployeeAddressEntityUsingEmployeeId); break; case "EmployeeDepartmentHistories": toReturn.Add(Relations.EmployeeDepartmentHistoryEntityUsingEmployeeId); break; case "EmployeePayHistories": toReturn.Add(Relations.EmployeePayHistoryEntityUsingEmployeeId); break; case "JobCandidates": toReturn.Add(Relations.JobCandidateEntityUsingEmployeeId); break; case "PurchaseOrderHeaders": toReturn.Add(Relations.PurchaseOrderHeaderEntityUsingEmployeeId); break; case "SalesPerson": toReturn.Add(Relations.SalesPersonEntityUsingSalesPersonId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> public static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "AuctionEvent": toReturn.Add(RaffleEntity.Relations.AuctionEventEntityUsingEventId); break; case "User_": toReturn.Add(RaffleEntity.Relations.UserEntityUsingUpdatedBy); break; case "User": toReturn.Add(RaffleEntity.Relations.UserEntityUsingCreatedBy); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Language": toReturn.Add(Relations.LanguageEntityUsingLanguageId); break; case "Page": toReturn.Add(Relations.PageEntityUsingPageId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Customer": toReturn.Add(Relations.CustomerEntityUsingCustomerId); break; case "Employee": toReturn.Add(Relations.EmployeeEntityUsingEmployeeId); break; case "Shipper": toReturn.Add(Relations.ShipperEntityUsingShipVia); break; case "OrderDetails": toReturn.Add(Relations.OrderDetailEntityUsingOrderId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Forums": toReturn.Add(Relations.ForumEntityUsingSectionID); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "BillOfMaterials": toReturn.Add(Relations.BillOfMaterialEntityUsingUnitMeasureCode); break; case "Products": toReturn.Add(Relations.ProductEntityUsingSizeUnitMeasureCode); break; case "Products_": toReturn.Add(Relations.ProductEntityUsingWeightUnitMeasureCode); break; case "ProductVendors": toReturn.Add(Relations.ProductVendorEntityUsingUnitMeasureCode); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Customer": toReturn.Add(Relations.CustomerEntityUsingCustomerId); break; case "CustomerDemographic": toReturn.Add(Relations.CustomerDemographicEntityUsingCustomerTypeId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "ForumRoleForumActionRights": toReturn.Add(Relations.ForumRoleForumActionRightEntityUsingActionRightID); break; case "RoleSystemActionRights": toReturn.Add(Relations.RoleSystemActionRightEntityUsingActionRightID); break; case "SystemRightAssignedToRoles": toReturn.Add(Relations.RoleSystemActionRightEntityUsingActionRightID, "ActionRightEntity__", "RoleSystemActionRight_", JoinHint.None); toReturn.Add(RoleSystemActionRightEntity.Relations.RoleEntityUsingRoleID, "RoleSystemActionRight_", string.Empty, JoinHint.None); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Artwork": toReturn.Add(Relations.ArtworkEntityUsingArtworkId); break; case "Role": toReturn.Add(Relations.RoleEntityUsingRoleId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Employee": toReturn.Add(Relations.EmployeeEntityUsingEmployeeId); break; case "ShipMethod": toReturn.Add(Relations.ShipMethodEntityUsingShipMethodId); break; case "Vendor": toReturn.Add(Relations.VendorEntityUsingVendorId); break; case "PurchaseOrderDetails": toReturn.Add(Relations.PurchaseOrderDetailEntityUsingPurchaseOrderId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "Products": toReturn.Add(Relations.ProductEntityUsingCategoryId); break; default: break; } return toReturn; }
/// <summary>Gets the relation objects which represent the relation the fieldName specified is mapped on. </summary> /// <param name="fieldName">Name of the field mapped onto the relation of which the relation objects have to be obtained.</param> /// <returns>RelationCollection with relation object(s) which represent the relation the field is maped on</returns> internal static RelationCollection GetRelationsForField(string fieldName) { RelationCollection toReturn = new RelationCollection(); switch(fieldName) { case "CountryRegion": toReturn.Add(Relations.CountryRegionEntityUsingCountryRegionCode); break; case "Currency": toReturn.Add(Relations.CurrencyEntityUsingCurrencyCode); break; default: break; } return toReturn; }