コード例 #1
0
ファイル: ORMCoreModel.cs プロジェクト: cjheath/NORMA
		private static void NotifyRoleChanged(INotifySurveyElementChanged eventNotify, Role role)
		{
			foreach (ConstraintRoleSequence sequence in role.ConstraintRoleSequenceCollection)
			{
				UniquenessConstraint uniquenessConstraint;
				EntityTypeHasPreferredIdentifier identifierLink;
				if (null != (uniquenessConstraint = sequence as UniquenessConstraint) &&
					null != (identifierLink = EntityTypeHasPreferredIdentifier.GetLinkToPreferredIdentifierFor(uniquenessConstraint)))
				{
					NotifyErrorStateChanged(eventNotify, identifierLink);
				}
			}
			eventNotify.ElementChanged(role, SurveyGlyphQuestionTypes);
			eventNotify.ElementRenamed(role);
		}
コード例 #2
0
ファイル: ORMCoreModel.cs プロジェクト: cjheath/NORMA
		private static void NotifyErrorStateChanged(INotifySurveyElementChanged eventNotify, IModelErrorOwnerPath errorPath)
		{
			if (errorPath != null)
			{
				ModelError.WalkAssociatedElements(errorPath.ErrorOwnerRolePlayer,
					delegate(ModelElement associatedElement)
					{
						eventNotify.ElementChanged(associatedElement, SurveyErrorQuestionTypes);
					});
			}
		}