示例#1
0
 /// <summary>
 /// Called to ask the filter if a particular relationship from a source element should be included in the traversal
 /// </summary>
 /// <param name="walker">ElementWalker that is traversing the model</param>
 /// <param name="sourceElement">Model Element playing the source role</param>
 /// <param name="sourceRoleInfo">DomainRoleInfo of the role that the source element is playing in the relationship</param>
 /// <param name="domainRelationshipInfo">DomainRelationshipInfo for the ElementLink in question</param>
 /// <param name="targetRelationship">Relationship in question</param>
 /// <returns>Yes if the relationship should be traversed</returns>
 public virtual DslModeling::VisitorFilterResult ShouldVisitRelationship(DslModeling::ElementWalker walker, DslModeling::ModelElement sourceElement, DslModeling::DomainRoleInfo sourceRoleInfo, DslModeling::DomainRelationshipInfo domainRelationshipInfo, DslModeling::ElementLink targetRelationship)
 {
     return(DslModeling::VisitorFilterResult.Yes);
 }
示例#2
0
 /// <summary>
 /// Called to ask the filter if a particular relationship from a source element should be included in the traversal
 /// </summary>
 /// <param name="walker">ElementWalker traversing the model</param>
 /// <param name="sourceElement">Model Element playing the source role</param>
 /// <param name="sourceRoleInfo">DomainRoleInfo of the role that the source element is playing in the relationship</param>
 /// <param name="domainRelationshipInfo">DomainRelationshipInfo for the ElementLink in question</param>
 /// <param name="targetRelationship">Relationship in question</param>
 /// <returns>Yes if the relationship should be traversed</returns>
 public virtual DslModeling::VisitorFilterResult ShouldVisitRelationship(DslModeling::ElementWalker walker, DslModeling::ModelElement sourceElement, DslModeling::DomainRoleInfo sourceRoleInfo, DslModeling::DomainRelationshipInfo domainRelationshipInfo, DslModeling::ElementLink targetRelationship)
 {
     return(this.DomainRoles.ContainsKey(sourceRoleInfo.Id) ? DslModeling::VisitorFilterResult.Yes : DslModeling::VisitorFilterResult.DoNotCare);
 }
示例#3
0
 /// <summary>
 /// Called to ask the filter if a particular relationship from a source element should be included in the traversal
 /// </summary>
 /// <param name="walker">ElementWalker traversing the model</param>
 /// <param name="sourceElement">Model Element playing the source role</param>
 /// <param name="sourceRoleInfo">DomainRoleInfo of the role that the source element is playing in the relationship</param>
 /// <param name="domainRelationshipInfo">DomainRelationshipInfo for the ElementLink in question</param>
 /// <param name="targetRelationship">Relationship in question</param>
 /// <returns>Yes if the relationship should be traversed</returns>
 public virtual DslModeling::VisitorFilterResult ShouldVisitRelationship(DslModeling::ElementWalker walker, DslModeling::ModelElement sourceElement, DslModeling::DomainRoleInfo sourceRoleInfo, DslModeling::DomainRelationshipInfo domainRelationshipInfo, DslModeling::ElementLink targetRelationship)
 {
     if (sourceRoleInfo == null)
     {
         throw new global::System.ArgumentNullException("sourceRoleInfo");
     }
     return(this.DomainRoles.Contains(sourceRoleInfo.Id) ? DslModeling::VisitorFilterResult.Yes : DslModeling::VisitorFilterResult.DoNotCare);
 }