|
| 1 | +#pragma warning disable |
| 2 | +#nullable enable |
| 3 | +namespace Chickensoft.Introspection.Generator.Tests.TestCases; |
| 4 | + |
| 5 | +partial class ExplicitInterfaceProperty : Chickensoft.Introspection.IIntrospectiveRef { |
| 6 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 7 | + public Chickensoft.Introspection.MixinBlackboard MixinState { get; } = new(); |
| 8 | + |
| 9 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 10 | + public Chickensoft.Introspection.IMetatype Metatype => ((Chickensoft.Introspection.IIntrospectiveTypeMetadata)Chickensoft.Introspection.Types.Graph.GetMetadata(typeof(ExplicitInterfaceProperty))).Metatype; |
| 11 | + |
| 12 | + public class MetatypeMetadata : Chickensoft.Introspection.IMetatype { |
| 13 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 14 | + public System.Type Type => typeof(ExplicitInterfaceProperty); |
| 15 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 16 | + public bool HasInitProperties { get; } = false; |
| 17 | + |
| 18 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 19 | + public System.Collections.Generic.IReadOnlyList<Chickensoft.Introspection.PropertyMetadata> Properties { get; } = new System.Collections.Generic.List<Chickensoft.Introspection.PropertyMetadata>() { |
| 20 | + new Chickensoft.Introspection.PropertyMetadata( |
| 21 | + Name: "Name", |
| 22 | + IsInit: false, |
| 23 | + IsRequired: false, |
| 24 | + HasDefaultValue: false, |
| 25 | + Getter: static (object obj) => ((IInterfaceOne)obj).Name, |
| 26 | + Setter: null, |
| 27 | + TypeNode: new Chickensoft.Introspection.TypeNode( |
| 28 | + OpenType: typeof(string), |
| 29 | + ClosedType: typeof(string), |
| 30 | + IsNullable: false, |
| 31 | + Arguments: System.Array.Empty<TypeNode>(), |
| 32 | + GenericTypeGetter: static receiver => receiver.Receive<string>(), |
| 33 | + GenericTypeGetter2: default |
| 34 | + ), |
| 35 | + Attributes: new System.Collections.Generic.Dictionary<System.Type, System.Attribute[]>() { |
| 36 | + } |
| 37 | + ), |
| 38 | + new Chickensoft.Introspection.PropertyMetadata( |
| 39 | + Name: "Name", |
| 40 | + IsInit: false, |
| 41 | + IsRequired: false, |
| 42 | + HasDefaultValue: false, |
| 43 | + Getter: static (object obj) => ((IInterfaceTwo)obj).Name, |
| 44 | + Setter: null, |
| 45 | + TypeNode: new Chickensoft.Introspection.TypeNode( |
| 46 | + OpenType: typeof(string), |
| 47 | + ClosedType: typeof(string), |
| 48 | + IsNullable: false, |
| 49 | + Arguments: System.Array.Empty<TypeNode>(), |
| 50 | + GenericTypeGetter: static receiver => receiver.Receive<string>(), |
| 51 | + GenericTypeGetter2: default |
| 52 | + ), |
| 53 | + Attributes: new System.Collections.Generic.Dictionary<System.Type, System.Attribute[]>() { |
| 54 | + } |
| 55 | + ) |
| 56 | + }; |
| 57 | + |
| 58 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 59 | + public System.Collections.Generic.IReadOnlyDictionary<System.Type, System.Attribute[]> Attributes { get; } = new System.Collections.Generic.Dictionary<System.Type, System.Attribute[]>() { |
| 60 | + [typeof(MetaAttribute)] = new System.Attribute[] { |
| 61 | + new MetaAttribute() |
| 62 | + } |
| 63 | + }; |
| 64 | + |
| 65 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 66 | + public System.Collections.Generic.IReadOnlyList<System.Type> Mixins { get; } = new System.Collections.Generic.List<System.Type>() { |
| 67 | + }; |
| 68 | + |
| 69 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 70 | + public System.Collections.Generic.IReadOnlyDictionary<System.Type, System.Action<object>> MixinHandlers { get; } = new System.Collections.Generic.Dictionary<System.Type, System.Action<object>>() { |
| 71 | + }; |
| 72 | + |
| 73 | + |
| 74 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 75 | + public object Construct(System.Collections.Generic.IReadOnlyDictionary<string, object?>? args = null) { |
| 76 | + return new ExplicitInterfaceProperty(); |
| 77 | + } |
| 78 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 79 | + public override bool Equals(object obj) => true; |
| 80 | + [System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverage] |
| 81 | + public override int GetHashCode() => base.GetHashCode(); |
| 82 | + } |
| 83 | +} |
| 84 | +#nullable restore |
| 85 | +#pragma warning restore |
0 commit comments