Example #1
0
        /// <summary>
        /// Create all annotations for this class and it's members
        /// </summary>
        public virtual void CreateAnnotations(DexTargetPackage targetPackage)
        {
            // Build class annotations
            if (Class != null)
            {
                // Custom attributes
                AttributeAnnotationInstanceBuilder.CreateAttributeAnnotations(compiler, Type, Class, targetPackage);

                // Properties
                if ((methodBuilders != null) && compiler.AddPropertyAnnotations())
                {
                    AddPropertiesAnnotation(targetPackage);
                }

                AddDefaultAnnotations(targetPackage);
            }

            // Build nested class annotation
            nestedBuilders.ForEach(x => x.CreateAnnotations(targetPackage));

            // Build field annotations
            if (fieldBuilders != null)
            {
                fieldBuilders.ForEach(x => x.CreateAnnotations(targetPackage));
            }

            // Build method annotations
            if (methodBuilders != null)
            {
                methodBuilders.ForEach(x => x.CreateAnnotations(targetPackage));
            }
        }