FileDocCategorySizeDatePackage
StringLengthCall.javaAPI DocJava SE 5 API1910Fri Aug 26 14:55:36 BST 2005com.sun.org.apache.xalan.internal.xsltc.compiler

StringLengthCall

public final class StringLengthCall extends FunctionCall
author
Jacek Ambroziak
author
Santiago Pericas-Geertsen

Fields Summary
Constructors Summary
public StringLengthCall(QName fname, Vector arguments)

	super(fname, arguments);
    
Methods Summary
public voidtranslate(com.sun.org.apache.xalan.internal.xsltc.compiler.util.ClassGenerator classGen, com.sun.org.apache.xalan.internal.xsltc.compiler.util.MethodGenerator methodGen)

	final ConstantPoolGen cpg = classGen.getConstantPool();
	final InstructionList il = methodGen.getInstructionList();
	if (argumentCount() > 0) {
	    argument().translate(classGen, methodGen);
	}
	else {
	    il.append(methodGen.loadContextNode());
	    Type.Node.translateTo(classGen, methodGen, Type.String);
	}
	il.append(new INVOKEVIRTUAL(cpg.addMethodref(STRING_CLASS,
						     "length", "()I")));