MonoSoftware.MonoX.DAL.EntityClasses.SnNoteEntity.GetRelationsForField C# (CSharp) Method

GetRelationsForField() static private method

Gets the relation objects which represent the relation the fieldName specified is mapped on.
static private GetRelationsForField ( string fieldName ) : RelationCollection
fieldName string Name of the field mapped onto the relation of which the relation objects have to be obtained.
return RelationCollection
        internal static RelationCollection GetRelationsForField(string fieldName)
        {
            RelationCollection toReturn = new RelationCollection();
            switch(fieldName)
            {
                case "AspnetApplication":
                    toReturn.Add(Relations.AspnetApplicationsEntityUsingApplicationId);
                    break;
                case "AspnetUserAuthor":
                    toReturn.Add(Relations.AspnetUsersEntityUsingUserId);
                    break;
                case "AspnetUserPostedTo":
                    toReturn.Add(Relations.AspnetUsersEntityUsingPostToUserId);
                    break;
                case "Language":
                    toReturn.Add(Relations.LanguageEntityUsingLanguageId);
                    break;
                case "PrivacyLevel":
                    toReturn.Add(Relations.PrivacyLevelEntityUsingPrivacyLevelId);
                    break;
                case "SnGroup":
                    toReturn.Add(Relations.SnGroupEntityUsingGroupId);
                    break;
                case "SnEvents":
                    toReturn.Add(Relations.SnEventEntityUsingSnNoteId);
                    break;
                case "SnRelationships":
                    toReturn.Add(Relations.SnRelationshipEntityUsingNoteId);
                    break;
                default:
                    break;
            }
            return toReturn;
        }