tecscde 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (237) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +12 -0
  3. data/.rubocop.yml +125 -0
  4. data/.rubocop_todo.yml +188 -0
  5. data/CHANGELOG.md +3 -0
  6. data/Gemfile +6 -0
  7. data/LICENSE +46 -0
  8. data/LICENSE.ja +32 -0
  9. data/README.ja.md +200 -0
  10. data/README.md +35 -0
  11. data/Rakefile +27 -0
  12. data/bin/tecscde +64 -0
  13. data/glade/tecscde-cell-property.glade +205 -0
  14. data/glade/tecscde-celltype-property.glade +172 -0
  15. data/glade/tecscde-celltype.glade +414 -0
  16. data/glade/tecscde-export.glade +161 -0
  17. data/glade/test-cell-plugin.rb +51 -0
  18. data/glade/test-cell-property.rb +35 -0
  19. data/glade/test-export.rb +35 -0
  20. data/glade/test-palette.rb +26 -0
  21. data/lib/tcflow.rb +148 -0
  22. data/lib/tecscde.rb +65 -0
  23. data/lib/tecscde/NewCell.png +0 -0
  24. data/lib/tecscde/SelectArrow.png +0 -0
  25. data/lib/tecscde/attr_tree_view.rb +253 -0
  26. data/lib/tecscde/cell_plugin_dialog.glade +294 -0
  27. data/lib/tecscde/cell_plugin_dialog.rb +89 -0
  28. data/lib/tecscde/celltype_tree_view.rb +105 -0
  29. data/lib/tecscde/change_set_control.rb +35 -0
  30. data/lib/tecscde/change_set_control/change_set.rb +32 -0
  31. data/lib/tecscde/change_set_control/change_set_manager.rb +62 -0
  32. data/lib/tecscde/command.rb +35 -0
  33. data/lib/tecscde/control.rb +491 -0
  34. data/lib/tecscde/highlighted_objects.rb +180 -0
  35. data/lib/tecscde/logger.rb +74 -0
  36. data/lib/tecscde/main_view_and_model.rb +80 -0
  37. data/lib/tecscde/palette.glade +553 -0
  38. data/lib/tecscde/palette.rb +174 -0
  39. data/lib/tecscde/preferences.glade +117 -0
  40. data/lib/tecscde/preferences.rb +44 -0
  41. data/lib/tecscde/tecs_model.rb +1137 -0
  42. data/lib/tecscde/tecs_model/hbar.rb +68 -0
  43. data/lib/tecscde/tecs_model/tm_c_port.rb +122 -0
  44. data/lib/tecscde/tecs_model/tm_c_port_array.rb +98 -0
  45. data/lib/tecscde/tecs_model/tm_cell.rb +496 -0
  46. data/lib/tecscde/tecs_model/tm_e_port.rb +126 -0
  47. data/lib/tecscde/tecs_model/tm_e_port_array.rb +78 -0
  48. data/lib/tecscde/tecs_model/tm_join.rb +293 -0
  49. data/lib/tecscde/tecs_model/tm_join_bar.rb +146 -0
  50. data/lib/tecscde/tecs_model/tm_port.rb +238 -0
  51. data/lib/tecscde/tecs_model/tm_port_array.rb +246 -0
  52. data/lib/tecscde/tecs_model/tm_region.rb +107 -0
  53. data/lib/tecscde/tecs_model/tm_uneditable.rb +68 -0
  54. data/lib/tecscde/tecs_model/vbar.rb +68 -0
  55. data/lib/tecscde/templates/_cell_info.cde.erb +15 -0
  56. data/lib/tecscde/templates/_join_info.cde.erb +28 -0
  57. data/lib/tecscde/templates/main.cde.erb +49 -0
  58. data/lib/tecscde/tm_object.rb +91 -0
  59. data/lib/tecscde/version.rb +4 -0
  60. data/lib/tecscde/view.rb +58 -0
  61. data/lib/tecscde/view/cairo_matrix.rb +90 -0
  62. data/lib/tecscde/view/canvas.rb +59 -0
  63. data/lib/tecscde/view/constants.rb +114 -0
  64. data/lib/tecscde/view/main_view.rb +1245 -0
  65. data/lib/tecsflow.rb +475 -0
  66. data/lib/tecsflow/C_parser.tab.rb +2471 -0
  67. data/lib/tecsflow/C_parser.y.rb +1087 -0
  68. data/lib/tecsflow/classes.rb +421 -0
  69. data/lib/tecsgen.rb +581 -0
  70. data/lib/tecsgen/core/C_parser.tab.rb +2477 -0
  71. data/lib/tecsgen/core/C_parser.y +1032 -0
  72. data/lib/tecsgen/core/bnf-deb.tab.rb +5193 -0
  73. data/lib/tecsgen/core/bnf.tab.rb +5193 -0
  74. data/lib/tecsgen/core/bnf.y +2211 -0
  75. data/lib/tecsgen/core/componentobj.rb +7901 -0
  76. data/lib/tecsgen/core/ctypes.rb +226 -0
  77. data/lib/tecsgen/core/expression.rb +1031 -0
  78. data/lib/tecsgen/core/gen_xml.rb +374 -0
  79. data/lib/tecsgen/core/generate.rb +5206 -0
  80. data/lib/tecsgen/core/location.rb +116 -0
  81. data/lib/tecsgen/core/messages.rb +101 -0
  82. data/lib/tecsgen/core/optimize.rb +456 -0
  83. data/lib/tecsgen/core/plugin.rb +332 -0
  84. data/lib/tecsgen/core/pluginModule.rb +165 -0
  85. data/lib/tecsgen/core/syntaxobj.rb +1234 -0
  86. data/lib/tecsgen/core/tecs_lang.rb +306 -0
  87. data/lib/tecsgen/core/tecsgen.rb +453 -0
  88. data/lib/tecsgen/core/tecsinfo.rb +860 -0
  89. data/lib/tecsgen/core/tool_info.rb +258 -0
  90. data/lib/tecsgen/core/types.rb +1632 -0
  91. data/lib/tecsgen/core/unjoin_plugin.rb +218 -0
  92. data/lib/tecsgen/core/value.rb +650 -0
  93. data/lib/tecsgen/messages/messages_console_en_US.rb +1171 -0
  94. data/lib/tecsgen/messages/messages_console_ja_JP.rb +1171 -0
  95. data/lib/tecsgen/messages/messages_file_en_US.rb +334 -0
  96. data/lib/tecsgen/messages/messages_file_ja_JP.rb +163 -0
  97. data/lib/tecsgen/plugin/ATK1AlarmPlugin.rb +196 -0
  98. data/lib/tecsgen/plugin/ATK1DelayTaskPlugin.rb +106 -0
  99. data/lib/tecsgen/plugin/ATK1EventPlugin.rb +147 -0
  100. data/lib/tecsgen/plugin/ATK1ISRPlugin.rb +174 -0
  101. data/lib/tecsgen/plugin/ATK1KernelPlugin.rb +287 -0
  102. data/lib/tecsgen/plugin/ATK1ResourcePlugin.rb +124 -0
  103. data/lib/tecsgen/plugin/ATK1TaskPlugin.rb +220 -0
  104. data/lib/tecsgen/plugin/C2TECSBridgePlugin.rb +210 -0
  105. data/lib/tecsgen/plugin/CellPlugin.rb +61 -0
  106. data/lib/tecsgen/plugin/CelltypePlugin.rb +72 -0
  107. data/lib/tecsgen/plugin/CompositePlugin.rb +66 -0
  108. data/lib/tecsgen/plugin/DomainPlugin.rb +89 -0
  109. data/lib/tecsgen/plugin/HRP2AlarmHandlerPlugin.rb +76 -0
  110. data/lib/tecsgen/plugin/HRP2Cache.rb +1 -0
  111. data/lib/tecsgen/plugin/HRP2CyclicHandlerPlugin.rb +75 -0
  112. data/lib/tecsgen/plugin/HRP2DataqueuePlugin.rb +68 -0
  113. data/lib/tecsgen/plugin/HRP2EventflagPlugin.rb +68 -0
  114. data/lib/tecsgen/plugin/HRP2FixedSizeMemoryPoolPlugin.rb +68 -0
  115. data/lib/tecsgen/plugin/HRP2HandlerPlugin.rb +117 -0
  116. data/lib/tecsgen/plugin/HRP2KernelObjectPlugin.rb +372 -0
  117. data/lib/tecsgen/plugin/HRP2ObjectPlugin.rb +94 -0
  118. data/lib/tecsgen/plugin/HRP2Plugin.rb +140 -0
  119. data/lib/tecsgen/plugin/HRP2PostHook.rb +111 -0
  120. data/lib/tecsgen/plugin/HRP2PriorityDataqueuePlugin.rb +66 -0
  121. data/lib/tecsgen/plugin/HRP2RPCPlugin.rb +319 -0
  122. data/lib/tecsgen/plugin/HRP2SVCPlugin.rb +473 -0
  123. data/lib/tecsgen/plugin/HRP2SemaphorePlugin.rb +67 -0
  124. data/lib/tecsgen/plugin/HRP2TaskPlugin.rb +200 -0
  125. data/lib/tecsgen/plugin/HRPHandlerPlugin.rb +125 -0
  126. data/lib/tecsgen/plugin/HRPKernelObjectManager.rb +72 -0
  127. data/lib/tecsgen/plugin/HRPKernelObjectPlugin.rb +333 -0
  128. data/lib/tecsgen/plugin/HRPObjectPlugin.rb +93 -0
  129. data/lib/tecsgen/plugin/HRPPlugin.rb +356 -0
  130. data/lib/tecsgen/plugin/HRPRPCPlugin.rb +407 -0
  131. data/lib/tecsgen/plugin/HRPSVCPlugin.rb +859 -0
  132. data/lib/tecsgen/plugin/HRPTaskPlugin.rb +107 -0
  133. data/lib/tecsgen/plugin/Mruby2CBridgePlugin.rb +86 -0
  134. data/lib/tecsgen/plugin/MrubyBridgeCellPlugin.rb +264 -0
  135. data/lib/tecsgen/plugin/MrubyBridgeCelltypePlugin.rb +293 -0
  136. data/lib/tecsgen/plugin/MrubyBridgeCompositePlugin.rb +49 -0
  137. data/lib/tecsgen/plugin/MrubyBridgePlugin.rb +67 -0
  138. data/lib/tecsgen/plugin/MrubyBridgeSignaturePlugin.rb +1307 -0
  139. data/lib/tecsgen/plugin/MrubyInfoBridgePlugin.rb +14 -0
  140. data/lib/tecsgen/plugin/MrubyInfoBridgeSignaturePlugin.rb +994 -0
  141. data/lib/tecsgen/plugin/MultiPlugin.rb +57 -0
  142. data/lib/tecsgen/plugin/NotifierPlugin.rb +1217 -0
  143. data/lib/tecsgen/plugin/OpaqueMarshalerPlugin.rb +81 -0
  144. data/lib/tecsgen/plugin/OpaqueRPCPlugin.rb +323 -0
  145. data/lib/tecsgen/plugin/RPCPlugin.rb +266 -0
  146. data/lib/tecsgen/plugin/RepeatCellPlugin.rb +166 -0
  147. data/lib/tecsgen/plugin/RepeatJoinPlugin.rb +130 -0
  148. data/lib/tecsgen/plugin/SharedOpaqueRPCPlugin.rb +357 -0
  149. data/lib/tecsgen/plugin/SharedRPCPlugin.rb +329 -0
  150. data/lib/tecsgen/plugin/SignaturePlugin.rb +77 -0
  151. data/lib/tecsgen/plugin/TECS2CBridgePlugin.rb +178 -0
  152. data/lib/tecsgen/plugin/TECSInfoPlugin.rb +280 -0
  153. data/lib/tecsgen/plugin/ThroughPlugin.rb +333 -0
  154. data/lib/tecsgen/plugin/TracePlugin.rb +484 -0
  155. data/lib/tecsgen/plugin/lib/GenHRP2Marshaler.rb +761 -0
  156. data/lib/tecsgen/plugin/lib/GenOpaqueMarshaler.rb +1107 -0
  157. data/lib/tecsgen/plugin/lib/GenParamCopy.rb +365 -0
  158. data/lib/tecsgen/plugin/lib/GenTransparentMarshaler.rb +683 -0
  159. data/lib/tecsgen/plugin/lib/MrubyBridgeCelltypePluginModule.rb +283 -0
  160. data/lib/tecsgen/plugin/lib/MrubyBridgeSignaturePluginModule.rb +277 -0
  161. data/lib/tecsgen/version.rb +6 -0
  162. data/samples/FigureSamples/active/active.cde +104 -0
  163. data/samples/FigureSamples/active/active.cdl +20 -0
  164. data/samples/FigureSamples/active/active.pdf +0 -0
  165. data/samples/FigureSamples/active/active.png +0 -0
  166. data/samples/FigureSamples/active/gen/tmp_C_src.c +36 -0
  167. data/samples/FigureSamples/active/gen/tmp_cygwin_tecs.h +1908 -0
  168. data/samples/FigureSamples/active/gen/tmp_plugin_post_code.cdl +0 -0
  169. data/samples/FigureSamples/allocator/allocator-internal.png +0 -0
  170. data/samples/FigureSamples/allocator/allocator.cde +171 -0
  171. data/samples/FigureSamples/allocator/allocator.cdl +58 -0
  172. data/samples/FigureSamples/allocator/allocator.png +0 -0
  173. data/samples/FigureSamples/basic/Makefile +87 -0
  174. data/samples/FigureSamples/basic/SimpleSample-trace.cdl +50 -0
  175. data/samples/FigureSamples/basic/SimpleSample.cde +91 -0
  176. data/samples/FigureSamples/basic/SimpleSample.cdl +47 -0
  177. data/samples/FigureSamples/basic/basic.cde +93 -0
  178. data/samples/FigureSamples/basic/basic.cdl +46 -0
  179. data/samples/FigureSamples/basic/basic.png +0 -0
  180. data/samples/FigureSamples/callback/callback.cde +130 -0
  181. data/samples/FigureSamples/callback/callback.cdl +29 -0
  182. data/samples/FigureSamples/callback/callback.png +0 -0
  183. data/samples/FigureSamples/carray/carray.cde +144 -0
  184. data/samples/FigureSamples/carray/carray.cdl +38 -0
  185. data/samples/FigureSamples/carray/carray.png +0 -0
  186. data/samples/FigureSamples/cearray/cearray.cde +314 -0
  187. data/samples/FigureSamples/cearray/cearray.cdl +60 -0
  188. data/samples/FigureSamples/cearray/cearray.png +0 -0
  189. data/samples/FigureSamples/composite/composite-internal.png +0 -0
  190. data/samples/FigureSamples/composite/composite.cde +216 -0
  191. data/samples/FigureSamples/composite/composite.cdl +95 -0
  192. data/samples/FigureSamples/composite/composite.png +0 -0
  193. data/samples/FigureSamples/earray/earray.cde +142 -0
  194. data/samples/FigureSamples/earray/earray.cdl +38 -0
  195. data/samples/FigureSamples/earray/earray.png +0 -0
  196. data/samples/FigureSamples/join/Makefile +87 -0
  197. data/samples/FigureSamples/join/join.cde +132 -0
  198. data/samples/FigureSamples/join/join.cdl +40 -0
  199. data/samples/FigureSamples/join/join.png +0 -0
  200. data/samples/FigureSamples/relay/Makefile +99 -0
  201. data/samples/FigureSamples/relay/relay-internal.png +0 -0
  202. data/samples/FigureSamples/relay/relay.cde +284 -0
  203. data/samples/FigureSamples/relay/relay.cdl +52 -0
  204. data/samples/FigureSamples/relay/relay.png +0 -0
  205. data/samples/FigureSamples/rpc/Makefile +123 -0
  206. data/samples/FigureSamples/rpc/rpc-expand.png +0 -0
  207. data/samples/FigureSamples/rpc/rpc.cde +245 -0
  208. data/samples/FigureSamples/rpc/rpc.png +0 -0
  209. data/samples/FigureSamples/rpc/rpc_sample.cdl +53 -0
  210. data/samples/SimpleSample/Makefile +25 -0
  211. data/samples/SimpleSample/SimpleSample/Makefile +86 -0
  212. data/samples/SimpleSample/SimpleSample/Makefile-trace +91 -0
  213. data/samples/SimpleSample/SimpleSample/README.txt +106 -0
  214. data/samples/SimpleSample/SimpleSample/SimpleSample-trace.cdl +50 -0
  215. data/samples/SimpleSample/SimpleSample/SimpleSample.cdl +45 -0
  216. data/samples/SimpleSample/SimpleSample/src/tSample.c +77 -0
  217. data/samples/SimpleSample/SimpleSample/src/tSimple.c +48 -0
  218. data/samples/SimpleSample/SimpleSample/src/tecs-types.h +27 -0
  219. data/samples/SimpleSample/SimpleSampleOpaqueRPC/Makefile +51 -0
  220. data/samples/SimpleSample/SimpleSampleOpaqueRPC/Makefile-trace +91 -0
  221. data/samples/SimpleSample/SimpleSampleOpaqueRPC/README.txt +106 -0
  222. data/samples/SimpleSample/SimpleSampleOpaqueRPC/SimpleSample-trace.cdl +80 -0
  223. data/samples/SimpleSample/SimpleSampleOpaqueRPC/SimpleSample.cdl +77 -0
  224. data/samples/SimpleSample/SimpleSampleOpaqueRPC/rSample/Makefile +112 -0
  225. data/samples/SimpleSample/SimpleSampleOpaqueRPC/rSimple/Makefile +109 -0
  226. data/samples/SimpleSample/SimpleSampleOpaqueRPC/src/tSample.c +80 -0
  227. data/samples/SimpleSample/SimpleSampleOpaqueRPC/src/tSimple.c +47 -0
  228. data/samples/SimpleSample/SimpleSampleOpaqueRPC/src/tTaskMain.c +66 -0
  229. data/samples/SimpleSample/SimpleSampleOpaqueRPC/src/tecs-types.h +27 -0
  230. data/samples/SimpleSample/SimpleSampleTransparentRPC/Makefile +125 -0
  231. data/samples/SimpleSample/SimpleSampleTransparentRPC/Makefile-trace +130 -0
  232. data/samples/SimpleSample/SimpleSampleTransparentRPC/SimpleSample-trace.cdl +54 -0
  233. data/samples/SimpleSample/SimpleSampleTransparentRPC/SimpleSample.cdl +53 -0
  234. data/samples/SimpleSample/SimpleSampleTransparentRPC/src/tSample.c +80 -0
  235. data/samples/SimpleSample/SimpleSampleTransparentRPC/src/tSimple.c +54 -0
  236. data/tecscde.gemspec +41 -0
  237. metadata +353 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: d3bbaf695cdc54504a5409bd894170806204221f842f2d970f567719e1cf12c2
4
+ data.tar.gz: 5bdac577725c8d959943eec337ae292b4285b278902c1bf558dead3daf2fdfef
5
+ SHA512:
6
+ metadata.gz: c7dd5e074412450aa85ffca477fe3c5d347a9a3dc8d224c668e013c311530bd12afeab1a8f861a178e1d5fa5f5709f75eb5f18e5a6eddb95cfb8a389bfedec84
7
+ data.tar.gz: b0d42135d714c6cfe618786f5157f78b74bf21f7ae1210b5b0507094cbe2db69633719bd063797482f08544faad786919cd930a80170bb0a367b872877918cd9
@@ -0,0 +1,12 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /gen/
8
+ /html/
9
+ /pkg/
10
+ /spec/reports/
11
+ /tmp/
12
+ *.log
@@ -0,0 +1,125 @@
1
+ inherit_from: .rubocop_todo.yml
2
+
3
+ AllCops:
4
+ TargetRubyVersion: 2.5
5
+ DisplayCopNames: true
6
+ Exclude:
7
+ - "Rakefile"
8
+ - "*.gemspec"
9
+ - "vendor/**/*"
10
+ - "lib/**/*.tab.rb"
11
+ - "lib/tecsgen.rb"
12
+ - "lib/tecsgen/**/*.rb"
13
+ - "lib/tcflow.rb"
14
+ - "lib/tecsflow.rb"
15
+ - "lib/tecsflow/**/*.rb"
16
+ - "glade/*.rb"
17
+
18
+ Layout/ExtraSpacing:
19
+ AllowForAlignment: true
20
+ Layout/SpaceInsideBlockBraces:
21
+ EnforcedStyle: space
22
+ SpaceBeforeBlockParameters: false
23
+ Layout/MultilineMethodCallIndentation:
24
+ EnforcedStyle: indented
25
+ Layout/EmptyLineAfterGuardClause:
26
+ Enabled: false
27
+ Layout/MultilineOperationIndentation:
28
+ EnforcedStyle: indented
29
+
30
+ Lint/UnderscorePrefixedVariableName:
31
+ Enabled: false
32
+ Lint/UnusedMethodArgument:
33
+ Enabled: false
34
+
35
+ Metrics/LineLength:
36
+ Enabled: false
37
+ Metrics/ClassLength:
38
+ Exclude:
39
+ - "test/**/*.rb"
40
+ Metrics/ParameterLists:
41
+ Max: 7
42
+ Metrics/MethodLength:
43
+ Max: 30
44
+
45
+ Naming/FileName:
46
+ Enabled: false
47
+ Naming/UncommunicativeMethodParamName:
48
+ AllowedNames:
49
+ - x
50
+ - y
51
+ - x0
52
+ - y0
53
+ - xm
54
+ - ym
55
+ - xx
56
+ - xy
57
+ - yx
58
+ - yy
59
+
60
+ Style/AsciiComments:
61
+ Enabled: false
62
+ Style/HashSyntax:
63
+ Exclude:
64
+ - "**/*.rake"
65
+ - "Rakefile"
66
+ Style/EmptyMethod:
67
+ Enabled: false
68
+ Style/FrozenStringLiteralComment:
69
+ Enabled: false
70
+ Style/NumericLiterals:
71
+ Enabled: false
72
+ Style/StringLiterals:
73
+ EnforcedStyle: double_quotes
74
+ Style/TrailingCommaInArrayLiteral:
75
+ Enabled: false
76
+ Style/TrailingCommaInHashLiteral:
77
+ Enabled: false
78
+ Style/TrailingCommaInArguments:
79
+ Enabled: false
80
+ Style/Documentation:
81
+ Enabled: false
82
+ Style/WordArray:
83
+ Enabled: false
84
+ Style/BarePercentLiterals:
85
+ EnforcedStyle: percent_q
86
+ Style/BracesAroundHashParameters:
87
+ Enabled: false
88
+ Style/PercentQLiterals:
89
+ Enabled: false
90
+ Style/UnneededPercentQ:
91
+ Enabled: false
92
+ Style/IfUnlessModifier:
93
+ Enabled: false
94
+ Style/NumericPredicate:
95
+ Enabled: false
96
+ Style/MutableConstant:
97
+ Enabled: false
98
+ Style/SymbolArray:
99
+ Enabled: false
100
+ Style/FormatString:
101
+ Enabled: false
102
+ Style/ConditionalAssignment:
103
+ Enabled: false
104
+ Style/WhileUntilModifier:
105
+ Enabled: false
106
+ Style/RedundantBegin:
107
+ Enabled: false
108
+ Style/YodaCondition:
109
+ EnforcedStyle: forbid_for_equality_operators_only
110
+ Style/TernaryParentheses:
111
+ EnforcedStyle: require_parentheses_when_complex
112
+ Style/MethodCallWithArgsParentheses:
113
+ Exclude:
114
+ - "**/*.rake"
115
+ - "Rakefile"
116
+ - "Gemfile"
117
+ Enabled: true
118
+ IgnoredMethods:
119
+ - p
120
+ - pp
121
+ - puts
122
+ - print
123
+ - printf
124
+ - raise
125
+ - require
@@ -0,0 +1,188 @@
1
+ # This configuration was generated by
2
+ # `rubocop --auto-gen-config`
3
+ # on 2019-03-12 11:17:37 +0900 using RuboCop version 0.65.0.
4
+ # The point is for the user to remove these configuration records
5
+ # one by one as the offenses are removed from the code base.
6
+ # Note that changes in the inspected code, or installation of new
7
+ # versions of RuboCop, may require this file to be generated again.
8
+
9
+ # Offense count: 1
10
+ # Cop supports --auto-correct.
11
+ # Configuration parameters: EnforcedStyle.
12
+ # SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines, beginning_only, ending_only
13
+ Layout/EmptyLinesAroundClassBody:
14
+ Exclude:
15
+ - 'lib/tecscde/preferences.rb'
16
+
17
+ # Offense count: 4
18
+ Lint/EmptyWhen:
19
+ Exclude:
20
+ - 'lib/tecscde/control.rb'
21
+
22
+ # Offense count: 10
23
+ Lint/ShadowingOuterLocalVariable:
24
+ Exclude:
25
+ - 'lib/tecscde/attr_tree_view.rb'
26
+ - 'lib/tecscde/tecs_model/tm_cell.rb'
27
+
28
+ # Offense count: 2
29
+ # Cop supports --auto-correct.
30
+ # Configuration parameters: IgnoreEmptyBlocks, AllowUnusedKeywordArguments.
31
+ Lint/UnusedBlockArgument:
32
+ Exclude:
33
+ - 'lib/tecscde/tecs_model.rb'
34
+
35
+ # Offense count: 9
36
+ Lint/UselessAssignment:
37
+ Exclude:
38
+ - 'lib/tecscde/control.rb'
39
+ - 'lib/tecscde/tecs_model.rb'
40
+ - 'lib/tecscde/view/main_view.rb'
41
+
42
+ # Offense count: 54
43
+ Metrics/AbcSize:
44
+ Max: 129
45
+
46
+ # Offense count: 5
47
+ # Configuration parameters: CountComments, ExcludedMethods.
48
+ # ExcludedMethods: refine
49
+ Metrics/BlockLength:
50
+ Max: 73
51
+
52
+ # Offense count: 9
53
+ # Configuration parameters: CountComments.
54
+ Metrics/ClassLength:
55
+ Max: 820
56
+
57
+ # Offense count: 21
58
+ Metrics/CyclomaticComplexity:
59
+ Max: 27
60
+
61
+ # Offense count: 18
62
+ # Configuration parameters: CountComments, ExcludedMethods.
63
+ Metrics/MethodLength:
64
+ Max: 79
65
+
66
+ # Offense count: 23
67
+ Metrics/PerceivedComplexity:
68
+ Max: 30
69
+
70
+ # Offense count: 38
71
+ Naming/AccessorMethodName:
72
+ Exclude:
73
+ - 'lib/tecscde/attr_tree_view.rb'
74
+ - 'lib/tecscde/control.rb'
75
+ - 'lib/tecscde/palette.rb'
76
+ - 'lib/tecscde/tecs_model.rb'
77
+ - 'lib/tecscde/tecs_model/tm_c_port.rb'
78
+ - 'lib/tecscde/tecs_model/tm_cell.rb'
79
+ - 'lib/tecscde/tecs_model/tm_e_port.rb'
80
+ - 'lib/tecscde/tecs_model/tm_join.rb'
81
+ - 'lib/tecscde/tecs_model/tm_join_bar.rb'
82
+ - 'lib/tecscde/tecs_model/tm_port.rb'
83
+ - 'lib/tecscde/tecs_model/tm_region.rb'
84
+ - 'lib/tecscde/tecs_model/tm_uneditable.rb'
85
+ - 'lib/tecscde/view/main_view.rb'
86
+
87
+ # Offense count: 6
88
+ Naming/ConstantName:
89
+ Exclude:
90
+ - 'lib/tecscde/view/constants.rb'
91
+
92
+ # Offense count: 7
93
+ # Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames.
94
+ # AllowedNames: io, id, to, by, on, in, at, ip, db
95
+ Naming/UncommunicativeMethodParamName:
96
+ Exclude:
97
+ - 'lib/tecscde/tecs_model.rb'
98
+ - 'lib/tecscde/tecs_model/tm_cell.rb'
99
+ - 'lib/tecscde/tecs_model/tm_join.rb'
100
+ - 'lib/tecscde/view/main_view.rb'
101
+
102
+ # Offense count: 1
103
+ # Configuration parameters: EnforcedStyle.
104
+ # SupportedStyles: snake_case, normalcase, non_integer
105
+ Naming/VariableNumber:
106
+ Exclude:
107
+ - 'lib/tecscde/view/main_view.rb'
108
+
109
+ # Offense count: 3
110
+ # Cop supports --auto-correct.
111
+ Performance/RegexpMatch:
112
+ Exclude:
113
+ - 'lib/tecscde/tecs_model.rb'
114
+
115
+ # Offense count: 9
116
+ Style/ClassVars:
117
+ Exclude:
118
+ - 'lib/tecscde/view/main_view.rb'
119
+
120
+ # Offense count: 16
121
+ # Configuration parameters: AllowedVariables.
122
+ Style/GlobalVars:
123
+ Exclude:
124
+ - 'bin/tecscde'
125
+ - 'lib/tecscde/command.rb'
126
+ - 'lib/tecscde/tecs_model.rb'
127
+ - 'lib/tecscde/tecs_model/tm_cell.rb'
128
+
129
+ # Offense count: 9
130
+ # Configuration parameters: MinBodyLength.
131
+ Style/GuardClause:
132
+ Exclude:
133
+ - 'lib/tecscde/highlighted_objects.rb'
134
+ - 'lib/tecscde/tecs_model.rb'
135
+ - 'lib/tecscde/tecs_model/tm_cell.rb'
136
+ - 'lib/tecscde/view/main_view.rb'
137
+
138
+ # Offense count: 10
139
+ Style/IfInsideElse:
140
+ Exclude:
141
+ - 'lib/tecscde/control.rb'
142
+ - 'lib/tecscde/highlighted_objects.rb'
143
+ - 'lib/tecscde/tecs_model.rb'
144
+ - 'lib/tecscde/tecs_model/tm_cell.rb'
145
+ - 'lib/tecscde/tecs_model/tm_join.rb'
146
+ - 'lib/tecscde/view/main_view.rb'
147
+
148
+ # Offense count: 1
149
+ # Cop supports --auto-correct.
150
+ # Configuration parameters: InverseMethods, InverseBlocks.
151
+ Style/InverseMethods:
152
+ Exclude:
153
+ - 'lib/tecscde/control.rb'
154
+
155
+ # Offense count: 2
156
+ # Cop supports --auto-correct.
157
+ # Configuration parameters: EnforcedStyle.
158
+ # SupportedStyles: both, prefix, postfix
159
+ Style/NegatedIf:
160
+ Exclude:
161
+ - 'lib/tecscde/control.rb'
162
+ - 'lib/tecscde/view/main_view.rb'
163
+
164
+ # Offense count: 4
165
+ # Cop supports --auto-correct.
166
+ # Configuration parameters: EnforcedStyle, MinBodyLength.
167
+ # SupportedStyles: skip_modifier_ifs, always
168
+ Style/Next:
169
+ Exclude:
170
+ - 'lib/tecscde/attr_tree_view.rb'
171
+ - 'lib/tecscde/tecs_model.rb'
172
+
173
+ # Offense count: 3
174
+ # Cop supports --auto-correct.
175
+ # Configuration parameters: EnforcedStyle.
176
+ # SupportedStyles: implicit, explicit
177
+ Style/RescueStandardError:
178
+ Exclude:
179
+ - 'lib/tecscde/tecs_model.rb'
180
+ - 'lib/tecscde/view/main_view.rb'
181
+
182
+ # Offense count: 1
183
+ # Cop supports --auto-correct.
184
+ # Configuration parameters: EnforcedStyle, AllowSafeAssignment.
185
+ # SupportedStyles: require_parentheses, require_no_parentheses, require_parentheses_when_complex
186
+ Style/TernaryParentheses:
187
+ Exclude:
188
+ - 'lib/tecscde/tecs_model.rb'
@@ -0,0 +1,3 @@
1
+ ## Release v0.6.0
2
+
3
+ * First release as a gem.
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ source "https://rubygems.org"
2
+
3
+ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
+
5
+ # Specify your gem's dependencies in tecscde.gemspec
6
+ gemspec
data/LICENSE ADDED
@@ -0,0 +1,46 @@
1
+ TECSCDE - TECS Component Diagram Editor
2
+
3
+ Copyright (C) 2014-2015 by TOPPERS Project
4
+
5
+ The above copyright holders grant permission gratis to use,
6
+ duplicate, modify, or redistribute (hereafter called use) this
7
+ software (including the one made by modifying this software),
8
+ provided that the following four conditions (1) through (4) are
9
+ satisfied.
10
+
11
+ (1) When this software is used in the form of source code, the above
12
+ copyright notice, this use conditions, and the disclaimer shown
13
+ below must be retained in the source code without modification.
14
+
15
+ (2) When this software is redistributed in the forms usable for the
16
+ development of other software, such as in library form, the above
17
+ copyright notice, this use conditions, and the disclaimer shown
18
+ below must be shown without modification in the document provided
19
+ with the redistributed software, such as the user manual.
20
+
21
+ (3) When this software is redistributed in the forms unusable for the
22
+ development of other software, such as the case when the software
23
+ is embedded in a piece of equipment, either of the following two
24
+ conditions must be satisfied:
25
+
26
+ (a) The above copyright notice, this use conditions, and the
27
+ disclaimer shown below must be shown without modification in
28
+ the document provided with the redistributed software, such as
29
+ the user manual.
30
+
31
+ (b) How the software is to be redistributed must be reported to the
32
+ TOPPERS Project according to the procedure described
33
+ separately.
34
+
35
+ (4) The above copyright holders and the TOPPERS Project are exempt
36
+ from responsibility for any type of damage directly or indirectly
37
+ caused from the use of this software and are indemnified by any
38
+ users or end users of this software from any and all causes of
39
+ action whatsoever.
40
+
41
+ THIS SOFTWARE IS PROVIDED "AS IS." THE ABOVE COPYRIGHT HOLDERS AND
42
+ THE TOPPERS PROJECT DISCLAIM ANY EXPRESS OR IMPLIED WARRANTIES,
43
+ INCLUDING, BUT NOT LIMITED TO, ITS APPLICABILITY TO A PARTICULAR
44
+ PURPOSE. IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS AND THE
45
+ TOPPERS PROJECT BE LIABLE FOR ANY TYPE OF DAMAGE DIRECTLY OR
46
+ INDIRECTLY CAUSED FROM THE USE OF THIS SOFTWARE.
@@ -0,0 +1,32 @@
1
+ TECSCDE - TECS Component Diagram Editor
2
+
3
+ Copyright (C) 2014-2015 by TOPPERS Project
4
+
5
+ 上記著作権者は,以下の(1)〜(4)の条件を満たす場合に限り,本ソフトウェ
6
+ ア(本ソフトウェアを改変したものを含む.以下同じ)を使用・複製・改
7
+ 変・再配布(以下,利用と呼ぶ)することを無償で許諾する.
8
+ (1) 本ソフトウェアをソースコードの形で利用する場合には,上記の著作
9
+ 権表示,この利用条件および下記の無保証規定が,そのままの形でソー
10
+ スコード中に含まれていること.
11
+ (2) 本ソフトウェアを,ライブラリ形式など,他のソフトウェア開発に使
12
+ 用できる形で再配布する場合には,再配布に伴うドキュメント(利用
13
+ 者マニュアルなど)に,上記の著作権表示,この利用条件および下記
14
+ の無保証規定を掲載すること.
15
+ (3) 本ソフトウェアを,機器に組み込むなど,他のソフトウェア開発に使
16
+ 用できない形で再配布する場合には,次のいずれかの条件を満たすこ
17
+ と.
18
+ (a) 再配布に伴うドキュメント(利用者マニュアルなど)に,上記の著
19
+ 作権表示,この利用条件および下記の無保証規定を掲載すること.
20
+ (b) 再配布の形態を,別に定める方法によって,TOPPERSプロジェクトに
21
+ 報告すること.
22
+ (4) 本ソフトウェアの利用により直接的または間接的に生じるいかなる損
23
+ 害からも,上記著作権者およびTOPPERSプロジェクトを免責すること.
24
+ また,本ソフトウェアのユーザまたはエンドユーザからのいかなる理
25
+ 由に基づく請求からも,上記著作権者およびTOPPERSプロジェクトを
26
+ 免責すること.
27
+
28
+ 本ソフトウェアは,無保証で提供されているものである.上記著作権者お
29
+ よびTOPPERSプロジェクトは,本ソフトウェアに関して,特定の使用目的
30
+ に対する適合性も含めて,いかなる保証も行わない.また,本ソフトウェ
31
+ アの利用により直接的または間接的に生じたいかなる損害に関しても,そ
32
+ の責任を負わない.
@@ -0,0 +1,200 @@
1
+ TECS Component Diagram Editor -- tecscde V0.5.1
2
+ 2015.6.8 (V0.5.0)
3
+ 2016.5.8 (V0.5.1)
4
+ 大山 博司
5
+
6
+ 【概要】
7
+
8
+ tecscde は、TECS コンポーネント図を編集する GUI ツールです。
9
+
10
+ tecscde V0.5.1 は、tecsgen V1.3.1.0 以降に対応します。TOPPERS/ASP3 の
11
+ CDL ファイルを扱うことができます。
12
+
13
+ V0.5.* では、既存のセルタイプ (シグニチャ) を CDL ファイルから読み込ん
14
+ でセルを配置することができます。既存の CDL ファイルからコンポーネント
15
+ 図をおこすのに大変便利です。
16
+
17
+ 現在の実装では、コンソールから起動するツールです。tecscde には、2通り
18
+ の起動方法があります。1つは CDL ファイルを入力とする方法で、もう1つは
19
+ CDE ファイルを入力とする方法です。
20
+
21
+ 【動作環境】
22
+
23
+ ・MinGW 版を使用する場合(Windows)
24
+
25
+ tecsgen V1.3.1.7 パッケージの他に、tecscde-MinGW-RT パッケージが追加
26
+ で必要になります。以下のように、同じディレクトリで、解凍します。
27
+
28
+ % tar xvzf tecsgen-V1.3.1.7.tgz
29
+ % tar xvzf tecscde-MinGW-RT.tgz
30
+ % cp -pr tecscde/tecsgen/{MinGW,Ruby200,tecsgen.exe,tecscde.exe,tecsmerge.exe} tecsgen/tecsgen/
31
+
32
+ Windows 7 SP1 64bit にて動作確認しています。ランタイム部分は 32bit で
33
+ すので、32bit 版でも動作します。
34
+
35
+ tecscde.exe のあるディレクトリに実行パスを通すか、パスを指定して起動
36
+ します。実行パスを通すには PATH 環境変数を設定するか、以下のコマンド
37
+ で設定できます(シェルを起動するごとに行う必要があります)。
38
+
39
+ % source set_evn.sh
40
+
41
+ 注) cygwin のシェルから起動した場合、拡張子の付いていない tecscde スク
42
+ リプトが起動されることがあります。この場合 X Window 版が起動されてしまいます。
43
+ X サーバーの準備ができていない場合、エラーメッセージの一部は、以下
44
+ のようになります。
45
+ "Cannot open display: :0 (Gtk::InitError)"
46
+ MinGW 版は tecsgen.exe のように、拡張子を付加して起動します。ある
47
+ いは、スクリプト tecscde を削除してください。
48
+
49
+ 注) cygwin 上の X-Window でも起動できますが、試した限りでは、
50
+ LANG=C.utf-8 を指定しないと、期待したフォントが表示されませんでし
51
+ た。
52
+
53
+ 注) cygwin 上で MinGW 版 Ruby へのパスを通したうえで tecscde を起動す
54
+ ると、期待したようには動作しません.理由や対処方法が分からない場合、
55
+ tecscde-MinGW-RT.tgz を使用することをお勧めします.
56
+
57
+ ・Linux で使用する場合
58
+
59
+ 以下が必要です。
60
+
61
+ Ruby 1.9 以降
62
+ Ruby Gtk2
63
+
64
+ 勿論 X Window が前提となっています。
65
+ Ruby Gtk2 は、以下の方法でインストールできます。
66
+ % gem install gtk2
67
+
68
+ tecscde のあるディレクトリに実行パスを通すか、パスを指定して起動しま
69
+ す。実行パスを通すには PATH 環境変数を設定するか、以下のコマンドで設
70
+ 定できます(シェルを起動するごとに行う必要があります)。
71
+
72
+ % source set_evn.sh
73
+
74
+ 注) 以下の説明で tecscde.exe を起動するように書いていますが、Linux で
75
+ 使用する場合には、拡張子 .exe は付加しないようにします。
76
+
77
+ 【CDL ファイルを入力とする方法】
78
+
79
+ 既存の CDL ファイルを入力として編集できます。
80
+ この起動方法は、既存の CDL ファイルからコンポーネント図を起こす場合に
81
+ 適しています。tecsgen を起動するような Makefile がある場合、以下のよう
82
+ にすることで起動できます。ただし tecscde への実行パスが通っているもの
83
+ とします。
84
+
85
+ % make TECSGEN=tecscde.exe tecs
86
+
87
+ または
88
+
89
+ % make TECSGEN_EXE=tecscde.exe tecs
90
+
91
+ で tecsgen の代わりに tecscde を起動します。Linux 上で使用する場合、拡
92
+ 張子 .exe を付けないようにします。
93
+
94
+ tecscde には、tecsgen に対する引数が与えられます。
95
+ 実行前に、タイムスタンプファイルを消す必要があるかもしれません。
96
+ 以下のように消すことができます。
97
+
98
+ % rm gen/tecsgen.timestamp
99
+
100
+ 【CDE ファイルを入力とする方法】
101
+
102
+ 単に CDE ファイルを指定することで起動できます。
103
+ tecscde への実行パスが通っている場合、以下のように起動できます。
104
+
105
+ % tecscde.exe file.cde
106
+
107
+ file.cde の部分は、適宜変更してください。
108
+ CDE ファイルは、tecsgen のコマンドラインオプションも記憶しているため、
109
+ tecscde では、単に CDE ファイルを指定するだけで編集が可能になります。
110
+
111
+ CDE ファイルの所在するディレクトリを変更する場合、次の点に注意してください。
112
+ CDE ファイルには、読み込んだ CDL ファイルのデータを内部に持っていません。
113
+ 代わりに CDL ファイルを読み込んだ時のパス (-I) を記憶しています。
114
+ このため、読み込んだパスに CDL ファイルがないと、読み込みに失敗します。
115
+
116
+ この場合、-I でサーチパスを指定しなおして読み込ませます。オプション
117
+ --base_dir を指定することで、対応することもできます。
118
+
119
+ 【機能】
120
+
121
+ ・入出力機能
122
+ ・tecsgen コマンド引数による CDL ファイルの編集
123
+ ・CDE ファイルを引数に編集
124
+ ・編集ファイルの CDE ファイルへの保存
125
+ ・PDF ファイルへのエクスポート
126
+
127
+ ・編集機能
128
+ ・セルの設置
129
+ ・セルの削除 (CDL ファイル由来のセルは削除できない.CDE ファイル由来のものは削除可)
130
+ ・セル間の結合 (上記と同様)
131
+ ・セルの属性変更 (上記と同様)
132
+ ・アンドゥー
133
+
134
+ shift や ctrl を押しながら選択することで、複数のセルを選択できます。
135
+
136
+ 注意) CDL ファイル内で定義されたセルや結合を削除や変更することはできません。
137
+ (第一引数として与えられた CDE ファイルで定義されたセルは、削除・変更できます)
138
+
139
+ ・表示機能
140
+ ・ファイル名ごとの色分け表示 (デフォルト)
141
+ ・リージョン(ドメイン)ごとの色分け
142
+ ・セル名の強調表示
143
+ ・拡大・縮小表示
144
+
145
+ ・用紙サイズの指定 (V0.5.* では CDE ファイルを直接編集する必要があります)
146
+
147
+ 【補足】
148
+
149
+ ・CDE ファイルは、CDL ファイルと同じ文法で記述できます。加えて JSON 形
150
+ 式で記述された tecsgen コマンドのオプションとセルや結合(join) の位置
151
+ 情報を記憶します。
152
+ ・tecscde は CDL ファイルを読みこむ際に、エラーがあっても読み込みます
153
+ が、Ruby 例外が発生し読み込めないことがあります。
154
+ この場合、予め tecsgen でエラーの無いようにしてから読み込みます。
155
+ ・CDE ファイルには CDL ファイルと同じ要素を置くことができます。
156
+ しかし、tecscde で編集後保存することができるものは、限られています
157
+ (現時点では cell 以外は保存できません)。
158
+ ・CDE ファイルは編集時のパスを記憶します。他へ配布する場合、このことが
159
+ セキュリティホールになる可能性があります。
160
+ ・本リリースに同梱の tecsgen は、TECS ジェネレータ V1.3.1.1 と互換性が
161
+ あり、gen ディレクトリ下にコードを生成します。加えて CDE ファイルを
162
+ 引数に取ることができます。tecsgen に対するオプションは、CDE ファイル
163
+ に含まれているため、指定する必要がありません。
164
+
165
+ 【tecscde 固有のオプション】
166
+
167
+ tecscde は、tecsgen のすべてのオプションを受け付けます。
168
+ ただし、コード生成に関わるオプションは、指定しても意味がありません。
169
+
170
+ --base_dir=dir base directory (tecscde only)
171
+ cde ファイルのパスが変わった場合など、base directory を使用しないと、読み込めない場合があります。
172
+ インポートパスが変わった場合には、-I も指定する必要があります。
173
+
174
+ --force-apply-tool_info force to apply tool_info, even if validation failed. this might cause ruby exception and stop tecscde
175
+ tecscde は、まだ開発途上なので tool_info に必須の情報を追加する場合があります。
176
+ 古いバージョンの CDE ファイルを読みこむ際に、このオプションを指定する必要があるかもしれません。
177
+
178
+ --tate vertical (tate) style (tecscde only) デフォルト
179
+ 新しく作成するセルの受け口、呼び口が、上辺、下辺に設けられます。
180
+
181
+ --yoko horizontal (yoko) style (tecscde only)
182
+ 新しく作成するセルの受け口、呼び口が、左辺、右辺に設けられます。
183
+
184
+
185
+ 【注意点】
186
+
187
+ 少なくとも、以下の問題点があります。
188
+
189
+ * CDE ファイルのオーバーライト警告を出さない
190
+ * CDE ファイルの未保存でも終了してしまう
191
+ * 扱えない要素は、多くあります (少なくとも以下は、扱えない)
192
+ * リージョン ・・・ Ruby 例外が発生します
193
+ * アロケータ
194
+ * プラグイン
195
+ through プラグインを適用したファイルも開けますが、うまく繋がっていないセルが見れます
196
+ * セル名のインプレース編集は、実装が不完全です
197
+ * cygwin 版で、何回も起動/終了を繰返すうちに X サーバーがダウンすることを何回か経験しています
198
+ (X サーバーは、OS に近いレベルのものなので、ダウンするのはよろしくない。恐らく Linux 版/MacOS版は、もっと安定していると思います)
199
+
200
+