XSLT now part of JDK 1.5 itself.
(Thanks god, we don’t have to download xalan, xerces etc.
& setting big class paths to author style sheets.)
Minus points are Java implementation of xalan sucks badly.
It is working fine for simple transformation use cases &
but failing for the complex cases.
(I will write those test cases in the next post)
Following is the sample Test.java to transform the input xml in to HTML ( or another other output) using java Xalan libs.
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.transform.Source;
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamResult;
import javax.xml.transform.stream.StreamSource;
import org.w3c.dom.Document;
import java.io.FileInputStream;
import java.io.FileOutputStream;
public class Test
{
public static void main(String[] args) throws Exception
{
Source source = new StreamSource(new FileInputStream("C://AE_html.xsl"));
Transformer t = TransformerFactory.newInstance().newTransformer(source);
Document doc = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(new FileInputStream("c://users.xml"));
System.out.println("Transforming...");
t.transform(new DOMSource(doc),new StreamResult ( new FileOutputStream("C://users.html")) ); }
}
//System.out.println( "doc as text content"+ doc.getTextContent() );
//t.transform(new DOMSource(doc), new StreamResult(System.out));
Daily I help teams with solution engineering aspect of connected vehicle data projects. (massive datasets & always some new datasets with new car models aka new technologies.) Lately in the spare time, applying some of the ML/Deep learning techniques on datasets (many are create based on observations of real datasets)To Share some thoughts on my work (main half of this blog) and the other half will be about my family and friends.
Thursday, September 06, 2007
Thursday, August 30, 2007
Tuesday, August 28, 2007
Monday, August 27, 2007
Monday, June 04, 2007
More online references
Few more alternatives to wikipedia (www.wikipedia.org) I am finding more useful
Scholarpedia
www.scholarpedia.org
Conservapedia
www.conservapedia.org
Citizendium
www.citizendium.org
Scholarpedia
www.scholarpedia.org
Conservapedia
www.conservapedia.org
Citizendium
www.citizendium.org
Wednesday, April 11, 2007
Became a member in kiva
As usual, yesterday, I was watching PBS documentaries.
But following program was really inspiring. (It is a small part in Frontline)
(A Little Goes a Long Way)
Watch it online first.
http://www.pbs.org/frontlineworld/stories/uganda601/
Immediately decided to be a member in kiva.
I believe in the concept (microfinance & direct lending & to the needy.)
I watched many programs on microfinance.
But I never know how to be part of it or Can an individual can join.
www.kava.org helped me to contribute.
At present I am thinking of contributing to the same for another one year.
Started with 6 & my goal is help 50 all the time.
Please read the FAQ etc in the www.kiva.org before jumping.
“It's a new, direct and sustainable way to fight global poverty, and the way I see it, I get a higher return on $25 helping someone build a future than the interest my checking account pays. “
Following is my lender page in kiva.
http://www.kiva.org/lender/dhasa
But following program was really inspiring. (It is a small part in Frontline)
(A Little Goes a Long Way)
Watch it online first.
http://www.pbs.org/frontlineworld/stories/uganda601/
Immediately decided to be a member in kiva.
I believe in the concept (microfinance & direct lending & to the needy.)
I watched many programs on microfinance.
But I never know how to be part of it or Can an individual can join.
www.kava.org helped me to contribute.
At present I am thinking of contributing to the same for another one year.
Started with 6 & my goal is help 50 all the time.
Please read the FAQ etc in the www.kiva.org before jumping.
“It's a new, direct and sustainable way to fight global poverty, and the way I see it, I get a higher return on $25 helping someone build a future than the interest my checking account pays. “
Following is my lender page in kiva.
http://www.kiva.org/lender/dhasa
Wednesday, November 29, 2006
Sunday, May 21, 2006
Tuesday, March 21, 2006
Saketh's first birthday invitation card
Friday, February 17, 2006
Another Interesting Quote
Good programmers write good code. Great programmers write programs to generate it.
—Unknown
—Unknown
Tuesday, February 14, 2006
Monday, February 13, 2006
Funny but real
I believe everybody in the world should have guns. Citizens should have bazookas and rocket launchers too. I believe that all citizens should have their weapons of choice. However, I also believe that only I should have the ammunition. Because frankly, I wouldn't trust the rest of the goobers with anything more dangerous than [a] string.
—Scott Adams
—Scott Adams
Monday, February 06, 2006
Quotes of the Day
You cannot believe in God until you believe in yourself.
Swami Vivekananda
There is no security on this earth; there is only opportunity
Science without religion is lame, religion without science is blind.
Albert Einstein
Swami Vivekananda
There is no security on this earth; there is only opportunity
Science without religion is lame, religion without science is blind.
Albert Einstein
Sunday, February 05, 2006
Free & simple web picture software
it is free & very easy to use it & works with very small memory footprint.
Subscribe to:
Posts (Atom)






