src/sys/dotnet/perwapi/PERWAPI.cs
/// <summary>
/// Add a class to this Module
/// If this class already exists, throw an exception
/// </summary>
/// <param name="attrSet">attributes of this class</param>
/// <param name="nsName">name space name</param>
/// <param name="name">class name</param>
/// <returns>a descriptor for this new class</returns>
Add a class to this Module
If this class already exists, throw an exception
Add a class to this Module If this class already exists throw an exception
public ClassDef AddClass(TypeAttr attrSet, string nsName, string name) {
            ClassDef aClass = GetClass(nsName,name);
            if (aClass != null)
                throw new DescriptorException("Class " + aClass.NameString());
            aClass = new ClassDef((PEFile)this,attrSet,nsName,name);
            classes.Add(aClass);
            return aClass;
        }
public ClassDef AddClass ( TypeAttr attrSet , string nsName , string name ) { ClassDef aClass = GetClass ( nsName , name ) ; if ( aClass != null ) throw new DescriptorException ( " " + aClass . NameString ( ) ) ; aClass = new ClassDef ( ( PEFile ) this , attrSet , nsName , name ) ; classes . Add ( aClass ) ; return aClass ; }
Add a class to this Module
If this class already exists, throw an exception
Add a class to this Module If this class already exists throw an exception
a descriptor for this new class
a descriptor for this new class
attrSet
TypeAttr
attributes of this class
attributes of this class
nsName
string
name space name
name space name
name
string
None