Exemplo n.º 1
0
        protected virtual void Process(HierarchyMethod parent, ApiTypeParameter typeParameter)
        {
            var hierarchyTypeParameter = CreateHierarchyElementInternal <HierarchyTypeParameter> (parent);

            hierarchyTypeParameter.Init(typeParameter);
            AddTypeParameterGenericConstraints(hierarchyTypeParameter, typeParameter);
            parent.AddMember(hierarchyTypeParameter);
        }
Exemplo n.º 2
0
        public override void Init(ApiElement apiElement)
        {
            base.Init(apiElement);

            apiTypeParameter = EnsureApiElementType <ApiTypeParameter> (apiElement);

            // Unused for now
            //
            // ClassBound = apiTypeParameter.ClassBound;
            // JniClassBound = apiTypeParameter.JniClassBound;
            // InterfaceBounds = apiTypeParameter.InterfaceBounds;
            // JniInterfaceBounds = apiTypeParameter.JniInterfaceBounds;
        }
Exemplo n.º 3
0
        protected void AddTypeParameterGenericConstraints(HierarchyTypeParameter parameter, ApiTypeParameter typeParameter)
        {
            Helpers.ForEachNotNull(typeParameter.ChildElements, (ApiElement e) => {
                switch (e)
                {
                case ApiTypeParameterGenericConstraint constraint:
                    Process(parameter, constraint);
                    break;

                default:
                    Logger.Warning($"Unexpected member type for ApiTypeParameter: '{e.GetType ().FullName}'");
                    break;
                }
            });
        }