Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import java.util.Enumeration;
import java.util.Properties;

import javax.xml.transform.Transformer;

public class Main {
    /**
     * All the standard parameters must be set in the properties file
     * 
     * @param renderer
     * @param params
     * @return
     */
    public static Transformer setStdTransParamsProps(Transformer renderer, Properties params) {

        // log.severe("setStdTransParamsProps params = "+params);

        if (params != null) {
            for (Enumeration e = params.keys(); e.hasMoreElements();) {

                String localkey = (String) e.nextElement();
                String val = params.getProperty(localkey);
                renderer.setParameter(localkey, val);
            }
        }
        return renderer;
    }
}