FileDocCategorySizeDatePackage
NamespaceUriCall.javaAPI DocJava SE 6 API2137Tue Jun 10 00:22:28 BST 2008com.sun.org.apache.xalan.internal.xsltc.compiler

NamespaceUriCall

public final class NamespaceUriCall extends NameBase
author
Morten Jorgensen

(Omit source code)

Fields Summary
Constructors Summary
public NamespaceUriCall(QName fname)
Handles calls with no parameter (current node is implicit parameter).

	super(fname);
    
public NamespaceUriCall(QName fname, Vector arguments)
Handles calls with one parameter (either node or node-set).

	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)
Translate code that leaves a node's namespace URI (as a String) on the stack

	final ConstantPoolGen cpg = classGen.getConstantPool();
	final InstructionList il = methodGen.getInstructionList();

	// Returns the string value for a node in the DOM
	final int getNamespace = cpg.addInterfaceMethodref(DOM_INTF,
							   "getNamespaceName",
							   "(I)"+STRING_SIG);
	super.translate(classGen, methodGen);
	il.append(new INVOKEINTERFACE(getNamespace, 2));