Implement base constructor in ClassOrInterface.

This commit is contained in:
Jakob Herrmann 2017-01-16 14:28:22 +01:00
parent e4e98797fc
commit 4c79023889

View File

@ -24,19 +24,36 @@ public class ClassOrInterface extends GTVDeclarationContext implements IItemWith
protected boolean isInterface;
private List<RefType> implementedInterfaces;
public ClassOrInterface(Modifiers modifiers, JavaClassName name, Block class_block, List<Field> fielddecl, GenericDeclarationList genericClassParameters, int offset, RefType superClass, Boolean isInterface, List<RefType> implementedInterfaces){
if(modifiers != null){
this.modifiers = modifiers;
}
if(name != null){
this.name = name;
}
if(class_block != null){
this.class_block = class_block;
}
if(fielddecl != null){
this.fielddecl = fielddecl;
}
if(genericClassParameters != null){
this.genericClassParameters = genericClassParameters;
}
this.offset = offset;
if(superClass != null){
this.superClass = superClass;
}
this.isInterface = isInterface;
if(implementedInterfaces != null){
this.implementedInterfaces = implementedInterfaces;
}
}
// Gets class name
public JavaClassName getClassName(){
return this.name;
}
// Sets class name.
public void setClassName(JavaClassName name){
this.name = name;
}
// Sets interface "switch".
public void setInterface(Boolean isInterface){
this.isInterface = isInterface;
}
}