AddAssemblyAttr() public method

public AddAssemblyAttr ( AssemAttr aa ) : void
aa AssemAttr
return void
Example #1
0
        public override void Resolve(CodeGen code_gen)
        {
            if (is_resolved)
            {
                return;
            }

            AssemblyRef = code_gen.PEFile.AddExternAssembly(name);
            AssemblyRef.AddAssemblyAttr(attr);
            if (major != -1)
            {
                AssemblyRef.AddVersionInfo(major, minor, build, revision);
            }
            if (public_key != null)
            {
                AssemblyRef.AddKey(public_key);
            }
            if (public_key_token != null)
            {
                AssemblyRef.AddKeyToken(public_key_token);
            }
            if (locale != null)
            {
                AssemblyRef.AddCulture(locale);
            }
            if (hash != null)
            {
                AssemblyRef.AddHash(hash);
            }

            if (customattr_list != null)
            {
                foreach (CustomAttr customattr in customattr_list)
                {
                    customattr.AddTo(code_gen, AssemblyRef);
                }
            }

            if (decl_sec != null)
            {
                decl_sec.AddTo(code_gen, AssemblyRef);
            }

            class_table = new Hashtable();

            is_resolved = true;
        }
Example #2
0
                public override void Resolve (CodeGen code_gen)
                {
                        if (is_resolved)
                                return;

                        AssemblyRef = code_gen.PEFile.AddExternAssembly (name);
                        AssemblyRef.AddAssemblyAttr (attr);
                        if (major != -1)
                                AssemblyRef.AddVersionInfo (major, minor, build, revision);
                        if (public_key != null)
                                AssemblyRef.AddKey (public_key);
                        if (public_key_token != null)
                                AssemblyRef.AddKeyToken (public_key_token);
                        if (locale != null)
                                AssemblyRef.AddCulture (locale);
                        if (hash != null)
                                AssemblyRef.AddHash (hash);

                        if (customattr_list != null)
                                foreach (CustomAttr customattr in customattr_list)
                                        customattr.AddTo (code_gen, AssemblyRef);
                                        
                        if (decl_sec != null)
                                decl_sec.AddTo (code_gen, AssemblyRef);

                        class_table = new Hashtable ();

                        is_resolved = true;
                }