<?xml-stylesheet type="text/xsl" href="http://coco-lab.org/Elgg/timo/weblog/rss/java/rssstyles.xsl"?>

<rss version='2.0'   xmlns:dc='http://purl.org/dc/elements/1.1/'>        
    <channel xml:base='http://coco-lab.org/Elgg/timo/weblog/'>
        <title><![CDATA[Timo Baumann : Weblog items tagged with java]]></title>
        <description><![CDATA[The weblog for Timo Baumann, hosted on Coco-Lab Weblog.]]></description>
        <link>http://coco-lab.org/Elgg/timo/weblog/</link>        
        <item>
            <title><![CDATA[eclipse plugins]]></title>
            <link>http://coco-lab.org/Elgg/timo/weblog/69.html</link>
            <guid isPermaLink="true">http://coco-lab.org/Elgg/timo/weblog/69.html</guid>
            <pubDate>Wed, 16 Apr 2008 18:44:56 GMT</pubDate>
		<dc:subject><![CDATA[eclipse]]></dc:subject>
		<dc:subject><![CDATA[sphinx]]></dc:subject>
		<dc:subject><![CDATA[java]]></dc:subject>
            <description><![CDATA[<p>I am currently investigating the ton of classes that implement the Sphinx interface &quot;SearchSpace&quot;, or one of the three sub-interfaces. There are 19 in total and I am likely to have to add another one for the feature that I have in mind. </p><p>Anyway, I decided that I need something, preferably an Eclipse-plugin to visualize class dependencies, and there are actually a few options:</p><ul><li><a href="http://atelier.inf.unisi.ch/~malnatij/xray.php "  title="X-Ray">X-Ray</a> would probably do the job, but it doesn&#39;t work. Maybe I just don&#39;t know how to install it correctly. </li><li><a href="http://byecycle.sourceforge.net/"  title="Bycycle">Byecycle</a> have a great screencast on their page and more friendly installation instructions. It shows a dependency graph between classes and automatically and incrementally optimizes the graph layout. Infinitely. Using 20% of your processor(s). It&#39;s quite slow and it seems to be limited to only show dependencies within the package, while the dependencies I&#39;m interested in often cross dependency boundaries (classes from different packages implementing an interface).</li></ul>Also, I found <a href="http://fjep.sourceforge.net/">Fat Jar</a>, an Eclipse plugin that turns your whole project into a single jar. That&#39;s something my collegue asked my about the other day.]]></description>
        </item>
                
        <item>
            <title><![CDATA[maɪ̯ iːpaː tɛkstfiːld]]></title>
            <link>http://coco-lab.org/Elgg/timo/weblog/68.html</link>
            <guid isPermaLink="true">http://coco-lab.org/Elgg/timo/weblog/68.html</guid>
            <pubDate>Sat, 12 Apr 2008 00:39:29 GMT</pubDate>
		<dc:subject><![CDATA[howto]]></dc:subject>
		<dc:subject><![CDATA[java]]></dc:subject>
            <description><![CDATA[<p>This has been programmed before, but here it is for you to see (and use):</p><p>IPATextField, a simple descendant of JTextField that will only accept phonetic input (either SAMPA or IPA if you know your uni codes by heart) and show IPA symbols.</p><p>You can try it out directly, as a main routine is included. It&#39;s even useful as your tiny copy-and-paste-IPA-editor. </p> <div style="background-color: lightgray; font-family: monospace; line-height: 110%"> <p>/** Copyright (C) 2008 Timo Baumann<br />&nbsp;* This program is free software; you can redistribute it and/or modify it <br />&nbsp;* under the terms of the GNU General Public License as published by the <br />&nbsp;* Free Software Foundation; either version 2 of the License, <br />&nbsp;* or (at your option) any later version.<br />&nbsp;* <br />&nbsp;* This program is distributed in the hope that it will be useful, <br />&nbsp;* but WITHOUT ANY WARRANTY; without even the implied warranty of <br />&nbsp;* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. <br />&nbsp;* See the GNU General Public License for more details.<br />&nbsp;* <br />&nbsp;* You should have received a copy of the GNU General Public License <br />&nbsp;* along with this program; if not, see &lt;<a href="http://www.gnu.org/licenses/">http://www.gnu.org/licenses/</a>&gt;.<br />&nbsp;**/<br /><br />import java.awt.event.ActionEvent;<br />import java.awt.event.WindowAdapter;<br />import java.awt.event.WindowEvent;<br />import java.text.CharacterIterator;<br />import java.text.StringCharacterIterator;<br /><br />import javax.swing.AbstractAction;<br />import javax.swing.JFrame;<br />import javax.swing.JTextField;<br />import javax.swing.text.AttributeSet;<br />import javax.swing.text.BadLocationException;<br />import javax.swing.text.Document;<br />import javax.swing.text.PlainDocument;<br /><br />public class IPATextField extends JTextField {<br /><br />&nbsp;&nbsp;&nbsp; public IPATextField(int cols) {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; super(cols);<br />&nbsp;&nbsp;&nbsp; }<br /><br />&nbsp;&nbsp;&nbsp; protected Document createDefaultModel() {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return new IPADocument();<br />&nbsp;&nbsp;&nbsp; }<br /><br />&nbsp;&nbsp;&nbsp; static class IPADocument extends PlainDocument {<br /><br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; String search&nbsp; = &quot;Q?ɡTDSZC&chi;ʁNR=&quot; + &quot;IEA{OUY29@6:_&quot;;<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; char[] replace = &quot;ʔʔg&theta;&eth;ʃʒ&ccedil;xrŋʀu0329ɪɛɑ&aelig;ɔʊʏ&oslash;&oelig;əɐːu032F&quot;.toCharArray();<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; String pass = search + replace + &quot;pbtdkgfvszwjxhmnlrieaouy .&quot;;<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public void insertString(int offs, String str, AttributeSet a) <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  throws BadLocationException<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  if (str == null) {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; return;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  }<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  StringBuffer sb = new StringBuffer();<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  CharacterIterator ci = new StringCharacterIterator(str);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  while (ci.getIndex() &lt; ci.getEndIndex()) {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; char[] c = new char[1];<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; c[0] = ci.current();<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; String s = new String(c);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; if (pass.contains(s)) {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; int replaceIndex = search.indexOf(s);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if (replaceIndex == -1) {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; sb.append(s);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; } else {<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; sb.append(replace[replaceIndex]);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  &nbsp;&nbsp;&nbsp; ci.next();<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  }<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  super.insertString(offs, sb.toString(), a);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; <br />&nbsp;&nbsp;&nbsp; /**<br />&nbsp;&nbsp;&nbsp; &nbsp;* pretty much stolen from the Swing-Tutorial...<br />&nbsp;&nbsp;&nbsp; &nbsp;* @param args does not take any arguments<br />&nbsp;&nbsp;&nbsp; &nbsp;*/<br />&nbsp;&nbsp;&nbsp; public static void main(String[] args) {<br /><br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //Create the top-level container and add contents to it.<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; JFrame frame = new JFrame(&quot;VoxforgeDE Lexicon Tool&quot;);<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; final IPATextField tf = new IPATextField(10);<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; tf.addActionListener(new AbstractAction() {<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; public void actionPerformed(ActionEvent e) {<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; System.out.println(tf.getText());<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; });<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; frame.add(tf);<br /><br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //Finish setting up the frame, and show it.<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; frame.addWindowListener(new WindowAdapter() {<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; public void windowClosing(WindowEvent e) {<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; System.exit(0);<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; });<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; frame.pack();<br />&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; frame.setVisible(true);<br />&nbsp;&nbsp;&nbsp; }<br />}<br />&nbsp;</p></div>]]></description>
        </item>
                
        <item>
            <title><![CDATA[Profiling für Java-Programme]]></title>
            <link>http://coco-lab.org/Elgg/timo/weblog/44.html</link>
            <guid isPermaLink="true">http://coco-lab.org/Elgg/timo/weblog/44.html</guid>
            <pubDate>Mon, 09 Jul 2007 10:13:30 GMT</pubDate>
		<dc:subject><![CDATA[performance]]></dc:subject>
		<dc:subject><![CDATA[OAA]]></dc:subject>
		<dc:subject><![CDATA[Java]]></dc:subject>
		<dc:subject><![CDATA[JRat]]></dc:subject>
            <description><![CDATA[<p>Schonmal interessiert gewesen, warum und was bei der Ausf&uuml;hrung so lange dauert? </p><p>Klar, beim eigenen Programm sollte ich es wissen, aber wenn ich jetzt Toolkit XYZ benutze, welche benutzte Operation ist dann besonders teuer? </p><p>Antwort darauf gibt ein Profiler, der das Laufzeitverhalten des Programms analysiert. F&uuml;r Java macht das JRat ( <a href="http://jrat.sourceforge.net/quickstart.html#9.%20Examine%20the%20JRat%20Output">http://jrat.sourceforge.net/quickstart.html#9.%20Examine%20the%20JR</a> ). </p><p>Sehr interessant, aber meine Frage, warum IclDataQ-Pakete dreimal so langsam zu entpacken sind als IclList-Pakete mit den entsprechenden Bytes drin, hat es auch nicht beantwortet. Bl&ouml;des OAA... </p>]]></description>
        </item>
        
    </channel>
</rss>
