XObject value = (XObject)ctx.getVariableOrParam(new QName(parm.getName()));
/** * This is an internal version of Set Error that is called withen * XConnection where there is no SQLDocument created yet. As in the * Connect statement or creation of the ConnectionPool. */ public void setError(Exception excp,ExpressionContext expr) { try { ErrorListener listen = expr.getErrorListener(); if ( listen != null && excp != null ) { listen.warning( new TransformerException(excp.toString(), expr.getXPathContext().getSAXLocator(), excp)); } } catch(Exception e) {} }
/** * <code>systemId</code> returns the system id of the current * context node. * * @param context an <code>ExpressionContext</code> value * @return a <code>String</code> value */ public static String systemId(ExpressionContext context) { Node contextNode = context.getContextNode(); int nodeHandler = ((DTMNodeProxy)contextNode).getDTMNodeNumber(); SourceLocator locator = ((DTMNodeProxy)contextNode).getDTM() .getSourceLocatorFor(nodeHandler); if (locator != null) return locator.getSystemId(); else return null; }
(TransformerImpl)exprContext.getXPathContext().getOwnerObject() : null; if (funcName.equals("new")) { // Handle constructor call
(TransformerImpl)exprContext.getXPathContext().getOwnerObject() : null; if (funcName.endsWith(".new")) { // Handle constructor call
ErrorListener listen = cont.getErrorListener(); if ( listen != null && excp != null ) listen.warning( new TransformerException(excp.toString(), cont.getXPathContext().getSAXLocator(), excp)); warn.toString(), cont.getXPathContext().getSAXLocator(), warn));
XPathContext context = exprContext.getXPathContext(); TransformerImpl transformer = (TransformerImpl)context.getOwnerObject(); transformer.pushCurrentFuncResult(null);
/** * <code>publicId</code> returns the public identifier of the current * context node. * * Xalan does not currently record this value, and will return null. * * @param context an <code>ExpressionContext</code> value * @return a <code>String</code> value */ public static String publicId(ExpressionContext context) { Node contextNode = context.getContextNode(); int nodeHandler = ((DTMNodeProxy)contextNode).getDTMNodeNumber(); SourceLocator locator = ((DTMNodeProxy)contextNode).getDTM() .getSourceLocatorFor(nodeHandler); if (locator != null) return locator.getPublicId(); else return null; }
public static String getString(ExpressionContext context, String varName) { try { XObject var = context.getVariableOrParam(new QName(varName)); if (var != null) { return var.toString(); } else { System.out.println("$" + varName + " is not a defined parameter."); return ""; } } catch (TransformerException te) { // Nevermind the warning // System.out.println("Transformer exception getting value of $" + varName); return ""; } }
/** * This is an internal version of Set Error that is called withen * XConnection where there is no SQLDocument created yet. As in the * Connect statement or creation of the ConnectionPool. */ public void setError(Exception excp,ExpressionContext expr) { try { ErrorListener listen = expr.getErrorListener(); if ( listen != null && excp != null ) { listen.warning( new TransformerException(excp.toString(), expr.getXPathContext().getSAXLocator(), excp)); } } catch(Exception e) {} }
private XNodeSet asNodeSet(ExpressionContext context, Node node) throws TransformerException, JDOMException { NodeSet nodeSet = new NodeSet(); nodeSet.addNode(node); XPathContext xpc = context.getXPathContext(); return new XNodeSetForDOM((NodeList) nodeSet, xpc); } }
/** * <code>lineNumber</code> returns the line number of the current * context node. * * NOTE: Xalan does not normally record location information for each node. * To obtain it, you must set the custom TrAX attribute * "http://xml.apache.org/xalan/features/source_location" * true in the TransformerFactory before generating the Transformer and executing * the stylesheet. Storage cost per node will be noticably increased in this mode. * * @param context an <code>ExpressionContext</code> value * @return an <code>int</code> value. This may be -1 to indicate that the * line number is not known. */ public static int lineNumber(ExpressionContext context) { Node contextNode = context.getContextNode(); int nodeHandler = ((DTMNodeProxy)contextNode).getDTMNodeNumber(); SourceLocator locator = ((DTMNodeProxy)contextNode).getDTM() .getSourceLocatorFor(nodeHandler); if (locator != null) return locator.getLineNumber(); else return -1; }
XObject value = (XObject)ctx.getVariableOrParam(new QName(parm.getName()));
/** * This is an internal version of Set Error that is called withen * XConnection where there is no SQLDocument created yet. As in the * Connect statement or creation of the ConnectionPool. */ public void setError(Exception excp,ExpressionContext expr) { try { ErrorListener listen = expr.getErrorListener(); if ( listen != null && excp != null ) { listen.warning( new TransformerException(excp.toString(), expr.getXPathContext().getSAXLocator(), excp)); } } catch(Exception e) {} }
(TransformerImpl)exprContext.getXPathContext().getOwnerObject() : null; if (funcName.endsWith(".new")) { // Handle constructor call
/** * <code>columnNumber</code> returns the column number of the * current context node. * * NOTE: Xalan does not normally record location information for each node. * To obtain it, you must set the custom TrAX attribute * "http://xml.apache.org/xalan/features/source_location" * true in the TransformerFactory before generating the Transformer and executing * the stylesheet. Storage cost per node will be noticably increased in this mode. * * @param context an <code>ExpressionContext</code> value * @return an <code>int</code> value. This may be -1 to indicate that the * column number is not known. */ public static int columnNumber(ExpressionContext context) { Node contextNode = context.getContextNode(); int nodeHandler = ((DTMNodeProxy)contextNode).getDTMNodeNumber(); SourceLocator locator = ((DTMNodeProxy)contextNode).getDTM() .getSourceLocatorFor(nodeHandler); if (locator != null) return locator.getColumnNumber(); else return -1; }
XObject value = (XObject)ctx.getVariableOrParam(new QName(parm.getName()));
/** * This is an internal version of Set Error that is called withen * XConnection where there is no SQLDocument created yet. As in the * Connect statement or creation of the ConnectionPool. */ public void setError(Exception excp,ExpressionContext expr) { try { ErrorListener listen = expr.getErrorListener(); if ( listen != null && excp != null ) { listen.warning( new TransformerException(excp.toString(), expr.getXPathContext().getSAXLocator(), excp)); } } catch(Exception e) {} }
(TransformerImpl)exprContext.getXPathContext().getOwnerObject() : null; if (funcName.equals("new")) { // Handle constructor call
XPath.SELECT); return dynamicXPath.execute(xctxt, myContext.getContextNode(), xctxt.getNamespaceContext());