JavaPatternMatching/src/de/dhbwstuttgart/syntaxtree/statement/Null.java

107 lines
2.9 KiB
Java
Raw Normal View History

2013-10-18 11:33:46 +00:00
// ino.module.Null.8644.package
2014-09-02 08:33:54 +00:00
package de.dhbwstuttgart.syntaxtree.statement;
2013-10-18 11:33:46 +00:00
// ino.end
// ino.module.Null.8644.import
import java.util.Hashtable;
import java.util.Vector;
2013-10-18 11:33:46 +00:00
2014-10-09 10:01:16 +00:00
import de.dhbwstuttgart.logger.Logger;
2014-09-04 14:35:44 +00:00
import de.dhbwstuttgart.bytecode.ClassFile;
import de.dhbwstuttgart.bytecode.CodeAttribute;
import de.dhbwstuttgart.bytecode.JVMCode;
import de.dhbwstuttgart.myexception.CTypeReconstructionException;
import de.dhbwstuttgart.myexception.JVMCodeException;
2014-09-02 08:33:54 +00:00
import de.dhbwstuttgart.syntaxtree.Class;
2014-09-04 14:35:44 +00:00
import de.dhbwstuttgart.syntaxtree.SyntaxTreeNode;
2014-09-02 08:33:54 +00:00
import de.dhbwstuttgart.syntaxtree.type.GenericTypeVar;
import de.dhbwstuttgart.syntaxtree.type.Type;
import de.dhbwstuttgart.syntaxtree.type.TypePlaceholder;
import de.dhbwstuttgart.typeinference.ConstraintsSet;
import de.dhbwstuttgart.typeinference.JavaCodeResult;
import de.dhbwstuttgart.typeinference.ResultSet;
import de.dhbwstuttgart.typeinference.assumptions.TypeAssumptions;
import de.dhbwstuttgart.typeinference.unify.CSubstitutionSet;
2013-10-18 11:33:46 +00:00
// ino.class.Null.25919.declaration
public class Null extends Literal
// ino.end
// ino.class.Null.25919.body
{
// ino.attribute.parserlog.25923.declaration
protected static Logger parserlog = Logger.getLogger("parser");
// ino.end
// ino.method.Null.25926.definition
public Null()
// ino.end
// ino.method.Null.25926.body
{
super(-1,-1);
//this.setType(new Type("__NULL__",this,getOffset()));
2013-10-18 11:33:46 +00:00
}
// ino.end
// ino.method.get_Name.25929.definition
public String get_Name()
// ino.end
// ino.method.get_Name.25929.body
{
return null;
}
// ino.end
2014-11-04 12:47:05 +00:00
/*
2013-10-18 11:33:46 +00:00
// ino.method.sc_check.25932.definition
public void sc_check(Vector<Class> classname, Hashtable ch, Hashtable<String, String> bh, boolean ext, Hashtable parach, Hashtable<String, Hashtable> parabh)
// ino.end
// ino.method.sc_check.25932.body
{
if(ext)
parserlog.debug(" ---Null---");
}
// ino.end
2014-11-04 12:47:05 +00:00
*/
2013-10-18 11:33:46 +00:00
// ino.method.codegen.25935.definition
public void codegen(ClassFile classfile, CodeAttribute code, Vector paralist)
throws JVMCodeException
// ino.end
// ino.method.codegen.25935.body
{
code.add_code(JVMCode.aconst_null);
}
// ino.end
// ino.end
// ino.method.wandleRefTypeAttributes2GenericAttributes.25944.definition
public void wandleRefTypeAttributes2GenericAttributes(Vector<Type> paralist, Vector<GenericTypeVar> genericMethodParameters)
// ino.end
// ino.method.wandleRefTypeAttributes2GenericAttributes.25944.body
{
}
// ino.end
@Override
public ConstraintsSet TYPEExpr(TypeAssumptions assumptions) {
// TODO Auto-generated method stub
return null;
}
@Override
public JavaCodeResult printJavaCode(ResultSet resultSet) {
return new JavaCodeResult("null");
}
2014-03-17 16:55:55 +00:00
@Override
public Vector<SyntaxTreeNode> getChildren() {
return new Vector<SyntaxTreeNode>();
}
2013-10-18 11:33:46 +00:00
}
// ino.end