Beispiel #1
0
 public TypeMemberDesc(QualifiedIdentifier value, IEnumerable <KeyValuePair <QualifiedIdentifier, object> > extensions = null)
 {
     Value      = value;
     Extensions = extensions is IImmutableDictionary <QualifiedIdentifier, object> id
         ? id
         : (extensions?.ToImmutableDictionary() ?? ImmutableDictionary <QualifiedIdentifier, object> .Empty);
 }
Beispiel #2
0
 public ComplexTypeDesc([NotNull] QualifiedIdentifier name, IEnumerable <KeyValuePair <NameAndIndex, TypeMemberDesc> > members,
                        IEnumerable <KeyValuePair <QualifiedIdentifier, object> > extensions = null) : base(name)
 {
     Members = members is IImmutableDictionary <NameAndIndex, TypeMemberDesc> mid
         ? mid
         : (members?.ToImmutableDictionary() ?? ImmutableDictionary <NameAndIndex, TypeMemberDesc> .Empty);
     Extensions = extensions is IImmutableDictionary <QualifiedIdentifier, object> eid
         ? eid
         : (extensions?.ToImmutableDictionary() ?? ImmutableDictionary <QualifiedIdentifier, object> .Empty);
 }
Beispiel #3
0
 public EnumDesc([NotNull] QualifiedIdentifier name,
                 IEnumerable <KeyValuePair <Identifier, EnumFieldValue> > fields,
                 IEnumerable <KeyValuePair <QualifiedIdentifier, object> > extensions = null) : base(name)
 {
     Fields =
         fields is IImmutableDictionary <Identifier, EnumFieldValue> fid
             ? fid
             : (fields?.ToImmutableDictionary() ?? ImmutableDictionary <Identifier, EnumFieldValue> .Empty);
     Extensions =
         extensions is IImmutableDictionary <QualifiedIdentifier, object> id
             ? id
             : (extensions?.ToImmutableDictionary() ?? ImmutableDictionary <QualifiedIdentifier, object> .Empty);
 }
Beispiel #4
0
 public UnionDesc([NotNull] QualifiedIdentifier name, IEnumerable <KeyValuePair <NameAndIndex, TypeMemberDesc> > members,
                  IEnumerable <KeyValuePair <QualifiedIdentifier, object> > extensions = null) : base(name, members, extensions)
 {
 }
Beispiel #5
0
 protected TypeDesc([NotNull] QualifiedIdentifier name)
 {
     Name = name ?? throw new ArgumentNullException(nameof(name));
 }
Beispiel #6
0
 public RecordDesc([NotNull] QualifiedIdentifier name, [CanBeNull] QualifiedIdentifier baseRecord, IEnumerable <KeyValuePair <NameAndIndex, TypeMemberDesc> > members) : base(name, members)
 {
     BaseRecord = baseRecord;
 }