コード例 #1
0
        private static T PushClass <[_0008._0012(0)] T>(Type first) where T : Attribute
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            Type type = ForgotClass(first);
            T    val;

            if (type != null)
            {
                val = ResolverErrorFilter.PopReader <T>(type, iscounter: true);
                if (val != null)
                {
                    return(val);
                }
            }
            val = ResolverErrorFilter.PopReader <T>(first, iscounter: true);
            if (val != null)
            {
                return(val);
            }
            Type[] interfaces = first.GetInterfaces();
            for (int i = 0; i < interfaces.Length; i++)
            {
                val = ResolverErrorFilter.PopReader <T>(interfaces[i], iscounter: true);
                if (val != null)
                {
                    return(val);
                }
            }
            return(null);
        }
コード例 #2
0
        public static DataMemberAttribute LogoutClass(MemberInfo i)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            if (i.DefineReader() == MemberTypes.Field)
            {
                return(GDBD.Items.WriterTestItem <DataMemberAttribute> .CompareClient(i));
            }
            PropertyInfo        propertyInfo        = (PropertyInfo)i;
            DataMemberAttribute dataMemberAttribute = GDBD.Items.WriterTestItem <DataMemberAttribute> .CompareClient(propertyInfo);

            if (dataMemberAttribute == null && propertyInfo.DefineIssuer())
            {
                Type type = propertyInfo.DeclaringType;
                while (dataMemberAttribute == null && type != null)
                {
                    PropertyInfo propertyInfo2 = (PropertyInfo)ResolverErrorFilter.PrepareReader(type, propertyInfo);
                    if (propertyInfo2 != null && propertyInfo2.DefineIssuer())
                    {
                        dataMemberAttribute = GDBD.Items.WriterTestItem <DataMemberAttribute> .CompareClient(propertyInfo2);
                    }
                    type = type.WriteReader();
                }
            }
            return(dataMemberAttribute);
        }
コード例 #3
0
 public static SettingsSerializeAs FindProperty(Type ident, out bool counter)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     if (_PublisherComposer.TryGetValue(ident, out SettingsSerializeAs value))
     {
         counter = false;
         return(value);
     }
     if (ident.LoginClient())
     {
         counter = true;
         return(PatchProperty(Enum.GetUnderlyingType(ident)));
     }
     if (ResolverErrorFilter.PatchReader(ident))
     {
         Type underlyingType = Nullable.GetUnderlyingType(ident);
         if (underlyingType.LoginClient())
         {
             Type var = typeof(Nullable <>).MakeGenericType(Enum.GetUnderlyingType(underlyingType));
             counter = true;
             return(PatchProperty(var));
         }
     }
     counter = false;
     return((SettingsSerializeAs)1);
 }
コード例 #4
0
 private static bool VerifyProperty(object asset)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     if (!(asset is T) && (asset != null || (typeof(T).FindClient() && !ResolverErrorFilter.PatchReader(typeof(T)))))
     {
         return(false);
     }
     return(true);
 }
コード例 #5
0
        public ParamClientBridge(Type asset)
        {
            //Discarded unreachable code: IL_0002, IL_0006
            //IL_0003: Incompatible stack heights: 0 vs 1
            //IL_0007: Incompatible stack heights: 0 vs 1
            SingletonReader.PushGlobal();
            base._002Ector(asset);
            _ErrorProperty = (ParameterFilterResolver)5;
            Type second;
            Type util;

            if (ResolverErrorFilter.FillReader(asset, typeof(IDictionary <, >), out m_AttrProperty))
            {
                second = m_AttrProperty.GetGenericArguments()[0];
                util   = m_AttrProperty.GetGenericArguments()[1];
                if (ResolverErrorFilter.OrderReader(base._0002(), typeof(IDictionary <, >)))
                {
                    _0002(typeof(Dictionary <, >).MakeGenericType(second, util));
                }
                else if (asset.CallReader() && asset.GetGenericTypeDefinition().FullName == "System.Collections.Concurrent.ConcurrentDictionary`2")
                {
                    printerProperty = true;
                }
            }
            else
            {
                ResolverErrorFilter.MapReader(base._0002(), out second, out util);
                if (base._0002() == typeof(IDictionary))
                {
                    _0002(typeof(Dictionary <object, object>));
                }
            }
            if (second != null && util != null)
            {
                m_MappingProperty = ObserverIteratorMapping.InitTest(base._0003(), typeof(KeyValuePair <, >).MakeGenericType(second, util), typeof(IDictionary <, >).MakeGenericType(second, util));
                if (!this._0003() && asset.Name == "FSharpMap`2")
                {
                    PropertyTest.MoveIssuer(asset.RevertReader());
                    _ObserverProperty = PropertyTest._0001().IncludeIssuer(second, util);
                }
            }
            if (!typeof(IDictionary).IsAssignableFrom(base._0003()))
            {
                printerProperty = true;
            }
            queueProperty   = second;
            m_ProxyProperty = util;
            if (this._0001() != null && _0004() != null && ParamRequestStrategy.InstantiateIssuer(asset, this._0001(), _0004(), out Type _0005, out GDBD.Specifications.AdapterClassSpec <object> _0006))
            {
                _0002(_0005);
                _ObserverProperty = _0006;
                composerProperty  = true;
            }
        }
コード例 #6
0
        public override bool _0001(Type instance)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            Type type = ResolverErrorFilter.PatchReader(instance) ? Nullable.GetUnderlyingType(instance) : instance;

            if (type.FindClient() && type.CallReader())
            {
                return(type.GetGenericTypeDefinition() == typeof(KeyValuePair <, >));
            }
            return(false);
        }
コード例 #7
0
 public void _0001(object v, object vis)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     try
     {
         ResolverErrorFilter.CloneReader(recordIssuer, v, vis);
     }
     catch (Exception second)
     {
         throw new StrategyError("Error setting value to '{0}' on '{1}'.".SelectReader(CultureInfo.InvariantCulture, recordIssuer.Name, v.GetType()), second);
     }
 }
コード例 #8
0
        public override Func <T> _0001 <[_0008._0012(2)] T>(Type key)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            ContextClientBridge.RunClient(key, "type");
            if (key.FindClient())
            {
                return(() => (T)Activator.CreateInstance(key));
            }
            ConstructorInfo constructorInfo = ResolverErrorFilter.DisableReader(key, ismap: true);

            return(() => (T)constructorInfo.Invoke(null));
        }
コード例 #9
0
        private void WriteBroadcaster(RecordClassDispatcher ident, Type map)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            string text = ResolverErrorFilter.PublishIssuer(map, baseProperty._StatusError, baseProperty.writerError);

            if (containerProperty != null && containerProperty._0001() >= TraceLevel.Verbose)
            {
                containerProperty._0001(TraceLevel.Verbose, QueueError.ComputeError(null, ident._0002(), "Writing type name '{0}' for {1}.".SelectReader(CultureInfo.InvariantCulture, text, map)), null);
            }
            ident._0001("$type", injectcust: false);
            ident._0004(text);
        }
コード例 #10
0
 public static bool SetupTest(Type value)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     ContextClientBridge.RunClient(value, "type");
     if (typeof(IDictionary).IsAssignableFrom(value))
     {
         return(true);
     }
     if (ResolverErrorFilter.ResolveReader(value, typeof(IDictionary <, >)))
     {
         return(true);
     }
     return(false);
 }
コード例 #11
0
 internal object InitClient()
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     if (m_ValueProperty == null)
     {
         return(null);
     }
     if (!m_ParamProperty && !utilsProperty)
     {
         publisherProperty = ResolverErrorFilter.ReflectReader(m_ValueProperty);
         utilsProperty     = true;
     }
     return(publisherProperty);
 }
コード例 #12
0
        public override object _0001(TagTestItem config, Type ivk, object template, PrototypeError connection2)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            if (config._0001() == WatcherComposer.Null)
            {
                if (!ResolverErrorFilter.PatchReader(ivk))
                {
                    throw StrategyError.PatchComposer(config, "Cannot convert null value to KeyValuePair.");
                }
                return(null);
            }
            object obj  = null;
            object obj2 = null;

            config.SortError();
            Type res = ResolverErrorFilter.PatchReader(ivk) ? Nullable.GetUnderlyingType(ivk) : ivk;
            ModelInstanceExpression modelInstanceExpression = m_ListenerIssuer.InitReader(res);
            ProcTest procTest  = connection2._0001()._0001(modelInstanceExpression.SetupIssuer("Key"));
            ProcTest procTest2 = connection2._0001()._0001(modelInstanceExpression.SetupIssuer("Value"));

            while (config._0001() == WatcherComposer.PropertyName)
            {
                string a = config._0001().ToString();
                if (string.Equals(a, "Key", StringComparison.OrdinalIgnoreCase))
                {
                    config.CallError(procTest, iscaller: false);
                    obj = connection2.AddComposer(config, procTest._0002());
                }
                else if (string.Equals(a, "Value", StringComparison.OrdinalIgnoreCase))
                {
                    config.CallError(procTest2, iscaller: false);
                    obj2 = connection2.AddComposer(config, procTest2._0002());
                }
                else
                {
                    config.AssetError();
                }
                config.SortError();
            }
            return(modelInstanceExpression._0001()(new object[2]
            {
                obj,
                obj2
            }));
        }
コード例 #13
0
 public object _0001(object v)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     try
     {
         PropertyInfo propertyInfo = recordIssuer as PropertyInfo;
         if ((object)propertyInfo != null && propertyInfo.PropertyType.IsByRef)
         {
             throw new InvalidOperationException("Could not create getter for {0}. ByRef return values are not supported.".ListReader(CultureInfo.InvariantCulture, propertyInfo));
         }
         return(ResolverErrorFilter.StopReader(recordIssuer, v));
     }
     catch (Exception second)
     {
         throw new StrategyError("Error getting value from '{0}' on '{1}'.".SelectReader(CultureInfo.InvariantCulture, recordIssuer.Name, v.GetType()), second);
     }
 }
コード例 #14
0
 public static object MapProperty(object res, CultureInfo selection, Type temp)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     if (temp == typeof(object))
     {
         return(res);
     }
     if (res == null && ResolverErrorFilter.VerifyReader(temp))
     {
         return(null);
     }
     if (AddProperty(res, selection, temp, out object _0005))
     {
         return(_0005);
     }
     return(InsertProperty(res, ResolverErrorFilter.CallIssuer(res), temp));
 }
コード例 #15
0
        public static T ReadClass <[_0008._0012(0)] T>(object key) where T : Attribute
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            Type type = key as Type;

            if ((object)type != null)
            {
                return(PushClass <T>(type));
            }
            MemberInfo memberInfo = key as MemberInfo;

            if ((object)memberInfo != null)
            {
                return(PrepareClass <T>(memberInfo));
            }
            return(ResolverErrorFilter.PopReader <T>(key, iscounter: true));
        }
コード例 #16
0
        private static Func <object[], object> NewClass(Type item)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            Func <object> func = ResolverErrorFilter.LoginReader(item, isconnection: false) ? ConfigProperty._0001()._0001 <object>(item) : null;

            return(delegate(object[] P_0)
            {
                //Discarded unreachable code: IL_0002
                //IL_0003: Incompatible stack heights: 0 vs 1
                try
                {
                    if (P_0 != null)
                    {
                        Type[] types = P_0.Select(delegate(object res)
                        {
                            //Discarded unreachable code: IL_0002
                            //IL_0003: Incompatible stack heights: 0 vs 1
                            if (res == null)
                            {
                                throw new InvalidOperationException("Cannot pass a null parameter to the constructor.");
                            }
                            return res.GetType();
                        }).ToArray();
                        ConstructorInfo constructor = item.GetConstructor(types);
                        if (!(constructor != null))
                        {
                            throw new ListenerTestItem("No matching parameterized constructor found for '{0}'.".ListReader(CultureInfo.InvariantCulture, item));
                        }
                        return ConfigProperty._0001()._0001(constructor)(P_0);
                    }
                    if (func == null)
                    {
                        throw new ListenerTestItem("No parameterless constructor defined for '{0}'.".ListReader(CultureInfo.InvariantCulture, item));
                    }
                    return func();
                }
                catch (Exception cont)
                {
                    throw new ListenerTestItem("Error creating '{0}'.".ListReader(CultureInfo.InvariantCulture, item), cont);
                }
            });
        }
コード例 #17
0
 internal ManagerErrorFilter CalculateClient(object def)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     if (m_ExporterTest == null)
     {
         annotationTest = typeof(GDBD.Dispatcher.SetterComposer <>).MakeGenericType(this._0001());
         Type            type        = (!ResolverErrorFilter.RunReader(_AlgoTest, typeof(List <>)) && !(_AlgoTest.GetGenericTypeDefinition() == typeof(IEnumerable <>))) ? _AlgoTest : typeof(ICollection <>).MakeGenericType(this._0001());
         ConstructorInfo constructor = annotationTest.GetConstructor(new Type[1]
         {
             type
         });
         m_ExporterTest = ConfigProperty._0001()._0001(constructor);
     }
     return((ManagerErrorFilter)m_ExporterTest(new object[1]
     {
         def
     }));
 }
コード例 #18
0
        private static T PrepareClass <[_0008._0012(0)] T>(MemberInfo item) where T : Attribute
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            Type type = ForgotClass(item.DeclaringType);
            T    val;

            if (type != null)
            {
                MemberInfo memberInfo = ResolverErrorFilter.PrepareReader(type, item);
                if (memberInfo != null)
                {
                    val = ResolverErrorFilter.PopReader <T>(memberInfo, iscounter: true);
                    if (val != null)
                    {
                        return(val);
                    }
                }
            }
            val = ResolverErrorFilter.PopReader <T>(item, iscounter: true);
            if (val != null)
            {
                return(val);
            }
            if (item.DeclaringType != null)
            {
                Type[] interfaces = item.DeclaringType.GetInterfaces();
                for (int i = 0; i < interfaces.Length; i++)
                {
                    MemberInfo memberInfo2 = ResolverErrorFilter.PrepareReader(interfaces[i], item);
                    if (memberInfo2 != null)
                    {
                        val = ResolverErrorFilter.PopReader <T>(memberInfo2, iscounter: true);
                        if (val != null)
                        {
                            return(val);
                        }
                    }
                }
            }
            return(null);
        }
コード例 #19
0
        internal ProcTest(Type task)
        {
            //Discarded unreachable code: IL_0002, IL_0006
            //IL_0003: Incompatible stack heights: 0 vs 1
            //IL_0007: Incompatible stack heights: 0 vs 1
            SingletonReader.PushGlobal();
            base._002Ector();
            ContextClientBridge.RunClient(task, "underlyingType");
            _TestsProperty    = task;
            task              = ResolverErrorFilter.ValidateReader(task);
            recordProperty    = ResolverErrorFilter.VerifyReader(task);
            _InstanceProperty = ((recordProperty && ResolverErrorFilter.PatchReader(task)) ? Nullable.GetUnderlyingType(task) : task);
            Type instanceProperty;

            _0002(instanceProperty = _InstanceProperty);
            m_IteratorProperty     = instanceProperty;
            m_EventProperty        = HelperDicCandidate.OrderProperty(_InstanceProperty);
            _FilterProperty        = _InstanceProperty.LoginClient();
            dicProperty            = (Docking)0;
        }
コード例 #20
0
        public override object _0001(TagTestItem instance, Type pred, object res, PrototypeError reference2)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            if (instance._0001() == WatcherComposer.Null)
            {
                if (!ResolverErrorFilter.VerifyReader(pred))
                {
                    throw StrategyError.PatchComposer(instance, "Cannot convert null value to {0}.".ListReader(CultureInfo.InvariantCulture, pred));
                }
                return(null);
            }
            byte[] array;
            if (instance._0001() == WatcherComposer.StartArray)
            {
                array = RegisterRequest(instance);
            }
            else
            {
                if (instance._0001() != WatcherComposer.String)
                {
                    throw StrategyError.PatchComposer(instance, "Unexpected token parsing binary. Expected String or StartArray, got {0}.".ListReader(CultureInfo.InvariantCulture, instance._0001()));
                }
                array = Convert.FromBase64String(instance._0001().ToString());
            }
            Type type = ResolverErrorFilter.PatchReader(pred) ? Nullable.GetUnderlyingType(pred) : pred;

            if (type.FullName == "System.Data.Linq.Binary")
            {
                ResetRequest(type);
                return(_InfoIssuer._0001()(new object[1]
                {
                    array
                }));
            }
            if (type == typeof(SqlBinary))
            {
                return(new SqlBinary(array));
            }
            throw StrategyError.PatchComposer(instance, "Unexpected object type when writing binary: {0}".ListReader(CultureInfo.InvariantCulture, pred));
        }
コード例 #21
0
        internal static TT SearchClass <[_0008._0012(0)] T, [_0008._0012(2)] TT>(this T init) where T : ParserFilterResolver
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            if (init == null)
            {
                return(default(TT));
            }
            if (init is TT)
            {
                TT result = init as TT;
                if (typeof(TT) != typeof(IComparable) && typeof(TT) != typeof(IFormattable))
                {
                    return(result);
                }
            }
            PoolIssuer poolIssuer = init as PoolIssuer;

            if (poolIssuer == null)
            {
                throw new InvalidCastException("Cannot cast {0} to {1}.".SelectReader(CultureInfo.InvariantCulture, init.GetType(), typeof(T)));
            }
            object obj = poolIssuer._0001();

            if (obj is TT)
            {
                return((TT)obj);
            }
            Type type = typeof(TT);

            if (ResolverErrorFilter.PatchReader(type))
            {
                if (poolIssuer._0001() == null)
                {
                    return(default(TT));
                }
                type = Nullable.GetUnderlyingType(type);
            }
            return((TT)Convert.ChangeType(poolIssuer._0001(), type, CultureInfo.InvariantCulture));
        }
コード例 #22
0
 private static Type IncludeClass(Type info)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     Attribute[] array = ResolverErrorFilter.ForgotReader(info, null, controlopen: true);
     foreach (Attribute attribute in array)
     {
         Type type = attribute.GetType();
         if (string.Equals(type.FullName, "System.ComponentModel.DataAnnotations.MetadataTypeAttribute", StringComparison.Ordinal))
         {
             if (_RefProperty == null)
             {
                 _RefProperty = ModelInstanceExpression.ManageIssuer(type, new string[1]
                 {
                     "MetadataClassType"
                 });
             }
             return((Type)_RefProperty.CancelIssuer(attribute, "MetadataClassType"));
         }
     }
     return(null);
 }
コード例 #23
0
 private static object InsertProperty(object param, Type result, Type tag)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     if (param != null)
     {
         Type type = param.GetType();
         if (tag.IsAssignableFrom(type))
         {
             return(param);
         }
         Func <object, object> func = m_StrategyComposer.InitReader(new GDBD.Workers.TemplateComposerWorker <Type, Type>(type, tag));
         if (func != null)
         {
             return(func(param));
         }
     }
     else if (ResolverErrorFilter.VerifyReader(tag))
     {
         return(null);
     }
     throw new ArgumentException("Could not cast or convert from {0} to {1}.".SelectReader(CultureInfo.InvariantCulture, result?.ToString() ?? "{null}", tag));
 }
コード例 #24
0
        private Type PostClient(string res, Assembly pol)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            Type result = null;
            int  num    = res.IndexOf('[');

            if (num >= 0)
            {
                string name = res.Substring(0, num);
                Type   type = pol.GetType(name);
                if (type != null)
                {
                    List <Type> list = new List <Type>();
                    int         num2 = 0;
                    int         num3 = 0;
                    int         num4 = res.Length - 1;
                    for (int i = num + 1; i < num4; i++)
                    {
                        switch (res[i])
                        {
                        case '[':
                            if (num2 == 0)
                            {
                                num3 = i + 1;
                            }
                            num2++;
                            break;

                        case ']':
                            num2--;
                            if (num2 == 0)
                            {
                                GDBD.Workers.TemplateComposerWorker <string, string> first = ResolverErrorFilter.IncludeReader(res.Substring(num3, i - num3));
                                list.Add(ChangeClient(first));
                            }
                            break;
                        }
                    }
                    result = type.MakeGenericType(list.ToArray());
                }
            }
            return(result);
        }
コード例 #25
0
 private bool CancelProperty(string spec)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     return(ResolverErrorFilter.InstantiateReader(modelComposer.GetType(), typeof(GDBD.Bridges.SetterClientBridge <T>), spec));
 }
コード例 #26
0
        public MessageTest(Type instance)
        {
            //Discarded unreachable code: IL_0002, IL_0006
            //IL_0003: Incompatible stack heights: 0 vs 1
            //IL_0007: Incompatible stack heights: 0 vs 1
            SingletonReader.PushGlobal();
            base._002Ector(instance);
            _ErrorProperty = (ParameterFilterResolver)2;
            m_GlobalTest   = (base._0003().IsArray || (_InstanceProperty.CallReader() && _InstanceProperty.GetGenericTypeDefinition().FullName == "System.Linq.EmptyPartition`1"));
            bool forcedef;
            Type _0004;

            if (this._0002())
            {
                _ProductTest      = ResolverErrorFilter.EnableReader(base._0002());
                composerProperty  = true;
                _AlgoTest         = typeof(List <>).MakeGenericType(this._0001());
                forcedef          = true;
                m_InterceptorTest = (base._0003().IsArray&& base._0002().GetArrayRank() > 1);
            }
            else if (typeof(IList).IsAssignableFrom(_InstanceProperty))
            {
                if (ResolverErrorFilter.FillReader(_InstanceProperty, typeof(ICollection <>), out _AlgoTest))
                {
                    _ProductTest = _AlgoTest.GetGenericArguments()[0];
                }
                else
                {
                    _ProductTest = ResolverErrorFilter.EnableReader(_InstanceProperty);
                }
                if (_InstanceProperty == typeof(IList))
                {
                    _0002(typeof(List <object>));
                }
                if (this._0001() != null)
                {
                    _TemplateTest = ObserverIteratorMapping.ManageTest(_InstanceProperty, this._0001());
                }
                composerProperty = ResolverErrorFilter.RunReader(_InstanceProperty, typeof(ReadOnlyCollection <>));
                forcedef         = true;
            }
            else if (ResolverErrorFilter.FillReader(_InstanceProperty, typeof(ICollection <>), out _AlgoTest))
            {
                _ProductTest = _AlgoTest.GetGenericArguments()[0];
                if (ResolverErrorFilter.OrderReader(_InstanceProperty, typeof(ICollection <>)) || ResolverErrorFilter.OrderReader(_InstanceProperty, typeof(IList <>)))
                {
                    _0002(typeof(List <>).MakeGenericType(this._0001()));
                }
                if (ResolverErrorFilter.OrderReader(_InstanceProperty, typeof(ISet <>)))
                {
                    _0002(typeof(HashSet <>).MakeGenericType(this._0001()));
                }
                _TemplateTest = ObserverIteratorMapping.ManageTest(_InstanceProperty, this._0001());
                forcedef      = true;
                _WrapperTest  = true;
            }
            else if (ResolverErrorFilter.FillReader(_InstanceProperty, typeof(IEnumerable <>), out _0004))
            {
                _ProductTest = _0004.GetGenericArguments()[0];
                if (ResolverErrorFilter.OrderReader(base._0002(), typeof(IEnumerable <>)))
                {
                    _0002(typeof(List <>).MakeGenericType(this._0001()));
                }
                _TemplateTest = ObserverIteratorMapping.ManageTest(_InstanceProperty, this._0001());
                StartClient(_InstanceProperty);
                if (_InstanceProperty.CallReader() && _InstanceProperty.GetGenericTypeDefinition() == typeof(IEnumerable <>))
                {
                    _AlgoTest        = _0004;
                    composerProperty = false;
                    _WrapperTest     = false;
                    forcedef         = true;
                }
                else
                {
                    _AlgoTest        = typeof(List <>).MakeGenericType(this._0001());
                    composerProperty = true;
                    _WrapperTest     = true;
                    forcedef         = _0006();
                }
            }
            else
            {
                forcedef     = false;
                _WrapperTest = true;
            }
            _0001(forcedef);
            if (this._0001() != null && ParamRequestStrategy.CalcIssuer(_InstanceProperty, this._0001(), out Type _00042, out GDBD.Specifications.AdapterClassSpec <object> _0005))
            {
                _0002(_00042);
                m_ExpressionTest = _0005;
                composerProperty = true;
                _0001(forcedef: true);
            }
        }
コード例 #27
0
        private static ListViewColumns EnableProperty([_0008._0012(2)] object _0002, CultureInfo ivk, Type proc, [_0008._0012(2)] out object _0005)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            if (_0002 == null)
            {
                throw new ArgumentNullException("initialValue");
            }
            if (ResolverErrorFilter.PatchReader(proc))
            {
                proc = Nullable.GetUnderlyingType(proc);
            }
            Type type = _0002.GetType();

            if (proc == type)
            {
                _0005 = _0002;
                return((ListViewColumns)0);
            }
            if (OrderProperty(_0002.GetType()) && OrderProperty(proc))
            {
                if (proc.LoginClient())
                {
                    if (_0002 is string)
                    {
                        _0005 = Enum.Parse(proc, _0002.ToString(), ignoreCase: true);
                        return((ListViewColumns)0);
                    }
                    if (CreateProperty(_0002))
                    {
                        _0005 = Enum.ToObject(proc, _0002);
                        return((ListViewColumns)0);
                    }
                }
                _0005 = Convert.ChangeType(_0002, proc, ivk);
                return((ListViewColumns)0);
            }
            if (_0002 is DateTime)
            {
                DateTime dateTime = (DateTime)_0002;
                if (proc == typeof(DateTimeOffset))
                {
                    _0005 = new DateTimeOffset(dateTime);
                    return((ListViewColumns)0);
                }
            }
            byte[] array = _0002 as byte[];
            if (array != null && proc == typeof(Guid))
            {
                _0005 = new Guid(array);
                return((ListViewColumns)0);
            }
            if (_0002 is Guid)
            {
                Guid guid = (Guid)_0002;
                if (proc == typeof(byte[]))
                {
                    _0005 = guid.ToByteArray();
                    return((ListViewColumns)0);
                }
            }
            string text = _0002 as string;

            if (text != null)
            {
                if (proc == typeof(Guid))
                {
                    _0005 = new Guid(text);
                    return((ListViewColumns)0);
                }
                if (proc == typeof(Uri))
                {
                    _0005 = new Uri(text, UriKind.RelativeOrAbsolute);
                    return((ListViewColumns)0);
                }
                if (proc == typeof(TimeSpan))
                {
                    _0005 = ResolveProperty(text);
                    return((ListViewColumns)0);
                }
                if (proc == typeof(byte[]))
                {
                    _0005 = Convert.FromBase64String(text);
                    return((ListViewColumns)0);
                }
                if (proc == typeof(Version))
                {
                    if (FlushProperty(text, out Version _0003))
                    {
                        _0005 = _0003;
                        return((ListViewColumns)0);
                    }
                    _0005 = null;
                    return((ListViewColumns)3);
                }
                if (typeof(Type).IsAssignableFrom(proc))
                {
                    _0005 = Type.GetType(text, throwOnError: true);
                    return((ListViewColumns)0);
                }
            }
            if (proc == typeof(BigInteger))
            {
                _0005 = RunProperty(_0002);
                return((ListViewColumns)0);
            }
            if (_0002 is BigInteger)
            {
                BigInteger first = (BigInteger)_0002;
                _0005 = CompareProperty(first, proc);
                return((ListViewColumns)0);
            }
            TypeConverter converter = TypeDescriptor.GetConverter(type);

            if (converter != null && converter.CanConvertTo(proc))
            {
                _0005 = converter.ConvertTo(null, ivk, _0002, proc);
                return((ListViewColumns)0);
            }
            TypeConverter converter2 = TypeDescriptor.GetConverter(proc);

            if (converter2 != null && converter2.CanConvertFrom(type))
            {
                _0005 = converter2.ConvertFrom(null, ivk, _0002);
                return((ListViewColumns)0);
            }
            if (_0002 == DBNull.Value)
            {
                if (ResolverErrorFilter.VerifyReader(proc))
                {
                    _0005 = InsertProperty(null, type, proc);
                    return((ListViewColumns)0);
                }
                _0005 = null;
                return((ListViewColumns)1);
            }
            if (proc.SortReader() || proc.PublishReader() || proc.VerifyClient())
            {
                _0005 = null;
                return((ListViewColumns)2);
            }
            _0005 = null;
            return((ListViewColumns)3);
        }
コード例 #28
0
        public static ModelInstanceExpression InitIssuer(Type var1, MethodBase cfg, string[] field)
        {
            //Discarded unreachable code: IL_0002
            //IL_0003: Incompatible stack heights: 0 vs 1
            VisitorComposer visitorComposer = ConfigProperty._0001();

            GDBD.Specifications.AdapterClassSpec <object> last = null;
            if (cfg != null)
            {
                last = visitorComposer._0001(cfg);
            }
            else if (ResolverErrorFilter.LoginReader(var1, isconnection: false))
            {
                Func <object> func = visitorComposer._0001 <object>(var1);
                last = ((object[] P_0) => func());
            }
            ModelInstanceExpression modelInstanceExpression = new ModelInstanceExpression(last);

            Newtonsoft.Rules.ClientInstanceRule <object, object> clientInstanceRule;
            Newtonsoft.Rules.ClientInstanceRule <object, object> clientInstanceRule2;
            foreach (string text in field)
            {
                MemberInfo[] member = var1.GetMember(text, BindingFlags.Instance | BindingFlags.Public);
                if (member.Length != 1)
                {
                    throw new ArgumentException("Expected a single member with the name '{0}'.".ListReader(CultureInfo.InvariantCulture, text));
                }
                MemberInfo memberInfo = member.Single();
                StubTest   stubTest   = new StubTest();
                switch (memberInfo.DefineReader())
                {
                case MemberTypes.Field:
                case MemberTypes.Property:
                    if (ResolverErrorFilter.LogoutReader(memberInfo, updateb: false))
                    {
                        stubTest._0001(visitorComposer.ValidateIssuer <object>(memberInfo));
                    }
                    if (ResolverErrorFilter.VisitReader(memberInfo, calcconnection: false, addrule: false))
                    {
                        stubTest._0001(visitorComposer.OrderIssuer <object>(memberInfo));
                    }
                    break;

                case MemberTypes.Method:
                {
                    MethodInfo methodInfo = (MethodInfo)memberInfo;
                    if (methodInfo.IsPublic)
                    {
                        ParameterInfo[] parameters = methodInfo.GetParameters();
                        if (parameters.Length == 0 && methodInfo.ReturnType != typeof(void))
                        {
                            clientInstanceRule = visitorComposer._0001 <object>(methodInfo);
                            stubTest._0001((object P_0) => clientInstanceRule(P_0, new object[0]));
                        }
                        else if (parameters.Length == 1 && methodInfo.ReturnType == typeof(void))
                        {
                            clientInstanceRule2 = visitorComposer._0001 <object>(methodInfo);
                            stubTest._0001(delegate(object P_0, object P_1)
                                {
                                    //Discarded unreachable code: IL_0002
                                    //IL_0003: Incompatible stack heights: 0 vs 1
                                    clientInstanceRule2(P_0, new object[1]
                                    {
                                        P_1
                                    });
                                });
                        }
                    }
                    break;
                }

                default:
                    throw new ArgumentException("Unexpected member type '{0}' for member '{1}'.".SelectReader(CultureInfo.InvariantCulture, memberInfo.DefineReader(), memberInfo.Name));
                }
                stubTest._0001(ResolverErrorFilter.InsertReader(memberInfo));
                modelInstanceExpression._0001()[text] = stubTest;
            }
            return(modelInstanceExpression);
        }
コード例 #29
0
 public static bool AwakeClass(object ident)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     return(ResolverErrorFilter.PopReader <NonSerializedAttribute>(ident, iscounter: false) != null);
 }
コード例 #30
0
 public static bool UpdateClass(object value)
 {
     //Discarded unreachable code: IL_0002
     //IL_0003: Incompatible stack heights: 0 vs 1
     return(ResolverErrorFilter.PopReader <SerializableAttribute>(value, iscounter: false) != null);
 }