private DictionaryEntrySourceMember( Type type, Func <string> pathFactory, QualifiedMember matchedTargetMember, DictionarySourceMember parent, Member[] childMembers = null) { Type = type; _pathFactory = pathFactory; _matchedTargetMember = matchedTargetMember; Parent = parent; _childMembers = childMembers ?? new[] { Member.RootSource(type) }; if (childMembers == null) { IsEnumerable = _childMembers.First().IsEnumerable; IsSimple = !IsEnumerable && _childMembers.First().IsSimple; return; } var leafMember = childMembers.Last(); IsEnumerable = leafMember.IsEnumerable; IsSimple = leafMember.IsSimple; }
public DictionaryEntrySourceMember( Type entryType, QualifiedMember matchedTargetMember, DictionarySourceMember parent) : this( entryType, () => parent.GetPath() + "['" + matchedTargetMember.Name + "']", matchedTargetMember, parent) { }
private DictionaryEntrySourceMember( Type type, Func <string> pathFactory, QualifiedMember matchedTargetMember, DictionarySourceMember parent) { Type = type; _pathFactory = pathFactory; _matchedTargetMember = matchedTargetMember; Parent = parent; }
private DictionaryEntrySourceMember( Type type, Func <string> pathFactory, QualifiedMember matchedTargetMember, DictionarySourceMember parent, Member[] childMembers) : this(type, pathFactory, matchedTargetMember, parent) { _childMembers = childMembers; var leafMember = childMembers.Last(); IsEnumerable = leafMember.IsEnumerable; IsSimple = leafMember.IsSimple; }
public DictionaryEntrySourceMember( Type entryType, QualifiedMember matchedTargetMember, DictionarySourceMember parent) : this( entryType, () => parent.GetPath() + "['" + matchedTargetMember.Name + "']", matchedTargetMember, parent) { var entryMember = Member.RootSource(entryType); _childMembers = new[] { entryMember }; IsEnumerable = entryMember.IsEnumerable; IsSimple = !IsEnumerable && entryMember.IsSimple; }