Package org.webharvest.runtime.variables

Examples of org.webharvest.runtime.variables.ListVariable.addVariable()


            if (item == null) {
                break;
            }

            XmlNodeWrapper value = new XmlNodeWrapper(item);
            listVariable.addVariable( new NodeVariable(value) );
        }

        return listVariable;
    }
View Full Code Here


                            default:
                                rowData[i] = resultSet.getString(i + 1); break;
                        }
                    }

                    queryResult.addVariable( new DbRowVariable(colDescs, rowData) );
                    rowCount++;
                }
                return queryResult;
            } else {
                return new EmptyVariable();
View Full Code Here

                        ByteArrayOutputStream out = new ByteArrayOutputStream();
                        Result domResult = new StreamResult(out);
                        TransformerFactory factory = TransformerFactory.newInstance();
                        Transformer transformer = factory.newTransformer();
                        transformer.transform(source, domResult);
                        result.addVariable(new NodeVariable(out.toByteArray()));
                    } catch (TransformerException e) {
                        log.error(transformError, e);
                        throw new PluginException(e);
                    } catch (IllegalAccessException e) {
                        throw new PluginException(e);
View Full Code Here

                log.error(EXCEPTION, e);
                throw new PluginException(EXCEPTION, e);
            }

        } else {
            result.addVariable(new NodeVariable(elementDef.getBodyText()));
        }
        return result;
    }

    public String[] getValidAttributes() {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.