<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-423164400323150214</id><updated>2011-11-28T09:19:38.103+09:00</updated><category term='プログラミング　コネタ'/><category term='プログラミング コネタ'/><category term='python 入門'/><title type='text'>vbnmの、いろいろやってみる！</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>17</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-4721947958847233097</id><published>2011-06-13T11:29:00.001+09:00</published><updated>2011-06-13T11:35:13.623+09:00</updated><title type='text'>maven で作る JAR の MANIFEST.MF にビルド時間を入れる</title><content type='html'>よく filter.properties に動的にビルド時間を突っ込む方法が紹介されてるっぽい。&lt;br /&gt;&lt;br /&gt;http://maven.apache.org/plugin-developers/cookbook/add-build-time-to-manifest.html&lt;br /&gt;&lt;br /&gt;でも filter.properties を用意するのめんどい！ってときは。&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;plugin&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;artifactId&amp;gt;maven-jar-plugin&amp;lt;/artifactId&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;version&amp;gt;2.3.1&amp;lt;/version&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;configuration&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;finalName&amp;gt;${project.artifactId}-${project.version}&amp;lt;/finalName&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;archive&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;manifestEntries&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;Built-By&amp;gt;HogeHoge, Inc.&amp;lt;/Built-By&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;Built-Time&amp;gt;${maven.build.timestamp}&amp;lt;/Built-Time&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/manifestEntries&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/archive&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/configuration&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/plugin&amp;gt;&lt;/blockquote&gt;&lt;br /&gt;maven-jar-plugin の manifestEntries 指定で動的に MANIFEST.MF を作る際に、&lt;br /&gt;${maven.build.timestamp} でビルド時間が参照できる。&lt;br /&gt;${maven.build.timestamp} さえ知っていれば簡単。&lt;br /&gt;&lt;br /&gt;日付フォーマットが気になる人は&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&amp;nbsp; &amp;lt;properties&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;lt;maven.build.timestamp.format&amp;gt;yyyy-MM-dd HH:mm:ss&amp;lt;/maven.build.timestamp.format&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;lt;/properties&amp;gt;&lt;/blockquote&gt;&lt;br /&gt;こんな感じ。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-4721947958847233097?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/4721947958847233097/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2011/06/maven-jar-manifestmf.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/4721947958847233097'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/4721947958847233097'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2011/06/maven-jar-manifestmf.html' title='maven で作る JAR の MANIFEST.MF にビルド時間を入れる'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-3072234921141007309</id><published>2011-05-27T16:40:00.000+09:00</published><updated>2011-05-27T16:40:51.438+09:00</updated><title type='text'>mvn test と mvn site で挙動が異なる(特に Proxy まわり)</title><content type='html'>spring aop を使用して挙動を追加しているクラスのテストで、mvn test と mvn site の結果が異なった現象についてのメモ。&lt;br /&gt;&lt;br /&gt;テストクラス&lt;br /&gt;&lt;blockquote&gt;@RunWith(SpringJUnit4ClassRunner.class)&lt;br /&gt;@ContextConfiguration(locations = {&lt;br /&gt;    "classpath:context.xml"&lt;br /&gt;})&lt;br /&gt;public class HogeControllerTest {&lt;br /&gt;    @Autowired&lt;br /&gt;    protected HogeController controller;&lt;br /&gt;...&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;コントローラ&lt;br /&gt;&lt;blockquote&gt;@Controller&lt;br /&gt;public class HogeController {&lt;br /&gt;...&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;インターフェースを用意していないコントローラの単体テスト。&lt;br /&gt;&lt;br /&gt;mvn test だとうまくインジェクションされるけど、&lt;br /&gt;mvn site だとエラーが発生する。&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'HogeControllerTest': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: protected HogeController HogeControllerTest.controller; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No matching bean of type [HogeController] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}&lt;br /&gt; at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:285)&lt;br /&gt; at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1074)&lt;br /&gt; at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireBeanProperties(AbstractAutowireCapableBeanFactory.java:374)&lt;br /&gt; at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.injectDependencies(DependencyInjectionTestExecutionListener.java:110)&lt;br /&gt; at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.prepareTestInstance(DependencyInjectionTestExecutionListener.java:75)&lt;br /&gt; at org.springframework.test.context.TestContextManager.prepareTestInstance(TestContextManager.java:321)&lt;br /&gt; at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.createTest(SpringJUnit4ClassRunner.java:220)&lt;br /&gt; at org.springframework.test.context.junit4.SpringJUnit4ClassRunner$1.runReflectiveCall(SpringJUnit4ClassRunner.java:301)&lt;br /&gt; at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)&lt;br /&gt; at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.methodBlock(SpringJUnit4ClassRunner.java:303)&lt;br /&gt; at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:240)&lt;br /&gt; at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:49)&lt;br /&gt; at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)&lt;br /&gt; at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)&lt;br /&gt; at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)&lt;br /&gt; at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)&lt;br /&gt; at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)&lt;br /&gt; at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)&lt;br /&gt; at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)&lt;br /&gt; at org.junit.runners.ParentRunner.run(ParentRunner.java:236)&lt;br /&gt; at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:180)&lt;br /&gt; at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)&lt;br /&gt; at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140)&lt;br /&gt; at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127)&lt;br /&gt; at org.apache.maven.surefire.Surefire.run(Surefire.java:177)&lt;br /&gt; at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)&lt;br /&gt; at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)&lt;br /&gt; at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)&lt;br /&gt; at java.lang.reflect.Method.invoke(Method.java:597)&lt;br /&gt; at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:334)&lt;br /&gt; at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:980)&lt;br /&gt;Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: protected HogeController HogeControllerTest.controller; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No matching bean of type [HogeController] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}&lt;br /&gt; at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:502)&lt;br /&gt; at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:84)&lt;br /&gt; at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:282)&lt;br /&gt; ... 30 more&lt;br /&gt;Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No matching bean of type [HogeController] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}&lt;br /&gt; at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoSuchBeanDefinitionException(DefaultListableBeanFactory.java:920)&lt;br /&gt; at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:789)&lt;br /&gt; at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:703)&lt;br /&gt; at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:474)&lt;br /&gt; ... 32 more&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;要はHogeController型の値がみつからなくなってる。&lt;br /&gt;&lt;br /&gt;なんでかなーと調べてみた。&lt;br /&gt;&lt;br /&gt;まず、AOPの仕組みから。&lt;br /&gt;&lt;br /&gt;参考：http://static.springsource.org/spring/docs/3.0.0.M3/spring-framework-reference/html/ch08s06.html&lt;br /&gt;&lt;br /&gt;インスタンスは、&lt;br /&gt;(1)インターフェースが実装されていればそのインターフェースのインスタンスとして  JDK dynamic proxiesで生成される。&lt;br /&gt;(2)実装するインターフェースが無ければ、そのクラスのインスタンスとして cglib で生成される。&lt;br /&gt;&lt;br /&gt;今回の例だと HogeController は(2)後者なので cglib で生成される。&lt;br /&gt;&lt;br /&gt;が、mvn site で実行すると、HogeControllerが　net.sourceforge.cobertura.coveragedata.HasBeenInstrumented　を実装する。&lt;br /&gt;このインターフェースはカバレッジを取るためのマーカインターフェースらしい。&lt;br /&gt;参考：http://d.hatena.ne.jp/garbagetown/20090717/1247920461&lt;br /&gt;&lt;br /&gt;これのせいで、(1)前者として扱われ、HasBeenInstrumented型のインスタンスとして生成される。&lt;br /&gt;HogeControllerではなく！&lt;br /&gt;&lt;br /&gt;ゆえにAutowiredでインジェクションするときにインスタンスがみつからないよーとなる。&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;はー。&lt;br /&gt;mvn site、そんな悪さしてくれるなよ。。。&lt;br /&gt;&lt;br /&gt;Controller、インターフェース実装させるか。。。&lt;br /&gt;&lt;br /&gt;そのほうが spring aop 哲学的にはいいんだよな。。。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-3072234921141007309?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/3072234921141007309/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2011/05/mvn-test-mvn-site-proxy.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/3072234921141007309'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/3072234921141007309'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2011/05/mvn-test-mvn-site-proxy.html' title='mvn test と mvn site で挙動が異なる(特に Proxy まわり)'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-3692957687648076940</id><published>2010-12-01T11:31:00.000+09:00</published><updated>2010-12-01T11:31:22.317+09:00</updated><title type='text'>正規表現 \d の罠（Java、commons-validator、perl）</title><content type='html'>Javaの正規表現(Regex) での正規表現 "\d" は、半角数字のみ受け付ける。&lt;br /&gt;&lt;br /&gt;perl の正規表現 "\d" は、全角数字、半角数字を受け付ける。&lt;br /&gt;&lt;br /&gt;罠なのは、Javaでも commons-validator を使っていると、&lt;br /&gt;commons-validator の正規表現は perl と同等であること！&lt;br /&gt;&lt;br /&gt;後者は罠として知ってたけど、前者を知らなかった。。。灯台下。。。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-3692957687648076940?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/3692957687648076940/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/12/d-javacommons-validatorperl.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/3692957687648076940'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/3692957687648076940'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/12/d-javacommons-validatorperl.html' title='正規表現 \d の罠（Java、commons-validator、perl）'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-8376876697660514316</id><published>2010-05-18T16:14:00.001+09:00</published><updated>2010-05-18T16:29:07.912+09:00</updated><title type='text'>eclipse で tomcat plugin 使ってるときは、「ソースパスを自動的に算出」をやめよう</title><content type='html'>最近 eclipse で tomcat 起動すると、ブレークポイントで止まってくれないことが多いなぁ・・・と思ってました。&lt;br /&gt;&lt;br /&gt;試しに、「ソースパスを自動的に算出」のチェックを外すと、ちゃんととまってくれるようになりました。&lt;br /&gt;&lt;br /&gt;#[Window] - [Preferences] で [Tomcat]タブの - [ソース・パス]内にあります。&lt;br /&gt;&lt;br /&gt;自分で設定する面倒を省くと、他が立たないんだなぁ。&lt;br /&gt;&lt;br /&gt;↑追記&lt;br /&gt;&lt;br /&gt;まだブレークポイントきかないことがあるなぁ。&lt;br /&gt;嘘情報かも。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-8376876697660514316?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/8376876697660514316/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/05/eclipse-tomcat-plugin.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/8376876697660514316'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/8376876697660514316'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/05/eclipse-tomcat-plugin.html' title='eclipse で tomcat plugin 使ってるときは、「ソースパスを自動的に算出」をやめよう'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-5683731880262674151</id><published>2010-05-07T11:15:00.000+09:00</published><updated>2010-05-07T11:15:18.667+09:00</updated><title type='text'>eclipse の Open Resource でtarget のファイルが表示されるのがうざい</title><content type='html'>普段eclipse で開発しているのですが、&lt;br /&gt;eclipse の Open Resource　(Ctrl+Shift+R) で target のファイルが表示されるのがほんとうざい。&lt;br /&gt;XMLとかpropertiesとか、targetのほう編集しちゃうとか、気をつけてるから最近はないけど、困る。&lt;br /&gt;&lt;br /&gt;ということでググったら、外人さんが教えてくれた。&lt;br /&gt;&lt;br /&gt;http://pilhuhn.blogspot.com/2008/01/ignore-target-folders-in-eclipse.html&lt;br /&gt;&lt;br /&gt;表示させたくないフォルダを右クリックしてResouceタブのDerivedのチェックをいれると、表示されなくなるよ！&lt;br /&gt;&lt;br /&gt;やった♪&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-5683731880262674151?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/5683731880262674151/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/05/eclipse-open-resource-target.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/5683731880262674151'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/5683731880262674151'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/05/eclipse-open-resource-target.html' title='eclipse の Open Resource でtarget のファイルが表示されるのがうざい'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-2554474411341717879</id><published>2010-04-22T14:01:00.002+09:00</published><updated>2010-04-22T14:09:29.121+09:00</updated><title type='text'>ant からキックしている tomcat に対してリモートデバッグする</title><content type='html'>ant の中の、tomcatをキックするところ&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;    &amp;lt;target name="tomcatstart"&amp;gt;&lt;br /&gt;    &amp;lt;java fork="true" dir="${basedir}" classname="org.apache.catalina.startup.Bootstrap"&amp;gt;&lt;br /&gt;      &amp;lt;classpath&amp;gt;&lt;br /&gt;        &amp;lt;pathelement path="${tomcat_dir}/bin/bootstrap.jar"/&amp;gt;&lt;br /&gt;        &amp;lt;pathelement path="${env.JAVA_HOME}/lib/tools.jar"/&amp;gt;&lt;br /&gt;      &amp;lt;/classpath&amp;gt;&lt;br /&gt;      &amp;lt;sysproperty key="catalina.home" value="${tomcat_dir}"/&amp;gt; &lt;br /&gt;      &amp;lt;arg value="start"/&amp;gt;&lt;br /&gt;    &amp;lt;/java&amp;gt;&lt;br /&gt;  &amp;lt;/target&amp;gt;&lt;/pre&gt;&lt;br /&gt;で、jvmargでリモートデバッグ設定をする。&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;    &amp;lt;target name="tomcatstart"&amp;gt;&lt;br /&gt;    &amp;lt;java fork="true" dir="${basedir}" classname="org.apache.catalina.startup.Bootstrap"&amp;gt;&lt;br /&gt;      &amp;lt;classpath&amp;gt;&lt;br /&gt;        &amp;lt;pathelement path="${tomcat_dir}/bin/bootstrap.jar"/&amp;gt;&lt;br /&gt;        &amp;lt;pathelement path="${env.JAVA_HOME}/lib/tools.jar"/&amp;gt;&lt;br /&gt;      &amp;lt;/classpath&amp;gt;&lt;br /&gt;      &amp;lt;sysproperty key="catalina.home" value="${tomcat_dir}"/&amp;gt; &lt;br /&gt;      &amp;lt;arg value="start"/&amp;gt;&lt;br /&gt;      &amp;lt;jvmarg value="-Xdebug"/&amp;gt;&lt;br /&gt;      &amp;lt;jvmarg value="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005"/&amp;gt;&lt;br /&gt;    &amp;lt;/java&amp;gt;&lt;br /&gt;  &amp;lt;/target&amp;gt;&lt;/pre&gt;&lt;br /&gt;上記のようにすると、ポート5005でlistenしててくれる。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-2554474411341717879?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/2554474411341717879/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/04/ant-tomcat.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2554474411341717879'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2554474411341717879'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/04/ant-tomcat.html' title='ant からキックしている tomcat に対してリモートデバッグする'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-8654594765700952805</id><published>2010-02-21T16:10:00.000+09:00</published><updated>2010-02-21T16:10:47.221+09:00</updated><title type='text'>GAE/Java でメール受信してみたいんだけど・・・</title><content type='html'>http://localhost:8888/_ah/admin/&lt;br /&gt;にアクセスすると、次のようなエラー&lt;br /&gt;&lt;br /&gt;ブラウザには&lt;br /&gt;&lt;blockquote&gt;HTTP ERROR: 404&lt;br /&gt;&lt;br /&gt;NOT_FOUND&lt;br /&gt;RequestURI=/_ah/admin/&lt;br /&gt;&lt;br /&gt;Powered by Jetty://&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;コンソールには&lt;br /&gt;&lt;blockquote&gt;The server is running at http://localhost:8888/&lt;br /&gt;2010/02/21 7:03:31 com.google.appengine.tools.development.LocalResourceFileServlet doGet&lt;br /&gt;WARNING: No file found for: /_ah/admin/&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;なんじゃこりゃ・・・&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-8654594765700952805?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/8654594765700952805/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/02/gaejava.html#comment-form' title='1 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/8654594765700952805'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/8654594765700952805'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/02/gaejava.html' title='GAE/Java でメール受信してみたいんだけど・・・'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-7863522196988083951</id><published>2010-02-11T00:47:00.000+09:00</published><updated>2010-02-11T00:47:11.839+09:00</updated><title type='text'>携帯のGPS情報をサーバに送信する方法</title><content type='html'>携帯のGPS情報をサーバに送信する方法&lt;br /&gt;&lt;br /&gt;http://www.utilz.jp/wiki/Gps&lt;br /&gt;&lt;br /&gt;ふむふむ・・・簡単そう・・・&lt;br /&gt;&lt;br /&gt;iphoneではどうするのかな？&lt;br /&gt;&lt;br /&gt;http://ascii.jp/elem/000/000/433/433470/&lt;br /&gt;&lt;br /&gt;JavaScriptらしい。ふーむ。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-7863522196988083951?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/7863522196988083951/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/02/gps.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/7863522196988083951'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/7863522196988083951'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/02/gps.html' title='携帯のGPS情報をサーバに送信する方法'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-2361909531735588689</id><published>2010-02-09T17:04:00.000+09:00</published><updated>2010-02-09T17:04:23.987+09:00</updated><title type='text'>スーツのハルヤマ</title><content type='html'>近所にあるのはスーツのハルヤマです。&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.rakuten.co.jp/haruyama/"&gt;http://www.rakuten.co.jp/haruyama/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;だから何って？&lt;br /&gt;いや、まぁ、ご察しください^^&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-2361909531735588689?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/2361909531735588689/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/02/blog-post.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2361909531735588689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2361909531735588689'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2010/02/blog-post.html' title='スーツのハルヤマ'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-6320699620082843937</id><published>2009-12-09T12:56:00.000+09:00</published><updated>2009-12-09T12:56:17.312+09:00</updated><title type='text'>hibernate synchronizer で ORA-01000</title><content type='html'>タイトルのまんま。&lt;br /&gt;&lt;br /&gt;eclipseでhibernate synchronizer で mapping file を作るウイザードで、&lt;br /&gt;リフレッシュボタン押してテーブル検索すると ORA-01000 カーソル数超過？&lt;br /&gt;&lt;br /&gt;テーブルパターンにテーブル名入力すると出てくる。&lt;br /&gt;&lt;br /&gt;単にテーブル多いだけ？&lt;br /&gt;システムのテーブルの数って人によって違うのかなぁ・・・&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-6320699620082843937?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/6320699620082843937/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/12/hibernate-synchronizer-ora-01000.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/6320699620082843937'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/6320699620082843937'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/12/hibernate-synchronizer-ora-01000.html' title='hibernate synchronizer で ORA-01000'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-2450278789816644768</id><published>2009-11-12T22:53:00.001+09:00</published><updated>2009-11-12T22:53:59.020+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='python 入門'/><title type='text'>python で GUI！</title><content type='html'>GUIが簡単にできるとな？&lt;br /&gt;&lt;br /&gt;gui.py&lt;br /&gt;&lt;blockquote&gt;#!C:/Python25/python&lt;br /&gt;from Tkinter import *&lt;br /&gt;&lt;br /&gt;widget = Label(None, text='Hello GUI world!')&lt;br /&gt;widget.pack()&lt;br /&gt;widget.mainloop()&lt;br /&gt;&lt;/blockquote&gt;おおお～&lt;br /&gt;&lt;br /&gt;pack() とか mainLoop() とかをコメントアウトして動かしてみる・・・ふむふむ。&lt;br /&gt;WindowシステムはCでWindowsプログラミングしたときとおんなじ感じなんかな？？？&lt;br /&gt;TkとかTclとかは全然しらん♪&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-2450278789816644768?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/2450278789816644768/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/gui-gui.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2450278789816644768'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2450278789816644768'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/gui-gui.html' title='python で GUI！'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-6545613743228647736</id><published>2009-11-11T23:34:00.004+09:00</published><updated>2009-11-11T23:48:24.304+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='python 入門'/><title type='text'>pythonの値としての関数、例外処理など</title><content type='html'>from apptools import StreamApp は、結局謎なまま。&lt;br /&gt;&lt;br /&gt;普段の自分やとここで「あーもうわけわかめ、やーんぺ」ってなるんやけど、&lt;br /&gt;ちょっと頑張ってすすんでみる。&lt;br /&gt;てか、わからんことは無視や、無視♪&lt;br /&gt;&lt;br /&gt;scanfile.py&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;#!C:/Python25/python&lt;br /&gt;&lt;br /&gt;def scanner(name, function):&lt;br /&gt;file = open(name, 'r')&lt;br /&gt;while 1:&lt;br /&gt;line = file.readline()&lt;br /&gt;if not line: break&lt;br /&gt;function(line)&lt;br /&gt;file.close()&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;commands.py&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;#!C:/Python25/python&lt;br /&gt;from scanfile import scanner&lt;br /&gt;&lt;br /&gt;def processLine(line):&lt;br /&gt;if line[0] == '*':&lt;br /&gt;print "Ms.", line[1:-1]&lt;br /&gt;elif line[0] == '+':&lt;br /&gt;print "Mr.", line[1:-1]&lt;br /&gt;else:&lt;br /&gt;raise 'unknown command', line&lt;br /&gt;&lt;br /&gt;scanner("../res/people.txt", processLine)&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;お、動いたぞ！&lt;br /&gt;&lt;br /&gt;わかったこと&lt;br /&gt;・from "ファイル名(.pyは抜く)" import "関数名" で、他のファイルに定義されている関数定義をもってこれる。Javaのimportみたいなもん。&lt;br /&gt;　⇒①scanfile.pyに他に実行されるような文があったらどうなる？ &lt;br /&gt;・関数を値として取ることができる。特別な記法は無いのでとっても直観的。第一級の値ってやつやね、懐かしい。&lt;br /&gt;　⇒②引数の数や値が違ったら例外でも起こるのかな？&lt;br /&gt;・raiseで例外を起こすことができる。Javaのthrowみたいなもん。例外に型はないのかな？&lt;br /&gt;&lt;br /&gt;①scanfile.pyに他に実行されるような文があったらどうなる？ &lt;br /&gt;scanfile.pyに print 'hello world' を足すと、 commands.py の処理の最初で実行されている模様。&lt;br /&gt;つまり、from hoge ってやると hoge.py がとりあえず実行されて、そのあと import foo で foo の値だけ持ってこれるって感じっぽいね。&lt;br /&gt;&lt;br /&gt;②引数の数や値が違ったら例外でも起こるのかな？&lt;br /&gt;不必要な引数をprocessLine に足してみると・・・&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;Traceback (most recent call last):&lt;br /&gt;hello world&lt;br /&gt;File "C:\eclipse35Python\workspace\test\src\commands.py", line 12, in &lt;module&gt;&lt;br /&gt;scanner("../res/people.txt", processLine)&lt;br /&gt;File "C:\eclipse35Python\workspace\test\src\scanfile.py", line 10, in scanner&lt;br /&gt;function(line)&lt;br /&gt;TypeError: processLine() takes exactly 2 arguments (1 given)&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;おおお、例外出た！（err出力とout出力が混ざってるから行がめちゃくちゃ）&lt;br /&gt;&lt;br /&gt;つまり、関数型言語でよくあるようなカリー化は行われてないっぽいね。&lt;br /&gt;&lt;br /&gt;楽しい♪&lt;br /&gt;&lt;br /&gt;---&lt;br /&gt;&lt;br /&gt;Blogger、WYSIWYGな機能がもっと増えたら使いやすいのに。アイテマイズとか欲しいよー、TracのWikiぐらい便利になってほしい。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-6545613743228647736?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/6545613743228647736/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/from-apptools-import-streamapp-scanfile.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/6545613743228647736'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/6545613743228647736'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/from-apptools-import-streamapp-scanfile.html' title='pythonの値としての関数、例外処理など'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-5536474415122250749</id><published>2009-11-11T00:09:00.002+09:00</published><updated>2009-11-11T00:11:37.417+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='python 入門'/><title type='text'>apptools がみつかんないってなんよ・・・</title><content type='html'>テキストの次のコードはclass。&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;#!C:/Python25/python&lt;br /&gt;from apptools import StreamApp&lt;br /&gt;from textpack import marker&lt;br /&gt;&lt;br /&gt;class PackApp(StreamApp):&lt;br /&gt;    def start(self):&lt;br /&gt;        if not self.args:&lt;br /&gt;            self.exit('use: packapp.py [-o target]? src src...')&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;こんな感じでかいていくと&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;Traceback (most recent call last):&lt;br /&gt;  File "./src/PackApp.py", line 2, in &lt;module&gt;&lt;br /&gt;    from apptools import StreamApp&lt;br /&gt;ImportError: No module named apptools&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;apptoolsが見つからないとか言われても・・・(;つД｀)&lt;br /&gt;&lt;br /&gt;あ、pythonは3.1から2.5にしてみました。&lt;br /&gt;バージョン違いかと思って。&lt;br /&gt;ただ、これ以上昔のには戻りたくない・・・&lt;br /&gt;GAEが2.5らしいから、どうせなら2.5でしたい。&lt;br /&gt;&lt;br /&gt;うーん・・・困ったなぁ&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-5536474415122250749?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/5536474415122250749/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/apptools.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/5536474415122250749'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/5536474415122250749'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/apptools.html' title='apptools がみつかんないってなんよ・・・'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-2253681006101077015</id><published>2009-11-10T23:00:00.003+09:00</published><updated>2009-11-10T23:14:31.594+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='python 入門'/><title type='text'></title><content type='html'>とりあえず、テキストのコードを自分の環境に合わせて動くように書いてみた！！！&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;#!C:/Python31/python&lt;br /&gt;import sys&lt;br /&gt;marker = '::::::'&lt;br /&gt;&lt;br /&gt;for name in sys.argv[1:]:&lt;br /&gt;    input = open(name, 'r')&lt;br /&gt;    print (marker + name)&lt;br /&gt;    print (input.read(),)&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;おおお、これで引数で与えたファイルパスでファイルを開いて次々printしてくれる！！！&lt;br /&gt;すごいすごい、簡単すぎる！&lt;br /&gt;&lt;br /&gt;でもいろんな疑問。&lt;br /&gt;&lt;br /&gt;・ファイルをオープンしてクローズしてないけどいいのかな？&lt;br /&gt;・input.read() でファイルから読み込んで全部メモリにのっけるの？メモリ食いまくり？&lt;br /&gt;・テキストファイル読み込んでるけどエンコーディング指定してないよ？&lt;br /&gt;&lt;br /&gt;そんなわけで、ファイルに日本語書いてみた！&lt;br /&gt;ら！エラー！&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;Traceback (most recent call last):&lt;br /&gt;  File "./src/packer.py", line 8, in &lt;module&gt;&lt;br /&gt;    print (input.read(),)&lt;br /&gt;UnicodeDecodeError: 'cp932' codec can't decode bytes in position 17-18: illegal&lt;br /&gt;multibyte sequence&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;ふむ、UTF-8でファイルを保存したのがだめらしい。&lt;br /&gt;&lt;br /&gt;CP932ってなんだ？&lt;br /&gt;&lt;br /&gt;http://www.kab-studio.biz/Programing/JavaA2Z/Word/00000716.html&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;Windowsでの正しい文字コード。 &lt;br /&gt;Windowsの文字コードは、一般的には「シフトJIS」だが、正しくは「CP932」である。 &lt;br /&gt;「MS932」とも言う。 &lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;なんと！！！&lt;br /&gt;&lt;br /&gt;ってなわけで、ファイルをあらためてShiftJISで保存してみる。&lt;br /&gt;&lt;br /&gt;おおお、動いたー！！！&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-2253681006101077015?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/2253681006101077015/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/cpython31python-import-sys-marker-for.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2253681006101077015'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/2253681006101077015'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/cpython31python-import-sys-marker-for.html' title=''/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-4027712448287235931</id><published>2009-11-09T23:17:00.000+09:00</published><updated>2009-11-09T23:19:11.012+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='プログラミング コネタ'/><title type='text'>Cプリプロセッサでプログラミング！？</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: 'Hiragino Kaku Gothic Pro', 'Hiragino Kaku Ghothic Pro W3', 'ヒラギノ角ゴ Pro W3', 'ＭＳ Ｐゴシック', Osaka, sans-serif; font-size: 13px; line-height: 15px; "&gt;Cプリプロセッサが関数型言語のインタープリタになってる・・・&lt;br /&gt;&lt;br /&gt;&lt;a href="http://d.hatena.ne.jp/qnighy/20091107/1257587259" target="_blank" style="font-size: 10pt; font-family: 'Hiragino Kaku Gothic Pro', 'Hiragino Kaku Ghothic Pro W3', 'ヒラギノ角ゴ Pro W3', 'ＭＳ Ｐゴシック', Osaka, sans-serif; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-color: initial; color: rgb(0, 74, 149); "&gt;http://d.hatena.ne.jp/qnighy/20091107/1257587259&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;あらゆる意味できもいヽ(;´Д｀)ﾉ&lt;br /&gt;&lt;br /&gt;とんでもない才能やなぁ・・・&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-4027712448287235931?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/4027712448287235931/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/c.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/4027712448287235931'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/4027712448287235931'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/c.html' title='Cプリプロセッサでプログラミング！？'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-7227281316986757741</id><published>2009-11-09T23:16:00.001+09:00</published><updated>2009-11-09T23:19:29.903+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='プログラミング　コネタ'/><title type='text'>C言語WindowsGCC、１時間でテトリス作る</title><content type='html'>&lt;span class="Apple-style-span"   style="  line-height: 15px; font-family:'Hiragino Kaku Gothic Pro', 'Hiragino Kaku Ghothic Pro W3', 'ヒラギノ角ゴ Pro W3', 'ＭＳ Ｐゴシック', Osaka, sans-serif;font-size:13px;"&gt;&lt;a href="http://www.nicovideo.jp/watch/sm8517855" target="_blank" style="font-size: 10pt; font-family: 'Hiragino Kaku Gothic Pro', 'Hiragino Kaku Ghothic Pro W3', 'ヒラギノ角ゴ Pro W3', 'ＭＳ Ｐゴシック', Osaka, sans-serif; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-color: initial; color: rgb(0, 74, 149); "&gt;http://www.nicovideo.jp/watch/sm8517855&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;だらだら見るぶんにはたのしかった♪&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:'Hiragino Kaku Gothic Pro', 'Hiragino Kaku Ghothic Pro W3', 'ヒラギノ角ゴ Pro W3', 'ＭＳ Ｐゴシック', Osaka, sans-serif;font-size:100%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 15px;font-size:13px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:'Hiragino Kaku Gothic Pro', 'Hiragino Kaku Ghothic Pro W3', 'ヒラギノ角ゴ Pro W3', 'ＭＳ Ｐゴシック', Osaka, sans-serif;font-size:100%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 15px;font-size:13px;"&gt;よし、pythonでテトリス作るぞ！！！＜できるのか&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-7227281316986757741?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/7227281316986757741/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/cwindowsgcc.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/7227281316986757741'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/7227281316986757741'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/cwindowsgcc.html' title='C言語WindowsGCC、１時間でテトリス作る'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-423164400323150214.post-9018219652630988069</id><published>2009-11-07T00:22:00.003+09:00</published><updated>2009-11-07T00:54:33.719+09:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='python 入門'/><title type='text'>とりあえずpython</title><content type='html'>&lt;blockquote&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;/blockquote&gt;本棚整理してたらo'reillyのpython入門が出てきた。&lt;div&gt;バージョン古いやろうなぁ・・・とおもいつつ、せっかくなんで勉強しなおす！&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;デファクトなIDEとかしらん！&lt;/div&gt;&lt;div&gt;Java-er なので eclipse ！&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://www.eclipse.org/downloads/"&gt;http://www.eclipse.org/downloads/&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="  line-height: 16px; font-family:Arial, sans-serif;font-size:12px;"&gt;&lt;a class="packageTitle" href="http://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/galileo/SR1/eclipse-java-galileo-SR1-win32.zip" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 3px; padding-right: 0px; padding-bottom: 3px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 14px; text-align: left; color: rgb(112, 54, 190); font-weight: bold; text-decoration: none; line-height: 14px; "&gt;Eclipse IDE for Java Developers (92 MB)&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:Arial, sans-serif;font-size:100%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 16px;font-size:12px;"&gt;これversionなんやろ？わからん・・・3.5か？Galileo です！！！&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:Arial, sans-serif;font-size:100%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 16px;font-size:12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:Arial, sans-serif;font-size:100%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 16px;font-size:12px;"&gt;pydevってのをいれたらいいらしい。&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:Arial, sans-serif;font-size:100%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 16px;font-size:12px;"&gt;eclipseのプラグインのURL：&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://pydev.org/updates/"&gt;http://pydev.org/updates/&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;あぁ！？&lt;/div&gt;&lt;div&gt;実行環境あらへんｗｗｗ&lt;/div&gt;&lt;div&gt;&lt;a href="http://www.python.org/download/"&gt;http://www.python.org/download/&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="  line-height: 17px; font-family:Arial, Verdana, Geneva, 'Bitstream Vera Sans', Helvetica, sans-serif;font-size:15px;"&gt;&lt;a class="reference external" href="http://www.python.org/ftp/python/3.1.1/python-3.1.1.msi" style="color: rgb(0, 0, 170); text-decoration: none; border-bottom-width: 1px; border-bottom-style: dashed; border-bottom-color: rgb(204, 204, 204); "&gt;Python 3.1.1 Windows x86 MSI Installer&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:Arial, Verdana, Geneva, 'Bitstream Vera Sans', Helvetica, sans-serif;font-size:130%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 17px;font-size:15px;"&gt;新しいものが好きです(*´∀`)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style="font-family:Arial, Verdana, Geneva, 'Bitstream Vera Sans', Helvetica, sans-serif;font-size:130%;"&gt;&lt;span class="Apple-style-span"  style=" line-height: 17px;font-size:15px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;とりあえず workspace の encoding は UTF-8 にしとく。&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;a href="http://d.hatena.ne.jp/ymotongpoo/20090428/1240933871"&gt;http://d.hatena.ne.jp/ymotongpoo/20090428/1240933871&lt;/a&gt;&lt;/div&gt;&lt;div&gt;今は意味不明やけど。&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;で、プラグインの Interpreter - Python にインストールした python.exeをセット。&lt;/div&gt;&lt;div&gt;なんかごちゃごちゃいわれるけどOK、OK。&lt;/div&gt;&lt;div&gt;む、いけたのか？&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;とりあえず新規プロジェクトで Pydev Project えらんでー&lt;/div&gt;&lt;div&gt;src の下に test.py 作ってー&lt;/div&gt;&lt;div&gt;&lt;blockquote&gt;&lt;/blockquote&gt;&lt;blockquote&gt;print 'Hello World';&lt;/blockquote&gt;&lt;/div&gt;&lt;div&gt;&lt;blockquote&gt;&lt;/blockquote&gt;って書いてー&lt;/div&gt;&lt;div&gt;実行！ Python Run!&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;・・・えー！？いきなり syntax error!?&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;調べてみると・・・&lt;span class="Apple-style-span"  style=" line-height: 22px; font-family:verdana, helvetica, sans-serif;"&gt;Python3.0系だと&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;blockquote&gt;print ('Hello World');&lt;/blockquote&gt;&lt;blockquote&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;と書けとな。&lt;/div&gt;&lt;div&gt;&lt;a href="http://www.howgry.com/page/view/id/507"&gt;http://www.howgry.com/page/view/id/507&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;今度こそ！いけー！！！&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;blockquote&gt;&lt;/blockquote&gt;&lt;blockquote&gt;Hello World&lt;/blockquote&gt;&lt;/div&gt;&lt;div&gt;いったー！！！&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;よし、寝れるｗｗｗ&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;他、参考URL：&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://lightson.dip.jp/blog/seko/1356"&gt;http://lightson.dip.jp/blog/seko/1356&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://www.atmarkit.co.jp/fjava/rensai3/eclipseplgn10/eclipseplgn10_3.html"&gt;http://www.atmarkit.co.jp/fjava/rensai3/eclipseplgn10/eclipseplgn10_3.html&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/423164400323150214-9018219652630988069?l=vbnmkyoto.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://vbnmkyoto.blogspot.com/feeds/9018219652630988069/comments/default' title='コメントの投稿'/><link rel='replies' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/python.html#comment-form' title='0 件のコメント'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/9018219652630988069'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/423164400323150214/posts/default/9018219652630988069'/><link rel='alternate' type='text/html' href='http://vbnmkyoto.blogspot.com/2009/11/python.html' title='とりあえずpython'/><author><name>vbnmkyoto</name><uri>http://www.blogger.com/profile/00883325835146165592</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
