- Timestamp:
- Apr 5, 2019, 9:26:53 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
asp3_tinet_ecnl_rx/trunk/asp3_dcre/tecsgen/tecslib/core/componentobj.rb
r359 r374 4 4 # Generator for TOPPERS Embedded Component System 5 5 # 6 # Copyright (C) 2008-201 7by TOPPERS Project6 # Copyright (C) 2008-2019 by TOPPERS Project 7 7 #-- 8 8 # 上記著作権者は,以下の(1)~(4)の条件を満たす場合に限り,本ソフトウェ … … 149 149 end 150 150 151 set_descriptor_list151 # set_descriptor_list ## 152 152 153 153 if @generate then … … 364 364 end 365 365 366 @@set_descriptor_list = {} 367 def self.set_descriptor_list 368 Namespace.get_root.travers_all_signature{ |sig| 369 if @@set_descriptor_list[ sig ] == nil then 370 @@set_descriptor_list[ sig ] = true 371 sig.set_descriptor_list 372 end 373 } 374 end 375 366 376 #== Signature# 引数で参照されている Descriptor 型のリストを作成する 367 377 def set_descriptor_list … … 538 548 # @ct_factory_list:: Factory[] : celltype factory 539 549 # @cell_list:: Cell[] : 定義のみ (V1.0.0.2 以降) 550 # @ordered_cell_list:: Cell[] : ID 順に順序付けされたセルリスト、最適化以降有効 (リンク単位ごとに生成されなおす) 540 551 # @singleton:: bool 541 552 # @idx_is_id:: bool 542 553 # @idx_is_id_act:: bool: actual value 554 # @b_need_ptab:: bool: true if having cells in multi-domain 543 555 # @active:: bool 544 556 # @b_reuse:: bool : reuse 指定されて import された(template 不要) … … 654 666 if $idx_is_id then 655 667 @idx_is_id = true 668 @idx_is_id_act = true 669 @b_need_ptab = true 656 670 else 657 671 @idx_is_id = false 658 end 659 @idx_is_id_act = @idx_is_id 672 @idx_is_id_act = false 673 @b_need_ptab = false 674 end 660 675 661 676 Namespace.new_celltype( self ) … … 700 715 end 701 716 702 check_dynamic_join717 # check_dynamic_join ## 703 718 704 719 @@current_object = nil … … 886 901 @idx_is_id = true 887 902 @idx_is_id_act = true 903 @b_need_ptab = true 888 904 when :ACTIVE 889 905 @active = true … … 899 915 if @singleton then 900 916 @idx_is_id_act = false 917 @b_need_ptab = false 901 918 end 902 919 end … … 999 1016 end 1000 1017 1018 @@dynamic_join_checked_list = {} 1019 def self.check_dynamic_join 1020 Namespace.get_root.travers_all_celltype{ |ct| 1021 if @@dynamic_join_checked_list[ ct ] == nil then 1022 @@dynamic_join_checked_list[ ct ] = true 1023 ct.check_dynamic_join 1024 end 1025 } 1026 end 1027 1001 1028 #=== Celltype#dynamic の適合性チェック 1002 1029 def check_dynamic_join 1030 return if ! $verbose 1003 1031 @port.each{ |port| 1004 1032 signature = port.get_signature … … 1038 1066 end 1039 1067 end 1040 cdl_warning( 'W9999 "$1" cannot handle Descriptor "$2" inf romation for port "$3"', @name, param.get_name, port.get_name )1068 cdl_warning( 'W9999 "$1" cannot handle Descriptor "$2" information for port "$3"', @name, param.get_name, port.get_name ) 1041 1069 } 1042 1070 end … … 1143 1171 # 呼び口(ただし、最適化で不要となるものは除く) 1144 1172 def has_INIB? 1145 # print "name=#{@name} @n_attribute_ro=#{@n_attribute_ro} @n_var_size_is=#{@n_var_size_is} @n_call_port=#{@n_call_port} @n_call_port_omitted_in_CB=#{@n_call_port_omitted_in_CB} @n_entry_port_array_ns=#{@n_entry_port_array_ns}\n" 1146 return $rom && 1147 (@n_attribute_ro > 0 || 1148 @n_var_size_is > 0 || 1149 ( @n_call_port - @n_call_port_omitted_in_CB - (@n_call_port_dynamic-@n_call_port_array_dynamic) ) > 0 || 1150 $ram_initializer && @n_call_port_dynamic || 1151 @n_entry_port_array_ns > 0) 1152 # return $rom && (@n_attribute_ro > 0 || ( @n_call_port - @n_call_port_omitted_in_CB ) > 0) 1173 1174 result = $rom && 1175 (@n_attribute_ro > 0 || 1176 @n_var_size_is > 0 || 1177 ( @n_call_port - @n_call_port_omitted_in_CB - (@n_call_port_dynamic-@n_call_port_array_dynamic) ) > 0 || 1178 $ram_initializer && @n_call_port_dynamic > 0 || 1179 @n_entry_port_array_ns > 0) 1180 # print "name=#{@name} n_attribute_ro=#{@n_attribute_ro} n_var_size_is=#{@n_var_size_is} n_call_port=#{@n_call_port} n_call_port_omitted_in_CB=#{@n_call_port_omitted_in_CB} n_call_port_dynamic=#{@n_call_port_dynamic} n_call_port_array_dynamic=#{@n_call_port_array_dynamic} n_entry_port_array_ns=#{@n_entry_port_array_ns} has_INIB?=#{result}\n" 1181 1182 return result 1153 1183 end 1154 1184 … … 1231 1261 def idx_is_id_act? 1232 1262 @idx_is_id_act 1263 end 1264 1265 def multi_domain? 1266 @b_need_ptab 1233 1267 end 1234 1268 … … 1353 1387 # 逆require ポートに対して複数の結合がないかチェックする 1354 1388 # @generate:: [ Symbol, String, Plugin ] = [ PluginName, option, Plugin ] Plugin は生成後に追加される 1389 # @b_post_code_generated:: Bool: true if generated in tmp_plugin_post_code.cdl 1355 1390 # 1356 1391 # composite のためインスタンス変数 … … 1375 1410 # @id:: Integer : コード生成直前に設定 (プロトタイプ宣言の場合は -1 のまま放置) 1376 1411 # @id_specified::Integer : 指定された id 1377 # @restrict_list::{ entry_name => { func_name, [ region_name, ... ] } } 1412 # @restrict_list::{ entry_name => { func_name, [ region_path_str, ... ] } } 1413 # @restrict_list2::{ entry_name => { func_name, [ domain_root_region, ... ] } } 1414 # @b_restrict_referenced::Bool: restrict_list が参照れた 1378 1415 1379 1416 =begin … … 1459 1496 @referenced_port_list = {} 1460 1497 @restrict_list = {} 1498 @restrict_list2 = {} 1499 @b_restrict_referenced = false 1500 @b_post_code_generated = false 1461 1501 1462 1502 @cell_list = {} … … 1803 1843 set_specifier_list( Generator.get_statement_specifier ) 1804 1844 end 1845 if TECSGEN.post_coded? 1846 @b_post_code_generated = true 1847 end 1805 1848 set_f_def f_def 1806 1849 … … 1820 1863 if ! @in_composite then 1821 1864 # if @celltype.instance_of? Celltype then 1865 if @celltype then # composite でも呼びだす, エラー時 nil 1822 1866 @celltype.new_cell self 1823 #end1867 end 1824 1868 @@cell_list << self 1825 1869 end … … 2132 2176 end 2133 2177 2178 #=== Cell# composite のセルか? 2179 def is_of_composite? 2180 if @celltype.kind_of? CompositeCelltype 2181 return true 2182 else 2183 return false 2184 end 2185 end 2186 2187 #=== Cell# tmp_plugin_post_code.cdl で生成されたセルか? 2188 def post_code_generated? 2189 @b_post_code_generated 2190 end 2191 2134 2192 # composite cell の port に対応する内部の cell の port の名前(リンク時に必要な名前) 2135 2193 def get_real_global_name port_name … … 2219 2277 2220 2278 # セルタイプ内で port_name の CompositeCelltypeJoin を探す(コード生成段階では必ず見つかる) 2279 # print "get_real_cell: cell=#{@name} port=#{port_name}\n" 2280 # pp @cell_list 2221 2281 cj = @celltype.find_export( port_name ) 2222 2282 … … 2230 2290 end 2231 2291 2292 #=== Cell#get_real_celltype 2293 # 2294 def get_real_celltype( port_name ) 2295 if @celltype.instance_of?( CompositeCelltype ) then 2296 return @celltype.get_real_celltype port_name 2297 else 2298 return @celltype 2299 end 2300 end 2232 2301 2233 2302 #=== Cell# 受け口のport の参照カウントをアップする … … 2270 2339 return "#{@global_name}_#{port_name}" 2271 2340 end 2341 end 2342 2343 #Cell#属性の初期値を得る 2344 #attr_name::Symbol 必ず初期化されていないと Ruby 例外となる 2345 def get_attr_initializer attr_name 2346 val = @join_list.get_item( attr_name ) 2347 if val == nil then 2348 val = (@celltype.find attr_name).get_initializer 2349 else 2350 val = val.get_rhs 2351 end 2352 return val 2272 2353 end 2273 2354 … … 2520 2601 else 2521 2602 cell = j.get_rhs_cell2 2522 next if cell == nil # 右辺が見つからなかった.既にエラー2603 next if cell == nil || cell.get_celltype == nil # 右辺が見つからなかった.既にエラー 2523 2604 port = cell.get_celltype.find( j.get_rhs_port2 ) 2605 if port == nil then 2606 dbgPrint "set_port_ref: #{@name}.#{j.get_name} = #{cell.get_name}.#{j.get_rhs_port2}\n" 2607 # through プラグインで生成されたセルの受け口が見つからないケース (のハズ) 2608 cdl_error( "entry '$1' not found in '$2' refered from $3.$4", j.get_rhs_port2, cell.get_name, @name, j.get_name ) 2609 next 2610 end 2524 2611 dbgPrint( "set_port_reference_count: #{@name}.#{j.get_name} => #{cell.get_name}.#{port.get_name}\n") 2525 2612 cell.port_referenced port … … 2966 3053 #=== Cell#restrict を追加 2967 3054 def add_restrict( entry_name, func_name, region_name_list ) 2968 if @restrict_list[ entry_name ] then 2969 if @restrict_list[ entry_name ][ func_name ] then 2970 @restrict_list[ entry_name ][ func_name ].each{ |rn| 2971 if region_name_list.include? rn then 2972 # p func_name 2973 name = func_name ? entry_name : entry_name+"."+func_name 2974 cdl_warning( "W9999 $1 restrict region duplicate $2", name, rn ) 3055 if @restrict_list[ entry_name ] == nil then 3056 @restrict_list[ entry_name ] = {} 3057 @restrict_list2[ entry_name ] = {} 3058 end 3059 if @restrict_list[ entry_name ][ func_name ] == nil then 3060 @restrict_list[ entry_name ][ func_name ] = [] 3061 @restrict_list2[ entry_name ][ func_name ] = [] 3062 end 3063 region_name_list.each { |rp| 3064 @restrict_list[ entry_name ][ func_name ] << rp 3065 # p "Class: " + rp.to_s 3066 obj = Namespace.find rp 3067 if ( obj.kind_of? Region ) then 3068 @restrict_list2[ entry_name ][ func_name ] << obj.get_domain_root 3069 else 3070 cdl_error( "S9999 $1 not found or not region", rp.to_s ) 3071 end 3072 } 3073 end 3074 3075 #=== Cell#check_restrict_list 3076 def check_restrict_list 3077 # p "check_restrict_list" 3078 @restrict_list.each{ |entry_name, func_hash| 3079 func_hash.each{ |func_name, region_list| 3080 region_list.each{ |rp| 3081 obj = Namespace.find rp 3082 if ( obj.kind_of? Region ) then 3083 if obj.get_domain_root != @region.get_domain_root then 3084 else 3085 cdl_info( "I9999 $1: restrict calling domain to $2, which is same domain as the cell locates", @name, rp.to_s ) 3086 # restrict を同じドメインを指定してもよいこととする (HRP3) 3087 # KernelDoamin 内のセルに対し、KernelDomain に restrict している場合、 3088 # 無所属経由で結合されているが、KernelDomain から呼出すことを想定した許可 3089 end 3090 else 3091 cdl_error( "S9999 $1 not region", rp.to_s ) 3092 end 3093 } 3094 } 3095 } 3096 end 3097 3098 #=== Cell#callable? 3099 def callable?( callee_cell, entry_name, func_name ) 3100 # p "callable? #{@name}" 3101 res = callee_cell.callable_from?( entry_name, func_name, self ) 3102 dbgPrint "callable? #{callee_cell.get_namespace_path}.#{entry_name}.#{func_name} from #{@NamespacePath} is #{res}\n" 3103 return res 3104 end 3105 3106 #=== Cell#callable_from? (private) 3107 def callable_from?( entry_name, func_name, caller_cell ) 3108 @b_restrict_referenced = true 3109 if @restrict_list.length == 0 then 3110 return true 3111 end 3112 3113 dr = caller_cell.get_region.get_domain_root 3114 if @restrict_list[entry_name] then 3115 if @restrict_list[entry_name][func_name] then 3116 @restrict_list2[entry_name][func_name].each{ |region| 3117 if dr == region then 3118 return true 3119 end 3120 } 3121 elsif @restrict_list[entry_name][nil] then 3122 @restrict_list2[entry_name][nil].each{ |region| 3123 if dr == region then 3124 return true 2975 3125 end 2976 3126 } 2977 3127 else 2978 @restrict_list[ entry_name ][ func_name ] = region_name_list 2979 end 2980 else 2981 func_list = { } 2982 func_list[ func_name ] = region_name_list 2983 @restrict_list[ entry_name ] = func_list 2984 end 2985 # pp @restrict_list 2986 end 2987 2988 #=== Cell#check_restrict_list 2989 def check_restrict_list 2990 @restrict_list.each{ |entry_name, func_hash| 2991 func_hash.each{ |func_name, region_list| 2992 region_list.each{ |rn| 2993 obj = Namespace.find [ rn ] 2994 if ( obj.kind_of? Region ) then 2995 if obj.get_domain_root != @region.get_domain_root then 2996 else 2997 cdl_warning( "W9999 $1 in same domain", rn ) 2998 end 2999 else 3000 cdl_error( "S9999 $1 not region", region ) 3001 end 3002 } 3003 } 3004 } 3005 end 3006 3007 #=== Cell#callable? 3008 def callable?( callee_cell, entry_name, func_name ) 3009 res = callee_cell.callable_from?( entry_name, func_name, self ) 3010 dbgPrint "callable? #{callee_cell.get_namespace_path}.#{entry_name}.#{func_name} from #{@NamespacePath} is #{res}\n" 3011 return res 3012 end 3013 3014 #=== Cell#callable_from? (private) 3015 def callable_from?( entry_name, func_name, caller_cell ) 3016 if @restrict_list.length == 0 then 3128 return false 3129 end 3130 else 3131 return false 3132 end 3133 end 3134 3135 #=== Cell#get_callable_regions( entry_name, func_name ) 3136 # func_name=nil の場合、entry_name の可否をチェック数る 3137 # nil が返る場合、制限されていないことを意味する 3138 def get_restricted_regions( entry_name, func_name ) 3139 # p "get_restricted_regions #{@name}" 3140 @b_restrict_referenced = true 3141 if @restrict_list[entry_name] then 3142 if @restrict_list[entry_name][func_name] then 3143 return @restrict_list2[entry_name][func_name] 3144 else 3145 return @restrict_list2[entry_name][nil] 3146 end 3147 end 3148 return nil 3149 end 3150 3151 #=== Cell#has_ineffective_restrict_specifier 3152 # restrict 指定子が指定されていて、参照されていない場合 true 3153 # 参照は、HRPSVCPlugin のみ 3154 def has_ineffective_restrict_specifier 3155 if @restrict_list.length != 0 && @b_restrict_referenced == false then 3017 3156 return true 3018 end 3019 3020 if @restrict_list[entry_name] then 3021 if @restrict_list[entry_name][nil] && 3022 @restrict_list[entry_name][nil].include?( caller_cell.get_region.get_domain_root.get_name )then 3023 return true 3024 end 3025 if @restrict_list[entry_name][func_name] && 3026 @restrict_list[entry_name][func_name].include?( caller_cell.get_region.get_domain_root.get_name )then 3027 return true 3028 else 3029 return false 3030 end 3031 else 3032 return true 3033 end 3034 end 3035 3157 else 3158 return false 3159 end 3160 end 3161 3036 3162 def show_tree( indent ) 3037 3163 indent.times { print " " } … … 3709 3835 end 3710 3836 3837 def get_global_name 3838 @global_name 3839 end 3840 3711 3841 def get_port_list 3712 3842 @port_list … … 3723 3853 def get_internal_allocator_list 3724 3854 @internal_allocator_list 3855 end 3856 3857 #== CompositeCelltype#get_real_celltype 3858 # port_name に接続されている内部のセルタイプを得る 3859 def get_real_celltype( port_name ) 3860 cj = find_export port_name 3861 inner_celltype = cj.get_cell.get_celltype 3862 if inner_celltype.instance_of? CompositeCelltype then 3863 return inner_celltype.get_real_celltype 3864 else 3865 return inner_celltype 3866 end 3725 3867 end 3726 3868 … … 3936 4078 else 3937 4079 # entry port optimize 3938 if $unopt then4080 if $unopt || $unopt_entry then 3939 4081 # 最適化なし 3940 4082 @b_VMT_useless = false # VMT 不要 (true の時 VMT を介することなく呼出す) … … 4260 4402 4261 4403 def is_VMT_useless? # VMT 関数テーブルを使用しない 4262 @b_VMT_useless 4404 if @port_type == :ENTRY && $unopt_entry == true then 4405 # プラグインから $unopt_entry を設定するケースのため 4406 # ここで読み出すときに、false を返す (reset_optimize での設定変更は速すぎる) 4407 return false 4408 else 4409 return @b_VMT_useless 4410 end 4263 4411 end 4264 4412 4265 4413 def is_skelton_useless? # スケルトン関数不要 (true の時、受け口関数を呼出す) 4266 @b_skelton_useless 4414 if @port_type == :ENTRY && $unopt_entry == true then 4415 # プラグインから $unopt_entry を設定するケースのため 4416 # ここで読み出すときに、false を返す (reset_optimize での設定変更は速すぎる) 4417 return false 4418 else 4419 return @b_skelton_useless 4420 end 4267 4421 end 4268 4422 … … 4801 4955 if ! c.get_f_def then # Namespace の @cell_list にはプロトタイプが含まれるケースあり 4802 4956 if c.get_f_ref then 4803 c dl_error( "S1093 $1 : undefined cell" , c.get_namespace_path.get_path_str )4957 c.cdl_error( "S1093 $1 : undefined cell" , c.get_namespace_path.get_path_str ) 4804 4958 elsif $verbose then 4805 c dl_warning( "W1006 $1 : only prototype, unused and undefined cell" , c.get_namespace_path.get_path_str )4959 c.cdl_warning( "W1006 $1 : only prototype, unused and undefined cell" , c.get_namespace_path.get_path_str ) 4806 4960 end 4807 4961 else … … 4810 4964 # if c.get_f_ref == false && c.is_generate? && ct && ct.is_inactive? then 4811 4965 if c.get_f_ref == false && ct && ct.is_inactive? then 4812 cdl_warning( "W1007 $1 : non-active cell has no entry join and no factory" , c.get_namespace_path.get_path_str ) 4966 c.cdl_warning( "W1007 $1 : non-active cell has no entry join and no factory" , c.get_namespace_path.get_path_str ) 4967 end 4968 if c.has_ineffective_restrict_specifier then 4969 c.cdl_warning( "W9999: $1 has ineffective restrict specifier", c.get_namespace_path.get_path_str ) 4813 4970 end 4814 4971 end … … 5005 5162 end 5006 5163 5164 #== Namespace (Region) に属するセルのリスト 5165 def get_cell_list 5166 @cell_list 5167 end 5168 5169 #== Namespace (Region)# 子リージョンのリスト 5170 # 5171 # リージョンは Namespace クラスで namespace として記憶されている 5172 def get_region_list 5173 @namespace_list 5174 end 5175 5007 5176 def show_tree( indent ) 5008 5177 indent.times { print " " } … … 5601 5770 next_cell_nsp = @through_generated_list[ i + 1 ].get_cell_namespace_path 5602 5771 next_port_name = @through_generated_list[ i + 1 ].get_through_entry_port_name 5772 next_port_subscript = @through_generated_list[ i + 1 ].get_through_entry_port_subscript 5603 5773 rescue Exception => evar 5604 5774 cdl_error( "S1124 $1: plugin function failed: \'get_through_entry_port_name\'" , plugin_name ) … … 5619 5789 next_cell = @cell 5620 5790 next_port_name = @port_name 5791 next_port_subscript = @rhs_subscript 5621 5792 5622 5793 if next_cell == nil then … … 5630 5801 # region から @cell_name.@port_name への through がないか探す 5631 5802 # rp = @through_list[i][3].find_cell_port_through_plugin( @cell_name, @port_name ) #762 5632 rp = @through_list[i][3].find_cell_port_through_plugin( @cell.get_global_name, @port_name )5803 rp = @through_list[i][3].find_cell_port_through_plugin( @cell.get_global_name, @port_name, @rhs_subscript ) 5633 5804 # @through_list[i] と @region_through_list[i-cp_len] は同じ 5634 5805 # 共用しないようにするには、見つからなかったことにすればよい … … 5643 5814 plClass = load_plugin( plugin_name, ThroughPlugin ) 5644 5815 if( plClass ) then 5645 gen_through_cell_code_and_parse( plugin_name, i, next_cell, next_port_name, plClass )5816 gen_through_cell_code_and_parse( plugin_name, i, next_cell, next_port_name, next_port_subscript, plClass ) 5646 5817 end 5647 5818 else … … 5656 5827 # 生成したものを region(@through_list[i][3]) のリストに追加 5657 5828 # @through_list[i][3].add_cell_port_through_plugin( @cell_name, @port_name, @through_generated_list[i] ) #762 5658 @through_list[i][3].add_cell_port_through_plugin( @cell.get_global_name, @port_name, @ through_generated_list[i] )5829 @through_list[i][3].add_cell_port_through_plugin( @cell.get_global_name, @port_name, @rhs_subscript, @through_generated_list[i] ) 5659 5830 end 5660 5831 end … … 5690 5861 5691 5862 #=== Join# through プラグインを呼び出して CDL 生成させるとともに、import する 5692 def gen_through_cell_code_and_parse( plugin_name, i, next_cell, next_port_name, plClass )5863 def gen_through_cell_code_and_parse( plugin_name, i, next_cell, next_port_name, next_port_subscript, plClass ) 5693 5864 5694 5865 through = @through_list[ i ] … … 5717 5888 5718 5889 begin 5719 plugin_object = plClass.new( "#{generating_cell_name}".to_sym, plugin_arg.to_s, next_cell, "#{next_port_name}".to_sym, @definition.get_signature, @celltype, caller_cell ) 5890 plugin_object = plClass.new( generating_cell_name.to_sym, plugin_arg.to_s, 5891 next_cell, next_port_name.to_sym, next_port_subscript, 5892 @definition.get_signature, @celltype, caller_cell ) 5720 5893 plugin_object.set_locale @locale 5721 5894 rescue Exception => evar … … 5912 6085 end 5913 6086 5914 def get_rhs_subscript 6087 # 末尾数字1 : CDL で指定された、右辺のセルを返す 6088 def get_rhs_cell1 # get_cell と同じ 6089 @cell 6090 end 6091 def get_rhs_port1 # get_port_name 同じ 6092 @port_name 6093 end 6094 def get_rhs_subscript1 5915 6095 @rhs_subscript 5916 6096 end … … 5922 6102 # through 指定あり? 5923 6103 if @through_list[0] then 5924 # mikan through で生成したものが root namespace 限定5925 6104 # through で生成されたセルを探す 5926 # cell = Namespace.find( [ "::", @through_generated_list[0].get_cell_name.to_sym ] ) #15927 6105 cell = Namespace.find( @through_generated_list[0].get_cell_namespace_path ) #1 5928 6106 # cell のプラグインで生成されたポート名のポートを探す (composite なら内部の繋がるポート) … … 5931 6109 # ポートを返す(composite なら内部の繋がるポートを返す) 5932 6110 return @cell.get_real_port( @port_name ) 6111 end 6112 end 6113 6114 #=== Join# 右辺の配列添数を得る 6115 # 右辺が through の場合は挿入されたセルの添数 6116 # 右辺が composite の場合は、内部の繋がるセルのポートの添数 (composite では変わらない) 6117 # このメソッドは get_rhs_cell, と対になっている 6118 def get_rhs_subscript 6119 if @through_list[0] then 6120 return @through_generated_list[0].get_through_entry_port_subscript 6121 else 6122 return @rhs_subscript 5933 6123 end 5934 6124 end … … 6568 6758 end 6569 6759 6570 #== Domain 6760 #== DomainType 6571 6761 # 6572 6762 # region の domain を記憶するクラス … … 6607 6797 return if pluginClass == nil 6608 6798 @plugin = pluginClass.new( @region, @name, @option ) 6799 @plugin.set_locale @locale 6609 6800 end 6610 6801 end … … 6624 6815 end 6625 6816 6626 #== Domain リージョンの Hash を得る6817 #== DomainType リージョンの Hash を得る 6627 6818 # @@domain_regions の説明参照 6628 6819 def self.get_domain_regions … … 6636 6827 def get_option 6637 6828 @option 6829 end 6830 6831 #== DomainType#ドメイン種別を得る 6832 #return::Symbol :kernel, :user, :OutOfDomain 6833 def get_kind 6834 @plugin.get_kind 6638 6835 end 6639 6836 … … 6697 6894 6698 6895 if @@domain_name then 6896 dbgPrint "Region=#{name} domain_type=#{@@domain_name} option=#{@@domain_option}\n" 6699 6897 domain_option = CDLString.remove_dquote @@domain_option.to_s 6700 6898 @domain_type = DomainType.new( self, @@domain_name, domain_option ) … … 6945 7143 end 6946 7144 7145 #== Region# ルートリージョン 7146 # ルートリージョンは、namespace のルートと同じインスタンス 7147 def selfget_root 7148 Namespace.get_root 7149 end 7150 6947 7151 def next_in_through_count 6948 7152 @in_through_count += 1 … … 6978 7182 #=== Region# through プラグインで、この region から cell_name.port_name へのプラグインオブジェクトを登録 6979 7183 # mikan namesppace 対応 (cell_name) 6980 def add_cell_port_through_plugin( cell_name, port_name, through_plugin_object ) 6981 @cell_port_throug_plugin_list[ "#{cell_name}.#{port_name}" ] = through_plugin_object 6982 end 6983 6984 def find_cell_port_through_plugin( cell_name, port_name ) 6985 return @cell_port_throug_plugin_list[ "#{cell_name}.#{port_name}" ] 7184 def add_cell_port_through_plugin( cell_name, port_name, subscript, through_plugin_object ) 7185 if subscript then 7186 subscript = '[' + subscript.to_s + ']' 7187 end 7188 @cell_port_throug_plugin_list[ "#{cell_name}.#{port_name}#{subscript}" ] = through_plugin_object 7189 end 7190 7191 def find_cell_port_through_plugin( cell_name, port_name, subscript ) 7192 if subscript then 7193 subscript = '[' + subscript.to_s + ']' 7194 end 7195 return @cell_port_throug_plugin_list[ "#{cell_name}.#{port_name}#{subscript}" ] 6986 7196 end 6987 7197
Note:
See TracChangeset
for help on using the changeset viewer.