[openrtm-commit:01138] r448 - in branches/work_ForRTMSafety/rtmtools: . jp.go.aist.rtm.rtcbuilder.safety jp.go.aist.rtm.rtcbuilder.safety/.settings jp.go.aist.rtm.rtcbuilder.safety/META-INF jp.go.aist.rtm.rtcbuilder.safety/bin jp.go.aist.rtm.rtcbuilder.safety/bin/jp jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100 jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective jp.go.aist.rtm.rtcbuilder.safety/resource jp.go.aist.rtm.rtcbuilder.safety/resource/100 jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6 jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3 jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4 jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/build jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1 jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2 jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/module jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src jp.go.aist.rtm.rtcbuilder.safety/src jp.go.aist.rtm.rtcbuilder.safety/src/jp jp.go.aist.rtm.rtcbuilder.safety/src/jp/go jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective jp.go.aist.rtm.rtcbuilder.safety/test jp.go.aist.rtm.rtcbuilder.safety/test/jp jp.go.aist.rtm.rtcbuilder.safety/test/jp/go jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100 jp.go.aist.rtm.toolscommon.profiles/src/jp/go/aist/rtm/toolscommon/profiles/util jp.go.aist.rtm.toolscommon.profiles/src/org/openrtp/namespaces/rtc/version01

openrtm @ openrtm.org openrtm @ openrtm.org
2013年 12月 3日 (火) 16:16:55 JST


Author: win-ei
Date: 2013-12-03 16:16:55 +0900 (Tue, 03 Dec 2013)
New Revision: 448

Added:
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.project
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.settings/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.settings/org.eclipse.core.resources.prefs
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/META-INF/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/META-INF/MANIFEST.MF
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.class
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/editors/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/build.properties
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.properties
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/build_ModuleName.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleName.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService2.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService2.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyService2SVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/DAQServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/CMakeLists.txt
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/Doxyfile.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/CPackWIX.cmake
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/FindOpenRTMJava.cmake
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_javacompile.cmake.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_uninstall.cmake.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/Description.txt
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.rtf
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.txt
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/wix.xsl.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.bat
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.sh
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/CMakeLists.txt
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/Doxyfile.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildMulti.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildWithType.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent1.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent2.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParentWithType.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/CPackWIX.cmake
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/FindOpenRTMJava.cmake
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_javacompile.cmake.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_uninstall.cmake.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/Description.txt
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.rtf
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.txt
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/wix.xsl.in
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.bat
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.sh
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceChildMulti.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent1.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent2.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyService2SVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceChildSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildMulti.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildWithType.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent1.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent2.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParentWithType.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyService2SVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceChildSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeChildSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/TestIDL.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/build_test.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/ComFkSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/test.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/build_test.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/test.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/.classpath
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/build_foo.xml
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/MyServiceSVC_impl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/foo.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooComp.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooImpl.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/DAQService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService3.idl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/editors/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.java
Modified:
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/jp/go/aist/rtm/toolscommon/profiles/util/YamlSubHandlerVer01.java
   branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/org/openrtp/namespaces/rtc/version01/Language.java
Log:
Daily work.

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="src" path="test"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3.8.1"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.project
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.project	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.project	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>jp.go.aist.rtm.rtcbuilder.safety</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+		<buildCommand>
+			<name>org.eclipse.pde.ManifestBuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+		<buildCommand>
+			<name>org.eclipse.pde.SchemaBuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.pde.PluginNature</nature>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.settings/org.eclipse.core.resources.prefs
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.settings/org.eclipse.core.resources.prefs	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/.settings/org.eclipse.core.resources.prefs	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,3 @@
+#Mon Dec 06 17:48:53 JST 2010
+eclipse.preferences.version=1
+encoding/<project>=UTF-8

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/META-INF/MANIFEST.MF
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/META-INF/MANIFEST.MF	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/META-INF/MANIFEST.MF	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,22 @@
+Manifest-Version: 1.0
+Ant-Version: Apache Ant 1.7.1
+Created-By: 20.0-b12 (Sun Microsystems Inc.)
+Bundle-ManifestVersion: 2
+Bundle-Name: %pluginName
+Bundle-SymbolicName: jp.go.aist.rtm.rtcbuilder.safety;singleton:=true
+Bundle-Version: 1.1.0.rc4v20130124
+Bundle-Activator: jp.go.aist.rtm.rtcbuilder.safety.RtcBuilderSafetyPlugin
+Bundle-Localization: plugin
+Require-Bundle: jp.go.aist.rtm.rtcbuilder,org.eclipse.ui,org.eclipse.c
+ ore.runtime
+Bundle-ActivationPolicy: lazy
+Bundle-Vendor: %providerName
+Export-Package: jp.go.aist.rtm.rtcbuilder.safety,jp.go.aist.rtm.rtcbuild
+ er.safety.manager,jp.go.aist.rtm.rtcbuilder.safety.template.cmake,jp.go.a
+ ist.rtm.rtcbuilder.safety.template.safety,jp.go.aist.rtm.rtcbuilder.safet
+ y.ui.Perspective
+Eclipse-BuddyPolicy: registered
+Eclipse-RegisterBuddy: jp.go.aist.rtm.rtcbuilder
+Built-By: n-ando
+Built-Date: 2013/01/25 00:47:16
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,234 @@
+cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
+
+project(${rtcParam.name} Safety)
+
+set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true)
+set(CMAKE_MODULE_PATH "${dol}{PROJECT_SOURCE_DIR}/cmake_modules")
+
+set(LINUX_PACKAGE_GENERATOR "DEB")
+${sharp}set(LINUX_PACKAGE_GENERATOR "RPM")
+
+
+${sharp} component settings
+set(RTC_NAME "${dol}{PROJECT_NAME}")
+set(RTC_VERSION "${rtcParam.version}")
+set(RTC_VERSION_MAJOR "${helper.getVerMajor(${rtcParam.version})}")
+set(RTC_VERSION_MINOR "${helper.getVerMinor(${rtcParam.version})}")
+set(RTC_VERSION_PATCH "${helper.getVerPatch(${rtcParam.version})}")
+set(RTC_LANG "${helper.toLower(${rtcParam.language})}")
+set(RTC_DESCRIPTION "${rtcParam.description}")
+set(RTC_VENDOR "${rtcParam.vender}")
+set(RTC_MAINTAINER "author at example.com")
+
+string(TOLOWER ${dol}{RTC_NAME} PACKAGE_NAME)
+set(PACKAGE_VERSION "${dol}{RTC_VERSION_MAJOR}.${dol}{RTC_VERSION_MINOR}.${dol}{RTC_VERSION_PATCH}")
+
+set(IDL_FILES ""
+#foreach($p in ${rtcParam.providerIdlPathes})
+              ${p.idlFile}
+#end
+#foreach($p in ${rtcParam.consumerIdlPathes})
+              ${p.idlFile}
+#end)
+
+set(OTHER_SRCS CMakeLists.txt Doxyfile.in
+               RTC.xml ${rtcParam.name}.conf rtc.conf)
+
+
+${sharp} check OpenRTM installed
+find_package(OpenRTMSafety REQUIRED)
+
+${sharp} check doxygen installed
+find_package(Doxygen)
+if(DOXYGEN_FOUND STREQUAL "NO")
+    message(FATAL_ERROR "Doxygen not found.")
+endif()
+
+${sharp} Safety IDL settings
+get_filename_component(CMAKE_Safety_HOME ${dol}{CMAKE_Safety_COMPILER} PATH)
+set(CMAKE_Safety_IDLJ ${dol}{CMAKE_Safety_HOME}/idlj)
+
+
+if(WIN32)
+    ${sharp} add command path
+    set(${dol}ENV{PATH} ${dol}ENV{PATH} "${dol}{OPENRTM_DIR}/bin")
+    ${sharp} set install path prefix
+    set(CMAKE_INSTALL_PREFIX "${dol}{OPENRTM_DIR}")
+    set(INSTALL_PREFIX "components/${dol}{RTC_LANG}/${dol}{PACKAGE_NAME}${dol}{PACKAGE_VERSION}")
+else()
+    ${sharp} add command path
+    set(${dol}ENV{PATH} ${dol}ENV{PATH} "${dol}{OPENRTM_DIR}/bin")
+    ${sharp} set install path prefix
+    set(CMAKE_INSTALL_PREFIX "/usr")
+    ${sharp} set(CMAKE_INSTALL_PREFIX "${dol}{OPENRTM_DIR}")
+    set(OPENRTM_SHARE_PREFIX "share/openrtm-${dol}{OPENRTM_VERSION_MAJOR}.${dol}{OPENRTM_VERSION_MINOR}")
+    set(INSTALL_PREFIX "${dol}{OPENRTM_SHARE_PREFIX}/components/${dol}{RTC_LANG}/${dol}{PACKAGE_NAME}${dol}{PACKAGE_VERSION}")
+endif()
+
+
+${sharp} add uninstall target
+configure_file(
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_uninstall.cmake.in"
+    "${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(uninstall COMMAND 
+    ${dol}{CMAKE_COMMAND} -P ${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
+
+
+${sharp} add compile target
+set(SAFETYC_SOURCE_DIRS ${dol}{PROJECT_SOURCE_DIR}/src ${dol}{PROJECT_BINARY_DIR}/src)
+set(SAFETYC_DEST_DIR ${dol}{PROJECT_BINARY_DIR}/bin)
+set(SAFETYC_CLASSPATH "${dol}{OPENRTM_CLASSPATH}")
+
+add_custom_target(idlcompile)
+
+foreach(idl ${dol}{IDL_FILES})
+    add_custom_command(TARGET idlcompile PRE_BUILD
+        COMMAND ${dol}{CMAKE_Safety_IDLJ} -td src -fall "${dol}{PROJECT_SOURCE_DIR}/${dol}{idl}")
+endforeach()
+
+configure_file(
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_safetycompile.cmake.in"
+    "${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_safetycompile.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(compile ALL
+    COMMAND ${dol}{CMAKE_COMMAND} -E make_directory bin
+    COMMAND ${dol}{CMAKE_COMMAND} -P ${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_safetycompile.cmake)
+add_dependencies(compile idlcompile)
+
+if(UNIX)
+    add_custom_command(TARGET compile
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.bat ${dol}{RTC_NAME}.bat
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.sh ${dol}{RTC_NAME}.sh.dos
+        COMMAND sed -e 's,\r,,' ${dol}{RTC_NAME}.sh.dos > ${dol}{RTC_NAME}.sh)
+else()
+    add_custom_command(TARGET compile
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.bat ${dol}{RTC_NAME}.bat
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.sh ${dol}{RTC_NAME}.sh)
+endif()
+
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES bin)
+
+install(FILES RTC.xml DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+
+install(PROGRAMS ${dol}{CMAKE_CURRENT_BINARY_DIR}/${dol}{RTC_NAME}.sh DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(PROGRAMS ${dol}{CMAKE_CURRENT_BINARY_DIR}/${dol}{RTC_NAME}.bat DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+
+install(DIRECTORY ${dol}{CMAKE_CURRENT_BINARY_DIR}/bin DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+
+
+${sharp} target settings for document
+configure_file("${dol}{CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in"
+               "${dol}{CMAKE_CURRENT_BINARY_DIR}/Doxyfile")
+
+add_custom_target(doxygen COMMAND
+                  ${dol}{DOXYGEN_EXECUTABLE} ${dol}{CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
+
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES doc)
+
+get_target_property(DOC_TARGET doc TYPE)
+if(NOT DOC_TARGET)
+    add_custom_target(doc)
+endif()
+add_dependencies(doc doxygen)
+
+install(DIRECTORY ${dol}{CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "documents")
+
+
+${sharp} install source files
+install(DIRECTORY src
+        DESTINATION "${dol}{INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+
+install(FILES ${dol}{IDL_FILES} ${dol}{RTC_NAME}.sh ${dol}{RTC_NAME}.bat ${dol}{OTHER_SRCS}
+        DESTINATION "${dol}{INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+
+install(DIRECTORY cmake_modules cpack_resources
+        DESTINATION "${dol}{INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+
+
+${sharp} package settings
+set(CPACK_PACKAGE_NAME "${dol}{RTC_NAME}")
+set(CPACK_PACKAGE_VERSION_MAJOR "${dol}{RTC_VERSION_MAJOR}")
+set(CPACK_PACKAGE_VERSION_MINOR "${dol}{RTC_VERSION_MINOR}")
+set(CPACK_PACKAGE_VERSION_PATCH "${dol}{RTC_VERSION_PATCH}")
+set(CPACK_PACKAGE_VERSION "${dol}{CPACK_PACKAGE_VERSION_MAJOR}.${dol}{CPACK_PACKAGE_VERSION_MINOR}.${dol}{CPACK_PACKAGE_VERSION_PATCH}")
+set(CPACK_PACKAGE_VENDOR "${dol}{RTC_VENDOR}")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${dol}{RTC_DESCRIPTION}")
+set(CPACK_PACKAGE_CONTACT "${dol}{RTC_MAINTAINER}")
+
+set(CPACK_RESOURCE_FILE_LICENSE
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/License.txt")
+set(CPACK_PACKAGE_DESCRIPTION_FILE
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/Description.txt")
+
+set(CPACK_COMPONENTS_ALL applications documents sources)
+set(CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME "Applications")
+set(CPACK_COMPONENT_APPLICATIONS_DESCRIPTION "RT-Component applications")
+set(CPACK_COMPONENT_APPLICATIONS_DISABLED FALSE)
+
+set(CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME "Documents")
+set(CPACK_COMPONENT_DOCUMENTS_DESCRIPTION "RT-Component documents")
+set(CPACK_COMPONENT_DOCUMENTS_DISABLED TRUE)
+
+set(CPACK_COMPONENT_SOURCES_DISPLAY_NAME "Source files")
+set(CPACK_COMPONENT_SOURCES_DESCRIPTION "RT-Component source files")
+set(CPACK_COMPONENT_SOURCES_DISABLED TRUE)
+
+if(WIN32)
+    set(CPACK_GENERATOR "WIX")
+
+    ${sharp} Windows WiX package settings
+
+    set(CPACK_WIX_XSL "@CMAKE_CURRENT_BINARY_DIR@/wix.xsl")
+    set(CPACK_WIX_LANG "ja-jp")
+    set(CPACK_RESOURCE_FILE_LICENSE
+        "@CMAKE_CURRENT_SOURCE_DIR@/cpack_resources/License.rtf")
+    configure_file(
+        "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/wix.xsl.in"
+        "${dol}{CMAKE_CURRENT_BINARY_DIR}/wix.xsl" @ONLY)
+
+    set(CPACK_PACKAGE_FILE_NAME
+        "rtc${dol}{OPENRTM_VERSION}-${dol}{PACKAGE_NAME}${dol}{PACKAGE_VERSION}")
+
+else()
+    set(CPACK_GENERATOR "${dol}{LINUX_PACKAGE_GENERATOR}")
+
+    if(CPACK_GENERATOR STREQUAL "DEB")
+        ${sharp} Linux Debian package settings
+
+        set(CPACK_DEBIAN_PACKAGE_VERSION "${dol}{CPACK_PACKAGE_VERSION}-1")
+        set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_DEBIAN_PACKAGE_SECTION "main")
+        set(CPACK_DEBIAN_PACKAGE_PRIORITY  "extra")
+        set(CPACK_DEBIAN_PACKAGE_DEPENDS "openrtm-aist (>= ${rtcParam.rtmVersion})")
+
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${dol}{OPENRTM_VERSION}-${dol}{PACKAGE_NAME}_${dol}{CPACK_DEBIAN_PACKAGE_VERSION}_${dol}{CPACK_DEBIAN_PACKAGE_ARCHITECTURE}")
+
+    elseif(CPACK_GENERATOR STREQUAL "RPM")
+        ${sharp} Linux RPM package settings
+
+        set(CPACK_RPM_PACKAGE_RELEASE "1.fc10")
+        set(CPACK_RPM_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_RPM_PACKAGE_GROUP "Development/Libraries")
+        set(CPACK_RPM_PACKAGE_LICENSE "LGPL")
+        set(CPACK_RPM_PACKAGE_REQUIRES "OpenRTM-aist >= ${rtcParam.rtmVersion}")
+
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${dol}{OPENRTM_VERSION}-${dol}{PACKAGE_NAME}-${dol}{PACKAGE_VERSION}-${dol}{CPACK_RPM_PACKAGE_RELEASE}.${dol}{CPACK_RPM_PACKAGE_ARCHITECTURE}")
+
+    endif()
+endif()
+
+message(STATUS "Package type: ${dol}{CPACK_GENERATOR}")
+message(STATUS "Package name: ${dol}{CPACK_PACKAGE_FILE_NAME}")
+
+include(CPack)

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,84 @@
+
+set(OPENRTM_FOUND FALSE)
+
+
+if(UNIX)
+    ${sharp} OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT ${dol}ENV{RTM_SAFETY_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "${dol}ENV{RTM_SAFETY_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${dol}{OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+
+    ${sharp} OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${dol}{OPENRTM_DIR}/jar" "${dol}{OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${dol}{_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+
+    if("${dol}{_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${dol}{_vers}")
+        string(REGEX REPLACE "\\.jar${dol}" "" _vers "${dol}{_vers}")
+        set(OPENRTM_VERSION "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${dol}{_vers}")
+    endif()
+
+    file(GLOB _jars "${dol}{OPENRTM_DIR}/jar/*.jar")
+    string(REPLACE ";" ":" OPENRTM_CLASSPATH "${dol}{_jars}")
+
+endif(UNIX)
+
+if(WIN32)
+    ${sharp} OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT ${dol}ENV{RTM_SAFETY_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "${dol}ENV{RTM_SAFETY_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${dol}{OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+
+    ${sharp} OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${dol}{OPENRTM_DIR}/jar" "${dol}{OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${dol}{_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+
+    if("${dol}{_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${dol}{_vers}")
+        string(REGEX REPLACE "\\.jar${dol}" "" _vers "${dol}{_vers}")
+        set(OPENRTM_VERSION "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${dol}{_vers}")
+    endif()
+
+    file(GLOB _jars "${dol}{OPENRTM_DIR}/jar/*.jar")
+    set(OPENRTM_CLASSPATH "${dol}{_jars}")
+
+endif(WIN32)
+
+message(STATUS "FindOpenRTMSafety setup done.")
+
+message(STATUS "  OPENRTM_DIR=${dol}{OPENRTM_DIR}")
+message(STATUS "  OPENRTM_VERSION=${dol}{OPENRTM_VERSION}")
+message(STATUS "  OPENRTM_VERSION_MAJOR=${dol}{OPENRTM_VERSION_MAJOR}")
+message(STATUS "  OPENRTM_VERSION_MINOR=${dol}{OPENRTM_VERSION_MINOR}")
+message(STATUS "  OPENRTM_VERSION_PATCH=${dol}{OPENRTM_VERSION_PATCH}")
+message(STATUS "  OPENRTM_CLASSPATH=${dol}{OPENRTM_CLASSPATH}")

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,48 @@
+include("@PROJECT_BINARY_DIR@/CMakeFiles/CMakeSafetyCompiler.cmake")
+
+set(_srcdir @SAFETYC_SOURCE_DIRS@)
+set(_destdir "@SAFETYC_DEST_DIR@")
+set(_classpath "@SAFETYC_CLASSPATH@")
+
+function(__safety_copy_file src dest)
+    exec_program("${dol}{CMAKE_COMMAND} -E copy_if_different \"${dol}{src}\" \"${dol}{dest}\""
+        OUTPUT_VARIABLE _out
+        RETURN_VALUE _retval)
+    message(STATUS "Copying \"${dol}{src}\" to the build directory")
+    message(STATUS ${dol}{_out})
+    if(NOT "${dol}{_retval}" STREQUAL 0)
+        message(FATAL_ERROR "Problem when copying \"${dol}{src}\"")
+    endif()
+endfunction()
+
+set(_sources)
+
+foreach(_dir ${dol}{_srcdir})
+    set(_files)
+
+    file(GLOB_RECURSE _globs RELATIVE "${dol}{_dir}" "${dol}{_dir}/*")
+    foreach(_file ${dol}{_globs})
+        get_filename_component(_file_ext "${dol}{_file}" EXT)
+        if(_file MATCHES "/.svn/")
+        elseif(_file_ext MATCHES ".c${dol}")
+            list(APPEND _sources "${dol}{_dir}/${dol}{_file}")
+        else()
+            __safety_copy_file("${dol}{_dir}/${dol}{_file}" "${dol}{_destdir}/${dol}{_file}")
+        endif()
+    endforeach()
+endforeach()
+
+message(STATUS "Compiling")
+foreach(f ${dol}{_sources})
+    message(STATUS "    ${dol}{f}")
+endforeach()
+
+string(REPLACE ";" " " _sources "${dol}{_sources}")
+exec_program("${dol}{CMAKE_Safety_COMPILER}"
+    ARGS "-d ${dol}{_destdir} -cp \"${dol}{_classpath}\" ${dol}{_sources}"
+    OUTPUT_VARIABLE _out
+    RETURN_VALUE _retval)
+message(STATUS ${dol}{_out})
+if(NOT "${dol}{_retval}" STREQUAL 0)
+    message(FATAL_ERROR "Problem when compiling \"${dol}{_sources}\"")
+endif()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<xsl:stylesheet version="1.0"
+   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+   xmlns:wix="http://schemas.microsoft.com/wix/2006/wi">
+  <xsl:output indent="yes" method="xml"/>
+
+  <xsl:template match="/wix:Wix">
+    <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
+      <Product xmlns="http://schemas.microsoft.com/wix/2006/wi" Id="${WIX_PRODUCT_ID}" Name="@RTC_NAME@ @PACKAGE_VERSION@" Language="1041" Codepage="932" Version="@PACKAGE_VERSION@" Manufacturer="@RTC_VENDOR@" UpgradeCode="${WIX_UPGRADECODE}">
+        <Package InstallerVersion="300" Compressed="yes" Languages='1041' SummaryCodepage='932' />
+        <Media Id="1" Cabinet="@RTC_NAME at .cab" EmbedCab="yes" />
+        <Directory Id="TARGETDIR" Name="SourceDir" >
+            <Directory Id="ProgramFilesFolder" Name="PFILE" >
+                <Directory Id="OPENRTM_DIR" Name="OpenRTM-aist" >
+                    <Directory Id="INSTALLLOCATION" Name="@OPENRTM_VERSION_MAJOR at .@OPENRTM_VERSION_MINOR@" />
+                </Directory>
+            </Directory>
+        </Directory>
+
+        <Feature Id="APPLICATIONS" Title="@CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME@" Level="1" Description="@CPACK_COMPONENT_APPLICATIONS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .bat')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .sh')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\bin')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\RTC.xml')]" />
+        </Feature>
+
+        <Feature Id="DOCUMENTS" Title="@CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_DOCUMENTS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\doc')]" />
+        </Feature>
+
+        <Feature Id="SOURCES" Title="@CPACK_COMPONENT_SOURCES_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_SOURCES_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\src')]" />
+        </Feature>
+
+        <!--Tack on your specific wix options-->
+        <UIRef Id="WixUI_FeatureTree" />
+        <UIRef Id="WixUI_ErrorProgressText" />
+        <WixVariable Id="WixUILicenseRtf" Value="@CPACK_RESOURCE_FILE_LICENSE@"/>
+        <!-- TODO: Add Wix Specific Dialogs and features. -->
+        <!-- TODO: Add artwork  -->
+        <!-- TODO: Add ... -->
+
+      </Product>
+
+      <!--Output the fragment info which heat generates-->
+      <xsl:copy-of select="wix:Fragment[wix:DirectoryRef/wix:Component]" />
+      <xsl:apply-templates select="wix:Fragment[wix:DirectoryRef/@Id!='TARGETDIR' and wix:DirectoryRef/wix:Directory]" />
+
+    </Wix>
+  </xsl:template>
+
+  <xsl:template match="wix:Fragment[wix:DirectoryRef/wix:Directory]" >
+    <xsl:copy>
+      <xsl:apply-templates select="wix:DirectoryRef" />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:DirectoryRef" >
+    <xsl:copy>
+      <xsl:choose>
+        <xsl:when test="wix:Directory[@Name='components']" >
+          <xsl:attribute name="Id">INSTALLLOCATION</xsl:attribute>
+        </xsl:when>
+        <xsl:otherwise>
+          <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+        </xsl:otherwise>
+      </xsl:choose>
+      <xsl:apply-templates />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Directory" >
+    <xsl:copy>
+      <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+      <xsl:attribute name="Name"><xsl:value-of select="@Name" /></xsl:attribute>
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Component">
+    <xsl:element name="ComponentRef" xmlns="http://schemas.microsoft.com/wix/2006/wi" >
+      <xsl:attribute name="Id">
+        <xsl:value-of select="@Id" />
+      </xsl:attribute>
+    </xsl:element>
+  </xsl:template>
+
+</xsl:stylesheet>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,110 @@
+// -*- C -*-
+/*!
+ * @file ${rtcParam.name}Comp.c
+ * @brief Standalone component
+#set( $Date$ = "dummy" )
+ * @date \$Date$
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+#set( $Id$ = "dummy" )
+ * \$Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class ${rtcParam.name}Comp
+ * @brief Standalone component Class
+ *
+ */
+public class ${rtcParam.name}Comp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(${rtcParam.name}.component_conf);
+      mgr.registerFactory(prop, new ${rtcParam.name}(), new ${rtcParam.name}());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("${rtcParam.name}");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        ${rtcParam.name}Comp init = new ${rtcParam.name}Comp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,89 @@
+// -*- Java -*-
+/*!
+ * @file ${rtcParam.name}.java
+#set( $Date$ = "dummy" )
+ * @date \$Date$
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+#set( $Id$ = "dummy" )
+ * \$Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class ${rtcParam.name}
+ * @brief ${rtcParam.description}
+ */
+public class ${rtcParam.name} implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "${rtcParam.name}",
+    	    "type_name",         "${rtcParam.name}",
+    	    "description",       "${rtcParam.description}",
+    	    "version",           "${rtcParam.version}",
+    	    "vendor",            "${rtcParam.vender}",
+    	    "category",          "${rtcParam.category}",
+    	    "activity_type",     "${rtcParam.componentType}",
+    	    "max_instance",      "${rtcParam.maxInstance}",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+#if( ${rtcParam.configParams.size()} > 0 )
+            // Configuration variables
+#foreach($configParam in ${rtcParam.configParams})  
+            "conf.default.${configParam.name}", "${configParam.defaultVal}",
+#end
+#end
+#if( ${rtcParam.configParams.size()} > 0 )
+            // Widget
+#foreach($configParam in ${rtcParam.configParams})
+#if( ${configParam.widget.length()} > 0 )
+            "conf.__widget__.${configParam.name}", "${configParam.widget}#if( ${configParam.step.length()} > 0 ).${configParam.step}#end",
+#end
+#end
+            // Constraints
+#foreach($configParam in ${rtcParam.configParams})
+#if( ${configParam.constraint.length()} > 0 )
+            "conf.__constraints__.${configParam.name}", "${configParam.constraint}",
+#end
+#end
+#end
+#if( ${rtcParam.configParameterParams.size()} > 0 )
+            // System Configuration
+#foreach($parameterParam in ${rtcParam.configParameterParams})  
+#if( ${parameterParam.isNonPeriodic()} )
+            "${parameterParam.configName}", "${parameterParam.defaultVal}",
+#end
+#end
+#end
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new ${rtcParam.name}Impl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new ${rtcParam.name}(), new ${rtcParam.name}());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,627 @@
+// -*- Java -*-
+/*!
+ * @file  ${rtcParam.name}Impl.java
+ * @brief ${rtcParam.description}
+#set( $Date$ = "dummy" )
+ * @date  \$Date$
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+#set( $Id$ = "dummy" )
+ * \$Id$
+ */
+
+#foreach($type in ${javaConv.getPortTypes(${rtcParam})})  
+${javaConv.getDataportPackageName(${type})}
+#end
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+#if( ${rtcParam.inports.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.InPort;
+#end
+#if( ${rtcParam.outports.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.OutPort;
+#end
+#if( ${rtcParam.inports.size()} > 0 || ${rtcParam.outports.size()} > 0 )
+import jp.go.aist.rtm.RTC.util.DataRef;
+#end
+#if( ${rtcParam.originalConsumerIdls.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+#end
+#if( ${rtcParam.originalProviderIdls.size()} > 0 || ${rtcParam.originalConsumerIdls.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+#end
+#if( ${rtcParam.originalProviderIdls.size()} > 0 )
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+#end
+#if( ${rtcParam.configParams.size()} > 0 )
+#foreach($type in ${javaConv.getParamTypes(${rtcParam})})  
+import jp.go.aist.rtm.RTC.util.${type};
+#end
+#end
+#if( ${javaConv.useReturnCode(${rtcParam})} )
+import RTC.ReturnCode_t;
+#end
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==1)
+#if(${tmpltHelper.isModule(${serviceInterface.interfaceType})})import ${tmpltHelper.convFormat(${serviceInterface.interfaceType})};
+#end#end#end#end#end#end
+
+/*!
+ * @class ${rtcParam.name}Impl
+ * @brief ${rtcParam.description}
+#if( ${rtcParam.docDescription.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docDescription})}
+#end
+#if( ${rtcParam.docInOut.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docInOut})}
+#end
+#if( ${rtcParam.docAlgorithm.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docAlgorithm})}
+#end
+#if( ${rtcParam.docReference.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docReference})}
+#end
+ *
+ */
+public class ${rtcParam.name}Impl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public ${rtcParam.name}Impl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+#foreach($port in ${rtcParam.inports})  
+        m_${port.tmplVarName}_val = new ${javaConv.getDataTypeName(${port.type})}();
+        m_${port.tmplVarName} = new DataRef<${javaConv.getDataTypeName(${port.type})}>(m_${port.tmplVarName}_val);
+        m_${port.name}In = new InPort<${javaConv.getDataTypeName(${port.type})}>("${port.name}", m_${port.tmplVarName});
+#end
+#foreach($port in ${rtcParam.outports})  
+        m_${port.tmplVarName}_val = new ${javaConv.getDataTypeName(${port.type})}();
+        m_${port.tmplVarName} = new DataRef<${javaConv.getDataTypeName(${port.type})}>(m_${port.tmplVarName}_val);
+        m_${port.name}Out = new OutPort<${javaConv.getDataTypeName(${port.type})}>("${port.name}", m_${port.tmplVarName});
+#end
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+        m_${servicePort.name}Port = new CorbaPort("${servicePort.name}");
+#end#end#end
+        // </rtc-template>
+
+    }
+
+    /*#if(${rtcParam.configParams.size()}==0)*#else!#end
+
+#if(${rtcParam.getDocActionOverView(0).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(0)})}
+#end
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(0).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(0)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(0).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(0)})}
+#end
+     * 
+     */
+#if( ${rtcParam.configParams.size()}>0 || ${rtcParam.inports.size()}>0 || ${rtcParam.outports.size()}>0 || ${rtcParam.servicePorts.size()}>0 || !${rtcParam.IsNotImplemented(0)} )
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+#if( ${rtcParam.inports.size()} > 0 )
+        // Set InPort buffers
+#foreach($port in ${rtcParam.inports})  
+        addInPort("${port.name}", m_${port.name}In);
+#end
+#end
+#if( ${rtcParam.outports.size()} > 0 )
+        
+        // Set OutPort buffer
+#foreach($port in ${rtcParam.outports})  
+        addOutPort("${port.name}", m_${port.name}Out);
+#end
+#end
+#if( ${rtcParam.providerIdlPathes.size()} > 0 )
+        
+        // Set service provider to Ports
+#if(${rtcParam.servicePorts.size()}>0)
+        try {
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==0)
+        	m_${servicePort.name}Port.registerProvider("${serviceInterface.name}", "${tmpltHelper.convFormat(${serviceInterface.interfaceType})}", m_${serviceInterface.tmplVarName});
+#end#end#end#end#end
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+#end
+#if(${rtcParam.servicePorts.size()}>0)
+        
+        // Set service consumers to Ports
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==1)
+        m_${servicePort.name}Port.registerConsumer("${serviceInterface.name}", "${tmpltHelper.convFormat(${serviceInterface.interfaceType})}", m_${serviceInterface.tmplVarName}Base);
+#end#end#end#end#end
+#if(${rtcParam.servicePorts.size()}>0)
+        
+        // Set CORBA Service Ports
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+        addPort(m_${servicePort.name}Port);
+#end#end#end
+        // </rtc-template>
+#foreach($configParam in ${rtcParam.configParams})  
+        bindParameter("${configParam.name}", m_${configParam.tmplVarName}, "${configParam.defaultVal}");
+#end
+#if(${tmpltHelper.checkDetailContent(0,${rtcParam})})${rtcParam.getDetailContent(0)}
+#end
+        return super.onInitialize();
+    }
+#else
+//    @Override
+//    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+//        return super.onInitialize();
+//    }
+#end
+
+    /***
+#if(${rtcParam.getDocActionOverView(1).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(1)})}
+#end
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(1).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(1)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(1).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(1)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(1)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(1)})//#end    protected ReturnCode_t onFinalize() {
+#if(${tmpltHelper.checkDetailContent(1,${rtcParam})})${rtcParam.getDetailContent(1)}
+#end
+#if(${rtcParam.IsNotImplemented(1)})//#end        return super.onFinalize();
+#if(${rtcParam.IsNotImplemented(1)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(2).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(2)})}
+#end
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(2).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(2)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(2).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(2)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(2)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(2)})//#end    protected ReturnCode_t onStartup(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(2,${rtcParam})})${rtcParam.getDetailContent(2)}
+#end
+#if(${rtcParam.IsNotImplemented(2)})//#end        return super.onStartup(ec_id);
+#if(${rtcParam.IsNotImplemented(2)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(3).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(3)})}
+#end
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(3).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(3)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(3).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(3)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(3)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(3)})//#end    protected ReturnCode_t onShutdown(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(3,${rtcParam})})${rtcParam.getDetailContent(3)}
+#end
+#if(${rtcParam.IsNotImplemented(3)})//#end        return super.onShutdown(ec_id);
+#if(${rtcParam.IsNotImplemented(3)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(4).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(4)})}
+#end
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(4).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(4)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(4).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(4)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(4)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(4)})//#end    protected ReturnCode_t onActivated(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(4,${rtcParam})})${rtcParam.getDetailContent(4)}
+#end
+#if(${rtcParam.IsNotImplemented(4)})//#end        return super.onActivated(ec_id);
+#if(${rtcParam.IsNotImplemented(4)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(5).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(5)})}
+#end
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(5).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(5)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(5).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(5)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(5)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(5)})//#end    protected ReturnCode_t onDeactivated(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(5,${rtcParam})})${rtcParam.getDetailContent(5)}
+#end
+#if(${rtcParam.IsNotImplemented(5)})//#end        return super.onDeactivated(ec_id);
+#if(${rtcParam.IsNotImplemented(5)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(9).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(9)})}
+#end
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(9).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(9)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(9).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(9)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(9)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(9)})//#end    protected ReturnCode_t onExecute(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(9,${rtcParam})})${rtcParam.getDetailContent(9)}
+#end
+#if(${rtcParam.IsNotImplemented(9)})//#end        return super.onExecute(ec_id);
+#if(${rtcParam.IsNotImplemented(9)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(6).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(6)})}
+#end
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(6).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(6)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(6).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(6)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(6)})//#end  @Override
+#if(${rtcParam.IsNotImplemented(6)})//#end  public ReturnCode_t onAborting(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(6,${rtcParam})})${rtcParam.getDetailContent(6)}
+#end
+#if(${rtcParam.IsNotImplemented(6)})//#end      return super.onAborting(ec_id);
+#if(${rtcParam.IsNotImplemented(6)})//#end  }
+
+    /***
+#if(${rtcParam.getDocActionOverView(7).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(7)})}
+#end
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(7).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(7)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(7).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(7)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(7)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(7)})//#end    public ReturnCode_t onError(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(7,${rtcParam})})${rtcParam.getDetailContent(7)}
+#end
+#if(${rtcParam.IsNotImplemented(7)})//#end        return super.onError(ec_id);
+#if(${rtcParam.IsNotImplemented(7)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(8).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(8)})}
+#end
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(8).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(8)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(8).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(8)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(8)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(8)})//#end    protected ReturnCode_t onReset(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(8,${rtcParam})})${rtcParam.getDetailContent(8)}
+#end
+#if(${rtcParam.IsNotImplemented(8)})//#end        return super.onReset(ec_id);
+#if(${rtcParam.IsNotImplemented(8)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(10).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(10)})}
+#end
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(10).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(10)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(10).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(10)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(10)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(10)})//#end    protected ReturnCode_t onStateUpdate(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(10,${rtcParam})})${rtcParam.getDetailContent(10)}
+#end
+#if(${rtcParam.IsNotImplemented(10)})//#end        return super.onStateUpdate(ec_id);
+#if(${rtcParam.IsNotImplemented(10)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(11).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(11)})}
+#end
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(11).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(11)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(11).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(11)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(11)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(11)})//#end    protected ReturnCode_t onRateChanged(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(11,${rtcParam})})${rtcParam.getDetailContent(11)}
+#end
+#if(${rtcParam.IsNotImplemented(11)})//#end        return super.onRateChanged(ec_id);
+#if(${rtcParam.IsNotImplemented(11)})//#end    }
+//
+#if( ${rtcParam.configParams.size()} > 0 )
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+#foreach($configParam in ${rtcParam.configParams})  
+    /*!
+     * ${tmpltHelperJava.convertDescDocJava(${configParam.docDescription})}
+     * - Name: ${configParam.docDataName} ${configParam.tmplVarName}
+     * - DefaultValue: ${configParam.defaultVal}
+#if(${configParam.docUnit.length()}>0)     * - Unit: ${tmpltHelperJava.convertUnitDocJava(${configParam.docUnit})}
+#end
+#if(${configParam.docRange.length()}>0)     * - Range: ${tmpltHelperJava.convertRangeDocJava(${configParam.docRange})}
+#end
+#if(${configParam.docConstraint.length()}>0)     * - Constraint: ${tmpltHelperJava.convertConstraintDocJava(${configParam.docConstraint})}
+#end
+     */
+    protected ${javaConv.convJava2ParamHolder(${configParam.type},true)} m_${configParam.tmplVarName} = new ${javaConv.convJava2ParamHolder(${configParam.type},true)}();
+#end
+	// </rtc-template>
+
+#end
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+#foreach($port in ${rtcParam.inports})  
+    protected ${javaConv.getDataTypeName(${port.type})} m_${port.tmplVarName}_val;
+    protected DataRef<${javaConv.getDataTypeName(${port.type})}> m_${port.tmplVarName};
+    /*!
+#if(${port.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${port.docDescription})}
+#end
+#if(${port.docType.length()}>0)     * - Type: ${tmpltHelperJava.convertTypeDocJava(${port.docType})}
+#end
+#if(${port.docNum.length()}>0)     * - Number: ${tmpltHelperJava.convertNumberDocJava(${port.docNum})}
+#end
+#if(${port.docSemantics.length()}>0)     * - Semantics: ${tmpltHelperJava.convertSemanticsDocJava(${port.docSemantics})}
+#end
+#if(${port.docUnit.length()}>0)     * - Unit: ${tmpltHelperJava.convertTypeDocJava(${port.docUnit})}
+#end
+#if(${port.docOccurrence.length()}>0)     * - Frequency: ${tmpltHelperJava.convertFrequencyDocJava(${port.docOccurrence})}
+#end
+#if(${port.docOperation.length()}>0)     * - Operation Cycle: ${tmpltHelperJava.convertCycleDocJava(${port.docOperation})}
+#end
+     */
+    protected InPort<${javaConv.getDataTypeName(${port.type})}> m_${port.name}In;
+
+#end
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+#foreach($port in ${rtcParam.outports})  
+    protected ${javaConv.getDataTypeName(${port.type})} m_${port.tmplVarName}_val;
+    protected DataRef<${javaConv.getDataTypeName(${port.type})}> m_${port.tmplVarName};
+    /*!
+#if(${port.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${port.docDescription})}
+#end
+#if(${port.docType.length()}>0)     * - Type: ${tmpltHelperJava.convertTypeDocJava(${port.docType})}
+#end
+#if(${port.docNum.length()}>0)     * - Number: ${tmpltHelperJava.convertNumberDocJava(${port.docNum})}
+#end
+#if(${port.docSemantics.length()}>0)     * - Semantics: ${tmpltHelperJava.convertSemanticsDocJava(${port.docSemantics})}
+#end
+#if(${port.docUnit.length()}>0)     * - Unit: ${tmpltHelperJava.convertTypeDocJava(${port.docUnit})}
+#end
+#if(${port.docOccurrence.length()}>0)     * - Frequency: ${tmpltHelperJava.convertFrequencyDocJava(${port.docOccurrence})}
+#end
+#if(${port.docOperation.length()}>0)     * - Operation Cycle: ${tmpltHelperJava.convertCycleDocJava(${port.docOperation})}
+#end
+     */
+    protected OutPort<${javaConv.getDataTypeName(${port.type})}> m_${port.name}Out;
+
+#end
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+    /*!
+#if(${servicePort.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${servicePort.docDescription})}
+#end
+#if(${servicePort.docIfDescription.length()}>0)     * Interface: ${tmpltHelperJava.convertInterfaceDocJava(${servicePort.docIfDescription})}
+#end
+     */
+    protected CorbaPort m_${servicePort.name}Port;
+#end#end#end
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==0)
+    /*!
+#if(${serviceInterface.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${serviceInterface.docDescription})}
+#end
+#if(${serviceInterface.docArgument.length()}>0)     * - Argument:      ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docArgument})}
+#end
+#if(${serviceInterface.docReturn.length()}>0)     * - Return Value:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docReturn})}
+#end
+#if(${serviceInterface.docException.length()}>0)     * - Exception:     ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docException})}
+#end
+#if(${serviceInterface.docPreCondition.length()}>0)     * - PreCondition:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPreCondition})}
+#end
+#if(${serviceInterface.docPostCondition.length()}>0)     * - PostCondition: ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPostCondition})}
+#end
+     */
+    protected ${serviceInterface.interfaceRawType}${tmpltHelper.serviceImplSuffix} m_${serviceInterface.tmplVarName} = new ${serviceInterface.interfaceRawType}${tmpltHelper.serviceImplSuffix}();
+#end#end#end#end#end
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==1)
+    protected CorbaConsumer<${serviceInterface.interfaceRawType}> m_${serviceInterface.tmplVarName}Base = new CorbaConsumer<${serviceInterface.interfaceRawType}>(${serviceInterface.interfaceRawType}.class);
+    /*!
+#if(${serviceInterface.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${serviceInterface.docDescription})}
+#end
+#if(${serviceInterface.docArgument.length()}>0)     * - Argument:      ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docArgument})}
+#end
+#if(${serviceInterface.docReturn.length()}>0)     * - Return Value:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docReturn})}
+#end
+#if(${serviceInterface.docException.length()}>0)     * - Exception:     ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docException})}
+#end
+#if(${serviceInterface.docPreCondition.length()}>0)     * - PreCondition:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPreCondition})}
+#end
+#if(${serviceInterface.docPostCondition.length()}>0)     * - PostCondition: ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPostCondition})}
+#end
+     */
+    protected ${serviceInterface.interfaceRawType} m_${serviceInterface.tmplVarName};
+#end#end#end#end#end
+    
+    // </rtc-template>
+
+#foreach($privateAttribute in ${rtcParam.privateAttributes})
+  ${privateAttribute}
+#end
+#foreach($privateOperation in ${rtcParam.privateOperations})
+  ${privateOperation}
+#end
+#foreach($protectedAttribute in ${rtcParam.protectedAttributes})
+  ${protectedAttribute}
+#end
+#foreach($protectedOperation in ${rtcParam.protectedOperations})
+  ${protectedOperation}
+#end
+#foreach($publicAttribute in ${rtcParam.publicAttributes})
+  ${publicAttribute}
+#end
+#foreach($publicOperation in ${rtcParam.publicOperations})
+  ${publicOperation}
+#end
+#if(${tmpltHelper.checkContents(${rtcParam.publicOpeSource})})${rtcParam.publicOpeSource}
+#end
+#if(${tmpltHelper.checkContents(${rtcParam.protectedOpeSource})})${rtcParam.protectedOpeSource}
+#end
+#if(${tmpltHelper.checkContents(${rtcParam.privateOpeSource})})${rtcParam.privateOpeSource}
+#end
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,43 @@
+// -*-Java-*-
+/*!
+ * @file  ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix}.java
+ * @brief Service implementation code of ${idlFileParam.idlFile}
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+ */
+#if(${tmpltHelper.isModule(${serviceClassParam.name})})import ${tmpltHelper.convFormat(${serviceClassParam.name})}POA;
+#end
+/*!
+ * @class ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix}
+ * Example class implementing IDL interface ${serviceClassParam.name}
+ */
+public class ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix} extends ${tmpltHelper.getBasename(${serviceClassParam.name})}POA{
+    
+    public ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix}() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+#foreach($serviceMethodParam in ${serviceClassParam.methods})
+    public ${javaConv.convCORBA2Java(${serviceMethodParam},${serviceClassParam})} ${serviceMethodParam.name}(#foreach($serviceArgumentParam in ${serviceMethodParam.arguments})#if($velocityCount > 1), #end${javaConv.convCORBA2JavaforArg(${serviceArgumentParam},${serviceArgumentParam.direction},${serviceClassParam})} ${serviceArgumentParam.name}#end) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <${javaConv.convCORBA2JavaNoDef(${serviceMethodParam.type})} ${serviceMethodParam.name}(#foreach($serviceArgumentParam in ${serviceMethodParam.arguments})#if($velocityCount > 1), #end${javaConv.convCORBA2JavaforArg(${serviceArgumentParam.type},${serviceArgumentParam.direction})} ${serviceArgumentParam.name}#end)>"
+#if(!${serviceMethodParam.isVoid})#if(${javaConv.isRetNull(${serviceMethodParam},${serviceClassParam})})        return null;
+#elseif(${serviceMethodParam.isBoolean})        return false;
+#else        return 0;
+#end
+#end
+    }
+
+#end
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,62 @@
+#set( $dollarStr = "$" )
+<!--
+# -*- Buildfile -*-
+# @file  build_${rtcParam.name}.xml
+# @brief RTComponent makefile for "${rtcParam.name} component"
+# @date  ${dollarStr}Date${dollarStr}
+#
+# ${dollarStr}Id${dollarStr}
+ -->
+<project name="${rtcParam.name}" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dollarStr}{dest}" />
+	</target>
+
+#if( ${rtcParam.providerIdlPathes.size()} > 0 || ${rtcParam.consumerIdlPathes.size()} > 0 )
+	<target name="idlcompile"  depends="mkdir">
+#foreach($idlPath in ${rtcParam.providerIdlPathes})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idlPath.idlFile})}'"/>
+		</exec>
+#foreach ($idl in ${idlPath.includeIdlParams})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idl.idlFile})}'"/>
+		</exec>
+#end
+#end
+#foreach($idlPath in ${rtcParam.consumerIdlPathes})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idlPath.idlFile})}'"/>
+		</exec>
+#foreach ($idl in ${idlPath.includeIdlParams})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idl.idlFile})}'"/>
+		</exec>
+#end
+#end
+	</target>
+#end
+
+#if( ${rtcParam.providerIdlPathes.size()} > 0 || ${rtcParam.consumerIdlPathes.size()} > 0 )
+	<target name="compile" depends="idlcompile">
+#else
+	<target name="compile" depends="mkdir">
+#end
+		<safatyc srcdir="${dollarStr}{source}" destdir="${dollarStr}{dest}">
+			<classpath>
+				<fileset dir="${dollarStr}{env.RTM_SAFETY_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+#if( ${rtcParam.libraryPathes.size()} > 0 )
+#foreach($safetyRef in ${rtcParam.libraryPathes})
+				<pathelement location="'${safetyRef}'"/>
+#end
+#end
+			</classpath>
+		</safetyc>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+#if( ${tmpltHelperJava.notNullRTMRoot()} )
+	<classpathentry kind="lib" path="${javaRoot}/jar/OpenRTM-aist-${rtcParam.rtmJavaVersion}.jar"/>
+#end
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,5 @@
+set CLASSPATH=.;%RTM_JAVA_ROOT%\jar\OpenRTM-aist-${rtcParam.rtmJavaVersion}.jar;%RTM_JAVA_ROOT%\jar\commons-cli-1.1.jar
+cd /d %~dp0
+cd bin
+java ${rtcParam.name}Comp -f rtc.conf %*
+pause;

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,10 @@
+#!/bin/sh
+if test "x${dol}RTM_JAVA_ROOT" = "x" ; then
+    echo "Environment variable RTM_JAVA_ROOT is not set."
+    echo "Please specify the OpenRTM-aist installation directory."
+    echo "Abort."
+    exit 1
+fi
+export CLASSPATH=.:${dol}{RTM_JAVA_ROOT}/jar/OpenRTM-aist-${rtcParam.rtmJavaVersion}.jar:${dol}{RTM_JAVA_ROOT}/jar/commons-cli-1.1.jar
+cd `dirname ${dol}0`/bin
+java ${rtcParam.name}Comp -f rtc.conf ${dol}*

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.class
===================================================================
(Binary files differ)


Property changes on: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/bin/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.class
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/build.properties
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/build.properties	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/build.properties	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.properties,\
+               plugin.xml
+javacDefaultEncoding.. = UTF-8

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.properties
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.properties	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.properties	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,20 @@
+# <copyright>
+# </copyright>
+#
+# $Id: plugin.properties,v 1.1 2007/12/25 05:43:00 tsakamoto Exp $
+
+# ====================================================================
+# To code developer:
+#   Do NOT change the properties between this line and the
+#   "%%% END OF TRANSLATED PROPERTIES %%%" line.
+#   Make a new property name, append to the end of the file and change
+#   the code to use the new property.
+# ====================================================================
+
+# ====================================================================
+# %%% END OF TRANSLATED PROPERTIES %%%
+# ====================================================================
+
+pluginName = RtcBuilder for Safety
+providerName = AIST
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/plugin.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.2"?>
+<plugin>
+   <extension point="jp.go.aist.rtm.rtcbuilder.generateManager">
+      <manager
+            managerclass="jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager"
+            seq="200"/>
+      <manager
+            managerclass="jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager"
+            seq="210"/>
+   </extension>
+
+</plugin>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/build_ModuleName.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/build_ModuleName.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/build_ModuleName.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_ModuleName.xml
+# @brief RTComponent makefile for "ModuleName component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="ModuleName" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleName.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleName.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleName.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,57 @@
+// -*- Java -*-
+/*!
+ * @file ModuleName.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class ModuleName
+ * @brief ModuleDescription
+ */
+public class ModuleName implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "ModuleName",
+    	    "type_name",         "ModuleName",
+    	    "description",       "ModuleDescription",
+    	    "version",           "1.0.0",
+    	    "vendor",            "VenderName",
+    	    "category",          "Category",
+    	    "activity_type",     "DataFlowComponent",
+    	    "max_instance",      "1",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+            // Configuration variables
+            "conf.default.int_param0", "0",
+            "conf.default.vector_param", "1.0,2.0,3.0",
+            // Widget
+            // Constraints
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new ModuleNameImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new ModuleName(), new ModuleName());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file ModuleNameComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class ModuleNameComp
+ * @brief Standalone component Class
+ *
+ */
+public class ModuleNameComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(ModuleName.component_conf);
+      mgr.registerFactory(prop, new ModuleName(), new ModuleName());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("ModuleName");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        ModuleNameComp init = new ModuleNameComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/AIST6/src/ModuleNameImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,267 @@
+// -*- Java -*-
+/*!
+ * @file  ModuleNameImpl.java
+ * @brief ModuleDescription
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.util.IntegerHolder;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class ModuleNameImpl
+ * @brief ModuleDescription
+ *
+ */
+public class ModuleNameImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public ModuleNameImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+    }
+
+    /*!
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+        bindParameter("int_param0", m_int_param0, "0");
+        bindParameter("vector_param", m_vector_param, "1.0,2.0,3.0");
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+    /*!
+     * 
+     * - Name:  int_param0
+     * - DefaultValue: 0
+     */
+    protected IntegerHolder m_int_param0 = new IntegerHolder();
+    /*!
+     * 
+     * - Name:  vector_param
+     * - DefaultValue: 1.0,2.0,3.0
+     */
+    protected VectorHolder m_vector_param = new VectorHolder();
+	// </rtc-template>
+
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,56 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.3",
+    	    "vendor",            "TA2",
+    	    "category",          "manip2",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "3",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+            // Configuration variables
+            "conf.default.short_param", "0",
+            "conf.default.int_param", "1",
+            "conf.default.long_param", "14",
+            "conf.default.float_param", "0.11",
+            "conf.default.double_param", "4.11",
+            "conf.default.str_param0", "hoge",
+            "conf.default.str_param1", "dara",
+            // Widget
+            // Constraints
+    	    ""
+            };
+//  </rtc-template>
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,89 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+        // Activate manager and register to naming service
+        manager.activateManager();
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/ConfigSetType/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,285 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.util.ShortHolder;
+import jp.go.aist.rtm.RTC.util.IntegerHolder;
+import jp.go.aist.rtm.RTC.util.LongHolder;
+import jp.go.aist.rtm.RTC.util.FloatHolder;
+import jp.go.aist.rtm.RTC.util.DoubleHolder;
+import jp.go.aist.rtm.RTC.util.StringHolder;
+import RTC.ReturnCode_t;
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+    }
+    /*!
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+        bindParameter("short_param", m_short_param, "0");
+        bindParameter("int_param", m_int_param, "1");
+        bindParameter("long_param", m_long_param, "14");
+        bindParameter("float_param", m_float_param, "0.11");
+        bindParameter("double_param", m_double_param, "4.11");
+        bindParameter("str_param0", m_str_param0, "hoge");
+        bindParameter("str_param1", m_str_param1, "dara");
+        return super.onInitialize();
+    }
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+    /*!
+     * 
+     * - Name:  short_param
+     * - DefaultValue: 0
+     */
+    protected ShortHolder m_short_param = new ShortHolder();
+    /*!
+     * 
+     * - Name:  int_param
+     * - DefaultValue: 1
+     */
+    protected IntegerHolder m_int_param = new IntegerHolder();
+    /*!
+     * 
+     * - Name:  long_param
+     * - DefaultValue: 14
+     */
+    protected LongHolder m_long_param = new LongHolder();
+    /*!
+     * 
+     * - Name:  float_param
+     * - DefaultValue: 0.11
+     */
+    protected FloatHolder m_float_param = new FloatHolder();
+    /*!
+     * 
+     * - Name:  double_param
+     * - DefaultValue: 4.11
+     */
+    protected DoubleHolder m_double_param = new DoubleHolder();
+    /*!
+     * 
+     * - Name:  str_param0
+     * - DefaultValue: hoge
+     */
+    protected StringHolder m_str_param0 = new StringHolder();
+    /*!
+     * 
+     * - Name:  str_param1
+     * - DefaultValue: dara
+     */
+    protected StringHolder m_str_param1 = new StringHolder();
+	// </rtc-template>
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,56 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.3",
+    	    "vendor",            "TA2",
+    	    "category",          "manip2",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "3",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+            // Configuration variables
+            "conf.default.int_param0", "0",
+            // Widget
+            // Constraints
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset1/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,261 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.util.IntegerHolder;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+
+    }
+
+    /*!
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+        bindParameter("int_param0", m_int_param0, "0");
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+    /*!
+     * 
+     * - Name:  int_param0
+     * - DefaultValue: 0
+     */
+    protected IntegerHolder m_int_param0 = new IntegerHolder();
+	// </rtc-template>
+
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,57 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.3",
+    	    "vendor",            "TA2",
+    	    "category",          "manip2",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "3",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+            // Configuration variables
+            "conf.default.int_param0", "0",
+            "conf.default.int_param1", "1",
+            // Widget
+            // Constraints
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset2/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,268 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.util.IntegerHolder;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+
+    }
+
+    /*!
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+        bindParameter("int_param0", m_int_param0, "0");
+        bindParameter("int_param1", m_int_param1, "1");
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+    /*!
+     * 
+     * - Name:  int_param0
+     * - DefaultValue: 0
+     */
+    protected IntegerHolder m_int_param0 = new IntegerHolder();
+    /*!
+     * 
+     * - Name:  int_param1
+     * - DefaultValue: 1
+     */
+    protected IntegerHolder m_int_param1 = new IntegerHolder();
+	// </rtc-template>
+
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,60 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.3",
+    	    "vendor",            "TA2",
+    	    "category",          "manip2",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "3",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+            // Configuration variables
+            "conf.default.int_param0", "0",
+            "conf.default.int_param1", "1",
+            "conf.default.double_param0", "0.11",
+            "conf.default.str_param0", "hoge",
+            "conf.default.str_param1", "dara",
+            // Widget
+            // Constraints
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset3/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,290 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.util.IntegerHolder;
+import jp.go.aist.rtm.RTC.util.DoubleHolder;
+import jp.go.aist.rtm.RTC.util.StringHolder;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+    }
+
+    /*!
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+        bindParameter("int_param0", m_int_param0, "0");
+        bindParameter("int_param1", m_int_param1, "1");
+        bindParameter("double_param0", m_double_param0, "0.11");
+        bindParameter("str_param0", m_str_param0, "hoge");
+        bindParameter("str_param1", m_str_param1, "dara");
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+    /*!
+     * 
+     * - Name:  int_param0
+     * - DefaultValue: 0
+     */
+    protected IntegerHolder m_int_param0 = new IntegerHolder();
+    /*!
+     * 
+     * - Name:  int_param1
+     * - DefaultValue: 1
+     */
+    protected IntegerHolder m_int_param1 = new IntegerHolder();
+    /*!
+     * 
+     * - Name:  double_param0
+     * - DefaultValue: 0.11
+     */
+    protected DoubleHolder m_double_param0 = new DoubleHolder();
+    /*!
+     * 
+     * - Name:  str_param0
+     * - DefaultValue: hoge
+     */
+    protected StringHolder m_str_param0 = new StringHolder();
+    /*!
+     * 
+     * - Name:  str_param1
+     * - DefaultValue: dara
+     */
+    protected StringHolder m_str_param1 = new StringHolder();
+	// </rtc-template>
+
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,54 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.3",
+    	    "vendor",            "TA2",
+    	    "category",          "manip2",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "3",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+            // Configuration variables
+            "conf.default.int_param0", "0",
+            "conf.default.int_param1", "1",
+            "conf.default.double_param0", "0.11",
+            "conf.default.str_param0", "日本語",
+            "conf.default.str_param1", "dara",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,95 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/ConfigSet/configset4/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,151 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.util.IntegerHolder;
+import jp.go.aist.rtm.RTC.util.DoubleHolder;
+import jp.go.aist.rtm.RTC.util.StringHolder;
+import RTC.ReturnCode_t;
+
+public class fooImpl extends DataFlowComponentBase {
+
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+    }
+
+    // The initialize action (on CREATED->ALIVE transition)
+    // formaer rtc_init_entry() 
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+        bindParameter("int_param0", m_int_param0, "0");
+        bindParameter("int_param1", m_int_param1, "1");
+        bindParameter("double_param0", m_double_param0, "0.11");
+        bindParameter("str_param0", m_str_param0, "日本語");
+        bindParameter("str_param1", m_str_param1, "dara");
+        return super.onInitialize();
+    }
+    // The finalize action (on ALIVE->END transition)
+    // formaer rtc_exiting_entry()
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+    //
+    // The startup action when ExecutionContext startup
+    // former rtc_starting_entry()
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+    //
+    // The shutdown action when ExecutionContext stop
+    // former rtc_stopping_entry()
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+    //
+    // The activated action (Active state entry action)
+    // former rtc_active_entry()
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+    //
+    // The deactivated action (Active state exit action)
+    // former rtc_active_exit()
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+    //
+    // The execution action that is invoked periodically
+    // former rtc_active_do()
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+    //
+    // The aborting action when main logic error occurred.
+    // former rtc_aborting_entry()
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+    //
+    // The error action in ERROR state
+    // former rtc_error_do()
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+    //
+    // The reset action that is invoked resetting
+    // This is same but different the former rtc_init_entry()
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+//  
+    // The state update action that is invoked after onExecute() action
+    // no corresponding operation exists in OpenRTm-aist-0.2.0
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+    //
+    // The action that is invoked when execution context's rate is changed
+    // no corresponding operation exists in OpenRTm-aist-0.2.0
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+    protected IntegerHolder m_int_param0 = new IntegerHolder();
+    protected IntegerHolder m_int_param1 = new IntegerHolder();
+    protected DoubleHolder m_double_param0 = new DoubleHolder();
+    protected StringHolder m_str_param0 = new StringHolder();
+    protected StringHolder m_str_param1 = new StringHolder();
+	// </rtc-template>
+
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,33 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/DAQService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief test module
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "test module",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "sample",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "2",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ConMulti/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,303 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief test module
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief test module
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_in1_val = new TimedShort();
+        m_in1 = new DataRef<TimedShort>(m_in1_val);
+        m_in1In = new InPort<TimedShort>("in1", m_in1);
+        m_out1_val = new TimedLong();
+        m_out1 = new DataRef<TimedLong>(m_out1_val);
+        m_out1Out = new OutPort<TimedLong>("out1", m_out1);
+        m_MyConProPort = new CorbaPort("MyConPro");
+        m_MyConPro2Port = new CorbaPort("MyConPro2");
+        // </rtc-template>
+
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("in1", m_in1In);
+        
+        // Set OutPort buffer
+        addOutPort("out1", m_out1Out);
+        
+        // Set service consumers to Ports
+        m_MyConProPort.registerConsumer("myservice0", "MyService", m_myservice0Base);
+        m_MyConPro2Port.registerConsumer("myservice2", "DAQService", m_myservice2Base);
+        
+        // Set CORBA Service Ports
+        addPort(m_MyConProPort);
+        addPort(m_MyConPro2Port);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_in1_val;
+    protected DataRef<TimedShort> m_in1;
+    /*!
+     */
+    protected InPort<TimedShort> m_in1In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_out1_val;
+    protected DataRef<TimedLong> m_out1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_out1Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MyConProPort;
+    /*!
+     */
+    protected CorbaPort m_MyConPro2Port;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyService> m_myservice0Base = new CorbaConsumer<MyService>(MyService.class);
+    /*!
+     */
+    protected MyService m_myservice0;
+    protected CorbaConsumer<DAQService> m_myservice2Base = new CorbaConsumer<DAQService>(DAQService.class);
+    /*!
+     */
+    protected DAQService m_myservice2;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService2.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService2.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/MyService2.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService2
+{
+  void setKpGain(in float gainkp);
+  float getKpGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService2.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService2.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/MyService2.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService2
+{
+  void setKpGain(in float gainkp);
+  float getKpGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,36 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService2.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/DAQService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyService2SVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyService2SVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyService2SVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyService2SVC_impl.java
+ * @brief Service implementation code of MyService2.idl
+ *
+ */
+/*!
+ * @class MyService2SVC_impl
+ * Example class implementing IDL interface MyService2
+ */
+public class MyService2SVC_impl extends MyService2POA{
+    
+    public MyService2SVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setKpGain(float gainkp) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setKpGain(float gainkp)>"
+    }
+
+    public float getKpGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getKpGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief test module
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "test module",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "sample",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "2",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProConMulti/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,333 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief test module
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief test module
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_in1_val = new TimedShort();
+        m_in1 = new DataRef<TimedShort>(m_in1_val);
+        m_in1In = new InPort<TimedShort>("in1", m_in1);
+        m_out1_val = new TimedLong();
+        m_out1 = new DataRef<TimedLong>(m_out1_val);
+        m_out1Out = new OutPort<TimedLong>("out1", m_out1);
+        m_MySVProPort = new CorbaPort("MySVPro");
+        m_MySVPro2Port = new CorbaPort("MySVPro2");
+        m_MyConProPort = new CorbaPort("MyConPro");
+        m_MyConPro2Port = new CorbaPort("MyConPro2");
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("in1", m_in1In);
+        
+        // Set OutPort buffer
+        addOutPort("out1", m_out1Out);
+        
+        // Set service provider to Ports
+        try {
+        	m_MySVProPort.registerProvider("myserviceP1", "MyService", m_myserviceP1);
+        	m_MySVPro2Port.registerProvider("myserviceP2", "MyService2", m_myserviceP2);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_MyConProPort.registerConsumer("myservice0", "MyService", m_myservice0Base);
+        m_MyConPro2Port.registerConsumer("myservice2", "DAQService", m_myservice2Base);
+        
+        // Set CORBA Service Ports
+        addPort(m_MySVProPort);
+        addPort(m_MySVPro2Port);
+        addPort(m_MyConProPort);
+        addPort(m_MyConPro2Port);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_in1_val;
+    protected DataRef<TimedShort> m_in1;
+    /*!
+     */
+    protected InPort<TimedShort> m_in1In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_out1_val;
+    protected DataRef<TimedLong> m_out1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_out1Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MySVProPort;
+    /*!
+     */
+    protected CorbaPort m_MySVPro2Port;
+    /*!
+     */
+    protected CorbaPort m_MyConProPort;
+    /*!
+     */
+    protected CorbaPort m_MyConPro2Port;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_myserviceP1 = new MyServiceSVC_impl();
+    /*!
+     */
+    protected MyService2SVC_impl m_myserviceP2 = new MyService2SVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyService> m_myservice0Base = new CorbaConsumer<MyService>(MyService.class);
+    /*!
+     */
+    protected MyService m_myservice0;
+    protected CorbaConsumer<DAQService> m_myservice2Base = new CorbaConsumer<DAQService>(DAQService.class);
+    /*!
+     */
+    protected DAQService m_myservice2;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,33 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/DAQService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/DAQServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/DAQServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/DAQServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,33 @@
+// -*-Java-*-
+/*!
+ * @file  DAQServiceSVC_impl.java
+ * @brief Service implementation code of DAQService.idl
+ *
+ */
+/*!
+ * @class DAQServiceSVC_impl
+ * Example class implementing IDL interface DAQService
+ */
+public class DAQServiceSVC_impl extends DAQServicePOA{
+    
+    public DAQServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public int setCommand(int com, double par) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <int setCommand(int com, double par)>"
+        return 0;
+    }
+
+    public short getCommand() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <short getCommand()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief test module
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "test module",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "sample",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "2",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/Multi/ProMulti/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,313 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief test module
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief test module
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_in1_val = new TimedShort();
+        m_in1 = new DataRef<TimedShort>(m_in1_val);
+        m_in1In = new InPort<TimedShort>("in1", m_in1);
+        m_out1_val = new TimedLong();
+        m_out1 = new DataRef<TimedLong>(m_out1_val);
+        m_out1Out = new OutPort<TimedLong>("out1", m_out1);
+        m_MySVProPort = new CorbaPort("MySVPro");
+        m_MySVPro2Port = new CorbaPort("MySVPro2");
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("in1", m_in1In);
+        
+        // Set OutPort buffer
+        addOutPort("out1", m_out1Out);
+        
+        // Set service provider to Ports
+        try {
+        	m_MySVProPort.registerProvider("myservice0", "MyService", m_myservice0);
+        	m_MySVPro2Port.registerProvider("myservice2", "DAQService", m_myservice2);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        
+        // Set CORBA Service Ports
+        addPort(m_MySVProPort);
+        addPort(m_MySVPro2Port);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_in1_val;
+    protected DataRef<TimedShort> m_in1;
+    /*!
+     */
+    protected InPort<TimedShort> m_in1In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_out1_val;
+    protected DataRef<TimedLong> m_out1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_out1Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MySVProPort;
+    /*!
+     */
+    protected CorbaPort m_MySVPro2Port;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_myservice0 = new MyServiceSVC_impl();
+    /*!
+     */
+    protected DAQServiceSVC_impl m_myservice2 = new DAQServiceSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:/Program Files (x86)/OpenRTM-aist/1.1//jar/OpenRTM-aist-1.1.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport1/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,262 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:/Program Files (x86)/OpenRTM-aist/1.1//jar/OpenRTM-aist-1.1.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/inport2/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,273 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        m_InP2_val = new TimedLong();
+        m_InP2 = new DataRef<TimedLong>(m_InP2_val);
+        m_InP2In = new InPort<TimedLong>("InP2", m_InP2);
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        addInPort("InP2", m_InP2In);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+
+    protected TimedLong m_InP2_val;
+    protected DataRef<TimedLong> m_InP2;
+    /*!
+     */
+    protected InPort<TimedLong> m_InP2In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:/Program Files (x86)/OpenRTM-aist/1.1//jar/OpenRTM-aist-1.1.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/name/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,247 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+//        return super.onInitialize();
+//    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:/Program Files (x86)/OpenRTM-aist/1.1//jar/OpenRTM-aist-1.1.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport1/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,286 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        m_InP2_val = new TimedLong();
+        m_InP2 = new DataRef<TimedLong>(m_InP2_val);
+        m_InP2In = new InPort<TimedLong>("InP2", m_InP2);
+        m_OutP1_val = new TimedLong();
+        m_OutP1 = new DataRef<TimedLong>(m_OutP1_val);
+        m_OutP1Out = new OutPort<TimedLong>("OutP1", m_OutP1);
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        addInPort("InP2", m_InP2In);
+        
+        // Set OutPort buffer
+        addOutPort("OutP1", m_OutP1Out);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+
+    protected TimedLong m_InP2_val;
+    protected DataRef<TimedLong> m_InP2;
+    /*!
+     */
+    protected InPort<TimedLong> m_InP2In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_OutP1_val;
+    protected DataRef<TimedLong> m_OutP1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_OutP1Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:/Program Files (x86)/OpenRTM-aist/1.1//jar/OpenRTM-aist-1.1.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,28 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+
+
+	<target name="compile" depends="mkdir">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/outport2/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,297 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import RTC.TimedFloat;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        m_InP2_val = new TimedLong();
+        m_InP2 = new DataRef<TimedLong>(m_InP2_val);
+        m_InP2In = new InPort<TimedLong>("InP2", m_InP2);
+        m_OutP1_val = new TimedLong();
+        m_OutP1 = new DataRef<TimedLong>(m_OutP1_val);
+        m_OutP1Out = new OutPort<TimedLong>("OutP1", m_OutP1);
+        m_OutP2_val = new TimedFloat();
+        m_OutP2 = new DataRef<TimedFloat>(m_OutP2_val);
+        m_OutP2Out = new OutPort<TimedFloat>("OutP2", m_OutP2);
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        addInPort("InP2", m_InP2In);
+        
+        // Set OutPort buffer
+        addOutPort("OutP1", m_OutP1Out);
+        addOutPort("OutP2", m_OutP2Out);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+
+    protected TimedLong m_InP2_val;
+    protected DataRef<TimedLong> m_InP2;
+    /*!
+     */
+    protected InPort<TimedLong> m_InP2In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_OutP1_val;
+    protected DataRef<TimedLong> m_OutP1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_OutP1Out;
+
+    protected TimedFloat m_OutP2_val;
+    protected DataRef<TimedFloat> m_OutP2;
+    /*!
+     */
+    protected OutPort<TimedFloat> m_OutP2Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service1/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,324 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import RTC.TimedFloat;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        m_InP2_val = new TimedLong();
+        m_InP2 = new DataRef<TimedLong>(m_InP2_val);
+        m_InP2In = new InPort<TimedLong>("InP2", m_InP2);
+        m_OutP1_val = new TimedLong();
+        m_OutP1 = new DataRef<TimedLong>(m_OutP1_val);
+        m_OutP1Out = new OutPort<TimedLong>("OutP1", m_OutP1);
+        m_OutP2_val = new TimedFloat();
+        m_OutP2 = new DataRef<TimedFloat>(m_OutP2_val);
+        m_OutP2Out = new OutPort<TimedFloat>("OutP2", m_OutP2);
+        m_svPortPort = new CorbaPort("svPort");
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        addInPort("InP2", m_InP2In);
+        
+        // Set OutPort buffer
+        addOutPort("OutP1", m_OutP1Out);
+        addOutPort("OutP2", m_OutP2Out);
+        
+        // Set service provider to Ports
+        try {
+        	m_svPortPort.registerProvider("acc", "MyService", m_acc);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        
+        // Set CORBA Service Ports
+        addPort(m_svPortPort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+
+    protected TimedLong m_InP2_val;
+    protected DataRef<TimedLong> m_InP2;
+    /*!
+     */
+    protected InPort<TimedLong> m_InP2In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_OutP1_val;
+    protected DataRef<TimedLong> m_OutP1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_OutP1Out;
+
+    protected TimedFloat m_OutP2_val;
+    protected DataRef<TimedFloat> m_OutP2;
+    /*!
+     */
+    protected OutPort<TimedFloat> m_OutP2Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_svPortPort;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_acc = new MyServiceSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,43 @@
+// -*- IDL -*-
+/*!
+ * @file RTCService.idl
+ * @brief RTComponent サービスインターフェース
+ * @date $Date: 2007/12/25 05:43:02 $
+ * @author Noriaki Ando <n-ando at aist.go.jp>
+ *
+ * Copyright (C) 2005
+ *     Task-intelligence Research Group,
+ *     Intelligent Systems Research Institute,
+ *     National Institute of
+ *         Advanced Industrial Science and Technology (AIST), Japan
+ *
+ *     All rights reserved.
+ *
+ * $Id: DAQService.idl,v 1.1 2007/12/25 05:43:02 tsakamoto Exp $
+ *
+ */
+
+/*
+ * $Log: DAQService.idl,v $
+ * Revision 1.1  2007/12/25 05:43:02  tsakamoto
+ * *** empty log message ***
+ *
+ * Revision 1.1  2007/03/14 12:14:35  tsakamoto
+ * 属性生成版
+ *
+ * Revision 1.1  2005/09/07 05:06:13  n-ando
+ * RTComponent's service management feature was added.
+ *
+ */
+
+#ifndef __RTCService_idl__
+#define __RTCService_idl__
+
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+  unsigned long checkDone();
+  void setDone();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,33 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/DAQService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/base/service2/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,335 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import RTC.TimedShort;
+import RTC.TimedLong;
+import RTC.TimedFloat;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        m_InP2_val = new TimedLong();
+        m_InP2 = new DataRef<TimedLong>(m_InP2_val);
+        m_InP2In = new InPort<TimedLong>("InP2", m_InP2);
+        m_OutP1_val = new TimedLong();
+        m_OutP1 = new DataRef<TimedLong>(m_OutP1_val);
+        m_OutP1Out = new OutPort<TimedLong>("OutP1", m_OutP1);
+        m_OutP2_val = new TimedFloat();
+        m_OutP2 = new DataRef<TimedFloat>(m_OutP2_val);
+        m_OutP2Out = new OutPort<TimedFloat>("OutP2", m_OutP2);
+        m_svPortPort = new CorbaPort("svPort");
+        m_cmPortPort = new CorbaPort("cmPort");
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        addInPort("InP2", m_InP2In);
+        
+        // Set OutPort buffer
+        addOutPort("OutP1", m_OutP1Out);
+        addOutPort("OutP2", m_OutP2Out);
+        
+        // Set service provider to Ports
+        try {
+        	m_svPortPort.registerProvider("acc", "MyService", m_acc);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_cmPortPort.registerConsumer("rate", "DAQService", m_rateBase);
+        
+        // Set CORBA Service Ports
+        addPort(m_svPortPort);
+        addPort(m_cmPortPort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+
+    protected TimedLong m_InP2_val;
+    protected DataRef<TimedLong> m_InP2;
+    /*!
+     */
+    protected InPort<TimedLong> m_InP2In;
+
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedLong m_OutP1_val;
+    protected DataRef<TimedLong> m_OutP1;
+    /*!
+     */
+    protected OutPort<TimedLong> m_OutP1Out;
+
+    protected TimedFloat m_OutP2_val;
+    protected DataRef<TimedFloat> m_OutP2;
+    /*!
+     */
+    protected OutPort<TimedFloat> m_OutP2Out;
+
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_svPortPort;
+    /*!
+     */
+    protected CorbaPort m_cmPortPort;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_acc = new MyServiceSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<DAQService> m_rateBase = new CorbaConsumer<DAQService>(DAQService.class);
+    /*!
+     */
+    protected DAQService m_rate;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/CMakeLists.txt
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/CMakeLists.txt	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/CMakeLists.txt	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,175 @@
+cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
+project(foo Java)
+set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true)
+set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake_modules")
+set(LINUX_PACKAGE_GENERATOR "DEB")
+#set(LINUX_PACKAGE_GENERATOR "RPM")
+# component settings
+set(RTC_NAME "${PROJECT_NAME}")
+set(RTC_VERSION "1.0.1")
+set(RTC_VERSION_MAJOR "1")
+set(RTC_VERSION_MINOR "0")
+set(RTC_VERSION_PATCH "1")
+set(RTC_LANG "java")
+set(RTC_DESCRIPTION "MDesc")
+set(RTC_VENDOR "TA")
+set(RTC_MAINTAINER "author at example.com")
+string(TOLOWER ${RTC_NAME} PACKAGE_NAME)
+set(PACKAGE_VERSION "${RTC_VERSION_MAJOR}.${RTC_VERSION_MINOR}.${RTC_VERSION_PATCH}")
+set(IDL_FILES ""
+              MyService.idl
+              DAQService.idl
+)
+set(OTHER_SRCS CMakeLists.txt Doxyfile.in
+               RTC.xml foo.conf rtc.conf)
+# check OpenRTM installed
+find_package(OpenRTMJava REQUIRED)
+# check doxygen installed
+find_package(Doxygen)
+if(DOXYGEN_FOUND STREQUAL "NO")
+    message(FATAL_ERROR "Doxygen not found.")
+endif()
+# Java IDL settings
+get_filename_component(CMAKE_Java_HOME ${CMAKE_Java_COMPILER} PATH)
+set(CMAKE_Java_IDLJ ${CMAKE_Java_HOME}/idlj)
+if(WIN32)
+    # add command path
+    set($ENV{PATH} $ENV{PATH} "${OPENRTM_DIR}/bin")
+    # set install path prefix
+    set(CMAKE_INSTALL_PREFIX "${OPENRTM_DIR}")
+    set(INSTALL_PREFIX "components/${RTC_LANG}/${PACKAGE_NAME}${PACKAGE_VERSION}")
+else()
+    # add command path
+    set($ENV{PATH} $ENV{PATH} "${OPENRTM_DIR}/bin")
+    # set install path prefix
+    set(CMAKE_INSTALL_PREFIX "/usr")
+    # set(CMAKE_INSTALL_PREFIX "${OPENRTM_DIR}")
+    set(OPENRTM_SHARE_PREFIX "share/openrtm-${OPENRTM_VERSION_MAJOR}.${OPENRTM_VERSION_MINOR}")
+    set(INSTALL_PREFIX "${OPENRTM_SHARE_PREFIX}/components/${RTC_LANG}/${PACKAGE_NAME}${PACKAGE_VERSION}")
+endif()
+# add uninstall target
+configure_file(
+    "${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_uninstall.cmake.in"
+    "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(uninstall COMMAND 
+    ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
+# add compile target
+set(JAVAC_SOURCE_DIRS ${PROJECT_SOURCE_DIR}/src ${PROJECT_BINARY_DIR}/src)
+set(JAVAC_DEST_DIR ${PROJECT_BINARY_DIR}/bin)
+set(JAVAC_CLASSPATH "${OPENRTM_CLASSPATH}")
+add_custom_target(idlcompile)
+foreach(idl ${IDL_FILES})
+    add_custom_command(TARGET idlcompile PRE_BUILD
+        COMMAND ${CMAKE_Java_IDLJ} -td src -fall "${PROJECT_SOURCE_DIR}/${idl}")
+endforeach()
+configure_file(
+    "${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_javacompile.cmake.in"
+    "${CMAKE_CURRENT_BINARY_DIR}/cmake_javacompile.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(compile ALL
+    COMMAND ${CMAKE_COMMAND} -E make_directory bin
+    COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_javacompile.cmake)
+add_dependencies(compile idlcompile)
+if(UNIX)
+    add_custom_command(TARGET compile
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.bat ${RTC_NAME}.bat
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.sh ${RTC_NAME}.sh.dos
+        COMMAND sed -e 's,\r,,' ${RTC_NAME}.sh.dos > ${RTC_NAME}.sh)
+else()
+    add_custom_command(TARGET compile
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.bat ${RTC_NAME}.bat
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.sh ${RTC_NAME}.sh)
+endif()
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES bin)
+install(FILES RTC.xml DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RTC_NAME}.sh DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RTC_NAME}.bat DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+# target settings for document
+configure_file("${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in"
+               "${CMAKE_CURRENT_BINARY_DIR}/Doxyfile")
+add_custom_target(doxygen COMMAND
+                  ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES doc)
+get_target_property(DOC_TARGET doc TYPE)
+if(NOT DOC_TARGET)
+    add_custom_target(doc)
+endif()
+add_dependencies(doc doxygen)
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "documents")
+# install source files
+install(DIRECTORY src
+        DESTINATION "${INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+install(FILES ${IDL_FILES} ${RTC_NAME}.sh ${RTC_NAME}.bat ${OTHER_SRCS}
+        DESTINATION "${INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+install(DIRECTORY cmake_modules cpack_resources
+        DESTINATION "${INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+# package settings
+set(CPACK_PACKAGE_NAME "${RTC_NAME}")
+set(CPACK_PACKAGE_VERSION_MAJOR "${RTC_VERSION_MAJOR}")
+set(CPACK_PACKAGE_VERSION_MINOR "${RTC_VERSION_MINOR}")
+set(CPACK_PACKAGE_VERSION_PATCH "${RTC_VERSION_PATCH}")
+set(CPACK_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
+set(CPACK_PACKAGE_VENDOR "${RTC_VENDOR}")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${RTC_DESCRIPTION}")
+set(CPACK_PACKAGE_CONTACT "${RTC_MAINTAINER}")
+set(CPACK_RESOURCE_FILE_LICENSE
+    "${CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/License.txt")
+set(CPACK_PACKAGE_DESCRIPTION_FILE
+    "${CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/Description.txt")
+set(CPACK_COMPONENTS_ALL applications documents sources)
+set(CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME "Applications")
+set(CPACK_COMPONENT_APPLICATIONS_DESCRIPTION "RT-Component applications")
+set(CPACK_COMPONENT_APPLICATIONS_DISABLED FALSE)
+set(CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME "Documents")
+set(CPACK_COMPONENT_DOCUMENTS_DESCRIPTION "RT-Component documents")
+set(CPACK_COMPONENT_DOCUMENTS_DISABLED TRUE)
+set(CPACK_COMPONENT_SOURCES_DISPLAY_NAME "Source files")
+set(CPACK_COMPONENT_SOURCES_DESCRIPTION "RT-Component source files")
+set(CPACK_COMPONENT_SOURCES_DISABLED TRUE)
+if(WIN32)
+    set(CPACK_GENERATOR "WIX")
+    # Windows WiX package settings
+    set(CPACK_WIX_XSL "@CMAKE_CURRENT_BINARY_DIR@/wix.xsl")
+    set(CPACK_WIX_LANG "ja-jp")
+    set(CPACK_RESOURCE_FILE_LICENSE
+        "@CMAKE_CURRENT_SOURCE_DIR@/cpack_resources/License.rtf")
+    configure_file(
+        "${CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/wix.xsl.in"
+        "${CMAKE_CURRENT_BINARY_DIR}/wix.xsl" @ONLY)
+    set(CPACK_PACKAGE_FILE_NAME
+        "rtc${OPENRTM_VERSION}-${PACKAGE_NAME}${PACKAGE_VERSION}")
+else()
+    set(CPACK_GENERATOR "${LINUX_PACKAGE_GENERATOR}")
+    if(CPACK_GENERATOR STREQUAL "DEB")
+        # Linux Debian package settings
+        set(CPACK_DEBIAN_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION}-1")
+        set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_DEBIAN_PACKAGE_SECTION "main")
+        set(CPACK_DEBIAN_PACKAGE_PRIORITY  "extra")
+        set(CPACK_DEBIAN_PACKAGE_DEPENDS "openrtm-aist (>= 1.0.0)")
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${OPENRTM_VERSION}-${PACKAGE_NAME}_${CPACK_DEBIAN_PACKAGE_VERSION}_${CPACK_DEBIAN_PACKAGE_ARCHITECTURE}")
+    elseif(CPACK_GENERATOR STREQUAL "RPM")
+        # Linux RPM package settings
+        set(CPACK_RPM_PACKAGE_RELEASE "1.fc10")
+        set(CPACK_RPM_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_RPM_PACKAGE_GROUP "Development/Libraries")
+        set(CPACK_RPM_PACKAGE_LICENSE "LGPL")
+        set(CPACK_RPM_PACKAGE_REQUIRES "OpenRTM-aist >= 1.0.0")
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${OPENRTM_VERSION}-${PACKAGE_NAME}-${PACKAGE_VERSION}-${CPACK_RPM_PACKAGE_RELEASE}.${CPACK_RPM_PACKAGE_ARCHITECTURE}")
+    endif()
+endif()
+message(STATUS "Package type: ${CPACK_GENERATOR}")
+message(STATUS "Package name: ${CPACK_PACKAGE_FILE_NAME}")
+include(CPack)

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,40 @@
+// -*- IDL -*-
+/*!
+ * @file RTCService.idl
+ * @brief RTComponent サービスインターフェース
+ * @date $Date: 2007/03/14 12:14:35 $
+ * @author Noriaki Ando <n-ando at aist.go.jp>
+ *
+ * Copyright (C) 2005
+ *     Task-intelligence Research Group,
+ *     Intelligent Systems Research Institute,
+ *     National Institute of
+ *         Advanced Industrial Science and Technology (AIST), Japan
+ *
+ *     All rights reserved.
+ *
+ * $Id: DAQService.idl,v 1.1 2007/03/14 12:14:35 tsakamoto Exp $
+ *
+ */
+
+/*
+ * $Log: DAQService.idl,v $
+ * Revision 1.1  2007/03/14 12:14:35  tsakamoto
+ * 属性生成版
+ *
+ * Revision 1.1  2005/09/07 05:06:13  n-ando
+ * RTComponent's service management feature was added.
+ *
+ */
+
+#ifndef __RTCService_idl__
+#define __RTCService_idl__
+
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+  unsigned long checkDone();
+  void setDone();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/Doxyfile.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/Doxyfile.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/Doxyfile.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,487 @@
+
+# Project related configuration options
+
+DOXYFILE_ENCODING = UTF-8
+
+PROJECT_NAME = @PACKAGE_NAME@
+
+PROJECT_NUMBER = @PACKAGE_VERSION@
+
+OUTPUT_DIRECTORY = doc
+
+CREATE_SUBDIRS = NO
+
+OUTPUT_LANGUAGE = Japanese
+
+BRIEF_MEMBER_DESC = YES
+
+REPEAT_BRIEF = YES
+
+ABBREVIATE_BRIEF = 
+
+ALWAYS_DETAILED_SEC = NO
+
+INLINE_INHERITED_MEMB = NO
+
+FULL_PATH_NAMES = YES
+
+STRIP_FROM_PATH = 
+
+STRIP_FROM_INC_PATH = 
+
+SHORT_NAMES = NO
+
+JAVADOC_AUTOBRIEF = NO
+
+QT_AUTOBRIEF = NO
+
+MULTILINE_CPP_IS_BRIEF = NO
+
+INHERIT_DOCS = YES
+
+SEPARATE_MEMBER_PAGES = NO
+
+TAB_SIZE = 8
+
+ALIASES = 
+
+OPTIMIZE_OUTPUT_FOR_C = NO
+
+OPTIMIZE_OUTPUT_JAVA = NO
+
+OPTIMIZE_FOR_FORTRAN = NO
+
+OPTIMIZE_OUTPUT_VHDL = NO
+
+EXTENSION_MAPPING = 
+
+BUILTIN_STL_SUPPORT = NO
+
+CPP_CLI_SUPPORT = NO
+
+SIP_SUPPORT = NO
+
+IDL_PROPERTY_SUPPORT = YES
+
+DISTRIBUTE_GROUP_DOC = NO
+
+SUBGROUPING = YES
+
+TYPEDEF_HIDES_STRUCT = NO
+
+SYMBOL_CACHE_SIZE = 0
+
+
+# Build related configuration options
+
+EXTRACT_ALL = NO
+
+EXTRACT_PRIVATE = NO
+
+EXTRACT_STATIC = NO
+
+EXTRACT_LOCAL_CLASSES = YES
+
+EXTRACT_LOCAL_METHODS = NO
+
+EXTRACT_ANON_NSPACES = NO
+
+HIDE_UNDOC_MEMBERS = NO
+
+HIDE_UNDOC_CLASSES = NO
+
+HIDE_FRIEND_COMPOUNDS = NO
+
+HIDE_IN_BODY_DOCS = NO
+
+INTERNAL_DOCS = NO
+
+CASE_SENSE_NAMES = NO
+
+HIDE_SCOPE_NAMES = NO
+
+SHOW_INCLUDE_FILES = YES
+
+FORCE_LOCAL_INCLUDES = NO
+
+INLINE_INFO = YES
+
+SORT_MEMBER_DOCS = YES
+
+SORT_BRIEF_DOCS = NO
+
+SORT_MEMBERS_CTORS_1ST = NO
+
+SORT_GROUP_NAMES = NO
+
+SORT_BY_SCOPE_NAME = YES
+
+GENERATE_TODOLIST = YES
+
+GENERATE_TESTLIST = YES
+
+GENERATE_BUGLIST = YES
+
+GENERATE_DEPRECATEDLIST = YES
+
+ENABLED_SECTIONS = 
+
+MAX_INITIALIZER_LINES = 30
+
+SHOW_USED_FILES = YES
+
+SHOW_DIRECTORIES = NO
+
+SHOW_FILES = YES
+
+SHOW_NAMESPACES = YES
+
+FILE_VERSION_FILTER = 
+
+LAYOUT_FILE = 
+
+
+# configuration options related to warning and progress messages
+
+QUIET = NO
+
+WARNINGS = YES
+
+WARN_IF_UNDOCUMENTED = YES
+
+WARN_IF_DOC_ERROR = YES
+
+WARN_NO_PARAMDOC = NO
+
+WARN_FORMAT = "$file:$line: $text"
+
+WARN_LOGFILE = 
+
+
+# configuration options related to the input files
+
+INPUT = @CMAKE_CURRENT_SOURCE_DIR@
+
+INPUT_ENCODING = UTF-8
+
+FILE_PATTERNS = *.java *.idl
+
+RECURSIVE = YES
+
+EXCLUDE = _CPack_Packages
+
+EXCLUDE_SYMLINKS = NO
+
+EXCLUDE_PATTERNS = .svn .git 
+
+EXCLUDE_SYMBOLS = 
+
+EXAMPLE_PATH = 
+
+EXAMPLE_PATTERNS = 
+
+EXAMPLE_RECURSIVE = NO
+
+IMAGE_PATH = 
+
+INPUT_FILTER = 
+
+FILTER_PATTERNS = 
+
+FILTER_SOURCE_FILES = NO
+
+
+# configuration options related to source browsing
+
+SOURCE_BROWSER = NO
+
+INLINE_SOURCES = NO
+
+STRIP_CODE_COMMENTS = YES
+
+REFERENCED_BY_RELATION = NO
+
+REFERENCES_RELATION = NO
+
+REFERENCES_LINK_SOURCE = YES
+
+USE_HTAGS = NO
+
+VERBATIM_HEADERS = YES
+
+
+# configuration options related to the alphabetical class index
+
+ALPHABETICAL_INDEX = YES
+
+COLS_IN_ALPHA_INDEX = 5
+
+IGNORE_PREFIX = 
+
+
+# configuration options related to the HTML output
+
+GENERATE_HTML = YES
+
+HTML_OUTPUT = html
+
+HTML_FILE_EXTENSION = .html
+
+HTML_HEADER = 
+
+HTML_FOOTER = 
+
+HTML_STYLESHEET = 
+
+HTML_COLORSTYLE_HUE = 220
+
+HTML_COLORSTYLE_SAT = 100
+
+HTML_COLORSTYLE_GAMMA = 80
+
+HTML_TIMESTAMP = YES
+
+HTML_ALIGN_MEMBERS = YES
+
+HTML_DYNAMIC_SECTIONS = NO
+
+GENERATE_DOCSET = NO
+
+DOCSET_FEEDNAME = "Doxygen generated docs"
+
+DOCSET_BUNDLE_ID = org.doxygen.Project
+
+DOCSET_PUBLISHER_ID = org.doxygen.Publisher
+
+DOCSET_PUBLISHER_NAME = Publisher
+
+GENERATE_HTMLHELP = NO
+
+CHM_FILE = 
+
+HHC_LOCATION = 
+
+GENERATE_CHI = NO
+
+CHM_INDEX_ENCODING = 
+
+BINARY_TOC = NO
+
+TOC_EXPAND = NO
+
+GENERATE_QHP = NO
+
+QCH_FILE = 
+
+QHP_NAMESPACE = org.doxygen.Project
+
+QHP_VIRTUAL_FOLDER = doc
+
+QHP_CUST_FILTER_NAME = 
+
+QHP_CUST_FILTER_ATTRS = 
+
+QHP_SECT_FILTER_ATTRS = 
+
+QHG_LOCATION = 
+
+GENERATE_ECLIPSEHELP = NO
+
+ECLIPSE_DOC_ID = org.doxygen.Project
+
+DISABLE_INDEX = NO
+
+ENUM_VALUES_PER_LINE = 4
+
+GENERATE_TREEVIEW = NO
+
+USE_INLINE_TREES = NO
+
+TREEVIEW_WIDTH = 250
+
+EXT_LINKS_IN_WINDOW = NO
+
+FORMULA_FONTSIZE = 10
+
+FORMULA_TRANSPARENT = YES
+
+SEARCHENGINE = YES
+
+SERVER_BASED_SEARCH = NO
+
+
+# configuration options related to the LaTeX output
+
+GENERATE_LATEX = NO
+
+LATEX_OUTPUT = latex
+
+LATEX_CMD_NAME = latex
+
+MAKEINDEX_CMD_NAME = makeindex
+
+COMPACT_LATEX = NO
+
+PAPER_TYPE = a4wide
+
+EXTRA_PACKAGES = 
+
+LATEX_HEADER = 
+
+PDF_HYPERLINKS = YES
+
+USE_PDFLATEX = YES
+
+LATEX_BATCHMODE = NO
+
+LATEX_HIDE_INDICES = NO
+
+LATEX_SOURCE_CODE = NO
+
+
+# configuration options related to the RTF output
+
+GENERATE_RTF = NO
+
+RTF_OUTPUT = rtf
+
+COMPACT_RTF = NO
+
+RTF_HYPERLINKS = NO
+
+RTF_STYLESHEET_FILE = 
+
+RTF_EXTENSIONS_FILE = 
+
+
+# configuration options related to the man page output
+
+GENERATE_MAN = NO
+
+MAN_OUTPUT = man
+
+MAN_EXTENSION = .3
+
+MAN_LINKS = NO
+
+
+# configuration options related to the XML output
+
+GENERATE_XML = NO
+
+XML_OUTPUT = xml
+
+XML_SCHEMA = 
+
+XML_DTD = 
+
+XML_PROGRAMLISTING = YES
+
+
+# configuration options for the AutoGen Definitions output
+
+GENERATE_AUTOGEN_DEF = NO
+
+
+# configuration options related to the Perl module output
+
+GENERATE_PERLMOD = NO
+
+PERLMOD_LATEX = NO
+
+PERLMOD_PRETTY = YES
+
+PERLMOD_MAKEVAR_PREFIX = 
+
+
+# Configuration options related to the preprocessor
+
+ENABLE_PREPROCESSING = YES
+
+MACRO_EXPANSION = NO
+
+EXPAND_ONLY_PREDEF = NO
+
+SEARCH_INCLUDES = YES
+
+INCLUDE_PATH = 
+
+INCLUDE_FILE_PATTERNS = 
+
+PREDEFINED = 
+
+EXPAND_AS_DEFINED = 
+
+SKIP_FUNCTION_MACROS = YES
+
+
+# Configuration::additions related to external references
+
+TAGFILES = 
+
+GENERATE_TAGFILE = 
+
+ALLEXTERNALS = NO
+
+EXTERNAL_GROUPS = YES
+
+PERL_PATH = /usr/bin/perl
+
+
+# Configuration options related to the dot tool
+
+CLASS_DIAGRAMS = YES
+
+MSCGEN_PATH = 
+
+HIDE_UNDOC_RELATIONS = YES
+
+HAVE_DOT = NO
+
+DOT_NUM_THREADS = 0
+
+DOT_FONTNAME = FreeSans.ttf
+
+DOT_FONTSIZE = 10
+
+DOT_FONTPATH = 
+
+CLASS_GRAPH = YES
+
+COLLABORATION_GRAPH = YES
+
+GROUP_GRAPHS = YES
+
+UML_LOOK = YES
+
+TEMPLATE_RELATIONS = NO
+
+INCLUDE_GRAPH = YES
+
+INCLUDED_BY_GRAPH = YES
+
+CALL_GRAPH = NO
+
+CALLER_GRAPH = NO
+
+GRAPHICAL_HIERARCHY = YES
+
+DIRECTORY_GRAPH = YES
+
+DOT_IMAGE_FORMAT = png
+
+DOT_PATH = 
+
+DOTFILE_DIRS = 
+
+DOT_GRAPH_MAX_NODES = 50
+
+MAX_DOT_GRAPH_DEPTH = 0
+
+DOT_TRANSPARENT = NO
+
+DOT_MULTI_TARGETS = NO
+
+GENERATE_LEGEND = YES
+
+DOT_CLEANUP = YES

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,33 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/DAQService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/CPackWIX.cmake
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/CPackWIX.cmake	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/CPackWIX.cmake	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+#=============================================================================
+# Copyright 2007-2009 Kitware, Inc.
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+# (To distributed this file outside of CMake, substitute the full
+#  License text for the above reference.)
+#
+# Fixed for OpenRTM
+#
+IF(CMAKE_BINARY_DIR)
+  MESSAGE(FATAL_ERROR "CPackWIX.cmake may only be used by CPack internally.")
+ENDIF(CMAKE_BINARY_DIR)
+
+IF(NOT CPACK_WIX_XSL OR NOT CPACK_PACKAGE_FILE_NAME OR NOT CPACK_RESOURCE_FILE_LICENSE OR NOT CPACK_PACKAGE_INSTALL_DIRECTORY)
+    MESSAGE(FATAL_ERROR "Variables required CPACK_WIX_XSL, CPACK_PACKAGE_FILE_NAME, CPACK_RESOURCE_FILE_LICENSE, CPACK_PACKAGE_INSTALL_DIRECTORY")
+ENDIF()
+
+IF(NOT CPACK_WIX_LANG)
+    SET(CPACK_WIX_LANG "en-us")
+ENDIF()
+
+# use the package defaults if none exists.
+# for the community.
+#IF ( NOT CPACK_WIX_XSL )
+#	
+#ENDIF( NOT CPACK_WIX_XSL )
+#
+
+IF ( CPACK_WIX_WXS_FILES )
+	# this could probably be a single expression but I'm no regex guru.
+    string(REGEX MATCH "[^/]*$" wix_temp "${CPACK_WIX_WXS_FILES}")
+	string(REGEX REPLACE "[.]wxs" ".wixobj" CPACK_WIX_OBJS "${wix_temp}" )
+ENDIF( CPACK_WIX_WXS_FILES )
+
+FIND_PROGRAM(WIX_EXE_HEAT heat PATHS "$ENV{ProgramFiles}/Windows Installer XML v3/bin")
+FIND_PROGRAM(WIX_EXE_CNDL candle PATHS "$ENV{ProgramFiles}/Windows Installer XML v3/bin")
+FIND_PROGRAM(WIX_EXE_LGHT light PATHS "$ENV{ProgramFiles}/Windows Installer XML v3/bin")
+
+IF( WIX_EXE_HEAT AND WIX_EXE_CNDL AND WIX_EXE_LGHT )
+  SET(CPACK_WIX_HEAT_COMMAND "\"${WIX_EXE_HEAT}\" dir ${CPACK_PACKAGE_FILE_NAME} -ke -g1 -gg -var var.Source -t:${CPACK_WIX_XSL} -out ${CPACK_PACKAGE_FILE_NAME}.wxs")
+  SET(CPACK_WIX_CNDL_COMMAND "\"${WIX_EXE_CNDL}\" -ext WixFirewallExtension -dSource=${CPACK_PACKAGE_FILE_NAME} ${CPACK_PACKAGE_FILE_NAME}.wxs ${CPACK_WIX_WXS_FILES}")
+  SET(CPACK_WIX_LGHT_COMMAND "\"${WIX_EXE_LGHT}\" -ext WixFirewallExtension -ext WixUIExtension -cultures:${CPACK_WIX_LANG} -out ${CPACK_PACKAGE_FILE_NAME}.msi ${CPACK_PACKAGE_FILE_NAME}.wixobj ${CPACK_WIX_OBJS}")
+ELSE()
+  MESSAGE(FATAL_ERROR "Can not find Wix Executables.")
+ENDIF()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/FindOpenRTMJava.cmake
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/FindOpenRTMJava.cmake	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/FindOpenRTMJava.cmake	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,70 @@
+set(OPENRTM_FOUND FALSE)
+if(UNIX)
+    # OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT $ENV{RTM_JAVA_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "$ENV{RTM_JAVA_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+    # OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${OPENRTM_DIR}/jar" "${OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+    if("${_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${_vers}")
+        string(REGEX REPLACE "\\.jar$" "" _vers "${_vers}")
+        set(OPENRTM_VERSION "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${_vers}")
+    endif()
+    file(GLOB _jars "${OPENRTM_DIR}/jar/*.jar")
+    string(REPLACE ";" ":" OPENRTM_CLASSPATH "${_jars}")
+endif(UNIX)
+if(WIN32)
+    # OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT $ENV{RTM_JAVA_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "$ENV{RTM_JAVA_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+    # OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${OPENRTM_DIR}/jar" "${OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+    if("${_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${_vers}")
+        string(REGEX REPLACE "\\.jar$" "" _vers "${_vers}")
+        set(OPENRTM_VERSION "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${_vers}")
+    endif()
+    file(GLOB _jars "${OPENRTM_DIR}/jar/*.jar")
+    set(OPENRTM_CLASSPATH "${_jars}")
+endif(WIN32)
+message(STATUS "FindOpenRTMJava setup done.")
+message(STATUS "  OPENRTM_DIR=${OPENRTM_DIR}")
+message(STATUS "  OPENRTM_VERSION=${OPENRTM_VERSION}")
+message(STATUS "  OPENRTM_VERSION_MAJOR=${OPENRTM_VERSION_MAJOR}")
+message(STATUS "  OPENRTM_VERSION_MINOR=${OPENRTM_VERSION_MINOR}")
+message(STATUS "  OPENRTM_VERSION_PATCH=${OPENRTM_VERSION_PATCH}")
+message(STATUS "  OPENRTM_CLASSPATH=${OPENRTM_CLASSPATH}")

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_javacompile.cmake.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_javacompile.cmake.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_javacompile.cmake.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,41 @@
+include("@PROJECT_BINARY_DIR@/CMakeFiles/CMakeJavaCompiler.cmake")
+set(_srcdir @JAVAC_SOURCE_DIRS@)
+set(_destdir "@JAVAC_DEST_DIR@")
+set(_classpath "@JAVAC_CLASSPATH@")
+function(__java_copy_file src dest)
+    exec_program("${CMAKE_COMMAND} -E copy_if_different \"${src}\" \"${dest}\""
+        OUTPUT_VARIABLE _out
+        RETURN_VALUE _retval)
+    message(STATUS "Copying \"${src}\" to the build directory")
+    message(STATUS ${_out})
+    if(NOT "${_retval}" STREQUAL 0)
+        message(FATAL_ERROR "Problem when copying \"${src}\"")
+    endif()
+endfunction()
+set(_sources)
+foreach(_dir ${_srcdir})
+    set(_files)
+    file(GLOB_RECURSE _globs RELATIVE "${_dir}" "${_dir}/*")
+    foreach(_file ${_globs})
+        get_filename_component(_file_ext "${_file}" EXT)
+        if(_file MATCHES "/.svn/")
+        elseif(_file_ext MATCHES ".java$")
+            list(APPEND _sources "${_dir}/${_file}")
+        else()
+            __java_copy_file("${_dir}/${_file}" "${_destdir}/${_file}")
+        endif()
+    endforeach()
+endforeach()
+message(STATUS "Compiling")
+foreach(f ${_sources})
+    message(STATUS "    ${f}")
+endforeach()
+string(REPLACE ";" " " _sources "${_sources}")
+exec_program("${CMAKE_Java_COMPILER}"
+    ARGS "-d ${_destdir} -cp \"${_classpath}\" ${_sources}"
+    OUTPUT_VARIABLE _out
+    RETURN_VALUE _retval)
+message(STATUS ${_out})
+if(NOT "${_retval}" STREQUAL 0)
+    message(FATAL_ERROR "Problem when compiling \"${_sources}\"")
+endif()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_uninstall.cmake.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_uninstall.cmake.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cmake_modules/cmake_uninstall.cmake.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,19 @@
+if(NOT EXISTS "@PROJECT_BINARY_DIR@/install_manifest.txt")
+    message(FATAL_ERROR "Cannot find install manifest: \"@PROJECT_BINARY_DIR@/install_manifest.txt\"")
+endif()
+
+file(READ "@PROJECT_BINARY_DIR@/install_manifest.txt" files)
+string(REGEX REPLACE "\n" ";" files "${files}")
+foreach(file ${files})
+    message(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"")
+    if(EXISTS "$ENV{DESTDIR}${file}")
+        exec_program("@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
+                     OUTPUT_VARIABLE rm_out
+                     RETURN_VALUE rm_retval)
+        if(NOT "${rm_retval}" STREQUAL 0)
+            message(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"")
+        endif()
+    else()
+        message(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
+    endif()
+endforeach()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/Description.txt
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/Description.txt	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/Description.txt	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,4 @@
+DESCRIPTION
+===========
+
+This is an installer created using CPack (http://www.cmake.org). No additional installation instructions provided.

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.rtf
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.rtf	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.rtf	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+{\rtf1\ansi\ansicpg932\deff0\deflang1033\deflangfe1041{\fonttbl{\f0\froman\fprq1\fcharset128 \'82\'6c\'82\'72 \'82\'6f\'83\'53\'83\'56\'83\'62\'83\'4e;}}
+{\*\generator Msftedit 5.41.15.1515;}\viewkind4\uc1\pard\lang1041\f0\fs20 LICENSE\par
+=======\par
+\par
+This is an installer created using CPack (http://www.cmake.org). No license provided.\par
+\par
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.txt
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.txt	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/License.txt	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,4 @@
+LICENSE
+=======
+
+This is an installer created using CPack (http://www.cmake.org). No license provided.

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/wix.xsl.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/wix.xsl.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/cpack_resources/wix.xsl.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<xsl:stylesheet version="1.0"
+   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+   xmlns:wix="http://schemas.microsoft.com/wix/2006/wi">
+  <xsl:output indent="yes" method="xml"/>
+
+  <xsl:template match="/wix:Wix">
+    <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
+      <Product xmlns="http://schemas.microsoft.com/wix/2006/wi" Id="D839647B-9EDA-4344-857D-FA5A102E5DE5" Name="@RTC_NAME@ @PACKAGE_VERSION@" Language="1041" Codepage="932" Version="@PACKAGE_VERSION@" Manufacturer="@RTC_VENDOR@" UpgradeCode="8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942">
+        <Package InstallerVersion="300" Compressed="yes" Languages='1041' SummaryCodepage='932' />
+        <Media Id="1" Cabinet="@RTC_NAME at .cab" EmbedCab="yes" />
+        <Directory Id="TARGETDIR" Name="SourceDir" >
+            <Directory Id="ProgramFilesFolder" Name="PFILE" >
+                <Directory Id="OPENRTM_DIR" Name="OpenRTM-aist" >
+                    <Directory Id="INSTALLLOCATION" Name="@OPENRTM_VERSION_MAJOR at .@OPENRTM_VERSION_MINOR@" />
+                </Directory>
+            </Directory>
+        </Directory>
+
+        <Feature Id="APPLICATIONS" Title="@CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME@" Level="1" Description="@CPACK_COMPONENT_APPLICATIONS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .bat')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .sh')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\bin')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\RTC.xml')]" />
+        </Feature>
+
+        <Feature Id="DOCUMENTS" Title="@CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_DOCUMENTS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\doc')]" />
+        </Feature>
+
+        <Feature Id="SOURCES" Title="@CPACK_COMPONENT_SOURCES_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_SOURCES_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\src')]" />
+        </Feature>
+
+        <!--Tack on your specific wix options-->
+        <UIRef Id="WixUI_FeatureTree" />
+        <UIRef Id="WixUI_ErrorProgressText" />
+        <WixVariable Id="WixUILicenseRtf" Value="@CPACK_RESOURCE_FILE_LICENSE@"/>
+        <!-- TODO: Add Wix Specific Dialogs and features. -->
+        <!-- TODO: Add artwork  -->
+        <!-- TODO: Add ... -->
+
+      </Product>
+
+      <!--Output the fragment info which heat generates-->
+      <xsl:copy-of select="wix:Fragment[wix:DirectoryRef/wix:Component]" />
+      <xsl:apply-templates select="wix:Fragment[wix:DirectoryRef/@Id!='TARGETDIR' and wix:DirectoryRef/wix:Directory]" />
+
+    </Wix>
+  </xsl:template>
+
+  <xsl:template match="wix:Fragment[wix:DirectoryRef/wix:Directory]" >
+    <xsl:copy>
+      <xsl:apply-templates select="wix:DirectoryRef" />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:DirectoryRef" >
+    <xsl:copy>
+      <xsl:choose>
+        <xsl:when test="wix:Directory[@Name='components']" >
+          <xsl:attribute name="Id">INSTALLLOCATION</xsl:attribute>
+        </xsl:when>
+        <xsl:otherwise>
+          <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+        </xsl:otherwise>
+      </xsl:choose>
+      <xsl:apply-templates />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Directory" >
+    <xsl:copy>
+      <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+      <xsl:attribute name="Name"><xsl:value-of select="@Name" /></xsl:attribute>
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Component">
+    <xsl:element name="ComponentRef" xmlns="http://schemas.microsoft.com/wix/2006/wi" >
+      <xsl:attribute name="Id">
+        <xsl:value-of select="@Id" />
+      </xsl:attribute>
+    </xsl:element>
+  </xsl:template>
+
+</xsl:stylesheet>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.bat
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.bat	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.bat	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,5 @@
+set CLASSPATH=.;%RTM_JAVA_ROOT%\jar\OpenRTM-aist-1.1.0.jar;%RTM_JAVA_ROOT%\jar\commons-cli-1.1.jar
+cd /d %~dp0
+cd bin
+java fooComp -f rtc.conf %*
+pause;

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.sh
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.sh	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/foo.sh	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,10 @@
+#!/bin/sh
+if test "x$RTM_JAVA_ROOT" = "x" ; then
+    echo "Environment variable RTM_JAVA_ROOT is not set."
+    echo "Please specify the OpenRTM-aist installation directory."
+    echo "Abort."
+    exit 1
+fi
+export CLASSPATH=.:${RTM_JAVA_ROOT}/jar/OpenRTM-aist-1.1.0.jar:${RTM_JAVA_ROOT}/jar/commons-cli-1.1.jar
+cd `dirname $0`/bin
+java fooComp -f rtc.conf $*

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,29 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake1/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,311 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+import RTC.TimedShort;
+import RTC.TimedLong;
+import RTC.TimedInt;
+import RTC.TimedFloat;
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.InPort;
+import jp.go.aist.rtm.RTC.port.OutPort;
+import jp.go.aist.rtm.RTC.util.DataRef;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_InP1_val = new TimedShort();
+        m_InP1 = new DataRef<TimedShort>(m_InP1_val);
+        m_InP1In = new InPort<TimedShort>("InP1", m_InP1);
+        m_InP2_val = new TimedLong();
+        m_InP2 = new DataRef<TimedLong>(m_InP2_val);
+        m_InP2In = new InPort<TimedLong>("InP2", m_InP2);
+        m_OutP1_val = new TimedInt();
+        m_OutP1 = new DataRef<TimedInt>(m_OutP1_val);
+        m_OutP1Out = new OutPort<TimedInt>("OutP1", m_OutP1);
+        m_OutP2_val = new TimedFloat();
+        m_OutP2 = new DataRef<TimedFloat>(m_OutP2_val);
+        m_OutP2Out = new OutPort<TimedFloat>("OutP2", m_OutP2);
+        m_svPortPort = new CorbaPort("svPort");
+        m_cmPortPort = new CorbaPort("cmPort");
+        // </rtc-template>
+    }
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // Set InPort buffers
+        addInPort("InP1", m_InP1In);
+        addInPort("InP2", m_InP2In);
+        
+        // Set OutPort buffer
+        addOutPort("OutP1", m_OutP1Out);
+        addOutPort("OutP2", m_OutP2Out);
+        
+        // Set service provider to Ports
+        try {
+        	m_svPortPort.registerProvider("acc", "MyService", m_acc);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_cmPortPort.registerConsumer("rate", "DAQService", m_rateBase);
+        
+        // Set CORBA Service Ports
+        addPort(m_svPortPort);
+        addPort(m_cmPortPort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    protected TimedShort m_InP1_val;
+    protected DataRef<TimedShort> m_InP1;
+    /*!
+     */
+    protected InPort<TimedShort> m_InP1In;
+    protected TimedLong m_InP2_val;
+    protected DataRef<TimedLong> m_InP2;
+    /*!
+     */
+    protected InPort<TimedLong> m_InP2In;
+    
+    // </rtc-template>
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    protected TimedInt m_OutP1_val;
+    protected DataRef<TimedInt> m_OutP1;
+    /*!
+     */
+    protected OutPort<TimedInt> m_OutP1Out;
+    protected TimedFloat m_OutP2_val;
+    protected DataRef<TimedFloat> m_OutP2;
+    /*!
+     */
+    protected OutPort<TimedFloat> m_OutP2Out;
+    
+    // </rtc-template>
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_svPortPort;
+    /*!
+     */
+    protected CorbaPort m_cmPortPort;
+    
+    // </rtc-template>
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_acc = new MyServiceSVC_impl();
+    
+    // </rtc-template>
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<DAQService> m_rateBase = new CorbaConsumer<DAQService>(DAQService.class);
+    /*!
+     */
+    protected DAQService m_rate;
+    
+    // </rtc-template>
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/CMakeLists.txt
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/CMakeLists.txt	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/CMakeLists.txt	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,175 @@
+cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
+project(foo Java)
+set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true)
+set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake_modules")
+set(LINUX_PACKAGE_GENERATOR "DEB")
+#set(LINUX_PACKAGE_GENERATOR "RPM")
+# component settings
+set(RTC_NAME "${PROJECT_NAME}")
+set(RTC_VERSION "1.0.1")
+set(RTC_VERSION_MAJOR "1")
+set(RTC_VERSION_MINOR "0")
+set(RTC_VERSION_PATCH "1")
+set(RTC_LANG "java")
+set(RTC_DESCRIPTION "MDesc")
+set(RTC_VENDOR "TA")
+set(RTC_MAINTAINER "author at example.com")
+string(TOLOWER ${RTC_NAME} PACKAGE_NAME)
+set(PACKAGE_VERSION "${RTC_VERSION_MAJOR}.${RTC_VERSION_MINOR}.${RTC_VERSION_PATCH}")
+set(IDL_FILES ""
+              MyServiceChildMulti.idl
+              MyServiceChildWithType.idl
+)
+set(OTHER_SRCS CMakeLists.txt Doxyfile.in
+               RTC.xml foo.conf rtc.conf)
+# check OpenRTM installed
+find_package(OpenRTMJava REQUIRED)
+# check doxygen installed
+find_package(Doxygen)
+if(DOXYGEN_FOUND STREQUAL "NO")
+    message(FATAL_ERROR "Doxygen not found.")
+endif()
+# Java IDL settings
+get_filename_component(CMAKE_Java_HOME ${CMAKE_Java_COMPILER} PATH)
+set(CMAKE_Java_IDLJ ${CMAKE_Java_HOME}/idlj)
+if(WIN32)
+    # add command path
+    set($ENV{PATH} $ENV{PATH} "${OPENRTM_DIR}/bin")
+    # set install path prefix
+    set(CMAKE_INSTALL_PREFIX "${OPENRTM_DIR}")
+    set(INSTALL_PREFIX "components/${RTC_LANG}/${PACKAGE_NAME}${PACKAGE_VERSION}")
+else()
+    # add command path
+    set($ENV{PATH} $ENV{PATH} "${OPENRTM_DIR}/bin")
+    # set install path prefix
+    set(CMAKE_INSTALL_PREFIX "/usr")
+    # set(CMAKE_INSTALL_PREFIX "${OPENRTM_DIR}")
+    set(OPENRTM_SHARE_PREFIX "share/openrtm-${OPENRTM_VERSION_MAJOR}.${OPENRTM_VERSION_MINOR}")
+    set(INSTALL_PREFIX "${OPENRTM_SHARE_PREFIX}/components/${RTC_LANG}/${PACKAGE_NAME}${PACKAGE_VERSION}")
+endif()
+# add uninstall target
+configure_file(
+    "${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_uninstall.cmake.in"
+    "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(uninstall COMMAND 
+    ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
+# add compile target
+set(JAVAC_SOURCE_DIRS ${PROJECT_SOURCE_DIR}/src ${PROJECT_BINARY_DIR}/src)
+set(JAVAC_DEST_DIR ${PROJECT_BINARY_DIR}/bin)
+set(JAVAC_CLASSPATH "${OPENRTM_CLASSPATH}")
+add_custom_target(idlcompile)
+foreach(idl ${IDL_FILES})
+    add_custom_command(TARGET idlcompile PRE_BUILD
+        COMMAND ${CMAKE_Java_IDLJ} -td src -fall "${PROJECT_SOURCE_DIR}/${idl}")
+endforeach()
+configure_file(
+    "${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_javacompile.cmake.in"
+    "${CMAKE_CURRENT_BINARY_DIR}/cmake_javacompile.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(compile ALL
+    COMMAND ${CMAKE_COMMAND} -E make_directory bin
+    COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_javacompile.cmake)
+add_dependencies(compile idlcompile)
+if(UNIX)
+    add_custom_command(TARGET compile
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.bat ${RTC_NAME}.bat
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.sh ${RTC_NAME}.sh.dos
+        COMMAND sed -e 's,\r,,' ${RTC_NAME}.sh.dos > ${RTC_NAME}.sh)
+else()
+    add_custom_command(TARGET compile
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.bat ${RTC_NAME}.bat
+        COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${RTC_NAME}.sh ${RTC_NAME}.sh)
+endif()
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES bin)
+install(FILES RTC.xml DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RTC_NAME}.sh DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RTC_NAME}.bat DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "applications")
+# target settings for document
+configure_file("${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in"
+               "${CMAKE_CURRENT_BINARY_DIR}/Doxyfile")
+add_custom_target(doxygen COMMAND
+                  ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES doc)
+get_target_property(DOC_TARGET doc TYPE)
+if(NOT DOC_TARGET)
+    add_custom_target(doc)
+endif()
+add_dependencies(doc doxygen)
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION "${INSTALL_PREFIX}"
+        COMPONENT "documents")
+# install source files
+install(DIRECTORY src
+        DESTINATION "${INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+install(FILES ${IDL_FILES} ${RTC_NAME}.sh ${RTC_NAME}.bat ${OTHER_SRCS}
+        DESTINATION "${INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+install(DIRECTORY cmake_modules cpack_resources
+        DESTINATION "${INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+# package settings
+set(CPACK_PACKAGE_NAME "${RTC_NAME}")
+set(CPACK_PACKAGE_VERSION_MAJOR "${RTC_VERSION_MAJOR}")
+set(CPACK_PACKAGE_VERSION_MINOR "${RTC_VERSION_MINOR}")
+set(CPACK_PACKAGE_VERSION_PATCH "${RTC_VERSION_PATCH}")
+set(CPACK_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
+set(CPACK_PACKAGE_VENDOR "${RTC_VENDOR}")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${RTC_DESCRIPTION}")
+set(CPACK_PACKAGE_CONTACT "${RTC_MAINTAINER}")
+set(CPACK_RESOURCE_FILE_LICENSE
+    "${CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/License.txt")
+set(CPACK_PACKAGE_DESCRIPTION_FILE
+    "${CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/Description.txt")
+set(CPACK_COMPONENTS_ALL applications documents sources)
+set(CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME "Applications")
+set(CPACK_COMPONENT_APPLICATIONS_DESCRIPTION "RT-Component applications")
+set(CPACK_COMPONENT_APPLICATIONS_DISABLED FALSE)
+set(CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME "Documents")
+set(CPACK_COMPONENT_DOCUMENTS_DESCRIPTION "RT-Component documents")
+set(CPACK_COMPONENT_DOCUMENTS_DISABLED TRUE)
+set(CPACK_COMPONENT_SOURCES_DISPLAY_NAME "Source files")
+set(CPACK_COMPONENT_SOURCES_DESCRIPTION "RT-Component source files")
+set(CPACK_COMPONENT_SOURCES_DISABLED TRUE)
+if(WIN32)
+    set(CPACK_GENERATOR "WIX")
+    # Windows WiX package settings
+    set(CPACK_WIX_XSL "@CMAKE_CURRENT_BINARY_DIR@/wix.xsl")
+    set(CPACK_WIX_LANG "ja-jp")
+    set(CPACK_RESOURCE_FILE_LICENSE
+        "@CMAKE_CURRENT_SOURCE_DIR@/cpack_resources/License.rtf")
+    configure_file(
+        "${CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/wix.xsl.in"
+        "${CMAKE_CURRENT_BINARY_DIR}/wix.xsl" @ONLY)
+    set(CPACK_PACKAGE_FILE_NAME
+        "rtc${OPENRTM_VERSION}-${PACKAGE_NAME}${PACKAGE_VERSION}")
+else()
+    set(CPACK_GENERATOR "${LINUX_PACKAGE_GENERATOR}")
+    if(CPACK_GENERATOR STREQUAL "DEB")
+        # Linux Debian package settings
+        set(CPACK_DEBIAN_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION}-1")
+        set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_DEBIAN_PACKAGE_SECTION "main")
+        set(CPACK_DEBIAN_PACKAGE_PRIORITY  "extra")
+        set(CPACK_DEBIAN_PACKAGE_DEPENDS "openrtm-aist (>= 1.0.0)")
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${OPENRTM_VERSION}-${PACKAGE_NAME}_${CPACK_DEBIAN_PACKAGE_VERSION}_${CPACK_DEBIAN_PACKAGE_ARCHITECTURE}")
+    elseif(CPACK_GENERATOR STREQUAL "RPM")
+        # Linux RPM package settings
+        set(CPACK_RPM_PACKAGE_RELEASE "1.fc10")
+        set(CPACK_RPM_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_RPM_PACKAGE_GROUP "Development/Libraries")
+        set(CPACK_RPM_PACKAGE_LICENSE "LGPL")
+        set(CPACK_RPM_PACKAGE_REQUIRES "OpenRTM-aist >= 1.0.0")
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${OPENRTM_VERSION}-${PACKAGE_NAME}-${PACKAGE_VERSION}-${CPACK_RPM_PACKAGE_RELEASE}.${CPACK_RPM_PACKAGE_ARCHITECTURE}")
+    endif()
+endif()
+message(STATUS "Package type: ${CPACK_GENERATOR}")
+message(STATUS "Package name: ${CPACK_PACKAGE_FILE_NAME}")
+include(CPack)

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/Doxyfile.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/Doxyfile.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/Doxyfile.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,487 @@
+
+# Project related configuration options
+
+DOXYFILE_ENCODING = UTF-8
+
+PROJECT_NAME = @PACKAGE_NAME@
+
+PROJECT_NUMBER = @PACKAGE_VERSION@
+
+OUTPUT_DIRECTORY = doc
+
+CREATE_SUBDIRS = NO
+
+OUTPUT_LANGUAGE = Japanese
+
+BRIEF_MEMBER_DESC = YES
+
+REPEAT_BRIEF = YES
+
+ABBREVIATE_BRIEF = 
+
+ALWAYS_DETAILED_SEC = NO
+
+INLINE_INHERITED_MEMB = NO
+
+FULL_PATH_NAMES = YES
+
+STRIP_FROM_PATH = 
+
+STRIP_FROM_INC_PATH = 
+
+SHORT_NAMES = NO
+
+JAVADOC_AUTOBRIEF = NO
+
+QT_AUTOBRIEF = NO
+
+MULTILINE_CPP_IS_BRIEF = NO
+
+INHERIT_DOCS = YES
+
+SEPARATE_MEMBER_PAGES = NO
+
+TAB_SIZE = 8
+
+ALIASES = 
+
+OPTIMIZE_OUTPUT_FOR_C = NO
+
+OPTIMIZE_OUTPUT_JAVA = NO
+
+OPTIMIZE_FOR_FORTRAN = NO
+
+OPTIMIZE_OUTPUT_VHDL = NO
+
+EXTENSION_MAPPING = 
+
+BUILTIN_STL_SUPPORT = NO
+
+CPP_CLI_SUPPORT = NO
+
+SIP_SUPPORT = NO
+
+IDL_PROPERTY_SUPPORT = YES
+
+DISTRIBUTE_GROUP_DOC = NO
+
+SUBGROUPING = YES
+
+TYPEDEF_HIDES_STRUCT = NO
+
+SYMBOL_CACHE_SIZE = 0
+
+
+# Build related configuration options
+
+EXTRACT_ALL = NO
+
+EXTRACT_PRIVATE = NO
+
+EXTRACT_STATIC = NO
+
+EXTRACT_LOCAL_CLASSES = YES
+
+EXTRACT_LOCAL_METHODS = NO
+
+EXTRACT_ANON_NSPACES = NO
+
+HIDE_UNDOC_MEMBERS = NO
+
+HIDE_UNDOC_CLASSES = NO
+
+HIDE_FRIEND_COMPOUNDS = NO
+
+HIDE_IN_BODY_DOCS = NO
+
+INTERNAL_DOCS = NO
+
+CASE_SENSE_NAMES = NO
+
+HIDE_SCOPE_NAMES = NO
+
+SHOW_INCLUDE_FILES = YES
+
+FORCE_LOCAL_INCLUDES = NO
+
+INLINE_INFO = YES
+
+SORT_MEMBER_DOCS = YES
+
+SORT_BRIEF_DOCS = NO
+
+SORT_MEMBERS_CTORS_1ST = NO
+
+SORT_GROUP_NAMES = NO
+
+SORT_BY_SCOPE_NAME = YES
+
+GENERATE_TODOLIST = YES
+
+GENERATE_TESTLIST = YES
+
+GENERATE_BUGLIST = YES
+
+GENERATE_DEPRECATEDLIST = YES
+
+ENABLED_SECTIONS = 
+
+MAX_INITIALIZER_LINES = 30
+
+SHOW_USED_FILES = YES
+
+SHOW_DIRECTORIES = NO
+
+SHOW_FILES = YES
+
+SHOW_NAMESPACES = YES
+
+FILE_VERSION_FILTER = 
+
+LAYOUT_FILE = 
+
+
+# configuration options related to warning and progress messages
+
+QUIET = NO
+
+WARNINGS = YES
+
+WARN_IF_UNDOCUMENTED = YES
+
+WARN_IF_DOC_ERROR = YES
+
+WARN_NO_PARAMDOC = NO
+
+WARN_FORMAT = "$file:$line: $text"
+
+WARN_LOGFILE = 
+
+
+# configuration options related to the input files
+
+INPUT = @CMAKE_CURRENT_SOURCE_DIR@
+
+INPUT_ENCODING = UTF-8
+
+FILE_PATTERNS = *.java *.idl
+
+RECURSIVE = YES
+
+EXCLUDE = _CPack_Packages
+
+EXCLUDE_SYMLINKS = NO
+
+EXCLUDE_PATTERNS = .svn .git 
+
+EXCLUDE_SYMBOLS = 
+
+EXAMPLE_PATH = 
+
+EXAMPLE_PATTERNS = 
+
+EXAMPLE_RECURSIVE = NO
+
+IMAGE_PATH = 
+
+INPUT_FILTER = 
+
+FILTER_PATTERNS = 
+
+FILTER_SOURCE_FILES = NO
+
+
+# configuration options related to source browsing
+
+SOURCE_BROWSER = NO
+
+INLINE_SOURCES = NO
+
+STRIP_CODE_COMMENTS = YES
+
+REFERENCED_BY_RELATION = NO
+
+REFERENCES_RELATION = NO
+
+REFERENCES_LINK_SOURCE = YES
+
+USE_HTAGS = NO
+
+VERBATIM_HEADERS = YES
+
+
+# configuration options related to the alphabetical class index
+
+ALPHABETICAL_INDEX = YES
+
+COLS_IN_ALPHA_INDEX = 5
+
+IGNORE_PREFIX = 
+
+
+# configuration options related to the HTML output
+
+GENERATE_HTML = YES
+
+HTML_OUTPUT = html
+
+HTML_FILE_EXTENSION = .html
+
+HTML_HEADER = 
+
+HTML_FOOTER = 
+
+HTML_STYLESHEET = 
+
+HTML_COLORSTYLE_HUE = 220
+
+HTML_COLORSTYLE_SAT = 100
+
+HTML_COLORSTYLE_GAMMA = 80
+
+HTML_TIMESTAMP = YES
+
+HTML_ALIGN_MEMBERS = YES
+
+HTML_DYNAMIC_SECTIONS = NO
+
+GENERATE_DOCSET = NO
+
+DOCSET_FEEDNAME = "Doxygen generated docs"
+
+DOCSET_BUNDLE_ID = org.doxygen.Project
+
+DOCSET_PUBLISHER_ID = org.doxygen.Publisher
+
+DOCSET_PUBLISHER_NAME = Publisher
+
+GENERATE_HTMLHELP = NO
+
+CHM_FILE = 
+
+HHC_LOCATION = 
+
+GENERATE_CHI = NO
+
+CHM_INDEX_ENCODING = 
+
+BINARY_TOC = NO
+
+TOC_EXPAND = NO
+
+GENERATE_QHP = NO
+
+QCH_FILE = 
+
+QHP_NAMESPACE = org.doxygen.Project
+
+QHP_VIRTUAL_FOLDER = doc
+
+QHP_CUST_FILTER_NAME = 
+
+QHP_CUST_FILTER_ATTRS = 
+
+QHP_SECT_FILTER_ATTRS = 
+
+QHG_LOCATION = 
+
+GENERATE_ECLIPSEHELP = NO
+
+ECLIPSE_DOC_ID = org.doxygen.Project
+
+DISABLE_INDEX = NO
+
+ENUM_VALUES_PER_LINE = 4
+
+GENERATE_TREEVIEW = NO
+
+USE_INLINE_TREES = NO
+
+TREEVIEW_WIDTH = 250
+
+EXT_LINKS_IN_WINDOW = NO
+
+FORMULA_FONTSIZE = 10
+
+FORMULA_TRANSPARENT = YES
+
+SEARCHENGINE = YES
+
+SERVER_BASED_SEARCH = NO
+
+
+# configuration options related to the LaTeX output
+
+GENERATE_LATEX = NO
+
+LATEX_OUTPUT = latex
+
+LATEX_CMD_NAME = latex
+
+MAKEINDEX_CMD_NAME = makeindex
+
+COMPACT_LATEX = NO
+
+PAPER_TYPE = a4wide
+
+EXTRA_PACKAGES = 
+
+LATEX_HEADER = 
+
+PDF_HYPERLINKS = YES
+
+USE_PDFLATEX = YES
+
+LATEX_BATCHMODE = NO
+
+LATEX_HIDE_INDICES = NO
+
+LATEX_SOURCE_CODE = NO
+
+
+# configuration options related to the RTF output
+
+GENERATE_RTF = NO
+
+RTF_OUTPUT = rtf
+
+COMPACT_RTF = NO
+
+RTF_HYPERLINKS = NO
+
+RTF_STYLESHEET_FILE = 
+
+RTF_EXTENSIONS_FILE = 
+
+
+# configuration options related to the man page output
+
+GENERATE_MAN = NO
+
+MAN_OUTPUT = man
+
+MAN_EXTENSION = .3
+
+MAN_LINKS = NO
+
+
+# configuration options related to the XML output
+
+GENERATE_XML = NO
+
+XML_OUTPUT = xml
+
+XML_SCHEMA = 
+
+XML_DTD = 
+
+XML_PROGRAMLISTING = YES
+
+
+# configuration options for the AutoGen Definitions output
+
+GENERATE_AUTOGEN_DEF = NO
+
+
+# configuration options related to the Perl module output
+
+GENERATE_PERLMOD = NO
+
+PERLMOD_LATEX = NO
+
+PERLMOD_PRETTY = YES
+
+PERLMOD_MAKEVAR_PREFIX = 
+
+
+# Configuration options related to the preprocessor
+
+ENABLE_PREPROCESSING = YES
+
+MACRO_EXPANSION = NO
+
+EXPAND_ONLY_PREDEF = NO
+
+SEARCH_INCLUDES = YES
+
+INCLUDE_PATH = 
+
+INCLUDE_FILE_PATTERNS = 
+
+PREDEFINED = 
+
+EXPAND_AS_DEFINED = 
+
+SKIP_FUNCTION_MACROS = YES
+
+
+# Configuration::additions related to external references
+
+TAGFILES = 
+
+GENERATE_TAGFILE = 
+
+ALLEXTERNALS = NO
+
+EXTERNAL_GROUPS = YES
+
+PERL_PATH = /usr/bin/perl
+
+
+# Configuration options related to the dot tool
+
+CLASS_DIAGRAMS = YES
+
+MSCGEN_PATH = 
+
+HIDE_UNDOC_RELATIONS = YES
+
+HAVE_DOT = NO
+
+DOT_NUM_THREADS = 0
+
+DOT_FONTNAME = FreeSans.ttf
+
+DOT_FONTSIZE = 10
+
+DOT_FONTPATH = 
+
+CLASS_GRAPH = YES
+
+COLLABORATION_GRAPH = YES
+
+GROUP_GRAPHS = YES
+
+UML_LOOK = YES
+
+TEMPLATE_RELATIONS = NO
+
+INCLUDE_GRAPH = YES
+
+INCLUDED_BY_GRAPH = YES
+
+CALL_GRAPH = NO
+
+CALLER_GRAPH = NO
+
+GRAPHICAL_HIERARCHY = YES
+
+DIRECTORY_GRAPH = YES
+
+DOT_IMAGE_FORMAT = png
+
+DOT_PATH = 
+
+DOTFILE_DIRS = 
+
+DOT_GRAPH_MAX_NODES = 50
+
+MAX_DOT_GRAPH_DEPTH = 0
+
+DOT_TRANSPARENT = NO
+
+DOT_MULTI_TARGETS = NO
+
+GENERATE_LEGEND = YES
+
+DOT_CLEANUP = YES

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildMulti.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildMulti.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildMulti.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+#include "MyServiceParent1.idl"
+#include "MyServiceParent2.idl"
+
+interface MyServiceChild : MyService, MyService2
+{
+  void setPos(in float pos);
+  EchoList1 getPos();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildWithType.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildWithType.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceChildWithType.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,8 @@
+#include "MyServiceParentWithType.idl"
+
+interface MyServiceWithTypeChild : MyServiceWithType
+{
+  void setPos(in float pos);
+  EchoList getPos();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent1.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent1.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent1.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,20 @@
+typedef sequence<string> EchoList1;
+typedef sequence<float> ValueList1;
+
+struct Time1
+{
+  unsigned long sec;    // sec
+  unsigned long nsec;   // nano sec
+};
+
+struct TimedState1
+{
+  Time1 tm;
+  short data;
+};
+
+interface MyService
+{
+  EchoList1 get_echo_history();
+  ValueList1 get_value_history();
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent2.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent2.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParent2.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService2
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParentWithType.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParentWithType.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/MyServiceParentWithType.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,20 @@
+typedef sequence<string> EchoList;
+typedef sequence<float> ValueList;
+
+struct Time
+{
+  unsigned long sec;    // sec
+  unsigned long nsec;   // nano sec
+};
+
+struct TimedState
+{
+  Time tm;
+  short data;
+};
+
+interface MyServiceWithType
+{
+  EchoList get_echo_history();
+  ValueList get_value_history();
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,42 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -fall 'idl/MyServiceChildMulti.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -fall 'idl/MyServiceParent1.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -fall 'idl/MyServiceParent2.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -fall 'idl/MyServiceChildWithType.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/build/cmake2' -fall 'idl/MyServiceParentWithType.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/CPackWIX.cmake
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/CPackWIX.cmake	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/CPackWIX.cmake	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+#=============================================================================
+# Copyright 2007-2009 Kitware, Inc.
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+# (To distributed this file outside of CMake, substitute the full
+#  License text for the above reference.)
+#
+# Fixed for OpenRTM
+#
+IF(CMAKE_BINARY_DIR)
+  MESSAGE(FATAL_ERROR "CPackWIX.cmake may only be used by CPack internally.")
+ENDIF(CMAKE_BINARY_DIR)
+
+IF(NOT CPACK_WIX_XSL OR NOT CPACK_PACKAGE_FILE_NAME OR NOT CPACK_RESOURCE_FILE_LICENSE OR NOT CPACK_PACKAGE_INSTALL_DIRECTORY)
+    MESSAGE(FATAL_ERROR "Variables required CPACK_WIX_XSL, CPACK_PACKAGE_FILE_NAME, CPACK_RESOURCE_FILE_LICENSE, CPACK_PACKAGE_INSTALL_DIRECTORY")
+ENDIF()
+
+IF(NOT CPACK_WIX_LANG)
+    SET(CPACK_WIX_LANG "en-us")
+ENDIF()
+
+# use the package defaults if none exists.
+# for the community.
+#IF ( NOT CPACK_WIX_XSL )
+#	
+#ENDIF( NOT CPACK_WIX_XSL )
+#
+
+IF ( CPACK_WIX_WXS_FILES )
+	# this could probably be a single expression but I'm no regex guru.
+    string(REGEX MATCH "[^/]*$" wix_temp "${CPACK_WIX_WXS_FILES}")
+	string(REGEX REPLACE "[.]wxs" ".wixobj" CPACK_WIX_OBJS "${wix_temp}" )
+ENDIF( CPACK_WIX_WXS_FILES )
+
+FIND_PROGRAM(WIX_EXE_HEAT heat PATHS "$ENV{ProgramFiles}/Windows Installer XML v3/bin")
+FIND_PROGRAM(WIX_EXE_CNDL candle PATHS "$ENV{ProgramFiles}/Windows Installer XML v3/bin")
+FIND_PROGRAM(WIX_EXE_LGHT light PATHS "$ENV{ProgramFiles}/Windows Installer XML v3/bin")
+
+IF( WIX_EXE_HEAT AND WIX_EXE_CNDL AND WIX_EXE_LGHT )
+  SET(CPACK_WIX_HEAT_COMMAND "\"${WIX_EXE_HEAT}\" dir ${CPACK_PACKAGE_FILE_NAME} -ke -g1 -gg -var var.Source -t:${CPACK_WIX_XSL} -out ${CPACK_PACKAGE_FILE_NAME}.wxs")
+  SET(CPACK_WIX_CNDL_COMMAND "\"${WIX_EXE_CNDL}\" -ext WixFirewallExtension -dSource=${CPACK_PACKAGE_FILE_NAME} ${CPACK_PACKAGE_FILE_NAME}.wxs ${CPACK_WIX_WXS_FILES}")
+  SET(CPACK_WIX_LGHT_COMMAND "\"${WIX_EXE_LGHT}\" -ext WixFirewallExtension -ext WixUIExtension -cultures:${CPACK_WIX_LANG} -out ${CPACK_PACKAGE_FILE_NAME}.msi ${CPACK_PACKAGE_FILE_NAME}.wixobj ${CPACK_WIX_OBJS}")
+ELSE()
+  MESSAGE(FATAL_ERROR "Can not find Wix Executables.")
+ENDIF()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/FindOpenRTMJava.cmake
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/FindOpenRTMJava.cmake	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/FindOpenRTMJava.cmake	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,70 @@
+set(OPENRTM_FOUND FALSE)
+if(UNIX)
+    # OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT $ENV{RTM_JAVA_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "$ENV{RTM_JAVA_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+    # OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${OPENRTM_DIR}/jar" "${OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+    if("${_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${_vers}")
+        string(REGEX REPLACE "\\.jar$" "" _vers "${_vers}")
+        set(OPENRTM_VERSION "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${_vers}")
+    endif()
+    file(GLOB _jars "${OPENRTM_DIR}/jar/*.jar")
+    string(REPLACE ";" ":" OPENRTM_CLASSPATH "${_jars}")
+endif(UNIX)
+if(WIN32)
+    # OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT $ENV{RTM_JAVA_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "$ENV{RTM_JAVA_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+    # OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${OPENRTM_DIR}/jar" "${OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+    if("${_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${_vers}")
+        string(REGEX REPLACE "\\.jar$" "" _vers "${_vers}")
+        set(OPENRTM_VERSION "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${_vers}")
+    endif()
+    file(GLOB _jars "${OPENRTM_DIR}/jar/*.jar")
+    set(OPENRTM_CLASSPATH "${_jars}")
+endif(WIN32)
+message(STATUS "FindOpenRTMJava setup done.")
+message(STATUS "  OPENRTM_DIR=${OPENRTM_DIR}")
+message(STATUS "  OPENRTM_VERSION=${OPENRTM_VERSION}")
+message(STATUS "  OPENRTM_VERSION_MAJOR=${OPENRTM_VERSION_MAJOR}")
+message(STATUS "  OPENRTM_VERSION_MINOR=${OPENRTM_VERSION_MINOR}")
+message(STATUS "  OPENRTM_VERSION_PATCH=${OPENRTM_VERSION_PATCH}")
+message(STATUS "  OPENRTM_CLASSPATH=${OPENRTM_CLASSPATH}")

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_javacompile.cmake.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_javacompile.cmake.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_javacompile.cmake.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,41 @@
+include("@PROJECT_BINARY_DIR@/CMakeFiles/CMakeJavaCompiler.cmake")
+set(_srcdir @JAVAC_SOURCE_DIRS@)
+set(_destdir "@JAVAC_DEST_DIR@")
+set(_classpath "@JAVAC_CLASSPATH@")
+function(__java_copy_file src dest)
+    exec_program("${CMAKE_COMMAND} -E copy_if_different \"${src}\" \"${dest}\""
+        OUTPUT_VARIABLE _out
+        RETURN_VALUE _retval)
+    message(STATUS "Copying \"${src}\" to the build directory")
+    message(STATUS ${_out})
+    if(NOT "${_retval}" STREQUAL 0)
+        message(FATAL_ERROR "Problem when copying \"${src}\"")
+    endif()
+endfunction()
+set(_sources)
+foreach(_dir ${_srcdir})
+    set(_files)
+    file(GLOB_RECURSE _globs RELATIVE "${_dir}" "${_dir}/*")
+    foreach(_file ${_globs})
+        get_filename_component(_file_ext "${_file}" EXT)
+        if(_file MATCHES "/.svn/")
+        elseif(_file_ext MATCHES ".java$")
+            list(APPEND _sources "${_dir}/${_file}")
+        else()
+            __java_copy_file("${_dir}/${_file}" "${_destdir}/${_file}")
+        endif()
+    endforeach()
+endforeach()
+message(STATUS "Compiling")
+foreach(f ${_sources})
+    message(STATUS "    ${f}")
+endforeach()
+string(REPLACE ";" " " _sources "${_sources}")
+exec_program("${CMAKE_Java_COMPILER}"
+    ARGS "-d ${_destdir} -cp \"${_classpath}\" ${_sources}"
+    OUTPUT_VARIABLE _out
+    RETURN_VALUE _retval)
+message(STATUS ${_out})
+if(NOT "${_retval}" STREQUAL 0)
+    message(FATAL_ERROR "Problem when compiling \"${_sources}\"")
+endif()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_uninstall.cmake.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_uninstall.cmake.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cmake_modules/cmake_uninstall.cmake.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,19 @@
+if(NOT EXISTS "@PROJECT_BINARY_DIR@/install_manifest.txt")
+    message(FATAL_ERROR "Cannot find install manifest: \"@PROJECT_BINARY_DIR@/install_manifest.txt\"")
+endif()
+
+file(READ "@PROJECT_BINARY_DIR@/install_manifest.txt" files)
+string(REGEX REPLACE "\n" ";" files "${files}")
+foreach(file ${files})
+    message(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"")
+    if(EXISTS "$ENV{DESTDIR}${file}")
+        exec_program("@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
+                     OUTPUT_VARIABLE rm_out
+                     RETURN_VALUE rm_retval)
+        if(NOT "${rm_retval}" STREQUAL 0)
+            message(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"")
+        endif()
+    else()
+        message(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
+    endif()
+endforeach()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/Description.txt
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/Description.txt	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/Description.txt	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,4 @@
+DESCRIPTION
+===========
+
+This is an installer created using CPack (http://www.cmake.org). No additional installation instructions provided.

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.rtf
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.rtf	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.rtf	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+{\rtf1\ansi\ansicpg932\deff0\deflang1033\deflangfe1041{\fonttbl{\f0\froman\fprq1\fcharset128 \'82\'6c\'82\'72 \'82\'6f\'83\'53\'83\'56\'83\'62\'83\'4e;}}
+{\*\generator Msftedit 5.41.15.1515;}\viewkind4\uc1\pard\lang1041\f0\fs20 LICENSE\par
+=======\par
+\par
+This is an installer created using CPack (http://www.cmake.org). No license provided.\par
+\par
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.txt
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.txt	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/License.txt	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,4 @@
+LICENSE
+=======
+
+This is an installer created using CPack (http://www.cmake.org). No license provided.

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/wix.xsl.in
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/wix.xsl.in	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/cpack_resources/wix.xsl.in	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<xsl:stylesheet version="1.0"
+   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+   xmlns:wix="http://schemas.microsoft.com/wix/2006/wi">
+  <xsl:output indent="yes" method="xml"/>
+
+  <xsl:template match="/wix:Wix">
+    <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
+      <Product xmlns="http://schemas.microsoft.com/wix/2006/wi" Id="D839647B-9EDA-4344-857D-FA5A102E5DE5" Name="@RTC_NAME@ @PACKAGE_VERSION@" Language="1041" Codepage="932" Version="@PACKAGE_VERSION@" Manufacturer="@RTC_VENDOR@" UpgradeCode="8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942">
+        <Package InstallerVersion="300" Compressed="yes" Languages='1041' SummaryCodepage='932' />
+        <Media Id="1" Cabinet="@RTC_NAME at .cab" EmbedCab="yes" />
+        <Directory Id="TARGETDIR" Name="SourceDir" >
+            <Directory Id="ProgramFilesFolder" Name="PFILE" >
+                <Directory Id="OPENRTM_DIR" Name="OpenRTM-aist" >
+                    <Directory Id="INSTALLLOCATION" Name="@OPENRTM_VERSION_MAJOR at .@OPENRTM_VERSION_MINOR@" />
+                </Directory>
+            </Directory>
+        </Directory>
+
+        <Feature Id="APPLICATIONS" Title="@CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME@" Level="1" Description="@CPACK_COMPONENT_APPLICATIONS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .bat')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .sh')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\bin')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\RTC.xml')]" />
+        </Feature>
+
+        <Feature Id="DOCUMENTS" Title="@CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_DOCUMENTS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\doc')]" />
+        </Feature>
+
+        <Feature Id="SOURCES" Title="@CPACK_COMPONENT_SOURCES_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_SOURCES_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\src')]" />
+        </Feature>
+
+        <!--Tack on your specific wix options-->
+        <UIRef Id="WixUI_FeatureTree" />
+        <UIRef Id="WixUI_ErrorProgressText" />
+        <WixVariable Id="WixUILicenseRtf" Value="@CPACK_RESOURCE_FILE_LICENSE@"/>
+        <!-- TODO: Add Wix Specific Dialogs and features. -->
+        <!-- TODO: Add artwork  -->
+        <!-- TODO: Add ... -->
+
+      </Product>
+
+      <!--Output the fragment info which heat generates-->
+      <xsl:copy-of select="wix:Fragment[wix:DirectoryRef/wix:Component]" />
+      <xsl:apply-templates select="wix:Fragment[wix:DirectoryRef/@Id!='TARGETDIR' and wix:DirectoryRef/wix:Directory]" />
+
+    </Wix>
+  </xsl:template>
+
+  <xsl:template match="wix:Fragment[wix:DirectoryRef/wix:Directory]" >
+    <xsl:copy>
+      <xsl:apply-templates select="wix:DirectoryRef" />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:DirectoryRef" >
+    <xsl:copy>
+      <xsl:choose>
+        <xsl:when test="wix:Directory[@Name='components']" >
+          <xsl:attribute name="Id">INSTALLLOCATION</xsl:attribute>
+        </xsl:when>
+        <xsl:otherwise>
+          <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+        </xsl:otherwise>
+      </xsl:choose>
+      <xsl:apply-templates />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Directory" >
+    <xsl:copy>
+      <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+      <xsl:attribute name="Name"><xsl:value-of select="@Name" /></xsl:attribute>
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Component">
+    <xsl:element name="ComponentRef" xmlns="http://schemas.microsoft.com/wix/2006/wi" >
+      <xsl:attribute name="Id">
+        <xsl:value-of select="@Id" />
+      </xsl:attribute>
+    </xsl:element>
+  </xsl:template>
+
+</xsl:stylesheet>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.bat
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.bat	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.bat	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,5 @@
+set CLASSPATH=.;%RTM_JAVA_ROOT%\jar\OpenRTM-aist-1.1.0.jar;%RTM_JAVA_ROOT%\jar\commons-cli-1.1.jar
+cd /d %~dp0
+cd bin
+java fooComp -f rtc.conf %*
+pause;

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.sh
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.sh	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/foo.sh	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,10 @@
+#!/bin/sh
+if test "x$RTM_JAVA_ROOT" = "x" ; then
+    echo "Environment variable RTM_JAVA_ROOT is not set."
+    echo "Please specify the OpenRTM-aist installation directory."
+    echo "Abort."
+    exit 1
+fi
+export CLASSPATH=.:${RTM_JAVA_ROOT}/jar/OpenRTM-aist-1.1.0.jar:${RTM_JAVA_ROOT}/jar/commons-cli-1.1.jar
+cd `dirname $0`/bin
+java fooComp -f rtc.conf $*

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 get_echo_history()>"
+        return null;
+    }
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList1 get_value_history()>"
+        return null;
+    }
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief MDesc
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "MDesc",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "Manip",
+    	    "activity_type",     "STATIC2",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/build/cmake2/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,274 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief MDesc
+ * @date  $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+/*!
+ * @class fooImpl
+ * @brief MDesc
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_MyServiceProviderPort = new CorbaPort("MyServiceProvider");
+        m_MyServiceRequirePort = new CorbaPort("MyServiceRequire");
+        // </rtc-template>
+    }
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_MyServiceProviderPort.registerProvider("MyServiceProvider", "MyServiceChild", m_MyServiceProvider);
+        	m_MyServiceProviderPort.registerProvider("MyServiceProvider2", "MyServiceWithTypeChild", m_MyServiceProvider2);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_MyServiceRequirePort.registerConsumer("MyServiceRequire", "MyServiceChild", m_MyServiceRequireBase);
+        m_MyServiceRequirePort.registerConsumer("MyServiceRequire2", "MyServiceWithTypeChild", m_MyServiceRequire2Base);
+        
+        // Set CORBA Service Ports
+        addPort(m_MyServiceProviderPort);
+        addPort(m_MyServiceRequirePort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MyServiceProviderPort;
+    /*!
+     */
+    protected CorbaPort m_MyServiceRequirePort;
+    
+    // </rtc-template>
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceChildSVC_impl m_MyServiceProvider = new MyServiceChildSVC_impl();
+    /*!
+     */
+    protected MyServiceWithTypeChildSVC_impl m_MyServiceProvider2 = new MyServiceWithTypeChildSVC_impl();
+    
+    // </rtc-template>
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyServiceChild> m_MyServiceRequireBase = new CorbaConsumer<MyServiceChild>(MyServiceChild.class);
+    /*!
+     */
+    protected MyServiceChild m_MyServiceRequire;
+    protected CorbaConsumer<MyServiceWithTypeChild> m_MyServiceRequire2Base = new CorbaConsumer<MyServiceWithTypeChild>(MyServiceWithTypeChild.class);
+    /*!
+     */
+    protected MyServiceWithTypeChild m_MyServiceRequire2;
+    
+    // </rtc-template>
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceChildMulti.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceChildMulti.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceChildMulti.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+#include "MyServiceParent1.idl"
+#include "MyServiceParent2.idl"
+
+interface MyServiceChild : MyService, MyService2
+{
+  void setPos(in float pos);
+  EchoList1 getPos();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent1.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent1.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent1.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,20 @@
+typedef sequence<string> EchoList1;
+typedef sequence<float> ValueList1;
+
+struct Time1
+{
+  unsigned long sec;    // sec
+  unsigned long nsec;   // nano sec
+};
+
+struct TimedState1
+{
+  Time1 tm;
+  short data;
+};
+
+interface MyService
+{
+  EchoList1 get_echo_history();
+  ValueList1 get_value_history();
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent2.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent2.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/MyServiceParent2.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService2
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,36 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit1' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit1' -fall 'idl/MyServiceChildMulti.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit1' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit1' -fall 'idl/MyServiceParent1.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit1' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit1' -fall 'idl/MyServiceParent2.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyService2SVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyService2SVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyService2SVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyService2SVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyService2SVC_impl
+ * Example class implementing IDL interface MyService2
+ */
+public class MyService2SVC_impl extends MyService2POA{
+    
+    public MyService2SVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceChildSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceChildSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceChildSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,55 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceChildSVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyServiceChildSVC_impl
+ * Example class implementing IDL interface MyServiceChild
+ */
+public class MyServiceChildSVC_impl extends MyServiceChildPOA{
+    
+    public MyServiceChildSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setPos(float pos) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setPos(float pos)>"
+    }
+
+    public String[] getPos() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 getPos()>"
+        return null;
+    }
+
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 get_echo_history()>"
+        return null;
+    }
+
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList1 get_value_history()>"
+        return null;
+    }
+
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 get_echo_history()>"
+        return null;
+    }
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList1 get_value_history()>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief test module
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "test module",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "sample",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "2",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit1/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,287 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief test module
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief test module
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_MyServiceProviderPort = new CorbaPort("MyServiceProvider");
+        m_MyServiceRequirePort = new CorbaPort("MyServiceRequire");
+        // </rtc-template>
+
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_MyServiceProviderPort.registerProvider("MyServiceProvider", "MyServiceChild", m_MyServiceProvider);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_MyServiceRequirePort.registerConsumer("MyServiceRequire", "MyServiceChild", m_MyServiceRequireBase);
+        
+        // Set CORBA Service Ports
+        addPort(m_MyServiceProviderPort);
+        addPort(m_MyServiceRequirePort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MyServiceProviderPort;
+    /*!
+     */
+    protected CorbaPort m_MyServiceRequirePort;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceChildSVC_impl m_MyServiceProvider = new MyServiceChildSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyServiceChild> m_MyServiceRequireBase = new CorbaConsumer<MyServiceChild>(MyServiceChild.class);
+    /*!
+     */
+    protected MyServiceChild m_MyServiceRequire;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildMulti.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildMulti.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildMulti.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+#include "MyServiceParent1.idl"
+#include "MyServiceParent2.idl"
+
+interface MyServiceChild : MyService, MyService2
+{
+  void setPos(in float pos);
+  EchoList1 getPos();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildWithType.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildWithType.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceChildWithType.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,8 @@
+#include "MyServiceParentWithType.idl"
+
+interface MyServiceWithTypeChild : MyServiceWithType
+{
+  void setPos(in float pos);
+  EchoList getPos();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent1.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent1.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent1.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,20 @@
+typedef sequence<string> EchoList1;
+typedef sequence<float> ValueList1;
+
+struct Time1
+{
+  unsigned long sec;    // sec
+  unsigned long nsec;   // nano sec
+};
+
+struct TimedState1
+{
+  Time1 tm;
+  short data;
+};
+
+interface MyService
+{
+  EchoList1 get_echo_history();
+  ValueList1 get_value_history();
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent2.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent2.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParent2.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService2
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParentWithType.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParentWithType.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/MyServiceParentWithType.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,20 @@
+typedef sequence<string> EchoList;
+typedef sequence<float> ValueList;
+
+struct Time
+{
+  unsigned long sec;    // sec
+  unsigned long nsec;   // nano sec
+};
+
+struct TimedState
+{
+  Time tm;
+  short data;
+};
+
+interface MyServiceWithType
+{
+  EchoList get_echo_history();
+  ValueList get_value_history();
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,42 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -fall 'idl/MyServiceChildMulti.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -fall 'idl/MyServiceParent1.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -fall 'idl/MyServiceParent2.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -fall 'idl/MyServiceChildWithType.idl'"/>
+		</exec>
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -i 'D:\GlobalAssist\EclipseAISTRep\jp.go.aist.rtm.rtcbuilder.java\resource/100/idlinherit/inherit2' -fall 'idl/MyServiceParentWithType.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyService2SVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyService2SVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyService2SVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyService2SVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyService2SVC_impl
+ * Example class implementing IDL interface MyService2
+ */
+public class MyService2SVC_impl extends MyService2POA{
+    
+    public MyService2SVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceChildSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceChildSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceChildSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,55 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceChildSVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyServiceChildSVC_impl
+ * Example class implementing IDL interface MyServiceChild
+ */
+public class MyServiceChildSVC_impl extends MyServiceChildPOA{
+    
+    public MyServiceChildSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setPos(float pos) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setPos(float pos)>"
+    }
+
+    public String[] getPos() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 getPos()>"
+        return null;
+    }
+
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 get_echo_history()>"
+        return null;
+    }
+
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList1 get_value_history()>"
+        return null;
+    }
+
+    public void setGain(float gain) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setGain(float gain)>"
+    }
+
+    public float getGain() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float getGain()>"
+        return 0;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,32 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyServiceChildMulti.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList1 get_echo_history()>"
+        return null;
+    }
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList1 get_value_history()>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeChildSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeChildSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeChildSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,44 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceWithTypeChildSVC_impl.java
+ * @brief Service implementation code of MyServiceChildWithType.idl
+ *
+ */
+/*!
+ * @class MyServiceWithTypeChildSVC_impl
+ * Example class implementing IDL interface MyServiceWithTypeChild
+ */
+public class MyServiceWithTypeChildSVC_impl extends MyServiceWithTypeChildPOA{
+    
+    public MyServiceWithTypeChildSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public void setPos(float pos) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void setPos(float pos)>"
+    }
+
+    public String[] getPos() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList getPos()>"
+        return null;
+    }
+
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList get_echo_history()>"
+        return null;
+    }
+
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList get_value_history()>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/MyServiceWithTypeSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,33 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceWithTypeSVC_impl.java
+ * @brief Service implementation code of MyServiceChildWithType.idl
+ *
+ */
+/*!
+ * @class MyServiceWithTypeSVC_impl
+ * Example class implementing IDL interface MyServiceWithType
+ */
+public class MyServiceWithTypeSVC_impl extends MyServiceWithTypePOA{
+    
+    public MyServiceWithTypeSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList get_echo_history()>"
+        return null;
+    }
+
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList get_value_history()>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief test module
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "test module",
+    	    "version",           "1.0.1",
+    	    "vendor",            "TA",
+    	    "category",          "sample",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "2",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idlinherit/inherit2/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,295 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief test module
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief test module
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_MyServiceProviderPort = new CorbaPort("MyServiceProvider");
+        m_MyServiceRequirePort = new CorbaPort("MyServiceRequire");
+        // </rtc-template>
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_MyServiceProviderPort.registerProvider("MyServiceProvider", "MyServiceChild", m_MyServiceProvider);
+        	m_MyServiceProviderPort.registerProvider("MyServiceProvider2", "MyServiceWithTypeChild", m_MyServiceProvider2);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_MyServiceRequirePort.registerConsumer("MyServiceRequire", "MyServiceChild", m_MyServiceRequireBase);
+        m_MyServiceRequirePort.registerConsumer("MyServiceRequire2", "MyServiceWithTypeChild", m_MyServiceRequire2Base);
+        
+        // Set CORBA Service Ports
+        addPort(m_MyServiceProviderPort);
+        addPort(m_MyServiceRequirePort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MyServiceProviderPort;
+    /*!
+     */
+    protected CorbaPort m_MyServiceRequirePort;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceChildSVC_impl m_MyServiceProvider = new MyServiceChildSVC_impl();
+    /*!
+     */
+    protected MyServiceWithTypeChildSVC_impl m_MyServiceProvider2 = new MyServiceWithTypeChildSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyServiceChild> m_MyServiceRequireBase = new CorbaConsumer<MyServiceChild>(MyServiceChild.class);
+    /*!
+     */
+    protected MyServiceChild m_MyServiceRequire;
+    protected CorbaConsumer<MyServiceWithTypeChild> m_MyServiceRequire2Base = new CorbaConsumer<MyServiceWithTypeChild>(MyServiceWithTypeChild.class);
+    /*!
+     */
+    protected MyServiceWithTypeChild m_MyServiceRequire2;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/TestIDL.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/TestIDL.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/TestIDL.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,63 @@
+typedef sequence<float> ValueList;
+typedef string<10> StringList;
+typedef long LongArray [100];
+typedef ValueList ValueListArray [100];
+typedef ValueListArray ValueListArray2 [100];
+
+enum color { RED, BLUE, YELLOW, GREEN, BLACK };
+
+struct Frame0 {
+  double mat[3][3];
+  double pos[3];
+};
+
+struct Frame1 {
+  ValueList matv;
+  ValueList posv;
+};
+
+struct Frame2 {
+  double mat[3][3];
+  double pos[3];
+  ValueList matv;
+};
+
+struct Frame3 {
+  double pos[3];
+  LongArray matv;
+};
+
+struct Frame4 {
+  double pos[3];
+  ValueListArray matv;
+};
+
+struct Frame5 {
+  double pos[3];
+  StringList matv;
+};
+
+typedef sequence<Frame1> Frame1List;
+typedef sequence<Frame2> Frame2List;
+typedef Frame1 Frame1Array [100];
+typedef Frame2 Frame2Array [100];
+
+
+interface ComFk {
+  ValueList set_value(in ValueList frm, out ValueList frmo, inout ValueList frmio);
+  StringList set_string(in StringList frm, out StringList frmo, inout StringList frmio);
+  LongArray set_longArray(in LongArray frm, out LongArray frmo, inout LongArray frmio);
+  ValueListArray set_longArrayv(in ValueListArray frm, out ValueListArray frmo, inout ValueListArray frmio);
+  ValueListArray2 set_longArrayv2(in ValueListArray2 frm, out ValueListArray2 frmo, inout ValueListArray2 frmio);
+  color set_color(in color frm, out color frmo, inout color frmio);
+  Frame0 set_tool0(in Frame0 frm, out Frame0 frmo, inout Frame0 frmio);
+  Frame1 set_tool1(in Frame1 frm, out Frame1 frmo, inout Frame1 frmio);
+  Frame2 set_tool2(in Frame2 frm, out Frame2 frmo, inout Frame2 frmio);
+  Frame3 set_tool3(in Frame3 frm, out Frame3 frmo, inout Frame3 frmio);
+  Frame4 set_tool4(in Frame4 frm, out Frame4 frmo, inout Frame4 frmio);
+  Frame5 set_tool5(in Frame5 frm, out Frame5 frmo, inout Frame5 frmio);
+  Frame1List set_toolSeq1(in Frame1List frm, out Frame1List frmo, inout Frame1List frmio);
+  Frame2List set_toolSeq2(in Frame2List frm, out Frame2List frmo, inout Frame2List frmio);
+  Frame1Array set_toolArray1(in Frame1Array frm, out Frame1Array frmo, inout Frame1Array frmio);
+  Frame2Array set_toolArray2(in Frame2Array frm, out Frame2Array frmo, inout Frame2Array frmio);
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/build_test.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/build_test.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/build_test.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_test.xml
+# @brief RTComponent makefile for "test component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="test" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/TestIDL.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/ComFkSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/ComFkSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/ComFkSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*-Java-*-
+/*!
+ * @file  ComFkSVC_impl.java
+ * @brief Service implementation code of TestIDL.idl
+ *
+ */
+/*!
+ * @class ComFkSVC_impl
+ * Example class implementing IDL interface ComFk
+ */
+public class ComFkSVC_impl extends ComFkPOA{
+    
+    public ComFkSVC_impl() {
+        // Please add extra constructor code here.
+    }
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public float[] set_value(float[] frm, ValueListHolder frmo, ValueListHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList set_value(ValueList frm, ValueList frmo, ValueList frmio)>"
+        return null;
+    }
+    public String set_string(String frm, org.omg.CORBA.StringHolder frmo, org.omg.CORBA.StringHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <String set_string(String frm, org.omg.CORBA.StringHolder frmo, org.omg.CORBA.StringHolder frmio)>"
+        return null;
+    }
+    public int[] set_longArray(int[] frm, LongArrayHolder frmo, LongArrayHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <LongArray set_longArray(LongArray frm, LongArray frmo, LongArray frmio)>"
+        return null;
+    }
+    public float[][] set_longArrayv(float[][] frm, ValueListArrayHolder frmo, ValueListArrayHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueListArray set_longArrayv(ValueListArray frm, ValueListArray frmo, ValueListArray frmio)>"
+        return null;
+    }
+    public float[][][] set_longArrayv2(float[][][] frm, ValueListArray2Holder frmo, ValueListArray2Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueListArray2 set_longArrayv2(ValueListArray2 frm, ValueListArray2 frmo, ValueListArray2 frmio)>"
+        return null;
+    }
+    public color set_color(color frm, colorHolder frmo, colorHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <color set_color(color frm, color frmo, color frmio)>"
+        return null;
+    }
+    public Frame0 set_tool0(Frame0 frm, Frame0Holder frmo, Frame0Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame0 set_tool0(Frame0 frm, Frame0 frmo, Frame0 frmio)>"
+        return null;
+    }
+    public Frame1 set_tool1(Frame1 frm, Frame1Holder frmo, Frame1Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame1 set_tool1(Frame1 frm, Frame1 frmo, Frame1 frmio)>"
+        return null;
+    }
+    public Frame2 set_tool2(Frame2 frm, Frame2Holder frmo, Frame2Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame2 set_tool2(Frame2 frm, Frame2 frmo, Frame2 frmio)>"
+        return null;
+    }
+    public Frame3 set_tool3(Frame3 frm, Frame3Holder frmo, Frame3Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame3 set_tool3(Frame3 frm, Frame3 frmo, Frame3 frmio)>"
+        return null;
+    }
+    public Frame4 set_tool4(Frame4 frm, Frame4Holder frmo, Frame4Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame4 set_tool4(Frame4 frm, Frame4 frmo, Frame4 frmio)>"
+        return null;
+    }
+    public Frame5 set_tool5(Frame5 frm, Frame5Holder frmo, Frame5Holder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame5 set_tool5(Frame5 frm, Frame5 frmo, Frame5 frmio)>"
+        return null;
+    }
+    public Frame1[] set_toolSeq1(Frame1[] frm, Frame1ListHolder frmo, Frame1ListHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame1List set_toolSeq1(Frame1List frm, Frame1List frmo, Frame1List frmio)>"
+        return null;
+    }
+    public Frame2[] set_toolSeq2(Frame2[] frm, Frame2ListHolder frmo, Frame2ListHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame2List set_toolSeq2(Frame2List frm, Frame2List frmo, Frame2List frmio)>"
+        return null;
+    }
+    public Frame1[] set_toolArray1(Frame1[] frm, Frame1ArrayHolder frmo, Frame1ArrayHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame1Array set_toolArray1(Frame1Array frm, Frame1Array frmo, Frame1Array frmio)>"
+        return null;
+    }
+    public Frame2[] set_toolArray2(Frame2[] frm, Frame2ArrayHolder frmo, Frame2ArrayHolder frmio) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <Frame2Array set_toolArray2(Frame2Array frm, Frame2Array frmo, Frame2Array frmio)>"
+        return null;
+    }
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/test.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/test.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/test.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,46 @@
+// -*- Java -*-
+/*!
+ * @file test.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+/*!
+ * @class test
+ * @brief test component
+ */
+public class test implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "test",
+    	    "type_name",         "test",
+    	    "description",       "test component",
+    	    "version",           "1.0.0",
+    	    "vendor",            "S.Kurihara",
+    	    "category",          "exmple",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "1",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+    public RTObject_impl createRtc(Manager mgr) {
+        return new testImpl(mgr);
+    }
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new test(), new test());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file testComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class testComp
+ * @brief Standalone component Class
+ *
+ */
+public class testComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(test.component_conf);
+      mgr.registerFactory(prop, new test(), new test());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("test");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        testComp init = new testComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type1/src/testImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,254 @@
+// -*- Java -*-
+/*!
+ * @file  testImpl.java
+ * @brief test component
+ * @date  $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+/*!
+ * @class testImpl
+ * @brief test component
+ *
+ */
+public class testImpl extends DataFlowComponentBase {
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public testImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_sV1Port = new CorbaPort("sV1");
+        // </rtc-template>
+    }
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_sV1Port.registerProvider("sIF1", "ComFk", m_sIFv);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        
+        // Set CORBA Service Ports
+        addPort(m_sV1Port);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_sV1Port;
+    
+    // </rtc-template>
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected ComFkSVC_impl m_sIFv = new ComFkSVC_impl();
+    
+    // </rtc-template>
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,19 @@
+interface MyService
+{
+  short echo01(in short ss, out short ss2, inout short ss3);
+  long echo02(in long ss, out long ss2, inout long ss3);
+  long long echo03(in long long ss, out long long ss2, inout long long ss3);
+  unsigned long echo04(in unsigned long ss, out unsigned long ss2, inout unsigned long ss3);
+  unsigned long long echo05(in unsigned long long ss, out unsigned long long ss2, inout unsigned long long ss3);
+  unsigned short echo06(in unsigned short ss, out unsigned short ss2, inout unsigned short ss3);
+  float echo07(in float ss, out float ss2, inout float ss3);
+  double echo08(in double ss, out double ss2, inout double ss3);
+  long double echo09(in long double ss, out long double ss2, inout long double ss3);
+  char echo10(in char ss, out char ss2, inout char ss3);
+  wchar echo11(in wchar ss, out wchar ss2, inout wchar ss3);
+  octet echo12(in octet ss, out octet ss2, inout octet ss3);
+  boolean echo13(in boolean ss, out boolean ss2, inout boolean ss3);
+  string echo14(in string ss, out string ss2, inout string ss3);
+  wstring echo15(in wstring ss, out wstring ss2, inout wstring ss3);
+  any echo16(in any ss, out any ss2, inout any ss3);
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/build_test.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/build_test.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/build_test.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_test.xml
+# @brief RTComponent makefile for "test component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="test" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,117 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public short echo01(short ss, org.omg.CORBA.ShortHolder ss2, org.omg.CORBA.ShortHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <short echo01(short ss, org.omg.CORBA.ShortHolder ss2, org.omg.CORBA.ShortHolder ss3)>"
+        return 0;
+    }
+
+    public int echo02(int ss, org.omg.CORBA.IntHolder ss2, org.omg.CORBA.IntHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <int echo02(int ss, org.omg.CORBA.IntHolder ss2, org.omg.CORBA.IntHolder ss3)>"
+        return 0;
+    }
+
+    public long echo03(long ss, org.omg.CORBA.LongHolder ss2, org.omg.CORBA.LongHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <long echo03(long ss, org.omg.CORBA.LongHolder ss2, org.omg.CORBA.LongHolder ss3)>"
+        return 0;
+    }
+
+    public int echo04(int ss, org.omg.CORBA.IntHolder ss2, org.omg.CORBA.IntHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <int echo04(int ss, org.omg.CORBA.IntHolder ss2, org.omg.CORBA.IntHolder ss3)>"
+        return 0;
+    }
+
+    public long echo05(long ss, org.omg.CORBA.LongHolder ss2, org.omg.CORBA.LongHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <long echo05(long ss, org.omg.CORBA.LongHolder ss2, org.omg.CORBA.LongHolder ss3)>"
+        return 0;
+    }
+
+    public short echo06(short ss, org.omg.CORBA.ShortHolder ss2, org.omg.CORBA.ShortHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <short echo06(short ss, org.omg.CORBA.ShortHolder ss2, org.omg.CORBA.ShortHolder ss3)>"
+        return 0;
+    }
+
+    public float echo07(float ss, org.omg.CORBA.FloatHolder ss2, org.omg.CORBA.FloatHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float echo07(float ss, org.omg.CORBA.FloatHolder ss2, org.omg.CORBA.FloatHolder ss3)>"
+        return 0;
+    }
+
+    public double echo08(double ss, org.omg.CORBA.DoubleHolder ss2, org.omg.CORBA.DoubleHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <double echo08(double ss, org.omg.CORBA.DoubleHolder ss2, org.omg.CORBA.DoubleHolder ss3)>"
+        return 0;
+    }
+
+    public double echo09(double ss, org.omg.CORBA.DoubleHolder ss2, org.omg.CORBA.DoubleHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <double echo09(double ss, org.omg.CORBA.DoubleHolder ss2, org.omg.CORBA.DoubleHolder ss3)>"
+        return 0;
+    }
+
+    public char echo10(char ss, org.omg.CORBA.CharHolder ss2, org.omg.CORBA.CharHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <char echo10(char ss, org.omg.CORBA.CharHolder ss2, org.omg.CORBA.CharHolder ss3)>"
+        return 0;
+    }
+
+    public char echo11(char ss, org.omg.CORBA.CharHolder ss2, org.omg.CORBA.CharHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <char echo11(char ss, org.omg.CORBA.CharHolder ss2, org.omg.CORBA.CharHolder ss3)>"
+        return 0;
+    }
+
+    public byte echo12(byte ss, org.omg.CORBA.ByteHolder ss2, org.omg.CORBA.ByteHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <byte echo12(byte ss, org.omg.CORBA.ByteHolder ss2, org.omg.CORBA.ByteHolder ss3)>"
+        return 0;
+    }
+
+    public boolean echo13(boolean ss, org.omg.CORBA.BooleanHolder ss2, org.omg.CORBA.BooleanHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <boolean echo13(boolean ss, org.omg.CORBA.BooleanHolder ss2, org.omg.CORBA.BooleanHolder ss3)>"
+        return false;
+    }
+
+    public String echo14(String ss, org.omg.CORBA.StringHolder ss2, org.omg.CORBA.StringHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <String echo14(String ss, org.omg.CORBA.StringHolder ss2, org.omg.CORBA.StringHolder ss3)>"
+        return null;
+    }
+
+    public String echo15(String ss, org.omg.CORBA.StringHolder ss2, org.omg.CORBA.StringHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <String echo15(String ss, org.omg.CORBA.StringHolder ss2, org.omg.CORBA.StringHolder ss3)>"
+        return null;
+    }
+
+    public org.omg.CORBA.Any echo16(org.omg.CORBA.Any ss, org.omg.CORBA.AnyHolder ss2, org.omg.CORBA.AnyHolder ss3) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <org.omg.CORBA.Any echo16(org.omg.CORBA.Any ss, org.omg.CORBA.AnyHolder ss2, org.omg.CORBA.AnyHolder ss3)>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/test.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/test.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/test.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,46 @@
+// -*- Java -*-
+/*!
+ * @file test.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+/*!
+ * @class test
+ * @brief test component
+ */
+public class test implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "test",
+    	    "type_name",         "test",
+    	    "description",       "test component",
+    	    "version",           "1.0.0",
+    	    "vendor",            "S.Kurihara",
+    	    "category",          "exmple",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "1",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+    public RTObject_impl createRtc(Manager mgr) {
+        return new testImpl(mgr);
+    }
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new test(), new test());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file testComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class testComp
+ * @brief Standalone component Class
+ *
+ */
+public class testComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(test.component_conf);
+      mgr.registerFactory(prop, new test(), new test());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("test");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        testComp init = new testComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/idltype/type2/src/testImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,254 @@
+// -*- Java -*-
+/*!
+ * @file  testImpl.java
+ * @brief test component
+ * @date  $Date$
+ *
+ * $Id$
+ */
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+/*!
+ * @class testImpl
+ * @brief test component
+ *
+ */
+public class testImpl extends DataFlowComponentBase {
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public testImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_MySVProPort = new CorbaPort("MySVPro");
+        // </rtc-template>
+    }
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_MySVProPort.registerProvider("myservice", "MyService", m_myservice);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        
+        // Set CORBA Service Ports
+        addPort(m_MySVProPort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_MySVProPort;
+    
+    // </rtc-template>
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_myservice = new MyServiceSVC_impl();
+    
+    // </rtc-template>
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,12 @@
+module SimpleService {
+typedef sequence<string> EchoList;
+typedef sequence<float> ValueList;
+interface MyService
+{
+  string echo(in string msg);
+  EchoList get_echo_history();
+  void set_value(in float value);
+  float get_value();
+  ValueList get_value_history();
+};
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief ModuleDescription
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "ModuleDescription",
+    	    "version",           "1.0.0",
+    	    "vendor",            "VenderName",
+    	    "category",          "Category",
+    	    "activity_type",     "STATIC",
+    	    "max_instance",      "1",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceCon/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,266 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief ModuleDescription
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import RTC.ReturnCode_t;
+import SimpleService.MyService;
+
+/*!
+ * @class fooImpl
+ * @brief ModuleDescription
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_sv_namePort = new CorbaPort("sv_name");
+        // </rtc-template>
+
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service consumers to Ports
+        m_sv_namePort.registerConsumer("if_name", "SimpleService.MyService", m_if_nameBase);
+        
+        // Set CORBA Service Ports
+        addPort(m_sv_namePort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_sv_namePort;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyService> m_if_nameBase = new CorbaConsumer<MyService>(MyService.class);
+    /*!
+     */
+    protected MyService m_if_name;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,12 @@
+module SimpleService {
+typedef sequence<string> EchoList;
+typedef sequence<float> ValueList;
+interface MyService
+{
+  string echo(in string msg);
+  EchoList get_echo_history();
+  void set_value(in float value);
+  float get_value();
+  ValueList get_value_history();
+};
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+import SimpleService.MyServicePOA;
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface SimpleService::MyService
+ */
+
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public String echo(String msg) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <String echo(String msg)>"
+        return null;
+    }
+
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList get_echo_history()>"
+        return null;
+    }
+
+    public void set_value(float value) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void set_value(float value)>"
+    }
+
+    public float get_value() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float get_value()>"
+        return 0;
+    }
+
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList get_value_history()>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief ModuleDescription
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "ModuleDescription",
+    	    "version",           "1.0.0",
+    	    "vendor",            "VenderName",
+    	    "category",          "Category",
+    	    "activity_type",     "UNIQUE",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceM/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,276 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief ModuleDescription
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+
+/*!
+ * @class fooImpl
+ * @brief ModuleDescription
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_sv_namePort = new CorbaPort("sv_name");
+        // </rtc-template>
+
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_sv_namePort.registerProvider("if_name", "SimpleService.MyService", m_if_name);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        
+        // Set CORBA Service Ports
+        addPort(m_sv_namePort);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_sv_namePort;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_if_name = new MyServiceSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/.classpath
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/.classpath	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/.classpath	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="C:\Program Files\OpenRTM-aist\1.0\jar/OpenRTM-aist-1.0.0.jar"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,12 @@
+module SimpleService {
+typedef sequence<string> EchoList;
+typedef sequence<float> ValueList;
+interface MyService
+{
+  string echo(in string msg);
+  EchoList get_echo_history();
+  void set_value(in float value);
+  float get_value();
+  ValueList get_value_history();
+};
+};

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/build_foo.xml
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/build_foo.xml	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/build_foo.xml	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+<!--
+# -*- Buildfile -*-
+# @file  build_foo.xml
+# @brief RTComponent makefile for "foo component"
+# @date  $Date$
+#
+# $Id$
+ -->
+<project name="foo" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+	<target name="mkdir">
+		<mkdir dir="${dest}" />
+	</target>
+	<target name="idlcompile"  depends="mkdir">
+		<exec executable="${java.home}/../bin/idlj">
+			<arg line="-td 'src' -fall 'idl/MyService.idl'"/>
+		</exec>
+	</target>
+	<target name="compile" depends="idlcompile">
+		<javac srcdir="${source}" destdir="${dest}">
+			<classpath>
+				<fileset dir="${env.RTM_JAVA_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+			</classpath>
+		</javac>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/MyServiceSVC_impl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/MyServiceSVC_impl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/MyServiceSVC_impl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,52 @@
+// -*-Java-*-
+/*!
+ * @file  MyServiceSVC_impl.java
+ * @brief Service implementation code of MyService.idl
+ *
+ */
+import SimpleService.MyServicePOA;
+
+/*!
+ * @class MyServiceSVC_impl
+ * Example class implementing IDL interface SimpleService::MyService
+ */
+public class MyServiceSVC_impl extends MyServicePOA{
+    
+    public MyServiceSVC_impl() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+    public String echo(String msg) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <String echo(String msg)>"
+        return null;
+    }
+
+    public String[] get_echo_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <EchoList get_echo_history()>"
+        return null;
+    }
+
+    public void set_value(float value) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <void set_value(float value)>"
+    }
+
+    public float get_value() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <float get_value()>"
+        return 0;
+    }
+
+    public float[] get_value_history() {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <ValueList get_value_history()>"
+        return null;
+    }
+
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/foo.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/foo.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/foo.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,51 @@
+// -*- Java -*-
+/*!
+ * @file foo.java
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class foo
+ * @brief ModuleDescription
+ */
+public class foo implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "foo",
+    	    "type_name",         "foo",
+    	    "description",       "ModuleDescription",
+    	    "version",           "1.0.0",
+    	    "vendor",            "VenderName",
+    	    "category",          "Category",
+    	    "activity_type",     "UNIQUE",
+    	    "max_instance",      "5",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new fooImpl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new foo(), new foo());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooComp.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooComp.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooComp.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,100 @@
+// -*- Java -*-
+/*!
+ * @file fooComp.java
+ * @brief Standalone component
+ * @date $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class fooComp
+ * @brief Standalone component Class
+ *
+ */
+public class fooComp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(foo.component_conf);
+      mgr.registerFactory(prop, new foo(), new foo());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("foo");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        fooComp init = new fooComp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooImpl.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooImpl.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/100/module/serviceMC/src/fooImpl.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,288 @@
+// -*- Java -*-
+/*!
+ * @file  fooImpl.java
+ * @brief ModuleDescription
+ * @date  $Date$
+ *
+ * $Id$
+ */
+
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+import RTC.ReturnCode_t;
+import SimpleService.MyService;
+
+/*!
+ * @class fooImpl
+ * @brief ModuleDescription
+ *
+ */
+public class fooImpl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public fooImpl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+        m_sv_namePort = new CorbaPort("sv_name");
+        m_sv_name2Port = new CorbaPort("sv_name2");
+        // </rtc-template>
+
+    }
+
+    /**
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        
+        // Set service provider to Ports
+        try {
+        	m_sv_namePort.registerProvider("if_name", "SimpleService.MyService", m_if_name);
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+        
+        // Set service consumers to Ports
+        m_sv_name2Port.registerConsumer("if_name2", "SimpleService.MyService", m_if_name2Base);
+        
+        // Set CORBA Service Ports
+        addPort(m_sv_namePort);
+        addPort(m_sv_name2Port);
+        // </rtc-template>
+        return super.onInitialize();
+    }
+
+    /***
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onFinalize() {
+//        return super.onFinalize();
+//    }
+
+    /***
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStartup(int ec_id) {
+//        return super.onStartup(ec_id);
+//    }
+
+    /***
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onShutdown(int ec_id) {
+//        return super.onShutdown(ec_id);
+//    }
+
+    /***
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onActivated(int ec_id) {
+//        return super.onActivated(ec_id);
+//    }
+
+    /***
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onDeactivated(int ec_id) {
+//        return super.onDeactivated(ec_id);
+//    }
+
+    /***
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onExecute(int ec_id) {
+//        return super.onExecute(ec_id);
+//    }
+
+    /***
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//  @Override
+//  public ReturnCode_t onAborting(int ec_id) {
+//      return super.onAborting(ec_id);
+//  }
+
+    /***
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    public ReturnCode_t onError(int ec_id) {
+//        return super.onError(ec_id);
+//    }
+
+    /***
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onReset(int ec_id) {
+//        return super.onReset(ec_id);
+//    }
+
+    /***
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onStateUpdate(int ec_id) {
+//        return super.onStateUpdate(ec_id);
+//    }
+
+    /***
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+     * 
+     */
+//    @Override
+//    protected ReturnCode_t onRateChanged(int ec_id) {
+//        return super.onRateChanged(ec_id);
+//    }
+//
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+    /*!
+     */
+    protected CorbaPort m_sv_namePort;
+    /*!
+     */
+    protected CorbaPort m_sv_name2Port;
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+    /*!
+     */
+    protected MyServiceSVC_impl m_if_name = new MyServiceSVC_impl();
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+    protected CorbaConsumer<MyService> m_if_name2Base = new CorbaConsumer<MyService>(MyService.class);
+    /*!
+     */
+    protected MyService m_if_name2;
+    
+    // </rtc-template>
+
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/DAQService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/DAQService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/DAQService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,43 @@
+// -*- IDL -*-
+/*!
+ * @file RTCService.idl
+ * @brief RTComponent サービスインターフェース
+ * @date $Date: 2007/12/25 05:43:04 $
+ * @author Noriaki Ando <n-ando at aist.go.jp>
+ *
+ * Copyright (C) 2005
+ *     Task-intelligence Research Group,
+ *     Intelligent Systems Research Institute,
+ *     National Institute of
+ *         Advanced Industrial Science and Technology (AIST), Japan
+ *
+ *     All rights reserved.
+ *
+ * $Id: DAQService.idl,v 1.1 2007/12/25 05:43:04 tsakamoto Exp $
+ *
+ */
+
+/*
+ * $Log: DAQService.idl,v $
+ * Revision 1.1  2007/12/25 05:43:04  tsakamoto
+ * *** empty log message ***
+ *
+ * Revision 1.1  2007/03/14 12:14:35  tsakamoto
+ * 属性生成版
+ *
+ * Revision 1.1  2005/09/07 05:06:13  n-ando
+ * RTComponent's service management feature was added.
+ *
+ */
+
+#ifndef __RTCService_idl__
+#define __RTCService_idl__
+
+interface DAQService
+{
+  long setCommand(in long com, in double par);
+  short getCommand();
+  unsigned long checkDone();
+  void setDone();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService3.idl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService3.idl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/resource/MyService3.idl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,6 @@
+interface MyService
+{
+  void setGain(in float gain);
+  float getGain();
+};
+

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/IRtcBuilderConstantsSafety.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,30 @@
+package jp.go.aist.rtm.rtcbuilder.safety;
+
+public interface IRtcBuilderConstantsSafety {
+
+	public static final String LANG_SAFETY = "Safety";
+	public static final String LANG_SAFETY_ARG = "Safety";
+	//
+	public static final String DOC_DESC_PREFIX_SAFETY = "     * ";
+	public static final String DOC_UNIT_PREFIX_SAFETY = "     *         "; 
+	public static final String DOC_RANGE_PREFIX_SAFETY = "     *          ";
+	public static final String DOC_CONSTRAINT_PREFIX_SAFETY = "     *               "; 
+	public static final String DOC_NUMBER_PREFIX_SAFETY = "     *           ";
+	public static final String DOC_SEMANTICS_PREFIX_SAFETY = "     *              ";
+	public static final String DOC_CYCLE_PREFIX_SAFETY = "     *                    "; 
+	public static final String DOC_INTERFACE_PREFIX_SAFETY = "     *            ";
+	public static final String DOC_INTERFACE_DETAIL_PREFIX_SAFETY = "     *                  ";
+	//
+	public static final int DOC_DESC_OFFSET_SAFETY = 7;
+	public static final int DOC_PRE_OFFSET_SAFETY = 12;
+	public static final int DOC_POST_OFFSET_SAFETY = 13;
+	public static final int DOC_UNIT_OFFSET_SAFETY = 15;
+	public static final int DOC_RANGE_OFFSET_SAFETY = 16;
+	public static final int DOC_CONSTRAINT_OFFSET_SAFETY = 21;
+	public static final int DOC_NUMBER_OFFSET_SAFETY = 17;
+	public static final int DOC_SEMANTICS_OFFSET_SAFETY = 20;
+	public static final int DOC_CYCLE_OFFSET_SAFETY = 26;
+	public static final int DOC_INTERFACE_OFFSET_SAFETY = 18;
+	public static final int DOC_INTERFACE_DETAIL_OFFSET_SAFETY = 24;
+	//
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/RtcBuilderSafetyPlugin.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,79 @@
+package jp.go.aist.rtm.rtcbuilder.safety;
+
+import java.util.logging.Logger;
+
+import jp.go.aist.rtm.rtcbuilder.RtcBuilderPlugin;
+
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class RtcBuilderSafetyPlugin extends AbstractUIPlugin {
+
+	// The plug-in ID
+	public static final String PLUGIN_ID = "jp.go.aist.rtm.rtcbuilder.safety";
+
+	// The shared instance
+	private static RtcBuilderSafetyPlugin plugin;
+	
+	/**
+	 * The constructor
+	 */
+	public RtcBuilderSafetyPlugin() {
+		System.out.println("RtcBuilderSafetyPlugin entry");
+		plugin = this;
+		getLogger();
+		System.out.println("RtcBuilderSafetyPlugin return");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
+	 */
+	public void start(BundleContext context) throws Exception {
+		System.out.println("start entry");
+		RtcBuilderPlugin.addLogger(getLogger());
+		//
+		System.out.println("start 050");
+		System.out.println(">>"+context);
+		super.start(context);
+		System.out.println("start return");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
+	 */
+	public void stop(BundleContext context) throws Exception {
+		System.out.println("stop entry");
+		RtcBuilderPlugin.removeLogger(getLogger());
+		//
+		plugin = null;
+		super.stop(context);
+		System.out.println("stop return");
+	}
+
+	/**
+	 * Returns the shared instance
+	 *
+	 * @return the shared instance
+	 */
+	public static RtcBuilderSafetyPlugin getDefault() {
+		System.out.println("getDefault entry");
+		return plugin;
+	}
+
+	static Logger log;
+
+	public static Logger getLogger() {
+		System.out.println("getLogger entry");
+		if (log == null) {
+			log = Logger.getLogger(PLUGIN_ID);
+		}
+		System.out.println("getLogger retrun");
+		return log;
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyCMakeGenerateManager.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,114 @@
+package jp.go.aist.rtm.rtcbuilder.safety.manager;
+
+import java.io.InputStream;
+import java.util.List;
+import java.util.Map;
+
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.manager.CMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.template.TemplateUtil;
+
+import static jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants.*;
+import static jp.go.aist.rtm.rtcbuilder.util.RTCUtil.form;
+
+import static jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety.LANG_SAFETY;
+import static jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety.LANG_SAFETY_ARG;
+
+public class SafetyCMakeGenerateManager extends CMakeGenerateManager {
+
+	static final String TEMPLATE_PATH_SAFETY = "jp/go/aist/rtm/rtcbuilder/safety/template";
+
+	public SafetyCMakeGenerateManager() {
+		DOXYGEN_FILE_PATTERNS = "*.c *.h *.idl";
+	}
+
+	@Override
+	public String getTargetVersion() {
+		return RTM_VERSION_100;
+	}
+
+	@Override
+	public String getManagerKey() {
+		return LANG_SAFETY;
+	}
+
+	@Override
+	public String getLangArgList() {
+		return LANG_SAFETY_ARG;
+	}
+
+	@Override
+	public Map<String, Object> createContextMap(RtcParam rtcParam) {
+		Map<String, Object> map = super.createContextMap(rtcParam);
+		map.put("templateSafety", TEMPLATE_PATH_SAFETY);
+		return map;
+	}
+
+	// RTM 1.0系
+	@Override
+	public List<GeneratedResult> generateTemplateCode10(
+			Map<String, Object> contextMap) {
+		List<GeneratedResult> result = super.generateTemplateCode10(contextMap);
+
+		GeneratedResult gr;
+		gr = generateModulesSafetyCompile(contextMap);
+		result.add(gr);
+
+		return result;
+	}
+
+	// 1.0系 (CMake)
+
+	@Override
+	public GeneratedResult generateCMakeLists(Map<String, Object> contextMap) {
+		String outfile = "CMakeLists.txt";
+		String infile = "cmake/CMakeLists.txt.vsl";
+		return generateSafety(infile, outfile, contextMap);
+	}
+
+	// 1.0系 (CMake/cmake_modules)
+
+	@Override
+	public GeneratedResult generateModulesFindOpenRTM(
+			Map<String, Object> contextMap) {
+		String outfile = "cmake_modules/FindOpenRTMSafety.cmake";
+		String infile = "cmake/FindOpenRTMSafety.cmake.vsl";
+		return generateSafety(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateModulesSafetyCompile(
+			Map<String, Object> contextMap) {
+		String outfile = "cmake_modules/cmake_safetycompile.cmake.in";
+		String infile = "cmake/cmake_safetycompile.cmake.in.vsl";
+		return generateSafety(infile, outfile, contextMap);
+	}
+
+	// 1.0系 (CMake/cpack_resources)
+
+	@Override
+	public GeneratedResult generateResourceWixXSL(Map<String, Object> contextMap) {
+		String outfile = "cpack_resources/wix.xsl.in";
+		String infile = "cmake/wix.xsl.in.vsl";
+		return generateSafety(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateSafety(String infile, String outfile,
+			Map<String, Object> contextMap) {
+		try {
+			String template = TEMPLATE_PATH_SAFETY + "/" + infile;
+			ClassLoader cl = Thread.currentThread().getContextClassLoader();
+			InputStream ins = cl.getResourceAsStream(template);
+			GeneratedResult gr = TemplateUtil.createGeneratedResult(ins,
+					contextMap, outfile);
+			if (ins != null) {
+				ins.close();
+			}
+			return gr;
+		} catch (Exception e) {
+			throw new RuntimeException(form(MSG_ERROR_GENERATE_FILE,
+					new String[] { "CMake", outfile }), e);
+		}
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyConverter.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,377 @@
+package jp.go.aist.rtm.rtcbuilder.safety.manager;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ConfigSetParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.DataPortParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.idl.ServiceArgumentParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.idl.ServiceClassParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.idl.ServiceMethodParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.idl.TypeDefParam;
+
+/**
+ * Safetyソースを出力する際に使用されるユーティリティ
+ */
+public class SafetyConverter {
+	protected Map<String, String> mapType;
+	protected Map<String, String> mapTypeHolder;
+	protected Map<String, String> mapParamHolder;
+
+	private final String dirIn = "in";
+//	private final String dirOut = "out";
+//	private final String dirInOut = "inout";
+
+	private final String idlLongLong = "longlong";
+	private final String idlLong = "long";
+	private final String idlUnsignedLong = "unsignedlong";
+	private final String idlUnsignedLongLong = "unsignedlonglong";
+	private final String idlShort = "short";
+	private final String idlUnsignedShort = "unsignedshort";
+	private final String idlFloat = "float";
+	private final String idlDouble = "double";
+	private final String idlLongDouble = "longdouble";
+	private final String idlChar = "char";
+	private final String idlWchar = "wchar";
+	private final String idlOctet = "octet";
+	private final String idlBoolean = "boolean";
+	private final String idlString = "string";
+	private final String idlWstring = "wstring";
+	private final String idlAny = "any";
+	private final String idlVoid= "void";
+	//
+	private final String safetyLongLong = "long";
+	private final String safetyLong = "int";
+	private final String safetyUnsignedLong = "int";
+	private final String safetyUnsignedLongLong = "long";
+	private final String safetyShort = "short";
+	private final String safetyUnsignedShort = "short";
+	private final String safetyFloat = "float";
+	private final String safetyDouble = "double";
+	private final String safetyLongDouble = "double";
+	private final String safetyChar = "char";
+	private final String safetyWchar = "char";
+	private final String safetyOctet = "byte";
+	private final String safetyBoolean = "boolean";
+	private final String safetyStringS = "string";
+	private final String safetyString = "String";
+	private final String safetyWstring = "String";
+	private final String safetyAny = "org.omg.CORBA.Any";
+	private final String safetyVoid= "void";
+	//
+	private final String safetyInt = "int";
+	private final String safetyByte = "byte";
+	//
+	private final String safetyShortHolder = "org.omg.CORBA.ShortHolder";
+	private final String safetyLongHolder = "org.omg.CORBA.IntHolder";
+	private final String safetyLongLongHolder = "org.omg.CORBA.LongHolder";
+	private final String safetyUnsignedLongHolder = "org.omg.CORBA.IntHolder";
+	private final String safetyUnsignedLongLongHolder = "org.omg.CORBA.LongHolder";
+	private final String safetyUnsignedShortHolder = "org.omg.CORBA.ShortHolder";
+	private final String safetyFloatHolder = "org.omg.CORBA.FloatHolder";
+	private final String safetyDoubleHolder = "org.omg.CORBA.DoubleHolder";
+	private final String safetyCharHolder = "org.omg.CORBA.CharHolder";
+	private final String safetyWcharHolder = "org.omg.CORBA.CharHolder";
+	private final String safetyOctetHolder = "org.omg.CORBA.ByteHolder";
+	private final String safetyBooleanHolder = "org.omg.CORBA.BooleanHolder";
+	private final String safetyStringHolder = "org.omg.CORBA.StringHolder";
+	private final String safetyWstringHolder = "org.omg.CORBA.StringHolder";
+	private final String safetyAnyHolder = "org.omg.CORBA.AnyHolder";
+	private final String safetyLongDoubleHolder = "org.omg.CORBA.DoubleHolder";
+	//
+	private final String safetyShortParam = "ShortHolder";
+	private final String safetyIntParam = "IntegerHolder";
+	private final String safetyLongParam = "LongHolder";
+	private final String safetyFloatParam = "FloatHolder";
+	private final String safetyDoubleParam = "DoubleHolder";
+	private final String safetyByteParam = "ByteHolder";
+	private final String safetyStringParam = "StringHolder";
+//	private final String safetyLongDouble = "double";
+
+	public SafetyConverter() {
+		mapType = new HashMap<String, String>();
+		mapType.put(idlLongLong, safetyLongLong);
+		mapType.put(idlLong, safetyLong);
+		mapType.put(idlUnsignedLong, safetyUnsignedLong);
+		mapType.put(idlUnsignedLongLong, safetyUnsignedLongLong);
+		mapType.put(idlShort, safetyShort);
+		mapType.put(idlUnsignedShort, safetyUnsignedShort);
+		mapType.put(idlFloat, safetyFloat);
+		mapType.put(idlDouble, safetyDouble);
+		mapType.put(idlLongDouble, safetyLongDouble);
+		mapType.put(idlChar, safetyChar);
+		mapType.put(idlWchar, safetyWchar);
+		mapType.put(idlOctet, safetyOctet);
+		mapType.put(idlBoolean, safetyBoolean);
+		mapType.put(idlString, safetyString);
+		mapType.put(idlWstring, safetyWstring);
+		mapType.put(idlAny, safetyAny);
+		mapType.put(idlVoid, safetyVoid);
+		//
+		mapTypeHolder = new HashMap<String, String>();
+		mapTypeHolder.put(idlLongLong, safetyLongLongHolder);
+		mapTypeHolder.put(idlLong, safetyLongHolder);
+		mapTypeHolder.put(idlUnsignedLong, safetyUnsignedLongHolder);
+		mapTypeHolder.put(idlUnsignedLongLong, safetyUnsignedLongLongHolder);
+		mapTypeHolder.put(idlShort, safetyShortHolder);
+		mapTypeHolder.put(idlUnsignedShort, safetyUnsignedShortHolder);
+		mapTypeHolder.put(idlFloat, safetyFloatHolder);
+		mapTypeHolder.put(idlDouble, safetyDoubleHolder);
+		mapTypeHolder.put(idlChar, safetyCharHolder);
+		mapTypeHolder.put(idlWchar, safetyWcharHolder);
+		mapTypeHolder.put(idlOctet, safetyOctetHolder);
+		mapTypeHolder.put(idlBoolean, safetyBooleanHolder);
+		mapTypeHolder.put(idlString, safetyStringHolder);
+		mapTypeHolder.put(idlWstring, safetyWstringHolder);
+		mapTypeHolder.put(idlAny, safetyAnyHolder);
+		mapTypeHolder.put(idlLongDouble, safetyLongDoubleHolder);
+		//
+		mapParamHolder = new HashMap<String, String>();
+		mapParamHolder.put(safetyShort, safetyShortParam);
+		mapParamHolder.put(safetyInt, safetyIntParam);
+		mapParamHolder.put(safetyLongLong, safetyLongParam);
+		mapParamHolder.put(safetyFloat, safetyFloatParam);
+		mapParamHolder.put(safetyDouble, safetyDoubleParam);
+		mapParamHolder.put(safetyByte, safetyByteParam);
+		mapParamHolder.put(safetyString, safetyStringParam);
+		mapParamHolder.put(safetyStringS, safetyStringParam);
+	}
+
+	/**
+	 * Portに設定された型の一覧を取得する
+	 * 
+	 * @param param  RtcParam
+	 * @return 型一覧リスト
+	 */
+	public List<String> getPortTypes(RtcParam param) {
+		List<String> portTypes = new ArrayList<String>();
+		for (DataPortParam dataPort : param.getInports()) {
+			if (!portTypes.contains(dataPort.getType())) {
+				portTypes.add(dataPort.getType());
+			}
+		}
+		for (DataPortParam dataPort : param.getOutports()) {
+			if (!portTypes.contains(dataPort.getType())) {
+				portTypes.add(dataPort.getType());
+			}
+		}
+		return portTypes;
+	}
+
+	/**
+	 * パラメータの型一覧を取得する
+	 * 
+	 * @param param  RtcParam
+	 * @return パラメータ型一覧リスト
+	 */
+	public List<String> getParamTypes(RtcParam param) {
+		List<String> paramTypes = new ArrayList<String>();
+		for( ConfigSetParam config : param.getConfigParams() ) {
+			String paramType = convSafety2ParamHolder(config.getType(),false);
+			if( paramType!=null && !paramTypes.contains(paramType) ) {
+				paramTypes.add(paramType);
+			}
+		}
+		return paramTypes;
+	}
+	/**
+	 * CORBA型からC型へ型を変換する(TypeDef考慮)
+	 * 
+	 * @param strCorba CORBA型
+	 * @return C型
+	 */
+	public String convCORBA2Safety(ServiceMethodParam typeDef, ServiceClassParam scp) {
+		String strType = getTypeDefs(typeDef.getType(), scp);
+		if( strType==null ) {
+			strType = typeDef.getType();
+		} else {
+			strType.replaceAll("::", ".");
+		}
+		
+		String rawType = strType.replaceAll("\\[\\]", "");
+		String convType = mapType.get(rawType);
+		
+		String result;
+		if( convType == null ) {
+			if(typeDef.isSequence() && !typeDef.isStruct()) {
+				result = strType;
+				
+			} else {
+				result = typeDef.getType();
+			}
+		} else {
+			result = strType.replaceAll(rawType, convType);
+			
+		}
+		
+		return result;
+	}
+	private String getTypeDefs(String target, ServiceClassParam scp) {
+		String result = null;
+		
+		TypeDefParam source = scp.getTypeDef().get(target);
+		if( source==null || source.getOriginalDef()==null || source.getOriginalDef().length()==0 ) {
+			return target;
+		} else {
+			result = getTypeDefs(source.getOriginalDef(), scp);
+			if( source!=null ) {
+				if( source.isSequence() || source.isArray() ) result += "[]";
+			}
+		}
+		return result;
+	}
+	
+	/**
+	 * CORBA型からC型へ型を変換する
+	 * 
+	 * @param strCorba CORBA型
+	 * @return C型
+	 */
+	public String convCORBA2SafetyNoDef(String strCorba) {
+		String result = mapType.get(strCorba);
+		if( result == null ) result = strCorba;
+		return result;
+	}
+	/**
+	 * CORBA型からC型へ型を変換する(引数用,TypeDef考慮)
+	 * 
+	 * @param strCorba CORBA型
+	 * @param strDirection 入出力方向
+	 * @return C型
+	 */
+	public String convCORBA2SafetyforArg(ServiceArgumentParam typeDef, String strDirection, ServiceClassParam scp) {
+		String result = "";
+		String strType = getTypeDefs(typeDef.getType(), scp);
+		if( typeDef.getType().equals(strType) ) {
+			if( strDirection.equals(dirIn) ) {
+				result = mapType.get(typeDef.getType());
+				if( result == null ) result = typeDef.getType();
+			} else {
+				result = mapTypeHolder.get(typeDef.getType());
+				if( result == null ) result = typeDef.getType() + "Holder";
+			}
+		} else {
+			strType.replaceAll("::", ".");
+			String rawType = strType.replaceAll("\\[\\]", "");
+			String convType = mapType.get(rawType);
+			if( convType == null ) {
+				if(typeDef.isStruct() || typeDef.isEnum()) {
+					result = typeDef.getType();
+				} else {
+					result = strType;
+				}
+				if( !strDirection.equals(dirIn) ) result = result + "Holder";
+			} else {
+				result = strType.replaceAll(rawType, convType);
+				
+			}
+			if( typeDef.isUnbounded() || typeDef.isArray() ) {
+				if( !strDirection.equals(dirIn) ) {
+					result = typeDef.getType() + "Holder";
+				}
+			}
+		}
+		return result;
+	}
+	/**
+	 * CORBA型からC型へ型を変換する(引数用)
+	 * 
+	 * @param strCorba CORBA型
+	 * @param strDirection 入出力方向
+	 * @return C型
+	 */
+	public String convCORBA2SafetyforArg(String strCorba, String strDirection) {
+		String result = "";
+		if( strDirection.equals(dirIn) ) {
+			result = mapType.get(strCorba);
+			
+		} else {
+			result = mapTypeHolder.get(strCorba);
+		}
+		if( result == null ) result = strCorba;
+		return result;
+	}
+	/**
+	 * C型からパラメータ用ホルダ型へ型を変換する
+	 * 
+	 * @param strSafety C型
+	 * @return パラメータ用ホルダ型
+	 */
+	public String convSafety2ParamHolder(String strSafety, boolean isNullAdd) {
+		String result = mapParamHolder.get(strSafety);
+		if( isNullAdd && result == null ) result = strSafety + "Holder";
+		return result;
+	}
+	/**
+	 * String型か判断する
+	 * 
+	 * @param srvMethod 検証対象メソッド
+	 * @return 検証結果
+	 */
+	public boolean isRetNull(ServiceMethodParam srvMethod, ServiceClassParam scp) {
+		if(srvMethod.isStruct()) return true;
+		String conv = this.convCORBA2Safety(srvMethod, scp);
+		if(conv.equals(safetyString) || conv.equals(safetyWstring) || conv.equals(safetyAny) || conv.endsWith("[]") )
+			return true;
+		return false;
+	}
+	
+	/**
+	 * データポート用のデータ型import文を返す
+	 * 
+	 * @param rtcType ポートの型
+	 * @return import文字列
+	 */
+	public String getDataportPackageName(String rtcType) {
+		//module名が付いていないデータ型(::が付いていない)はimport文を生成しない
+		if(!rtcType.matches(".*::.*")) return "";
+		
+		//module名=パッケージ名
+		//struct名=クラス名
+		String importDef = "import " + rtcType.replace("::", ".") + ";";
+		return importDef;
+	}
+	
+	/**
+	 * データポート初期化用にmodule名をカットしたデータ型クラス名を返す
+	 * 
+	 * @param rtcType ポートの型
+	 * @return クラス名
+	 */
+	public String getDataTypeName(String rtcType) {
+		
+		//module名が付いていないデータ型(::が付いていない)はそのまま返す
+		if(!rtcType.matches(".*::.*")) return rtcType;
+
+		String dataTypeNames[] = rtcType.split("::", 0);
+		return dataTypeNames[1];
+	}
+
+	/**
+	 * RTC.ReturnCode_tのインポートが必要な場合を判定します。
+	 * 
+	 * @param rtcParam
+	 *            RtcParam
+	 * @return RTC.ReturnCode_tのインポートが必要な場合は true
+	 */
+	public boolean useReturnCode(RtcParam rtcParam) {
+		if( rtcParam.getInports().size()>0 || rtcParam.getOutports().size()>0 ||
+				rtcParam.getServicePorts().size()>0 ) {
+			return true;
+		}
+		if (!rtcParam.getConfigParams().isEmpty()) {
+			return true;
+		}
+		for (int i = IRtcBuilderConstants.ACTIVITY_INITIALIZE; i < IRtcBuilderConstants.ACTIVITY_DUMMY; i++) {
+			if (!rtcParam.IsNotImplemented(i)) {
+				return true;
+			}
+		}
+		return false;
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/SafetyGenerateManager.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,236 @@
+package jp.go.aist.rtm.rtcbuilder.safety.manager;
+
+import java.io.File;
+import java.io.InputStream;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import jp.go.aist.rtm.rtcbuilder.IRTCBMessageConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.idl.IdlFileParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.idl.ServiceClassParam;
+import jp.go.aist.rtm.rtcbuilder.safety.ui.Perspective.SafetyProperty;
+import jp.go.aist.rtm.rtcbuilder.manager.GenerateManager;
+import jp.go.aist.rtm.rtcbuilder.template.TemplateHelper;
+import jp.go.aist.rtm.rtcbuilder.template.TemplateUtil;
+import jp.go.aist.rtm.rtcbuilder.ui.Perspective.LanguageProperty;
+
+import static jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants.*;
+import static jp.go.aist.rtm.rtcbuilder.util.RTCUtil.form;
+
+import static jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety.LANG_SAFETY;
+import static jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety.LANG_SAFETY_ARG;
+
+/**
+ * Safetyファイルの出力を制御するマネージャ
+ */
+public class SafetyGenerateManager extends GenerateManager {
+
+	static final String TEMPLATE_PATH = "jp/go/aist/rtm/rtcbuilder/safety/template";
+
+	static final String MSG_ERROR_GENERATE_FILE = IRTCBMessageConstants.ERROR_CODE_GENERATION;
+	
+	private final String DEFAULT_VERSION = "1.1.0"; 
+
+	@Override
+	public String getTargetVersion() {
+		return RTM_VERSION_100;
+	}
+
+	@Override
+	public String getManagerKey() {
+		return LANG_SAFETY;
+	}
+
+	@Override
+	public String getLangArgList() {
+		return LANG_SAFETY_ARG;
+	}
+
+	@Override
+	public LanguageProperty getLanguageProperty(RtcParam rtcParam) {
+		LanguageProperty langProp = null;
+		if (rtcParam.isLanguageExist(LANG_SAFETY)) {
+			langProp = new SafetyProperty();
+		}
+		return langProp;
+	}
+
+	/**
+	 * ファイルを出力する
+	 * 
+	 * @param generatorParam
+	 *            生成用パラメータ
+	 * @return 出力結果のリスト
+	 */
+	public List<GeneratedResult> generateTemplateCode(RtcParam rtcParam) {
+		List<GeneratedResult> result = new ArrayList<GeneratedResult>();
+
+		if (!rtcParam.isLanguageExist(LANG_SAFETY) || rtcParam.getName() == null) {
+			return result;
+		}
+		try {
+			String rootPath = System.getenv("RTM_SAFETY_ROOT") + File.separator + "jar";
+			File targetDir = new File(rootPath);
+			File[] targetFiles = targetDir.listFiles();
+			long lastDate = 0;
+			File targetJar = null;
+			if( targetFiles==null) {
+				//rtcParam.setRtmSafetyVersion(DEFAULT_VERSION);
+			} else {
+				for(File target : targetFiles) {
+					if( target.getName().startsWith("OpenRTM-aist") ) {
+						if( lastDate<target.lastModified() ) {
+							targetJar = target;
+						}
+					}
+				}
+				//
+				if( targetJar!=null ) {
+					String SafetyVersion = targetJar.getName().substring(13,18);
+					//rtcParam.setRtmSafetyVersion(safetyVersion);
+				} else {
+					//rtcParam.setRtmSafetyVersion(DEFAULT_VERSION);
+				}
+			}
+		} catch (NullPointerException ex) {
+			//rtcParam.setRtmSafetyVersion(DEFAULT_VERSION);
+		}
+		
+		Map<String, Object> contextMap = new HashMap<String, Object>();
+		contextMap.put("template", TEMPLATE_PATH);
+		contextMap.put("rtcParam", rtcParam);
+		contextMap.put("tmpltHelper", new TemplateHelper());
+		contextMap.put("tmpltHelperSafety", new TemplateHelperSafety());
+		contextMap.put("safetyConv", new SafetyConverter());
+		//
+		String defaultPath = System.getenv("RTM_SAFETY_ROOT");
+		if (defaultPath != null) {
+			defaultPath = defaultPath.replaceAll("\\\\", "/");
+			contextMap.put("safetyRoot", defaultPath);
+		}
+
+		resetIDLServiceClass(rtcParam);
+
+		return generateTemplateCode10(contextMap);
+	}
+
+	// RTM 1.0系
+	public List<GeneratedResult> generateTemplateCode10(
+			Map<String, Object> contextMap) {
+		List<GeneratedResult> result = new ArrayList<GeneratedResult>();
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+
+		GeneratedResult gr;
+		gr = generateCompSource(contextMap);
+		result.add(gr);
+		gr = generateRTCSource(contextMap);
+		result.add(gr);
+		gr = generateRTCImplSource(contextMap);
+		result.add(gr);
+
+		gr = generateClassPath(contextMap);
+		result.add(gr);
+		gr = generateRunBat(contextMap);
+		result.add(gr);
+		gr = generateRunSh(contextMap);
+		result.add(gr);
+
+		gr = generateBuildXML(contextMap);
+		result.add(gr);
+
+		for (IdlFileParam idl : rtcParam.getProviderIdlPathes()) {
+			contextMap.put("idlFileParam", idl);
+			for (ServiceClassParam svc : idl.getServiceClassParams()) {
+				contextMap.put("serviceClassParam", svc);
+				gr = generateSVCSource(contextMap);
+				result.add(gr);
+			}
+		}
+
+		return result;
+	}
+
+	// 1.0系 (Safety)
+
+	public GeneratedResult generateCompSource(Map<String, Object> contextMap) {
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+		String outfile = "src/" + rtcParam.getName() + "Comp.c";
+		String infile = "safety/Safety_Comp.c.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateRTCSource(Map<String, Object> contextMap) {
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+		String outfile = "src/" + rtcParam.getName() + ".c";
+		String infile = "safety/Safety_RTC.c.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateRTCImplSource(Map<String, Object> contextMap) {
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+		String outfile = "src/" + rtcParam.getName() + "Impl.c";
+		String infile = "safety/Safety_RTC_Impl.c.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateSVCSource(Map<String, Object> contextMap) {
+		ServiceClassParam svc = (ServiceClassParam) contextMap
+				.get("serviceClassParam");
+		String outfile = "src/" + TemplateHelper.getBasename(svc.getName())
+				+ TemplateHelper.getServiceImplSuffix() + ".c";
+		String infile = "safety/Safety_SVC.c.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateClassPath(Map<String, Object> contextMap) {
+		String outfile = ".classpath";
+		String infile = "safety/classpath.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateRunBat(Map<String, Object> contextMap) {
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+		String outfile = rtcParam.getName() + ".bat";
+		String infile = "safety/run.bat.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generateRunSh(Map<String, Object> contextMap) {
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+		String outfile = rtcParam.getName() + ".sh";
+		String infile = "safety/run.sh.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	// 1.0系 (ビルド環境)
+
+	public GeneratedResult generateBuildXML(Map<String, Object> contextMap) {
+		RtcParam rtcParam = (RtcParam) contextMap.get("rtcParam");
+		String outfile = "build_" + rtcParam.getName() + ".xml";
+		String infile = "safety/build.xml.vsl";
+		return generate(infile, outfile, contextMap);
+	}
+
+	public GeneratedResult generate(String infile, String outfile,
+			Map<String, Object> contextMap) {
+		try {
+			String template = TEMPLATE_PATH + "/" + infile;
+			ClassLoader cl = Thread.currentThread().getContextClassLoader();
+			InputStream ins = cl.getResourceAsStream(template);
+			GeneratedResult gr = TemplateUtil.createGeneratedResult(ins,
+					contextMap, outfile);
+			if (ins != null) {
+				ins.close();
+			}
+			return gr;
+		} catch (Exception e) {
+			throw new RuntimeException(form(MSG_ERROR_GENERATE_FILE,
+					new String[] { "Safety", outfile }), e);
+		}
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/manager/TemplateHelperSafety.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,71 @@
+package jp.go.aist.rtm.rtcbuilder.safety.manager;
+
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.util.StringUtil;
+
+/**
+ * テンプレートを出力する際に使用されるヘルパー
+ */
+public class TemplateHelperSafety {
+
+	//
+	public String convertDescDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_DESC_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_DESC_OFFSET_SAFETY);
+	}
+	public String convertPreDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_DESC_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_PRE_OFFSET_SAFETY);
+	}
+	public String convertPostDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_DESC_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_POST_OFFSET_SAFETY);
+	}
+	public String convertUnitDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_UNIT_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_UNIT_OFFSET_SAFETY);
+	}
+	public String convertRangeDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_RANGE_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_RANGE_OFFSET_SAFETY);
+	}
+	public String convertConstraintDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_CONSTRAINT_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_CONSTRAINT_OFFSET_SAFETY);
+	}
+	public String convertTypeDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_UNIT_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_UNIT_OFFSET_SAFETY);
+	}
+	public String convertNumberDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_NUMBER_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_NUMBER_OFFSET_SAFETY);
+	}
+	public String convertSemanticsDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_SEMANTICS_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_SEMANTICS_OFFSET_SAFETY);
+	}
+	public String convertFrequencyDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_SEMANTICS_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_SEMANTICS_OFFSET_SAFETY);
+	}
+	public String convertCycleDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_CYCLE_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_CYCLE_OFFSET_SAFETY);
+	}
+	public String convertInterfaceDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_INTERFACE_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_INTERFACE_OFFSET_SAFETY);
+	}
+	public String convertInterfaceDetailDocSafety(String source) {
+		return StringUtil.splitString(source, IRtcBuilderConstants.DOC_DEFAULT_WIDTH, 
+				IRtcBuilderConstantsSafety.DOC_INTERFACE_DETAIL_PREFIX_SAFETY, IRtcBuilderConstantsSafety.DOC_INTERFACE_DETAIL_OFFSET_SAFETY);
+	}
+	//
+	public boolean notNullRTMRoot() {
+		String defaultPath = System.getenv("RTM_ROOT");
+		if( defaultPath==null ) return false;
+		return true;
+	}
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/CMakeLists.txt.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,234 @@
+cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
+
+project(${rtcParam.name} Safety)
+
+set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true)
+set(CMAKE_MODULE_PATH "${dol}{PROJECT_SOURCE_DIR}/cmake_modules")
+
+set(LINUX_PACKAGE_GENERATOR "DEB")
+${sharp}set(LINUX_PACKAGE_GENERATOR "RPM")
+
+
+${sharp} component settings
+set(RTC_NAME "${dol}{PROJECT_NAME}")
+set(RTC_VERSION "${rtcParam.version}")
+set(RTC_VERSION_MAJOR "${helper.getVerMajor(${rtcParam.version})}")
+set(RTC_VERSION_MINOR "${helper.getVerMinor(${rtcParam.version})}")
+set(RTC_VERSION_PATCH "${helper.getVerPatch(${rtcParam.version})}")
+set(RTC_LANG "${helper.toLower(${rtcParam.language})}")
+set(RTC_DESCRIPTION "${rtcParam.description}")
+set(RTC_VENDOR "${rtcParam.vender}")
+set(RTC_MAINTAINER "author at example.com")
+
+string(TOLOWER ${dol}{RTC_NAME} PACKAGE_NAME)
+set(PACKAGE_VERSION "${dol}{RTC_VERSION_MAJOR}.${dol}{RTC_VERSION_MINOR}.${dol}{RTC_VERSION_PATCH}")
+
+set(IDL_FILES ""
+#foreach($p in ${rtcParam.providerIdlPathes})
+              ${p.idlFile}
+#end
+#foreach($p in ${rtcParam.consumerIdlPathes})
+              ${p.idlFile}
+#end)
+
+set(OTHER_SRCS CMakeLists.txt Doxyfile.in
+               RTC.xml ${rtcParam.name}.conf rtc.conf)
+
+
+${sharp} check OpenRTM installed
+find_package(OpenRTMSafety REQUIRED)
+
+${sharp} check doxygen installed
+find_package(Doxygen)
+if(DOXYGEN_FOUND STREQUAL "NO")
+    message(FATAL_ERROR "Doxygen not found.")
+endif()
+
+${sharp} Safety IDL settings
+get_filename_component(CMAKE_Safety_HOME ${dol}{CMAKE_Safety_COMPILER} PATH)
+set(CMAKE_Safety_IDLJ ${dol}{CMAKE_Safety_HOME}/idlj)
+
+
+if(WIN32)
+    ${sharp} add command path
+    set(${dol}ENV{PATH} ${dol}ENV{PATH} "${dol}{OPENRTM_DIR}/bin")
+    ${sharp} set install path prefix
+    set(CMAKE_INSTALL_PREFIX "${dol}{OPENRTM_DIR}")
+    set(INSTALL_PREFIX "components/${dol}{RTC_LANG}/${dol}{PACKAGE_NAME}${dol}{PACKAGE_VERSION}")
+else()
+    ${sharp} add command path
+    set(${dol}ENV{PATH} ${dol}ENV{PATH} "${dol}{OPENRTM_DIR}/bin")
+    ${sharp} set install path prefix
+    set(CMAKE_INSTALL_PREFIX "/usr")
+    ${sharp} set(CMAKE_INSTALL_PREFIX "${dol}{OPENRTM_DIR}")
+    set(OPENRTM_SHARE_PREFIX "share/openrtm-${dol}{OPENRTM_VERSION_MAJOR}.${dol}{OPENRTM_VERSION_MINOR}")
+    set(INSTALL_PREFIX "${dol}{OPENRTM_SHARE_PREFIX}/components/${dol}{RTC_LANG}/${dol}{PACKAGE_NAME}${dol}{PACKAGE_VERSION}")
+endif()
+
+
+${sharp} add uninstall target
+configure_file(
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_uninstall.cmake.in"
+    "${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(uninstall COMMAND 
+    ${dol}{CMAKE_COMMAND} -P ${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
+
+
+${sharp} add compile target
+set(SAFETYC_SOURCE_DIRS ${dol}{PROJECT_SOURCE_DIR}/src ${dol}{PROJECT_BINARY_DIR}/src)
+set(SAFETYC_DEST_DIR ${dol}{PROJECT_BINARY_DIR}/bin)
+set(SAFETYC_CLASSPATH "${dol}{OPENRTM_CLASSPATH}")
+
+add_custom_target(idlcompile)
+
+foreach(idl ${dol}{IDL_FILES})
+    add_custom_command(TARGET idlcompile PRE_BUILD
+        COMMAND ${dol}{CMAKE_Safety_IDLJ} -td src -fall "${dol}{PROJECT_SOURCE_DIR}/${dol}{idl}")
+endforeach()
+
+configure_file(
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/cmake_safetycompile.cmake.in"
+    "${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_safetycompile.cmake"
+    IMMEDIATE @ONLY)
+add_custom_target(compile ALL
+    COMMAND ${dol}{CMAKE_COMMAND} -E make_directory bin
+    COMMAND ${dol}{CMAKE_COMMAND} -P ${dol}{CMAKE_CURRENT_BINARY_DIR}/cmake_safetycompile.cmake)
+add_dependencies(compile idlcompile)
+
+if(UNIX)
+    add_custom_command(TARGET compile
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.bat ${dol}{RTC_NAME}.bat
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.sh ${dol}{RTC_NAME}.sh.dos
+        COMMAND sed -e 's,\r,,' ${dol}{RTC_NAME}.sh.dos > ${dol}{RTC_NAME}.sh)
+else()
+    add_custom_command(TARGET compile
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.bat ${dol}{RTC_NAME}.bat
+        COMMAND ${dol}{CMAKE_COMMAND} -E copy ${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{RTC_NAME}.sh ${dol}{RTC_NAME}.sh)
+endif()
+
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES bin)
+
+install(FILES RTC.xml DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+
+install(PROGRAMS ${dol}{CMAKE_CURRENT_BINARY_DIR}/${dol}{RTC_NAME}.sh DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+install(PROGRAMS ${dol}{CMAKE_CURRENT_BINARY_DIR}/${dol}{RTC_NAME}.bat DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+
+install(DIRECTORY ${dol}{CMAKE_CURRENT_BINARY_DIR}/bin DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "applications")
+
+
+${sharp} target settings for document
+configure_file("${dol}{CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in"
+               "${dol}{CMAKE_CURRENT_BINARY_DIR}/Doxyfile")
+
+add_custom_target(doxygen COMMAND
+                  ${dol}{DOXYGEN_EXECUTABLE} ${dol}{CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
+
+set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES doc)
+
+get_target_property(DOC_TARGET doc TYPE)
+if(NOT DOC_TARGET)
+    add_custom_target(doc)
+endif()
+add_dependencies(doc doxygen)
+
+install(DIRECTORY ${dol}{CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION "${dol}{INSTALL_PREFIX}"
+        COMPONENT "documents")
+
+
+${sharp} install source files
+install(DIRECTORY src
+        DESTINATION "${dol}{INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+
+install(FILES ${dol}{IDL_FILES} ${dol}{RTC_NAME}.sh ${dol}{RTC_NAME}.bat ${dol}{OTHER_SRCS}
+        DESTINATION "${dol}{INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+
+install(DIRECTORY cmake_modules cpack_resources
+        DESTINATION "${dol}{INSTALL_PREFIX}/src"
+        COMPONENT "sources")
+
+
+${sharp} package settings
+set(CPACK_PACKAGE_NAME "${dol}{RTC_NAME}")
+set(CPACK_PACKAGE_VERSION_MAJOR "${dol}{RTC_VERSION_MAJOR}")
+set(CPACK_PACKAGE_VERSION_MINOR "${dol}{RTC_VERSION_MINOR}")
+set(CPACK_PACKAGE_VERSION_PATCH "${dol}{RTC_VERSION_PATCH}")
+set(CPACK_PACKAGE_VERSION "${dol}{CPACK_PACKAGE_VERSION_MAJOR}.${dol}{CPACK_PACKAGE_VERSION_MINOR}.${dol}{CPACK_PACKAGE_VERSION_PATCH}")
+set(CPACK_PACKAGE_VENDOR "${dol}{RTC_VENDOR}")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${dol}{RTC_DESCRIPTION}")
+set(CPACK_PACKAGE_CONTACT "${dol}{RTC_MAINTAINER}")
+
+set(CPACK_RESOURCE_FILE_LICENSE
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/License.txt")
+set(CPACK_PACKAGE_DESCRIPTION_FILE
+    "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/Description.txt")
+
+set(CPACK_COMPONENTS_ALL applications documents sources)
+set(CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME "Applications")
+set(CPACK_COMPONENT_APPLICATIONS_DESCRIPTION "RT-Component applications")
+set(CPACK_COMPONENT_APPLICATIONS_DISABLED FALSE)
+
+set(CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME "Documents")
+set(CPACK_COMPONENT_DOCUMENTS_DESCRIPTION "RT-Component documents")
+set(CPACK_COMPONENT_DOCUMENTS_DISABLED TRUE)
+
+set(CPACK_COMPONENT_SOURCES_DISPLAY_NAME "Source files")
+set(CPACK_COMPONENT_SOURCES_DESCRIPTION "RT-Component source files")
+set(CPACK_COMPONENT_SOURCES_DISABLED TRUE)
+
+if(WIN32)
+    set(CPACK_GENERATOR "WIX")
+
+    ${sharp} Windows WiX package settings
+
+    set(CPACK_WIX_XSL "@CMAKE_CURRENT_BINARY_DIR@/wix.xsl")
+    set(CPACK_WIX_LANG "ja-jp")
+    set(CPACK_RESOURCE_FILE_LICENSE
+        "@CMAKE_CURRENT_SOURCE_DIR@/cpack_resources/License.rtf")
+    configure_file(
+        "${dol}{CMAKE_CURRENT_SOURCE_DIR}/cpack_resources/wix.xsl.in"
+        "${dol}{CMAKE_CURRENT_BINARY_DIR}/wix.xsl" @ONLY)
+
+    set(CPACK_PACKAGE_FILE_NAME
+        "rtc${dol}{OPENRTM_VERSION}-${dol}{PACKAGE_NAME}${dol}{PACKAGE_VERSION}")
+
+else()
+    set(CPACK_GENERATOR "${dol}{LINUX_PACKAGE_GENERATOR}")
+
+    if(CPACK_GENERATOR STREQUAL "DEB")
+        ${sharp} Linux Debian package settings
+
+        set(CPACK_DEBIAN_PACKAGE_VERSION "${dol}{CPACK_PACKAGE_VERSION}-1")
+        set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_DEBIAN_PACKAGE_SECTION "main")
+        set(CPACK_DEBIAN_PACKAGE_PRIORITY  "extra")
+        set(CPACK_DEBIAN_PACKAGE_DEPENDS "openrtm-aist (>= ${rtcParam.rtmVersion})")
+
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${dol}{OPENRTM_VERSION}-${dol}{PACKAGE_NAME}_${dol}{CPACK_DEBIAN_PACKAGE_VERSION}_${dol}{CPACK_DEBIAN_PACKAGE_ARCHITECTURE}")
+
+    elseif(CPACK_GENERATOR STREQUAL "RPM")
+        ${sharp} Linux RPM package settings
+
+        set(CPACK_RPM_PACKAGE_RELEASE "1.fc10")
+        set(CPACK_RPM_PACKAGE_ARCHITECTURE "i386")
+        set(CPACK_RPM_PACKAGE_GROUP "Development/Libraries")
+        set(CPACK_RPM_PACKAGE_LICENSE "LGPL")
+        set(CPACK_RPM_PACKAGE_REQUIRES "OpenRTM-aist >= ${rtcParam.rtmVersion}")
+
+        set(CPACK_PACKAGE_FILE_NAME
+            "rtc${dol}{OPENRTM_VERSION}-${dol}{PACKAGE_NAME}-${dol}{PACKAGE_VERSION}-${dol}{CPACK_RPM_PACKAGE_RELEASE}.${dol}{CPACK_RPM_PACKAGE_ARCHITECTURE}")
+
+    endif()
+endif()
+
+message(STATUS "Package type: ${dol}{CPACK_GENERATOR}")
+message(STATUS "Package name: ${dol}{CPACK_PACKAGE_FILE_NAME}")
+
+include(CPack)

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/FindOpenRTMSafety.cmake.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,84 @@
+
+set(OPENRTM_FOUND FALSE)
+
+
+if(UNIX)
+    ${sharp} OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT ${dol}ENV{RTM_SAFETY_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "${dol}ENV{RTM_SAFETY_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${dol}{OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+
+    ${sharp} OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${dol}{OPENRTM_DIR}/jar" "${dol}{OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${dol}{_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+
+    if("${dol}{_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${dol}{_vers}")
+        string(REGEX REPLACE "\\.jar${dol}" "" _vers "${dol}{_vers}")
+        set(OPENRTM_VERSION "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${dol}{_vers}")
+    endif()
+
+    file(GLOB _jars "${dol}{OPENRTM_DIR}/jar/*.jar")
+    string(REPLACE ";" ":" OPENRTM_CLASSPATH "${dol}{_jars}")
+
+endif(UNIX)
+
+if(WIN32)
+    ${sharp} OpenRTM-aist
+    if(NOT OPENRTM_DIR)
+        if(NOT ${dol}ENV{RTM_SAFETY_ROOT} STREQUAL "")
+            set(OPENRTM_DIR "${dol}ENV{RTM_SAFETY_ROOT}")
+            set(OPENRTM_FOUND TRUE)
+        endif()
+        set(OPENRTM_DIR "${dol}{OPENRTM_DIR}" CACHE PATH "OpenRTM-aist root directory")
+        if(NOT OPENRTM_FOUND)
+            message(FATAL_ERROR "OpenRTM-aist not found.")
+        endif()
+    endif()
+
+    ${sharp} OpenRTM-aist version
+    file(GLOB _vers RELATIVE "${dol}{OPENRTM_DIR}/jar" "${dol}{OPENRTM_DIR}/jar/OpenRTM-aist-*.jar")
+    if("${dol}{_vers}" STREQUAL "")
+        message(FATAL_ERROR "OpenRTM jar file not found.")
+    endif()
+
+    if("${dol}{_vers}" MATCHES "OpenRTM-aist-")
+        string(REGEX REPLACE "OpenRTM-aist-" "" _vers "${dol}{_vers}")
+        string(REGEX REPLACE "\\.jar${dol}" "" _vers "${dol}{_vers}")
+        set(OPENRTM_VERSION "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\1" OPENRTM_VERSION_MAJOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\2" OPENRTM_VERSION_MINOR "${dol}{_vers}")
+        string(REGEX REPLACE "([0-9]+)\\.([0-9]+)\\.([0-9]+)"
+               "\\3" OPENRTM_VERSION_PATCH "${dol}{_vers}")
+    endif()
+
+    file(GLOB _jars "${dol}{OPENRTM_DIR}/jar/*.jar")
+    set(OPENRTM_CLASSPATH "${dol}{_jars}")
+
+endif(WIN32)
+
+message(STATUS "FindOpenRTMSafety setup done.")
+
+message(STATUS "  OPENRTM_DIR=${dol}{OPENRTM_DIR}")
+message(STATUS "  OPENRTM_VERSION=${dol}{OPENRTM_VERSION}")
+message(STATUS "  OPENRTM_VERSION_MAJOR=${dol}{OPENRTM_VERSION_MAJOR}")
+message(STATUS "  OPENRTM_VERSION_MINOR=${dol}{OPENRTM_VERSION_MINOR}")
+message(STATUS "  OPENRTM_VERSION_PATCH=${dol}{OPENRTM_VERSION_PATCH}")
+message(STATUS "  OPENRTM_CLASSPATH=${dol}{OPENRTM_CLASSPATH}")

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/cmake_safetycompile.cmake.in.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,48 @@
+include("@PROJECT_BINARY_DIR@/CMakeFiles/CMakeSafetyCompiler.cmake")
+
+set(_srcdir @SAFETYC_SOURCE_DIRS@)
+set(_destdir "@SAFETYC_DEST_DIR@")
+set(_classpath "@SAFETYC_CLASSPATH@")
+
+function(__safety_copy_file src dest)
+    exec_program("${dol}{CMAKE_COMMAND} -E copy_if_different \"${dol}{src}\" \"${dol}{dest}\""
+        OUTPUT_VARIABLE _out
+        RETURN_VALUE _retval)
+    message(STATUS "Copying \"${dol}{src}\" to the build directory")
+    message(STATUS ${dol}{_out})
+    if(NOT "${dol}{_retval}" STREQUAL 0)
+        message(FATAL_ERROR "Problem when copying \"${dol}{src}\"")
+    endif()
+endfunction()
+
+set(_sources)
+
+foreach(_dir ${dol}{_srcdir})
+    set(_files)
+
+    file(GLOB_RECURSE _globs RELATIVE "${dol}{_dir}" "${dol}{_dir}/*")
+    foreach(_file ${dol}{_globs})
+        get_filename_component(_file_ext "${dol}{_file}" EXT)
+        if(_file MATCHES "/.svn/")
+        elseif(_file_ext MATCHES ".c${dol}")
+            list(APPEND _sources "${dol}{_dir}/${dol}{_file}")
+        else()
+            __safety_copy_file("${dol}{_dir}/${dol}{_file}" "${dol}{_destdir}/${dol}{_file}")
+        endif()
+    endforeach()
+endforeach()
+
+message(STATUS "Compiling")
+foreach(f ${dol}{_sources})
+    message(STATUS "    ${dol}{f}")
+endforeach()
+
+string(REPLACE ";" " " _sources "${dol}{_sources}")
+exec_program("${dol}{CMAKE_Safety_COMPILER}"
+    ARGS "-d ${dol}{_destdir} -cp \"${dol}{_classpath}\" ${dol}{_sources}"
+    OUTPUT_VARIABLE _out
+    RETURN_VALUE _retval)
+message(STATUS ${dol}{_out})
+if(NOT "${dol}{_retval}" STREQUAL 0)
+    message(FATAL_ERROR "Problem when compiling \"${dol}{_sources}\"")
+endif()

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/cmake/wix.xsl.in.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<xsl:stylesheet version="1.0"
+   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+   xmlns:wix="http://schemas.microsoft.com/wix/2006/wi">
+  <xsl:output indent="yes" method="xml"/>
+
+  <xsl:template match="/wix:Wix">
+    <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
+      <Product xmlns="http://schemas.microsoft.com/wix/2006/wi" Id="${WIX_PRODUCT_ID}" Name="@RTC_NAME@ @PACKAGE_VERSION@" Language="1041" Codepage="932" Version="@PACKAGE_VERSION@" Manufacturer="@RTC_VENDOR@" UpgradeCode="${WIX_UPGRADECODE}">
+        <Package InstallerVersion="300" Compressed="yes" Languages='1041' SummaryCodepage='932' />
+        <Media Id="1" Cabinet="@RTC_NAME at .cab" EmbedCab="yes" />
+        <Directory Id="TARGETDIR" Name="SourceDir" >
+            <Directory Id="ProgramFilesFolder" Name="PFILE" >
+                <Directory Id="OPENRTM_DIR" Name="OpenRTM-aist" >
+                    <Directory Id="INSTALLLOCATION" Name="@OPENRTM_VERSION_MAJOR at .@OPENRTM_VERSION_MINOR@" />
+                </Directory>
+            </Directory>
+        </Directory>
+
+        <Feature Id="APPLICATIONS" Title="@CPACK_COMPONENT_APPLICATIONS_DISPLAY_NAME@" Level="1" Description="@CPACK_COMPONENT_APPLICATIONS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .bat')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\@RTC_NAME at .sh')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\bin')]" />
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\RTC.xml')]" />
+        </Feature>
+
+        <Feature Id="DOCUMENTS" Title="@CPACK_COMPONENT_DOCUMENTS_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_DOCUMENTS_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\doc')]" />
+        </Feature>
+
+        <Feature Id="SOURCES" Title="@CPACK_COMPONENT_SOURCES_DISPLAY_NAME@" Level="1" Absent="allow" Description="@CPACK_COMPONENT_SOURCES_DESCRIPTION@" >
+          <!-- Start Ripping through the xml -->
+          <xsl:apply-templates select="wix:Fragment/wix:DirectoryRef/wix:Component[contains(wix:File/@Source, '@PACKAGE_NAME@@PACKAGE_VERSION@\src')]" />
+        </Feature>
+
+        <!--Tack on your specific wix options-->
+        <UIRef Id="WixUI_FeatureTree" />
+        <UIRef Id="WixUI_ErrorProgressText" />
+        <WixVariable Id="WixUILicenseRtf" Value="@CPACK_RESOURCE_FILE_LICENSE@"/>
+        <!-- TODO: Add Wix Specific Dialogs and features. -->
+        <!-- TODO: Add artwork  -->
+        <!-- TODO: Add ... -->
+
+      </Product>
+
+      <!--Output the fragment info which heat generates-->
+      <xsl:copy-of select="wix:Fragment[wix:DirectoryRef/wix:Component]" />
+      <xsl:apply-templates select="wix:Fragment[wix:DirectoryRef/@Id!='TARGETDIR' and wix:DirectoryRef/wix:Directory]" />
+
+    </Wix>
+  </xsl:template>
+
+  <xsl:template match="wix:Fragment[wix:DirectoryRef/wix:Directory]" >
+    <xsl:copy>
+      <xsl:apply-templates select="wix:DirectoryRef" />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:DirectoryRef" >
+    <xsl:copy>
+      <xsl:choose>
+        <xsl:when test="wix:Directory[@Name='components']" >
+          <xsl:attribute name="Id">INSTALLLOCATION</xsl:attribute>
+        </xsl:when>
+        <xsl:otherwise>
+          <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+        </xsl:otherwise>
+      </xsl:choose>
+      <xsl:apply-templates />
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Directory" >
+    <xsl:copy>
+      <xsl:attribute name="Id"><xsl:value-of select="@Id" /></xsl:attribute>
+      <xsl:attribute name="Name"><xsl:value-of select="@Name" /></xsl:attribute>
+    </xsl:copy>
+  </xsl:template>
+
+  <xsl:template match="wix:Component">
+    <xsl:element name="ComponentRef" xmlns="http://schemas.microsoft.com/wix/2006/wi" >
+      <xsl:attribute name="Id">
+        <xsl:value-of select="@Id" />
+      </xsl:attribute>
+    </xsl:element>
+  </xsl:template>
+
+</xsl:stylesheet>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_Comp.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,110 @@
+// -*- C -*-
+/*!
+ * @file ${rtcParam.name}Comp.c
+ * @brief Standalone component
+#set( $Date$ = "dummy" )
+ * @date \$Date$
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+#set( $Id$ = "dummy" )
+ * \$Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.ModuleInitProc;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class ${rtcParam.name}Comp
+ * @brief Standalone component Class
+ *
+ */
+public class ${rtcParam.name}Comp implements ModuleInitProc {
+
+    public void myModuleInit(Manager mgr) {
+      Properties prop = new Properties(${rtcParam.name}.component_conf);
+      mgr.registerFactory(prop, new ${rtcParam.name}(), new ${rtcParam.name}());
+
+      // Create a component
+      RTObject_impl comp = mgr.createComponent("${rtcParam.name}");
+      if( comp==null ) {
+    	  System.err.println("Component create failed.");
+    	  System.exit(0);
+      }
+      
+      // Example
+      // The following procedure is examples how handle RT-Components.
+      // These should not be in this function.
+
+//      // Get the component's object reference
+//      Manager manager = Manager.instance();
+//      RTObject rtobj = null;
+//      try {
+//          rtobj = RTObjectHelper.narrow(manager.getPOA().servant_to_reference(comp));
+//      } catch (ServantNotActive e) {
+//          e.printStackTrace();
+//      } catch (WrongPolicy e) {
+//          e.printStackTrace();
+//      }
+//
+//      // Get the port list of the component
+//      PortListHolder portlist = new PortListHolder();
+//      portlist.value = rtobj.get_ports();
+//
+//      // getting port profiles
+//      System.out.println( "Number of Ports: " );
+//      System.out.println( portlist.value.length );
+//      for( int intIdx=0;intIdx<portlist.value.length;++intIdx ) {
+//          Port port = portlist.value[intIdx];
+//          System.out.println( "Port" + intIdx + " (name): ");
+//          System.out.println( port.get_port_profile().name );
+//        
+//          PortInterfaceProfileListHolder iflist = new PortInterfaceProfileListHolder();
+//          iflist.value = port.get_port_profile().interfaces;
+//          System.out.println( "---interfaces---" );
+//          for( int intIdx2=0;intIdx2<iflist.value.length;++intIdx2 ) {
+//              System.out.println( "I/F name: " );
+//              System.out.println( iflist.value[intIdx2].instance_name  );
+//              System.out.println( "I/F type: " );
+//              System.out.println( iflist.value[intIdx2].type_name );
+//              if( iflist.value[intIdx2].polarity==PortInterfacePolarity.PROVIDED ) {
+//                  System.out.println( "Polarity: PROVIDED" );
+//              } else {
+//                  System.out.println( "Polarity: REQUIRED" );
+//              }
+//          }
+//          System.out.println( "---properties---" );
+//          NVUtil.dump( new NVListHolder(port.get_port_profile().properties) );
+//          System.out.println( "----------------" );
+//      }
+    }
+
+    public static void main(String[] args) {
+        // Initialize manager
+        final Manager manager = Manager.init(args);
+
+        // Set module initialization proceduer
+        // This procedure will be invoked in activateManager() function.
+        ${rtcParam.name}Comp init = new ${rtcParam.name}Comp();
+        manager.setModuleInitProc(init);
+
+        // Activate manager and register to naming service
+        manager.activateManager();
+
+        // run the manager in blocking mode
+        // runManager(false) is the default.
+        manager.runManager();
+
+        // If you want to run the manager in non-blocking mode, do like this
+        // manager.runManager(true);
+    }
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,89 @@
+// -*- Java -*-
+/*!
+ * @file ${rtcParam.name}.java
+#set( $Date$ = "dummy" )
+ * @date \$Date$
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+#set( $Id$ = "dummy" )
+ * \$Id$
+ */
+
+import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.RTObject_impl;
+import jp.go.aist.rtm.RTC.RtcDeleteFunc;
+import jp.go.aist.rtm.RTC.RtcNewFunc;
+import jp.go.aist.rtm.RTC.RegisterModuleFunc;
+import jp.go.aist.rtm.RTC.util.Properties;
+
+/*!
+ * @class ${rtcParam.name}
+ * @brief ${rtcParam.description}
+ */
+public class ${rtcParam.name} implements RtcNewFunc, RtcDeleteFunc, RegisterModuleFunc {
+
+//  Module specification
+//  <rtc-template block="module_spec">
+    public static String component_conf[] = {
+    	    "implementation_id", "${rtcParam.name}",
+    	    "type_name",         "${rtcParam.name}",
+    	    "description",       "${rtcParam.description}",
+    	    "version",           "${rtcParam.version}",
+    	    "vendor",            "${rtcParam.vender}",
+    	    "category",          "${rtcParam.category}",
+    	    "activity_type",     "${rtcParam.componentType}",
+    	    "max_instance",      "${rtcParam.maxInstance}",
+    	    "language",          "Java",
+    	    "lang_type",         "compile",
+#if( ${rtcParam.configParams.size()} > 0 )
+            // Configuration variables
+#foreach($configParam in ${rtcParam.configParams})  
+            "conf.default.${configParam.name}", "${configParam.defaultVal}",
+#end
+#end
+#if( ${rtcParam.configParams.size()} > 0 )
+            // Widget
+#foreach($configParam in ${rtcParam.configParams})
+#if( ${configParam.widget.length()} > 0 )
+            "conf.__widget__.${configParam.name}", "${configParam.widget}#if( ${configParam.step.length()} > 0 ).${configParam.step}#end",
+#end
+#end
+            // Constraints
+#foreach($configParam in ${rtcParam.configParams})
+#if( ${configParam.constraint.length()} > 0 )
+            "conf.__constraints__.${configParam.name}", "${configParam.constraint}",
+#end
+#end
+#end
+#if( ${rtcParam.configParameterParams.size()} > 0 )
+            // System Configuration
+#foreach($parameterParam in ${rtcParam.configParameterParams})  
+#if( ${parameterParam.isNonPeriodic()} )
+            "${parameterParam.configName}", "${parameterParam.defaultVal}",
+#end
+#end
+#end
+    	    ""
+            };
+//  </rtc-template>
+
+    public RTObject_impl createRtc(Manager mgr) {
+        return new ${rtcParam.name}Impl(mgr);
+    }
+
+    public void deleteRtc(RTObject_impl rtcBase) {
+        rtcBase = null;
+    }
+    public void registerModule() {
+        Properties prop = new Properties(component_conf);
+        final Manager manager = Manager.instance();
+        manager.registerFactory(prop, new ${rtcParam.name}(), new ${rtcParam.name}());
+    }
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_RTC_Impl.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,627 @@
+// -*- Java -*-
+/*!
+ * @file  ${rtcParam.name}Impl.java
+ * @brief ${rtcParam.description}
+#set( $Date$ = "dummy" )
+ * @date  \$Date$
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+#set( $Id$ = "dummy" )
+ * \$Id$
+ */
+
+#foreach($type in ${javaConv.getPortTypes(${rtcParam})})  
+${javaConv.getDataportPackageName(${type})}
+#end
+import jp.go.aist.rtm.RTC.DataFlowComponentBase;
+import jp.go.aist.rtm.RTC.Manager;
+#if( ${rtcParam.inports.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.InPort;
+#end
+#if( ${rtcParam.outports.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.OutPort;
+#end
+#if( ${rtcParam.inports.size()} > 0 || ${rtcParam.outports.size()} > 0 )
+import jp.go.aist.rtm.RTC.util.DataRef;
+#end
+#if( ${rtcParam.originalConsumerIdls.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.CorbaConsumer;
+#end
+#if( ${rtcParam.originalProviderIdls.size()} > 0 || ${rtcParam.originalConsumerIdls.size()} > 0 )
+import jp.go.aist.rtm.RTC.port.CorbaPort;
+#end
+#if( ${rtcParam.originalProviderIdls.size()} > 0 )
+import org.omg.PortableServer.POAPackage.ObjectNotActive;
+import org.omg.PortableServer.POAPackage.ServantAlreadyActive;
+import org.omg.PortableServer.POAPackage.WrongPolicy;
+#end
+#if( ${rtcParam.configParams.size()} > 0 )
+#foreach($type in ${javaConv.getParamTypes(${rtcParam})})  
+import jp.go.aist.rtm.RTC.util.${type};
+#end
+#end
+#if( ${javaConv.useReturnCode(${rtcParam})} )
+import RTC.ReturnCode_t;
+#end
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==1)
+#if(${tmpltHelper.isModule(${serviceInterface.interfaceType})})import ${tmpltHelper.convFormat(${serviceInterface.interfaceType})};
+#end#end#end#end#end#end
+
+/*!
+ * @class ${rtcParam.name}Impl
+ * @brief ${rtcParam.description}
+#if( ${rtcParam.docDescription.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docDescription})}
+#end
+#if( ${rtcParam.docInOut.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docInOut})}
+#end
+#if( ${rtcParam.docAlgorithm.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docAlgorithm})}
+#end
+#if( ${rtcParam.docReference.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docReference})}
+#end
+ *
+ */
+public class ${rtcParam.name}Impl extends DataFlowComponentBase {
+
+  /*!
+   * @brief constructor
+   * @param manager Maneger Object
+   */
+	public ${rtcParam.name}Impl(Manager manager) {  
+        super(manager);
+        // <rtc-template block="initializer">
+#foreach($port in ${rtcParam.inports})  
+        m_${port.tmplVarName}_val = new ${javaConv.getDataTypeName(${port.type})}();
+        m_${port.tmplVarName} = new DataRef<${javaConv.getDataTypeName(${port.type})}>(m_${port.tmplVarName}_val);
+        m_${port.name}In = new InPort<${javaConv.getDataTypeName(${port.type})}>("${port.name}", m_${port.tmplVarName});
+#end
+#foreach($port in ${rtcParam.outports})  
+        m_${port.tmplVarName}_val = new ${javaConv.getDataTypeName(${port.type})}();
+        m_${port.tmplVarName} = new DataRef<${javaConv.getDataTypeName(${port.type})}>(m_${port.tmplVarName}_val);
+        m_${port.name}Out = new OutPort<${javaConv.getDataTypeName(${port.type})}>("${port.name}", m_${port.tmplVarName});
+#end
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+        m_${servicePort.name}Port = new CorbaPort("${servicePort.name}");
+#end#end#end
+        // </rtc-template>
+
+    }
+
+    /*#if(${rtcParam.configParams.size()}==0)*#else!#end
+
+#if(${rtcParam.getDocActionOverView(0).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(0)})}
+#end
+     *
+     * The initialize action (on CREATED->ALIVE transition)
+     * formaer rtc_init_entry() 
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(0).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(0)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(0).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(0)})}
+#end
+     * 
+     */
+#if( ${rtcParam.configParams.size()}>0 || ${rtcParam.inports.size()}>0 || ${rtcParam.outports.size()}>0 || ${rtcParam.servicePorts.size()}>0 || !${rtcParam.IsNotImplemented(0)} )
+    @Override
+    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+#if( ${rtcParam.inports.size()} > 0 )
+        // Set InPort buffers
+#foreach($port in ${rtcParam.inports})  
+        addInPort("${port.name}", m_${port.name}In);
+#end
+#end
+#if( ${rtcParam.outports.size()} > 0 )
+        
+        // Set OutPort buffer
+#foreach($port in ${rtcParam.outports})  
+        addOutPort("${port.name}", m_${port.name}Out);
+#end
+#end
+#if( ${rtcParam.providerIdlPathes.size()} > 0 )
+        
+        // Set service provider to Ports
+#if(${rtcParam.servicePorts.size()}>0)
+        try {
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==0)
+        	m_${servicePort.name}Port.registerProvider("${serviceInterface.name}", "${tmpltHelper.convFormat(${serviceInterface.interfaceType})}", m_${serviceInterface.tmplVarName});
+#end#end#end#end#end
+        } catch (ServantAlreadyActive e) {
+            e.printStackTrace();
+        } catch (WrongPolicy e) {
+            e.printStackTrace();
+        } catch (ObjectNotActive e) {
+            e.printStackTrace();
+        }
+#end
+#if(${rtcParam.servicePorts.size()}>0)
+        
+        // Set service consumers to Ports
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==1)
+        m_${servicePort.name}Port.registerConsumer("${serviceInterface.name}", "${tmpltHelper.convFormat(${serviceInterface.interfaceType})}", m_${serviceInterface.tmplVarName}Base);
+#end#end#end#end#end
+#if(${rtcParam.servicePorts.size()}>0)
+        
+        // Set CORBA Service Ports
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+        addPort(m_${servicePort.name}Port);
+#end#end#end
+        // </rtc-template>
+#foreach($configParam in ${rtcParam.configParams})  
+        bindParameter("${configParam.name}", m_${configParam.tmplVarName}, "${configParam.defaultVal}");
+#end
+#if(${tmpltHelper.checkDetailContent(0,${rtcParam})})${rtcParam.getDetailContent(0)}
+#end
+        return super.onInitialize();
+    }
+#else
+//    @Override
+//    protected ReturnCode_t onInitialize() {
+        // Registration: InPort/OutPort/Service
+        // <rtc-template block="registration">
+        // </rtc-template>
+//        return super.onInitialize();
+//    }
+#end
+
+    /***
+#if(${rtcParam.getDocActionOverView(1).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(1)})}
+#end
+     *
+     * The finalize action (on ALIVE->END transition)
+     * formaer rtc_exiting_entry()
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(1).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(1)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(1).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(1)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(1)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(1)})//#end    protected ReturnCode_t onFinalize() {
+#if(${tmpltHelper.checkDetailContent(1,${rtcParam})})${rtcParam.getDetailContent(1)}
+#end
+#if(${rtcParam.IsNotImplemented(1)})//#end        return super.onFinalize();
+#if(${rtcParam.IsNotImplemented(1)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(2).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(2)})}
+#end
+     *
+     * The startup action when ExecutionContext startup
+     * former rtc_starting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(2).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(2)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(2).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(2)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(2)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(2)})//#end    protected ReturnCode_t onStartup(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(2,${rtcParam})})${rtcParam.getDetailContent(2)}
+#end
+#if(${rtcParam.IsNotImplemented(2)})//#end        return super.onStartup(ec_id);
+#if(${rtcParam.IsNotImplemented(2)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(3).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(3)})}
+#end
+     *
+     * The shutdown action when ExecutionContext stop
+     * former rtc_stopping_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(3).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(3)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(3).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(3)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(3)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(3)})//#end    protected ReturnCode_t onShutdown(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(3,${rtcParam})})${rtcParam.getDetailContent(3)}
+#end
+#if(${rtcParam.IsNotImplemented(3)})//#end        return super.onShutdown(ec_id);
+#if(${rtcParam.IsNotImplemented(3)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(4).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(4)})}
+#end
+     *
+     * The activated action (Active state entry action)
+     * former rtc_active_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(4).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(4)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(4).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(4)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(4)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(4)})//#end    protected ReturnCode_t onActivated(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(4,${rtcParam})})${rtcParam.getDetailContent(4)}
+#end
+#if(${rtcParam.IsNotImplemented(4)})//#end        return super.onActivated(ec_id);
+#if(${rtcParam.IsNotImplemented(4)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(5).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(5)})}
+#end
+     *
+     * The deactivated action (Active state exit action)
+     * former rtc_active_exit()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(5).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(5)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(5).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(5)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(5)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(5)})//#end    protected ReturnCode_t onDeactivated(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(5,${rtcParam})})${rtcParam.getDetailContent(5)}
+#end
+#if(${rtcParam.IsNotImplemented(5)})//#end        return super.onDeactivated(ec_id);
+#if(${rtcParam.IsNotImplemented(5)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(9).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(9)})}
+#end
+     *
+     * The execution action that is invoked periodically
+     * former rtc_active_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(9).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(9)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(9).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(9)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(9)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(9)})//#end    protected ReturnCode_t onExecute(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(9,${rtcParam})})${rtcParam.getDetailContent(9)}
+#end
+#if(${rtcParam.IsNotImplemented(9)})//#end        return super.onExecute(ec_id);
+#if(${rtcParam.IsNotImplemented(9)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(6).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(6)})}
+#end
+     *
+     * The aborting action when main logic error occurred.
+     * former rtc_aborting_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(6).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(6)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(6).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(6)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(6)})//#end  @Override
+#if(${rtcParam.IsNotImplemented(6)})//#end  public ReturnCode_t onAborting(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(6,${rtcParam})})${rtcParam.getDetailContent(6)}
+#end
+#if(${rtcParam.IsNotImplemented(6)})//#end      return super.onAborting(ec_id);
+#if(${rtcParam.IsNotImplemented(6)})//#end  }
+
+    /***
+#if(${rtcParam.getDocActionOverView(7).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(7)})}
+#end
+     *
+     * The error action in ERROR state
+     * former rtc_error_do()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(7).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(7)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(7).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(7)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(7)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(7)})//#end    public ReturnCode_t onError(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(7,${rtcParam})})${rtcParam.getDetailContent(7)}
+#end
+#if(${rtcParam.IsNotImplemented(7)})//#end        return super.onError(ec_id);
+#if(${rtcParam.IsNotImplemented(7)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(8).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(8)})}
+#end
+     *
+     * The reset action that is invoked resetting
+     * This is same but different the former rtc_init_entry()
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(8).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(8)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(8).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(8)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(8)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(8)})//#end    protected ReturnCode_t onReset(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(8,${rtcParam})})${rtcParam.getDetailContent(8)}
+#end
+#if(${rtcParam.IsNotImplemented(8)})//#end        return super.onReset(ec_id);
+#if(${rtcParam.IsNotImplemented(8)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(10).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(10)})}
+#end
+     *
+     * The state update action that is invoked after onExecute() action
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(10).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(10)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(10).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(10)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(10)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(10)})//#end    protected ReturnCode_t onStateUpdate(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(10,${rtcParam})})${rtcParam.getDetailContent(10)}
+#end
+#if(${rtcParam.IsNotImplemented(10)})//#end        return super.onStateUpdate(ec_id);
+#if(${rtcParam.IsNotImplemented(10)})//#end    }
+
+    /***
+#if(${rtcParam.getDocActionOverView(11).length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${rtcParam.getDocActionOverView(11)})}
+#end
+     *
+     * The action that is invoked when execution context's rate is changed
+     * no corresponding operation exists in OpenRTm-aist-0.2.0
+     *
+     * @param ec_id target ExecutionContext Id
+     *
+     * @return RTC::ReturnCode_t
+     * 
+#if(${rtcParam.getDocActionPreCondition(11).length()}>0)     * @pre ${tmpltHelperJava.convertPreDocJava(${rtcParam.getDocActionPreCondition(11)})}
+#end
+#if(${rtcParam.getDocActionPostCondition(11).length()}>0)     * @post ${tmpltHelperJava.convertPostDocJava(${rtcParam.getDocActionPostCondition(11)})}
+#end
+     * 
+     */
+#if(${rtcParam.IsNotImplemented(11)})//#end    @Override
+#if(${rtcParam.IsNotImplemented(11)})//#end    protected ReturnCode_t onRateChanged(int ec_id) {
+#if(${tmpltHelper.checkDetailContent(11,${rtcParam})})${rtcParam.getDetailContent(11)}
+#end
+#if(${rtcParam.IsNotImplemented(11)})//#end        return super.onRateChanged(ec_id);
+#if(${rtcParam.IsNotImplemented(11)})//#end    }
+//
+#if( ${rtcParam.configParams.size()} > 0 )
+	// Configuration variable declaration
+	// <rtc-template block="config_declare">
+#foreach($configParam in ${rtcParam.configParams})  
+    /*!
+     * ${tmpltHelperJava.convertDescDocJava(${configParam.docDescription})}
+     * - Name: ${configParam.docDataName} ${configParam.tmplVarName}
+     * - DefaultValue: ${configParam.defaultVal}
+#if(${configParam.docUnit.length()}>0)     * - Unit: ${tmpltHelperJava.convertUnitDocJava(${configParam.docUnit})}
+#end
+#if(${configParam.docRange.length()}>0)     * - Range: ${tmpltHelperJava.convertRangeDocJava(${configParam.docRange})}
+#end
+#if(${configParam.docConstraint.length()}>0)     * - Constraint: ${tmpltHelperJava.convertConstraintDocJava(${configParam.docConstraint})}
+#end
+     */
+    protected ${javaConv.convJava2ParamHolder(${configParam.type},true)} m_${configParam.tmplVarName} = new ${javaConv.convJava2ParamHolder(${configParam.type},true)}();
+#end
+	// </rtc-template>
+
+#end
+    // DataInPort declaration
+    // <rtc-template block="inport_declare">
+#foreach($port in ${rtcParam.inports})  
+    protected ${javaConv.getDataTypeName(${port.type})} m_${port.tmplVarName}_val;
+    protected DataRef<${javaConv.getDataTypeName(${port.type})}> m_${port.tmplVarName};
+    /*!
+#if(${port.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${port.docDescription})}
+#end
+#if(${port.docType.length()}>0)     * - Type: ${tmpltHelperJava.convertTypeDocJava(${port.docType})}
+#end
+#if(${port.docNum.length()}>0)     * - Number: ${tmpltHelperJava.convertNumberDocJava(${port.docNum})}
+#end
+#if(${port.docSemantics.length()}>0)     * - Semantics: ${tmpltHelperJava.convertSemanticsDocJava(${port.docSemantics})}
+#end
+#if(${port.docUnit.length()}>0)     * - Unit: ${tmpltHelperJava.convertTypeDocJava(${port.docUnit})}
+#end
+#if(${port.docOccurrence.length()}>0)     * - Frequency: ${tmpltHelperJava.convertFrequencyDocJava(${port.docOccurrence})}
+#end
+#if(${port.docOperation.length()}>0)     * - Operation Cycle: ${tmpltHelperJava.convertCycleDocJava(${port.docOperation})}
+#end
+     */
+    protected InPort<${javaConv.getDataTypeName(${port.type})}> m_${port.name}In;
+
+#end
+    
+    // </rtc-template>
+
+    // DataOutPort declaration
+    // <rtc-template block="outport_declare">
+#foreach($port in ${rtcParam.outports})  
+    protected ${javaConv.getDataTypeName(${port.type})} m_${port.tmplVarName}_val;
+    protected DataRef<${javaConv.getDataTypeName(${port.type})}> m_${port.tmplVarName};
+    /*!
+#if(${port.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${port.docDescription})}
+#end
+#if(${port.docType.length()}>0)     * - Type: ${tmpltHelperJava.convertTypeDocJava(${port.docType})}
+#end
+#if(${port.docNum.length()}>0)     * - Number: ${tmpltHelperJava.convertNumberDocJava(${port.docNum})}
+#end
+#if(${port.docSemantics.length()}>0)     * - Semantics: ${tmpltHelperJava.convertSemanticsDocJava(${port.docSemantics})}
+#end
+#if(${port.docUnit.length()}>0)     * - Unit: ${tmpltHelperJava.convertTypeDocJava(${port.docUnit})}
+#end
+#if(${port.docOccurrence.length()}>0)     * - Frequency: ${tmpltHelperJava.convertFrequencyDocJava(${port.docOccurrence})}
+#end
+#if(${port.docOperation.length()}>0)     * - Operation Cycle: ${tmpltHelperJava.convertCycleDocJava(${port.docOperation})}
+#end
+     */
+    protected OutPort<${javaConv.getDataTypeName(${port.type})}> m_${port.name}Out;
+
+#end
+    
+    // </rtc-template>
+
+    // CORBA Port declaration
+    // <rtc-template block="corbaport_declare">
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+    /*!
+#if(${servicePort.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${servicePort.docDescription})}
+#end
+#if(${servicePort.docIfDescription.length()}>0)     * Interface: ${tmpltHelperJava.convertInterfaceDocJava(${servicePort.docIfDescription})}
+#end
+     */
+    protected CorbaPort m_${servicePort.name}Port;
+#end#end#end
+    
+    // </rtc-template>
+
+    // Service declaration
+    // <rtc-template block="service_declare">
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==0)
+    /*!
+#if(${serviceInterface.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${serviceInterface.docDescription})}
+#end
+#if(${serviceInterface.docArgument.length()}>0)     * - Argument:      ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docArgument})}
+#end
+#if(${serviceInterface.docReturn.length()}>0)     * - Return Value:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docReturn})}
+#end
+#if(${serviceInterface.docException.length()}>0)     * - Exception:     ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docException})}
+#end
+#if(${serviceInterface.docPreCondition.length()}>0)     * - PreCondition:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPreCondition})}
+#end
+#if(${serviceInterface.docPostCondition.length()}>0)     * - PostCondition: ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPostCondition})}
+#end
+     */
+    protected ${serviceInterface.interfaceRawType}${tmpltHelper.serviceImplSuffix} m_${serviceInterface.tmplVarName} = new ${serviceInterface.interfaceRawType}${tmpltHelper.serviceImplSuffix}();
+#end#end#end#end#end
+    
+    // </rtc-template>
+
+    // Consumer declaration
+    // <rtc-template block="consumer_declare">
+#if(${rtcParam.servicePorts.size()}>0)
+#foreach($servicePort in ${rtcParam.servicePorts})
+#if(${servicePort.servicePortInterfaces.size()}>0)
+#foreach($serviceInterface in ${servicePort.servicePortInterfaces})
+#if(${serviceInterface.index}==1)
+    protected CorbaConsumer<${serviceInterface.interfaceRawType}> m_${serviceInterface.tmplVarName}Base = new CorbaConsumer<${serviceInterface.interfaceRawType}>(${serviceInterface.interfaceRawType}.class);
+    /*!
+#if(${serviceInterface.docDescription.length()}>0)     * ${tmpltHelperJava.convertDescDocJava(${serviceInterface.docDescription})}
+#end
+#if(${serviceInterface.docArgument.length()}>0)     * - Argument:      ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docArgument})}
+#end
+#if(${serviceInterface.docReturn.length()}>0)     * - Return Value:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docReturn})}
+#end
+#if(${serviceInterface.docException.length()}>0)     * - Exception:     ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docException})}
+#end
+#if(${serviceInterface.docPreCondition.length()}>0)     * - PreCondition:  ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPreCondition})}
+#end
+#if(${serviceInterface.docPostCondition.length()}>0)     * - PostCondition: ${tmpltHelperJava.convertInterfaceDetailDocJava(${serviceInterface.docPostCondition})}
+#end
+     */
+    protected ${serviceInterface.interfaceRawType} m_${serviceInterface.tmplVarName};
+#end#end#end#end#end
+    
+    // </rtc-template>
+
+#foreach($privateAttribute in ${rtcParam.privateAttributes})
+  ${privateAttribute}
+#end
+#foreach($privateOperation in ${rtcParam.privateOperations})
+  ${privateOperation}
+#end
+#foreach($protectedAttribute in ${rtcParam.protectedAttributes})
+  ${protectedAttribute}
+#end
+#foreach($protectedOperation in ${rtcParam.protectedOperations})
+  ${protectedOperation}
+#end
+#foreach($publicAttribute in ${rtcParam.publicAttributes})
+  ${publicAttribute}
+#end
+#foreach($publicOperation in ${rtcParam.publicOperations})
+  ${publicOperation}
+#end
+#if(${tmpltHelper.checkContents(${rtcParam.publicOpeSource})})${rtcParam.publicOpeSource}
+#end
+#if(${tmpltHelper.checkContents(${rtcParam.protectedOpeSource})})${rtcParam.protectedOpeSource}
+#end
+#if(${tmpltHelper.checkContents(${rtcParam.privateOpeSource})})${rtcParam.privateOpeSource}
+#end
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/Safety_SVC.c.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,43 @@
+// -*-Java-*-
+/*!
+ * @file  ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix}.java
+ * @brief Service implementation code of ${idlFileParam.idlFile}
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *
+ */
+#if(${tmpltHelper.isModule(${serviceClassParam.name})})import ${tmpltHelper.convFormat(${serviceClassParam.name})}POA;
+#end
+/*!
+ * @class ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix}
+ * Example class implementing IDL interface ${serviceClassParam.name}
+ */
+public class ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix} extends ${tmpltHelper.getBasename(${serviceClassParam.name})}POA{
+    
+    public ${tmpltHelper.getBasename(${serviceClassParam.name})}${tmpltHelper.serviceImplSuffix}() {
+        // Please add extra constructor code here.
+    }
+
+    /*
+     * Methods corresponding to IDL attributes and operations
+     */
+#foreach($serviceMethodParam in ${serviceClassParam.methods})
+    public ${javaConv.convCORBA2Java(${serviceMethodParam},${serviceClassParam})} ${serviceMethodParam.name}(#foreach($serviceArgumentParam in ${serviceMethodParam.arguments})#if($velocityCount > 1), #end${javaConv.convCORBA2JavaforArg(${serviceArgumentParam},${serviceArgumentParam.direction},${serviceClassParam})} ${serviceArgumentParam.name}#end) {
+        // Please insert your code here and remove the following warning pragma
+        // TODO "Code missing in function <${javaConv.convCORBA2JavaNoDef(${serviceMethodParam.type})} ${serviceMethodParam.name}(#foreach($serviceArgumentParam in ${serviceMethodParam.arguments})#if($velocityCount > 1), #end${javaConv.convCORBA2JavaforArg(${serviceArgumentParam.type},${serviceArgumentParam.direction})} ${serviceArgumentParam.name}#end)>"
+#if(!${serviceMethodParam.isVoid})#if(${javaConv.isRetNull(${serviceMethodParam},${serviceClassParam})})        return null;
+#elseif(${serviceMethodParam.isBoolean})        return false;
+#else        return 0;
+#end
+#end
+    }
+
+#end
+//  End of example implementational code
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/_doc.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+#if( ${rtcParam.docCreator.length()} > 0 )
+ *
+ * @author ${tmpltHelper.convertAuthorDoc(${rtcParam.docCreator})}
+#end
+#if( ${rtcParam.docLicense.length()} > 0 )
+ *
+ * ${tmpltHelper.convertDoc(${rtcParam.docLicense})}
+#end
+ *

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/build.xml.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,62 @@
+#set( $dollarStr = "$" )
+<!--
+# -*- Buildfile -*-
+# @file  build_${rtcParam.name}.xml
+# @brief RTComponent makefile for "${rtcParam.name} component"
+# @date  ${dollarStr}Date${dollarStr}
+#
+# ${dollarStr}Id${dollarStr}
+ -->
+<project name="${rtcParam.name}" default="compile">
+	<property name="source" value="src" />
+	<property name="dest" value="bin" />
+	<property environment="env" />
+
+	<target name="mkdir">
+		<mkdir dir="${dollarStr}{dest}" />
+	</target>
+
+#if( ${rtcParam.providerIdlPathes.size()} > 0 || ${rtcParam.consumerIdlPathes.size()} > 0 )
+	<target name="idlcompile"  depends="mkdir">
+#foreach($idlPath in ${rtcParam.providerIdlPathes})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idlPath.idlFile})}'"/>
+		</exec>
+#foreach ($idl in ${idlPath.includeIdlParams})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idl.idlFile})}'"/>
+		</exec>
+#end
+#end
+#foreach($idlPath in ${rtcParam.consumerIdlPathes})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idlPath.idlFile})}'"/>
+		</exec>
+#foreach ($idl in ${idlPath.includeIdlParams})
+		<exec executable="${dollarStr}{safety.home}/../bin/idlj">
+			<arg line="-td 'src' #foreach($idlSearchPath in ${idlPath.idlSearchPathes})-i '${idlSearchPath}' #end-fall 'idl/${tmpltHelper.getFileName(${idl.idlFile})}'"/>
+		</exec>
+#end
+#end
+	</target>
+#end
+
+#if( ${rtcParam.providerIdlPathes.size()} > 0 || ${rtcParam.consumerIdlPathes.size()} > 0 )
+	<target name="compile" depends="idlcompile">
+#else
+	<target name="compile" depends="mkdir">
+#end
+		<safatyc srcdir="${dollarStr}{source}" destdir="${dollarStr}{dest}">
+			<classpath>
+				<fileset dir="${dollarStr}{env.RTM_SAFETY_ROOT}/jar">
+					<include name="*.jar"/>
+				</fileset>
+#if( ${rtcParam.libraryPathes.size()} > 0 )
+#foreach($safetyRef in ${rtcParam.libraryPathes})
+				<pathelement location="'${safetyRef}'"/>
+#end
+#end
+			</classpath>
+		</safetyc>
+	</target>
+</project>

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/classpath.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+#if( ${tmpltHelperJava.notNullRTMRoot()} )
+	<classpathentry kind="lib" path="${javaRoot}/jar/OpenRTM-aist-${rtcParam.rtmJavaVersion}.jar"/>
+#end
+	<classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.bat.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,5 @@
+set CLASSPATH=.;%RTM_JAVA_ROOT%\jar\OpenRTM-aist-${rtcParam.rtmJavaVersion}.jar;%RTM_JAVA_ROOT%\jar\commons-cli-1.1.jar
+cd /d %~dp0
+cd bin
+java ${rtcParam.name}Comp -f rtc.conf %*
+pause;

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/template/safety/run.sh.vsl	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,10 @@
+#!/bin/sh
+if test "x${dol}RTM_JAVA_ROOT" = "x" ; then
+    echo "Environment variable RTM_JAVA_ROOT is not set."
+    echo "Please specify the OpenRTM-aist installation directory."
+    echo "Abort."
+    exit 1
+fi
+export CLASSPATH=.:${dol}{RTM_JAVA_ROOT}/jar/OpenRTM-aist-${rtcParam.rtmJavaVersion}.jar:${dol}{RTM_JAVA_ROOT}/jar/commons-cli-1.1.jar
+cd `dirname ${dol}0`/bin
+java ${rtcParam.name}Comp -f rtc.conf ${dol}*

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/src/jp/go/aist/rtm/rtcbuilder/safety/ui/Perspective/SafetyProperty.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,40 @@
+package jp.go.aist.rtm.rtcbuilder.safety.ui.Perspective;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.ui.Perspective.LanguageProperty;
+
+public class SafetyProperty extends LanguageProperty {
+	private String PerspectiveId = "org.eclipse.cdt.ui.CPerspective";
+	//private String PerspectiveName = "Safety";
+	private String PerspectiveName = "C/C++";
+	private String PluginId = "org.eclipse.cdt.ui.CPerspective";
+
+	public String getPerspectiveId() {
+		System.out.println("getPerspectiveId entry");
+		return PerspectiveId;
+	}
+
+	public String getPerspectiveName() {
+		System.out.println("getPerspectiveName entry");
+		return PerspectiveName;
+	}
+
+	public String getPluginId() {
+		System.out.println("getPluginId entry");
+		return PluginId;
+	}
+
+	@Override
+	public List<String> getNatures() {
+		System.out.println("getNatures entry");
+		List<String> natures = new ArrayList<String>();
+		natures.add("org.eclipse.cdt.core.cnature");
+		natures.add("org.eclipse.cdt.make.core.makeNature");
+		natures.add("org.eclipse.cdt.make.core.ScannerConfigNature");
+		natures.add("org.eclipse.cdt.core.ccnature");
+		//natures.add("org.eclipse.jdt.core.javanature");
+		return natures;
+	}
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/TestBase.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,96 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileReader;
+import java.io.IOException;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import junit.framework.TestCase;
+
+public class TestBase extends TestCase {
+//	protected String rootPath = "C:\\Tech-Arts\\Eclipse\\jp.go.aist.rtm.rtcbuilder\\";
+	protected String rootPath;
+	protected String expPath;
+	protected String expContent;
+	protected int index;
+	protected String[] ignore_row_phrases = {"--service-idl=", "--consumer-idl"};
+
+	public TestBase () {
+		File fileCurrent = new File(".");
+		rootPath = fileCurrent.getAbsolutePath();
+		rootPath = rootPath.substring(0,rootPath.length()-1);
+	}
+	protected String readFile(String fileName) {
+		StringBuffer stbRet = new StringBuffer();
+		try{
+			FileReader fr = new FileReader(fileName);
+			BufferedReader br = new BufferedReader(fr);
+	
+			String str = new String();
+			while( (str = br.readLine()) != null ){
+				boolean isIgnore = false;
+				for(int index=0;index<ignore_row_phrases.length;index++) {
+					if(str.length()==0 || str.contains(ignore_row_phrases[index])) {
+						isIgnore = true;
+						break;
+					}
+				}
+				if(!isIgnore) stbRet.append(str + "\r\n");
+			}
+			br.close();
+			fr.close();
+		} catch (IOException e){
+			e.printStackTrace();
+		}
+		return stbRet.toString();
+	}
+	
+	protected int getFileIndex(String targetName, List<GeneratedResult> targetList) {
+		int resultindex = -1;
+		
+		for( int intIdx=0; intIdx<targetList.size(); intIdx++ ) {
+			if( targetList.get(intIdx).getName().equals(targetName) ) {
+				return intIdx;
+			}
+		}
+		return resultindex;
+	}
+	
+	protected String getGeneratedString(String source) {
+		String sep = System.getProperty( "line.separator" );
+		String[] target = source.split(sep);
+		StringBuffer stbRet = new StringBuffer();
+		
+		for( int index=0; index<target.length; index++ ) {
+			boolean isIgnore = false;
+			for(int indexi=0;indexi<ignore_row_phrases.length;indexi++) {
+				if(target[index].length()==0 || target[index].contains(ignore_row_phrases[indexi])) {
+					isIgnore = true;
+					break;
+				}
+			}
+			if(!isIgnore) stbRet.append(target[index] + sep);
+		}
+		return stbRet.toString();
+	}
+
+	protected String replaceRootPath(String content) {
+		String result = content.replace("__ROOT_PATH__", rootPath);
+		String origPath = "C:\\Tech-Arts\\EclipseRTM\\jp.go.aist.rtm.rtcbuilder.java\\";
+		result = result.replace(origPath, rootPath);
+		return result;
+	}
+
+	protected void checkCode(List<GeneratedResult> result, String resourceDir,
+			String fileName) {
+		index = getFileIndex(fileName, result);
+		expPath = resourceDir + fileName;
+		expContent = readFile(expPath);
+		expContent = replaceRootPath(expContent);
+		assertEquals(expContent,
+				getGeneratedString(result.get(index).getCode()));
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/AllTestsSafety.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,23 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+public class AllTestsSafety {
+
+	public static Test suite() {
+		TestSuite suite = new TestSuite(
+				"Test for jp.go.aist.rtm.rtcbuilder._test");
+		//$JUnit-BEGIN$
+		suite.addTestSuite(ConfigSetTest.class);
+		suite.addTestSuite(MultiTest.class);
+		suite.addTestSuite(BaseTest.class);
+		suite.addTestSuite(SafetyIDLInheritTest.class);
+		suite.addTestSuite(ModuleTest.class);
+		suite.addTestSuite(SafetyIDLTypeTest.class);
+		suite.addTestSuite(BuildTest.class);
+		//$JUnit-END$
+		return suite;
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BaseTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,285 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.DataPortParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortInterfaceParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class BaseTest extends TestBase {
+
+	Generator generator;
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	public void testServicePort2() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setRtmVersion("1.0.0");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		dataport.add(new DataPortParam("InP2", "RTC::TimedLong", "", 0));
+		rtcParam.getInports().addAll(dataport);
+		List<DataPortParam> outport = new ArrayList<DataPortParam>();
+		outport.add(new DataPortParam("OutP1", "RTC::TimedLong", "", 0));
+		outport.add(new DataPortParam("OutP2", "RTC::TimedFloat", "", 0));
+		rtcParam.getOutports().addAll(outport);
+
+		ServicePortParam service1 = new ServicePortParam("svPort", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "acc", "", "", rootPath + "/resource/MyService.idl",
+				"MyService", "", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+
+		ServicePortParam service2 = new ServicePortParam("cmPort", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service2, "rate", "", "",
+				rootPath + "/resource/DAQService.idl", "DAQService", "", 1);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		srvports.add(service2);
+
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/service2/";
+
+		assertEquals(34, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testServicePort1() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		dataport.add(new DataPortParam("InP2", "RTC::TimedLong", "", 0));
+		rtcParam.getInports().addAll(dataport);
+		List<DataPortParam> outport = new ArrayList<DataPortParam>();
+		outport.add(new DataPortParam("OutP1", "RTC::TimedLong", "", 0));
+		outport.add(new DataPortParam("OutP2", "RTC::TimedFloat", "", 0));
+		rtcParam.getOutports().addAll(outport);
+
+		ServicePortParam service1 = new ServicePortParam("svPort", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "acc", "", "", rootPath + "\\resource/MyService.idl",
+				"MyService", "", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/service1/";
+
+		assertEquals(34, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testOutPort2() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		dataport.add(new DataPortParam("InP2", "RTC::TimedLong", "", 0));
+		rtcParam.getInports().addAll(dataport);
+		List<DataPortParam> outport = new ArrayList<DataPortParam>();
+		outport.add(new DataPortParam("OutP1", "RTC::TimedLong", "", 0));
+		outport.add(new DataPortParam("OutP2", "RTC::TimedFloat", "", 0));
+		rtcParam.getOutports().addAll(outport);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/outport2/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, ".classpath");
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testOutPort1() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setComponentKind("DataFlowComponent");
+		rtcParam.setMaxInstance(5);
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		dataport.add(new DataPortParam("InP2", "RTC::TimedLong", "", 0));
+		rtcParam.getInports().addAll(dataport);
+		List<DataPortParam> outport = new ArrayList<DataPortParam>();
+		outport.add(new DataPortParam("OutP1", "RTC::TimedLong", "", 0));
+		rtcParam.getOutports().addAll(outport);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/outport1/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, ".classpath");
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testInPort2() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setComponentKind("DataFlowComponent");
+		rtcParam.setMaxInstance(5);
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		dataport.add(new DataPortParam("InP2", "RTC::TimedLong", "", 0));
+		rtcParam.getInports().addAll(dataport);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/inport2/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, ".classpath");
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testInPort() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setComponentKind("DataFlowComponent");
+		rtcParam.setMaxInstance(5);
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		rtcParam.getInports().addAll(dataport);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/inport1/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, ".classpath");
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testBasic() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/base/name/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, ".classpath");
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/BuildTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,189 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.DataPortParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortInterfaceParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class BuildTest extends TestBase {
+
+	Generator generator;
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	String fixturePath(String name) {
+		return rootPath + "resource/100/" + name;
+	}
+
+	public void testCMake1() throws Exception {
+		String name = "build/cmake1";
+
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataport = new ArrayList<DataPortParam>();
+		dataport.add(new DataPortParam("InP1", "RTC::TimedShort", "", 0));
+		dataport.add(new DataPortParam("InP2", "RTC::TimedLong", "", 0));
+		rtcParam.getInports().addAll(dataport);
+
+		List<DataPortParam> outport = new ArrayList<DataPortParam>();
+		outport.add(new DataPortParam("OutP1", "RTC::TimedInt", "", 0));
+		outport.add(new DataPortParam("OutP2", "RTC::TimedFloat", "", 0));
+		rtcParam.getOutports().addAll(outport);
+
+		ServicePortParam service1 = new ServicePortParam("svPort", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "acc", "", "", rootPath + "/resource/MyService.idl",
+				"MyService", "", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+
+		ServicePortParam service2 = new ServicePortParam("cmPort", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service2, "rate", "", "",
+				rootPath + "/resource/DAQService.idl", "DAQService", "", 1);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		srvports.add(service2);
+
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = fixturePath(name) + "/";
+
+		assertEquals(34, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		checkCode(result, resourceDir, "foo.sh");
+		checkCode(result, resourceDir, "foo.bat");
+		//
+//		checkCode(result, resourceDir, "CMakeLists.txt");
+//		checkCode(result, resourceDir, "Doxyfile.in");
+//		checkCode(result, resourceDir, "cmake_modules/cmake_uninstall.cmake.in");
+//		checkCode(result, resourceDir,
+//				"cmake_modules/cmake_javacompile.cmake.in");
+//		checkCode(result, resourceDir, "cmake_modules/CPackWIX.cmake");
+//		checkCode(result, resourceDir, "cmake_modules/FindOpenRTMJava.cmake");
+//		checkCode(result, resourceDir, "cpack_resources/Description.txt");
+//		checkCode(result, resourceDir, "cpack_resources/License.txt");
+//		checkCode(result, resourceDir, "cpack_resources/License.rtf");
+//		checkCode(result, resourceDir, "cpack_resources/wix.xsl.in");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testCMake2() throws Exception {
+		String name = "build/cmake2";
+
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("Manip");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<ServicePortParam> svports = new ArrayList<ServicePortParam>();
+
+		ServicePortParam sv1 = new ServicePortParam("MyServiceProvider", 0);
+		List<ServicePortInterfaceParam> iflist = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam sif1 = new ServicePortInterfaceParam(sv1,
+				"MyServiceProvider", "", "", fixturePath(name)
+						+ "/MyServiceChildMulti.idl", "MyServiceChild",
+				fixturePath(name), 0);
+		iflist.add(sif1);
+		ServicePortInterfaceParam sif2 = new ServicePortInterfaceParam(sv1,
+				"MyServiceProvider2", "", "", fixturePath(name)
+						+ "/MyServiceChildWithType.idl",
+				"MyServiceWithTypeChild", fixturePath(name), 0);
+		iflist.add(sif2);
+		sv1.getServicePortInterfaces().addAll(iflist);
+		svports.add(sv1);
+
+		ServicePortParam sv2 = new ServicePortParam("MyServiceRequire", 0);
+		iflist = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam sif3 = new ServicePortInterfaceParam(sv2,
+				"MyServiceRequire", "", "", fixturePath(name)
+						+ "/MyServiceChildMulti.idl", "MyServiceChild",
+				fixturePath(name), 1);
+		iflist.add(sif3);
+		ServicePortInterfaceParam sif4 = new ServicePortInterfaceParam(sv2,
+				"MyServiceRequire2", "", "", fixturePath(name)
+						+ "/MyServiceChildWithType.idl",
+				"MyServiceWithTypeChild", fixturePath(name), 1);
+		iflist.add(sif4);
+		sv2.getServicePortInterfaces().addAll(iflist);
+		svports.add(sv2);
+
+		rtcParam.getServicePorts().addAll(svports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = fixturePath(name) + "/";
+
+		assertEquals(38, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		checkCode(result, resourceDir, "foo.sh");
+		checkCode(result, resourceDir, "foo.bat");
+		//
+//		checkCode(result, resourceDir, "CMakeLists.txt");
+//		checkCode(result, resourceDir, "Doxyfile.in");
+//		checkCode(result, resourceDir, "cmake_modules/cmake_uninstall.cmake.in");
+//		checkCode(result, resourceDir,
+//				"cmake_modules/cmake_javacompile.cmake.in");
+//		checkCode(result, resourceDir, "cmake_modules/CPackWIX.cmake");
+//		checkCode(result, resourceDir, "cmake_modules/FindOpenRTMJava.cmake");
+//		checkCode(result, resourceDir, "cpack_resources/Description.txt");
+//		checkCode(result, resourceDir, "cpack_resources/License.txt");
+//		checkCode(result, resourceDir, "cpack_resources/License.rtf");
+//		checkCode(result, resourceDir, "cpack_resources/wix.xsl.in");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ConfigSetTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,189 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ConfigSetParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class ConfigSetTest extends TestBase {
+
+	Generator generator;
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	public void testAIST6() throws Exception {
+		rtcParam.setName("ModuleName");
+		rtcParam.setDescription("ModuleDescription");
+		rtcParam.setVersion("1.0.0");
+		rtcParam.setVender("VenderName");
+		rtcParam.setCategory("Category");
+		rtcParam.setComponentType("DataFlowComponent");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(1);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<ConfigSetParam> configset = new ArrayList<ConfigSetParam>();
+		configset.add(new ConfigSetParam("int_param0", "int", "", "0"));
+		configset.add(new ConfigSetParam("vector_param", "Vector", "",
+				"1.0,2.0,3.0"));
+		rtcParam.getConfigParams().addAll(configset);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String targetDir = rootPath + "/resource/100/ConfigSet/AIST6/";
+
+		assertEquals(33, result.size());
+		checkCode(result, targetDir, "src/ModuleNameComp.c");
+		checkCode(result, targetDir, "src/ModuleName.c");
+		checkCode(result, targetDir, "src/ModuleNameImpl.c");
+		//
+		checkCode(result, targetDir, "build_ModuleName.xml");
+	}
+
+	public void testConfigSet() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.3");
+		rtcParam.setVender("TA2");
+		rtcParam.setCategory("manip2");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(3);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<ConfigSetParam> configset = new ArrayList<ConfigSetParam>();
+		configset.add(new ConfigSetParam("int_param0", "int", "", "0"));
+		rtcParam.getConfigParams().addAll(configset);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/ConfigSet/configset1/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testConfigSet2() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.3");
+		rtcParam.setVender("TA2");
+		rtcParam.setCategory("manip2");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(3);
+		rtcParam.setComponentKind("DataFlowComponent");
+		rtcParam.setRtmVersion("1.0.0");
+
+		List<ConfigSetParam> configset = new ArrayList<ConfigSetParam>();
+		configset.add(new ConfigSetParam("int_param0", "int", "", "0"));
+		configset.add(new ConfigSetParam("int_param1", "int", "", "1"));
+		rtcParam.getConfigParams().addAll(configset);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/ConfigSet/configset2/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testConfigSet3() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.3");
+		rtcParam.setVender("TA2");
+		rtcParam.setCategory("manip2");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(3);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<ConfigSetParam> configset = new ArrayList<ConfigSetParam>();
+		configset.add(new ConfigSetParam("int_param0", "int", "", "0"));
+		configset.add(new ConfigSetParam("int_param1", "int", "", "1"));
+		configset
+				.add(new ConfigSetParam("double_param0", "double", "", "0.11"));
+		configset.add(new ConfigSetParam("str_param0", "String", "", "hoge"));
+		configset.add(new ConfigSetParam("str_param1", "String", "", "dara"));
+		rtcParam.getConfigParams().addAll(configset);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/ConfigSet/configset3/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testConfigSetType() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("MDesc");
+		rtcParam.setVersion("1.0.3");
+		rtcParam.setVender("TA2");
+		rtcParam.setCategory("manip2");
+		rtcParam.setComponentType("STATIC2");
+		rtcParam.setActivityType("PERIODIC2");
+		rtcParam.setMaxInstance(3);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<ConfigSetParam> configset = new ArrayList<ConfigSetParam>();
+		configset.add(new ConfigSetParam("short_param", "short", "", "0"));
+		configset.add(new ConfigSetParam("int_param", "int", "", "1"));
+		configset.add(new ConfigSetParam("long_param", "long", "", "14"));
+		configset.add(new ConfigSetParam("float_param", "float", "", "0.11"));
+		configset.add(new ConfigSetParam("double_param", "double", "", "4.11"));
+		configset.add(new ConfigSetParam("str_param0", "string", "", "hoge"));
+		configset.add(new ConfigSetParam("str_param1", "string", "", "dara"));
+		rtcParam.getConfigParams().addAll(configset);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath
+				+ "/resource/100/ConfigSet/ConfigSetType/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/ModuleTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,158 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortInterfaceParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class ModuleTest extends TestBase {
+
+	Generator generator;
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	public void testServicePortProv() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("ModuleDescription");
+		rtcParam.setVersion("1.0.0");
+		rtcParam.setVender("VenderName");
+		rtcParam.setCategory("Category");
+		rtcParam.setComponentType("UNIQUE");
+		rtcParam.setActivityType("EVENTDRIVEN");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		ServicePortParam service1 = new ServicePortParam("sv_name", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "if_name", "", "", rootPath
+						+ "/resource/100/module/serviceM/MyService.idl",
+				"SimpleService::MyService", "", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/module/serviceM/";
+
+		assertEquals(34, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testServicePortCons() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("ModuleDescription");
+		rtcParam.setVersion("1.0.0");
+		rtcParam.setVender("VenderName");
+		rtcParam.setCategory("Category");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("EVENTDRIVEN");
+		rtcParam.setMaxInstance(1);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		ServicePortParam service2 = new ServicePortParam("sv_name", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service2, "if_name", "", "", rootPath
+						+ "/resource/100/module/serviceCon/MyService.idl",
+				"SimpleService::MyService", "", 1);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		List<ServicePortParam> srvports2 = new ArrayList<ServicePortParam>();
+		srvports2.add(service2);
+		rtcParam.getServicePorts().addAll(srvports2);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/module/serviceCon/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testServicePortProvCons() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("ModuleDescription");
+		rtcParam.setVersion("1.0.0");
+		rtcParam.setVender("VenderName");
+		rtcParam.setCategory("Category");
+		rtcParam.setComponentType("UNIQUE");
+		rtcParam.setActivityType("EVENTDRIVEN");
+		rtcParam.setMaxInstance(5);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		ServicePortParam service1 = new ServicePortParam("sv_name", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "if_name", "", "", rootPath
+						+ "/resource/100/module/serviceMC/MyService.idl",
+				"SimpleService::MyService", "", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		ServicePortParam service2 = new ServicePortParam("sv_name2", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service2, "if_name2", "", "", rootPath
+						+ "/resource/100/module/serviceMC/MyService.idl",
+				"SimpleService::MyService", "", 1);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		List<ServicePortParam> srvports2 = new ArrayList<ServicePortParam>();
+		srvports2.add(service2);
+		rtcParam.getServicePorts().addAll(srvports2);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/module/serviceMC/";
+
+		assertEquals(34, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/MultiTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,223 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.DataPortParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortInterfaceParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class MultiTest extends TestBase {
+
+	Generator generator;
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	public void testProConMulti() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("test module");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("sample");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(2);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataInport = new ArrayList<DataPortParam>();
+		dataInport.add(new DataPortParam("in1", "RTC::TimedShort", "", 0));
+		rtcParam.getInports().addAll(dataInport);
+
+		List<DataPortParam> dataOutport = new ArrayList<DataPortParam>();
+		dataOutport.add(new DataPortParam("out1", "RTC::TimedLong", "", 0));
+		rtcParam.getOutports().addAll(dataOutport);
+
+		ServicePortParam service1 = new ServicePortParam("MySVPro", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "myserviceP1", "", "", rootPath
+						+ "resource/100/Multi/MyService.idl", "MyService", "",
+				0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+
+		ServicePortParam service2 = new ServicePortParam("MySVPro2", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service1, "myserviceP2", "", "", rootPath
+						+ "resource/100/Multi/MyService2.idl", "MyService2",
+				"", 0);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		srvports.add(service2);
+
+		ServicePortParam service3 = new ServicePortParam("MyConPro", 0);
+		List<ServicePortInterfaceParam> srvintert3 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int3 = new ServicePortInterfaceParam(
+				service1, "myservice0", "", "", rootPath
+						+ "resource/100/Multi/MyService.idl", "MyService", "",
+				1);
+		srvintert3.add(int3);
+		service3.getServicePortInterfaces().addAll(srvintert3);
+		srvports.add(service3);
+
+		ServicePortParam service4 = new ServicePortParam("MyConPro2", 0);
+		List<ServicePortInterfaceParam> srvinterts4 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int4 = new ServicePortInterfaceParam(
+				service1, "myservice2", "", "", rootPath
+						+ "resource/100/Multi/DAQService.idl", "DAQService",
+				"", 1);
+		srvinterts4.add(int4);
+		service4.getServicePortInterfaces().addAll(srvinterts4);
+		srvports.add(service4);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/Multi/ProConMulti/";
+
+		assertEquals(35, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		checkCode(result, resourceDir, "src/MyService2SVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testConsumerMulti() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("test module");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("sample");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(2);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataInport = new ArrayList<DataPortParam>();
+		dataInport.add(new DataPortParam("in1", "RTC::TimedShort", "", 0));
+		rtcParam.getInports().addAll(dataInport);
+
+		List<DataPortParam> dataOutport = new ArrayList<DataPortParam>();
+		dataOutport.add(new DataPortParam("out1", "RTC::TimedLong", "", 0));
+		rtcParam.getOutports().addAll(dataOutport);
+
+		ServicePortParam service1 = new ServicePortParam("MyConPro", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "myservice0", "", "", rootPath
+						+ "resource/100/Multi/MyService.idl", "MyService", "",
+				1);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+
+		ServicePortParam service2 = new ServicePortParam("MyConPro2", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service1, "myservice2", "", "", rootPath
+						+ "resource/100/Multi/DAQService.idl", "DAQService",
+				"", 1);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		srvports.add(service2);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/Multi/ConMulti/";
+
+		assertEquals(33, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testProviderMulti() throws Exception {
+		rtcParam.setName("foo");
+		rtcParam.setDescription("test module");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("sample");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(2);
+		rtcParam.setComponentKind("DataFlowComponent");
+
+		List<DataPortParam> dataInport = new ArrayList<DataPortParam>();
+		dataInport.add(new DataPortParam("in1", "RTC::TimedShort", "", 0));
+		rtcParam.getInports().addAll(dataInport);
+
+		List<DataPortParam> dataOutport = new ArrayList<DataPortParam>();
+		dataOutport.add(new DataPortParam("out1", "RTC::TimedLong", "", 0));
+		rtcParam.getOutports().addAll(dataOutport);
+
+		ServicePortParam service1 = new ServicePortParam("MySVPro", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "myservice0", "", "", rootPath
+						+ "resource/100/Multi/MyService.idl", "MyService", "",
+				0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+
+		ServicePortParam service2 = new ServicePortParam("MySVPro2", 0);
+		List<ServicePortInterfaceParam> srvinterts2 = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int2 = new ServicePortInterfaceParam(
+				service1, "myservice2", "", "", rootPath
+						+ "resource/100/Multi/DAQService.idl", "DAQService",
+				"", 0);
+		srvinterts2.add(int2);
+		service2.getServicePortInterfaces().addAll(srvinterts2);
+		srvports.add(service2);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/Multi/ProMulti/";
+
+		assertEquals(35, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		checkCode(result, resourceDir, "src/DAQServiceSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLInheritTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,150 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortInterfaceParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class SafetyIDLInheritTest extends TestBase {
+
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+	Generator generator;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setName("foo");
+		rtcParam.setDescription("test module");
+		rtcParam.setVersion("1.0.1");
+		rtcParam.setVender("TA");
+		rtcParam.setCategory("sample");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(2);
+		rtcParam.setComponentKind("DataFlowComponent");
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	String fixturePath(String name) {
+		return rootPath + "resource/100/" + name;
+	}
+
+	public void testInherit1() throws Exception {
+		String name = "idlinherit/inherit1";
+
+		List<ServicePortParam> svports = new ArrayList<ServicePortParam>();
+
+		ServicePortParam sv1 = new ServicePortParam("MyServiceProvider", 0);
+		List<ServicePortInterfaceParam> iflist = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam sif1 = new ServicePortInterfaceParam(sv1,
+				"MyServiceProvider", "", "", fixturePath(name)
+						+ "/MyServiceChildMulti.idl", "MyServiceChild",
+				fixturePath(name), 0);
+		iflist.add(sif1);
+		sv1.getServicePortInterfaces().addAll(iflist);
+		svports.add(sv1);
+
+		ServicePortParam sv2 = new ServicePortParam("MyServiceRequire", 0);
+		iflist = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam sif2 = new ServicePortInterfaceParam(sv2,
+				"MyServiceRequire", "", "", fixturePath(name)
+						+ "/MyServiceChildMulti.idl", "MyServiceChild",
+				fixturePath(name), 1);
+		iflist.add(sif2);
+		sv2.getServicePortInterfaces().addAll(iflist);
+		svports.add(sv2);
+
+		rtcParam.getServicePorts().addAll(svports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = fixturePath(name) + "/";
+
+		assertEquals(36, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceChildSVC_impl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		checkCode(result, resourceDir, "src/MyService2SVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+	public void testInherit2() throws Exception {
+		String name = "idlinherit/inherit2";
+
+		List<ServicePortParam> svports = new ArrayList<ServicePortParam>();
+
+		ServicePortParam sv1 = new ServicePortParam("MyServiceProvider", 0);
+		List<ServicePortInterfaceParam> iflist = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam sif1 = new ServicePortInterfaceParam(sv1,
+				"MyServiceProvider", "", "", fixturePath(name)
+						+ "/MyServiceChildMulti.idl", "MyServiceChild",
+				fixturePath(name), 0);
+		iflist.add(sif1);
+		ServicePortInterfaceParam sif2 = new ServicePortInterfaceParam(sv1,
+				"MyServiceProvider2", "", "", fixturePath(name)
+						+ "/MyServiceChildWithType.idl",
+				"MyServiceWithTypeChild", fixturePath(name), 0);
+		iflist.add(sif2);
+		sv1.getServicePortInterfaces().addAll(iflist);
+		svports.add(sv1);
+
+		ServicePortParam sv2 = new ServicePortParam("MyServiceRequire", 0);
+		iflist = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam sif3 = new ServicePortInterfaceParam(sv2,
+				"MyServiceRequire", "", "", fixturePath(name)
+						+ "/MyServiceChildMulti.idl", "MyServiceChild",
+				fixturePath(name), 1);
+		iflist.add(sif3);
+		ServicePortInterfaceParam sif4 = new ServicePortInterfaceParam(sv2,
+				"MyServiceRequire2", "", "", fixturePath(name)
+						+ "/MyServiceChildWithType.idl",
+				"MyServiceWithTypeChild", fixturePath(name), 1);
+		iflist.add(sif4);
+		sv2.getServicePortInterfaces().addAll(iflist);
+		svports.add(sv2);
+
+		rtcParam.getServicePorts().addAll(svports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = fixturePath(name) + "/";
+
+		assertEquals(38, result.size());
+		checkCode(result, resourceDir, "src/fooComp.c");
+		checkCode(result, resourceDir, "src/foo.c");
+		checkCode(result, resourceDir, "src/fooImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceChildSVC_impl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		checkCode(result, resourceDir, "src/MyService2SVC_impl.c");
+		checkCode(result, resourceDir,
+				"src/MyServiceWithTypeChildSVC_impl.c");
+		checkCode(result, resourceDir, "src/MyServiceWithTypeSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_foo.xml");
+	}
+
+}

Added: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.java	                        (rev 0)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.rtcbuilder.safety/test/jp/go/aist/rtm/rtcbuilder/safety/_test/_100/SafetyIDLTypeTest.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -0,0 +1,107 @@
+package jp.go.aist.rtm.rtcbuilder.safety._test._100;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.go.aist.rtm.rtcbuilder.Generator;
+import jp.go.aist.rtm.rtcbuilder.IRtcBuilderConstants;
+import jp.go.aist.rtm.rtcbuilder.generator.GeneratedResult;
+import jp.go.aist.rtm.rtcbuilder.generator.param.GeneratorParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.RtcParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortInterfaceParam;
+import jp.go.aist.rtm.rtcbuilder.generator.param.ServicePortParam;
+import jp.go.aist.rtm.rtcbuilder.safety.IRtcBuilderConstantsSafety;
+import jp.go.aist.rtm.rtcbuilder.safety._test.TestBase;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyCMakeGenerateManager;
+import jp.go.aist.rtm.rtcbuilder.safety.manager.SafetyGenerateManager;
+
+public class SafetyIDLTypeTest extends TestBase {
+
+	Generator generator;
+	GeneratorParam genParam;
+	RtcParam rtcParam;
+
+	protected void setUp() throws Exception {
+		genParam = new GeneratorParam();
+		rtcParam = new RtcParam(genParam, true);
+		rtcParam.setOutputProject(rootPath + "/resource/work");
+		rtcParam.setLanguage(IRtcBuilderConstantsSafety.LANG_SAFETY);
+		rtcParam.setLanguageArg(IRtcBuilderConstantsSafety.LANG_SAFETY_ARG);
+		rtcParam.setRtmVersion(IRtcBuilderConstants.RTM_VERSION_100);
+		rtcParam.setIsTest(true);
+		genParam.getRtcParams().add(rtcParam);
+
+		generator = new Generator();
+		generator.addGenerateManager(new SafetyGenerateManager());
+		generator.addGenerateManager(new SafetyCMakeGenerateManager());
+	}
+
+	public void testType() throws Exception {
+		rtcParam.setName("test");
+		rtcParam.setDescription("test component");
+		rtcParam.setVersion("1.0.0");
+		rtcParam.setVender("S.Kurihara");
+		rtcParam.setCategory("exmple");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(1);
+
+		ServicePortParam service1 = new ServicePortParam("sV1", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "sIF1", "", "sIFv", rootPath
+						+ "resource/100/idltype/type1/TestIDL.idl", "ComFk",
+				"", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/idltype/type1/";
+
+		checkCode(result, resourceDir, "src/testComp.c");
+		checkCode(result, resourceDir, "src/test.c");
+		checkCode(result, resourceDir, "src/testImpl.c");
+		checkCode(result, resourceDir, "src/ComFkSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_test.xml");
+	}
+
+	public void testBasicType() throws Exception {
+		rtcParam.setName("test");
+		rtcParam.setDescription("test component");
+		rtcParam.setVersion("1.0.0");
+		rtcParam.setVender("S.Kurihara");
+		rtcParam.setCategory("exmple");
+		rtcParam.setComponentType("STATIC");
+		rtcParam.setActivityType("PERIODIC");
+		rtcParam.setMaxInstance(1);
+
+		ServicePortParam service1 = new ServicePortParam("MySVPro", 0);
+		List<ServicePortInterfaceParam> srvinterts = new ArrayList<ServicePortInterfaceParam>();
+		ServicePortInterfaceParam int1 = new ServicePortInterfaceParam(
+				service1, "myservice", "", "", rootPath
+						+ "resource/100/idltype/type2/MyService.idl",
+				"MyService", "", 0);
+		srvinterts.add(int1);
+		service1.getServicePortInterfaces().addAll(srvinterts);
+		List<ServicePortParam> srvports = new ArrayList<ServicePortParam>();
+		srvports.add(service1);
+		rtcParam.getServicePorts().addAll(srvports);
+
+		List<GeneratedResult> result = generator.generateTemplateCode(genParam);
+
+		String resourceDir = rootPath + "/resource/100/idltype/type2/";
+
+		checkCode(result, resourceDir, "src/testComp.c");
+		checkCode(result, resourceDir, "src/test.c");
+		checkCode(result, resourceDir, "src/testImpl.c");
+		checkCode(result, resourceDir, "src/MyServiceSVC_impl.c");
+		//
+		checkCode(result, resourceDir, "build_test.xml");
+	}
+
+}

Modified: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/jp/go/aist/rtm/toolscommon/profiles/util/YamlSubHandlerVer01.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/jp/go/aist/rtm/toolscommon/profiles/util/YamlSubHandlerVer01.java	2013-12-03 06:19:45 UTC (rev 447)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/jp/go/aist/rtm/toolscommon/profiles/util/YamlSubHandlerVer01.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -274,6 +274,9 @@
 					if( langInfoY.get("Ruby") != null ) {
 						language.setKind("Ruby");
 					}
+					if( langInfoY.get("Safety") != null ) {
+						language.setKind("safety");
+					}
 					profile.setLanguage(language);
 				}
 			}

Modified: branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/org/openrtp/namespaces/rtc/version01/Language.java
===================================================================
--- branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/org/openrtp/namespaces/rtc/version01/Language.java	2013-12-03 06:19:45 UTC (rev 447)
+++ branches/work_ForRTMSafety/rtmtools/jp.go.aist.rtm.toolscommon.profiles/src/org/openrtp/namespaces/rtc/version01/Language.java	2013-12-03 07:16:55 UTC (rev 448)
@@ -43,6 +43,7 @@
     "python",
     "java",
     "csharp",
+    "safety",
     "ruby"
 })
 public class Language {
@@ -57,6 +58,8 @@
     protected String csharp;
     @XmlElement(name = "Ruby")
     protected String ruby;
+    @XmlElement(name = "Safety")
+    protected String safety;
 
     /**
      * Gets the value of the cxx property.
@@ -178,4 +181,27 @@
         this.ruby = value;
     }
 
+    /**
+     * Gets the value of the safety property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getSafety() {
+        return safety;
+    }
+
+    /**
+     * Sets the value of the safety property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setSafety(String value) {
+        this.safety = value;
+    }
 }



More information about the openrtm-commit mailing list