Changeset 112
- Timestamp:
- Aug 9, 2017, 8:47:42 AM (7 years ago)
- Location:
- branches/generator
- Files:
-
- 9 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/generator/Forms/UFormMain.lfm
r110 r112 19 19 end 20 20 object MainMenu1: TMainMenu 21 left = 240 22 top = 152 21 Images = Core.ImageList1 22 left = 248 23 top = 216 23 24 object MenuItem2: TMenuItem 24 25 Caption = 'File' … … 44 45 end 45 46 object ActionList1: TActionList 47 Images = Core.ImageList1 46 48 left = 428 47 49 top = 229 … … 52 54 object AExit: TAction 53 55 Caption = 'Exit' 56 ImageIndex = 2 54 57 OnExecute = AExitExecute 55 58 end 56 59 object AOpen: TAction 57 60 Caption = 'Open...' 61 ImageIndex = 4 58 62 OnExecute = AOpenExecute 59 63 end 60 64 object ASaveAs: TAction 61 65 Caption = 'Save as...' 66 ImageIndex = 5 62 67 OnExecute = ASaveAsExecute 63 68 end -
branches/generator/Forms/UFormRule.lfm
r111 r112 1 1 object FormRule: TFormRule 2 2 Left = 679 3 Height = 3983 Height = 505 4 4 Top = 620 5 5 Width = 660 6 6 ActiveControl = ButtonOk 7 7 Caption = 'Rule' 8 ClientHeight = 3988 ClientHeight = 505 9 9 ClientWidth = 660 10 10 OnShow = FormShow … … 13 13 Left = 376 14 14 Height = 25 15 Top = 36015 Top = 467 16 16 Width = 75 17 17 Anchors = [akLeft, akBottom] … … 23 23 Left = 168 24 24 Height = 25 25 Top = 36025 Top = 467 26 26 Width = 75 27 27 Anchors = [akLeft, akBottom] … … 47 47 object ListView: TListView 48 48 Left = 16 49 Height = 23249 Height = 307 50 50 Top = 112 51 51 Width = 624 52 Anchors = [akTop, akLeft, ak Bottom]52 Anchors = [akTop, akLeft, akRight, akBottom] 53 53 Columns = < 54 54 item … … 78 78 object ComboBox1: TComboBox 79 79 Left = 186 80 Height = 3 680 Height = 34 81 81 Top = 61 82 82 Width = 390 … … 89 89 TabOrder = 4 90 90 end 91 object ToolBar1: TToolBar 92 Left = 16 93 Height = 26 94 Top = 424 95 Width = 624 96 Align = alCustom 97 Anchors = [akLeft, akRight, akBottom] 98 Caption = 'ToolBar1' 99 Images = Core.ImageList1 100 TabOrder = 5 101 object ToolButton1: TToolButton 102 Left = 1 103 Top = 2 104 Action = AAdd 105 end 106 object ToolButton2: TToolButton 107 Left = 24 108 Top = 2 109 Action = AModify 110 end 111 object ToolButton3: TToolButton 112 Left = 47 113 Top = 2 114 Action = ARemove 115 end 116 end 91 117 object ActionList1: TActionList 118 Images = Core.ImageList1 92 119 left = 347 93 120 top = 187 94 121 object AAdd: TAction 95 122 Caption = 'Add' 123 ImageIndex = 0 96 124 OnExecute = AAddExecute 97 125 end 98 126 object AModify: TAction 99 127 Caption = 'Modify' 128 ImageIndex = 3 100 129 OnExecute = AModifyExecute 101 130 end 102 131 object ARemove: TAction 103 132 Caption = 'Remove' 133 ImageIndex = 1 104 134 OnExecute = ARemoveExecute 105 135 end 106 136 end 107 137 object PopupMenu1: TPopupMenu 138 Images = Core.ImageList1 108 139 left = 118 109 140 top = 185 -
branches/generator/Forms/UFormRule.pas
r111 r112 29 29 MenuItem3: TMenuItem; 30 30 PopupMenu1: TPopupMenu; 31 ToolBar1: TToolBar; 32 ToolButton1: TToolButton; 33 ToolButton2: TToolButton; 34 ToolButton3: TToolButton; 31 35 procedure AAddExecute(Sender: TObject); 32 36 procedure AModifyExecute(Sender: TObject); -
branches/generator/Forms/UFormRules.lfm
r111 r112 27 27 Height = 24 28 28 Top = 5 29 Width = 15029 Width = 70 30 30 Align = alNone 31 31 AutoSize = True … … 33 33 BorderSpacing.Top = 3 34 34 Caption = 'ToolBar1' 35 Images = Core.ImageList1 35 36 TabOrder = 0 36 37 object ToolButton1: TToolButton … … 61 62 item 62 63 Caption = 'Name' 63 Width = 829 64 Width = 200 65 end 66 item 67 Caption = 'Items' 68 Width = 629 64 69 end> 65 70 MultiSelect = True … … 76 81 end 77 82 object ActionList1: TActionList 83 Images = Core.ImageList1 78 84 left = 248 79 85 top = 212 80 86 object AAdd: TAction 81 87 Caption = 'Add' 88 ImageIndex = 0 82 89 OnExecute = AAddExecute 83 90 end 84 91 object AModify: TAction 85 92 Caption = 'Modify' 93 ImageIndex = 3 86 94 OnExecute = AModifyExecute 87 95 end 88 96 object ARemove: TAction 89 97 Caption = 'Remove' 98 ImageIndex = 1 90 99 OnExecute = ARemoveExecute 91 100 ShortCut = 46 … … 93 102 end 94 103 object PopupMenu1: TPopupMenu 104 Images = Core.ImageList1 95 105 left = 427 96 106 top = 212 -
branches/generator/Forms/UFormRules.pas
r111 r112 105 105 Item.Caption := Rules[Item.Index].Name; 106 106 Item.Data := Rules[Item.Index]; 107 Item.SubItems.Add(Rules[Item.Index].Items.GetBNF(Rules[Item.Index].RuleType)); 107 108 end; 108 109 end; -
branches/generator/UCore.lfm
r109 r112 10 10 left = 432 11 11 top = 243 12 Bitmap = { 13 4C69060000001000000010000000000000000000000000000000000000000000 14 000070A970FF006400FF006200FF70A670FF0000000000000000000000000000 15 0000000000000000000000000000000000000000000000000000000000000000 16 0000006400FFECFFECFF8CFE8CFF006000FFD4D4D4FF00000000000000000000 17 0000000000000000000000000000000000000000000000000000000000000000 18 0000006400FF8CFE8CFF00E800FF005E00FFB2B2B2FF00000000000000000000 19 0000000000000000000000000000000000000000000000000000000000000000 20 0000006200FF8CFE8CFF00E500FF005C00FFB2B2B2FF00000000000000000000 21 0000000000000000000000000000000000000000000000000000000000000000 22 0000006000FF8CFE8CFF00E000FF005A00FFB2B2B2FF00000000000000000000 23 000000000000000000000000000070A970FF006400FF006400FF006200FF0060 24 00FF006000FF8CFE8CFF00DD00FF005800FF005600FF005400FF005300FF0050 25 00FF709C70FF0000000000000000006400FFECFFECFF8CFE8CFF8CFE8CFF8CFE 26 8CFF8CFE8CFF00DE00FF00D900FF00D400FF00D000FF00CC00FF00C800FF00C4 27 00FF004A00FFD4D4D4FF00000000006200FF8CFE8CFF00EA00FF00E600FF00E2 28 00FF00DE00FF00DA00FF00D400FF00D000FF00CC00FF00C800FF00C400FF00C2 29 00FF004800FFB2B2B2FF0000000070A670FF005E00FF005C00FF005A00FF0058 30 00FF005600FF00D600FF00D000FF005000FF004E00FF004C00FF004A00FF004A 31 00FF4E764EFFB2B2B2FF0000000000000000D4D4D4FFB2B2B2FFB2B2B2FFB2B2 32 B2FF005400FF00D200FF00CE00FF004E00FFB2B2B2FFB2B2B2FFB2B2B2FFB2B2 33 B2FFB2B2B2FFD4D4D4FF00000000000000000000000000000000000000000000 34 0000005300FF00CE00FF00CA00FF004C00FFB2B2B2FF00000000000000000000 35 0000000000000000000000000000000000000000000000000000000000000000 36 0000005000FF00CA00FF00C600FF004A00FFB2B2B2FF00000000000000000000 37 0000000000000000000000000000000000000000000000000000000000000000 38 0000004E00FF00C800FF00C400FF004800FFB2B2B2FF00000000000000000000 39 0000000000000000000000000000000000000000000000000000000000000000 40 0000709B70FF004A00FF004800FF4E764EFFB2B2B2FF00000000000000000000 41 0000000000000000000000000000000000000000000000000000000000000000 42 000000000000D4D4D4FFB2B2B2FFB2B2B2FFD4D4D4FF00000000000000000000 43 0000000000000000000000000000000000000000000000000000000000000000 44 0000000000000000000000000000000000000000000000000000000000000000 45 0000000000000000000000000000000000000000000000000000000000000000 46 0000000000000000000000000000000000000000000000000000000000000000 47 0000000000000000000000000000000000000000000000000000000000000000 48 0000000000000000000000000000000000000000000000000000000000000000 49 000000000000000000000000000000000000000000001818C0FF1818C0FFC0C0 50 C0FF000000000000000000000000000000000000000000000000000000000000 51 00001818C0FF1818C0FFC0C0C0FF00000000000000002020C8FF2020C8FF2020 52 C8FF2020C8FFC0C0C0FF00000000000000000000000000000000000000002020 53 C8FF2020C8FFC0C0C0FF000000000000000000000000000000002626CEFF2626 54 CEFF2626CEFF2626CEFFC0C0C0FF0000000000000000000000002626CEFF2626 55 CEFFC0C0C0FF0000000000000000000000000000000000000000000000000000 56 00002929D1FF2929D1FF2929D1FFC0C0C0FF000000002929D1FFC0C0C0FF0000 57 0000000000000000000000000000000000000000000000000000000000000000 58 0000000000002C2CD4FF2C2CD4FF2C2CD4FF2C2CD4FF2C2CD4FFC0C0C0FF0000 59 0000000000000000000000000000000000000000000000000000000000000000 60 000000000000000000002F2FD7FF2F2FD7FF2F2FD7FFC0C0C0FF000000000000 61 0000000000000000000000000000000000000000000000000000000000000000 62 0000000000003232DAFF3232DAFF3232DAFF3232DAFF3232DAFFC0C0C0FF0000 63 0000000000000000000000000000000000000000000000000000000000000000 64 00003535DDFF3535DDFF3535DDFFC0C0C0FF000000003535DDFF3535DDFFC0C0 65 C0FF000000000000000000000000000000000000000000000000000000003838 66 E0FF3838E0FF3838E0FFC0C0C0FF0000000000000000000000003838E0FF3838 67 E0FFC0C0C0FF00000000000000000000000000000000000000003A3AE2FF3A3A 68 E2FF3A3AE2FFC0C0C0FF00000000000000000000000000000000000000003A3A 69 E2FFC0C0C0FF00000000000000000000000000000000000000003A3AE2FF3A3A 70 E2FF3A3AE2FFC0C0C0FF00000000000000000000000000000000000000000000 71 00003A3AE2FFC0C0C0FF00000000000000000000000000000000000000003A3A 72 E2FFC0C0C0FF0000000000000000000000000000000000000000000000000000 73 0000000000000000000000000000000000000000000000000000000000000000 74 0000000000000000000000000000000000000000000000000000000000000000 75 0000000000003A3AE2FFC0C0C0FF000000000000000000000000000000000000 76 0000000000000000000000000000000000000000000000000000000000000000 77 0000000000000000000000000000000000000000000000000000000000000000 78 0000000000000000000000000000000000000000000000000000000000000000 79 000000000000000000000000000000000000000000FF000000FF000000FF0000 80 00FF000000FF000000FF000000FF000000FF0000000000000000000000000000 81 000000000000000000000000000000000000000000FF000000FFFFFFFFFFFFFF 82 FFFFFFFFFFFFFFFFFFFFFFFFFFFF000000FF0000000000000000000000000000 83 000000000000000000000000000000000000000000FF008484FF000000FFFFFF 84 FFFFFFFFFFFFFFFFFFFFFFFFFFFF000000FF0000000000000000000000000000 85 0000840000FF000000000000000000000000000000FF008484FF008484FF0000 86 00FFFFFFFFFFFFFFFFFFFFFFFFFF000000FF0000000000000000000000008400 87 00FF840000FF000000000000000000000000000000FF008484FF008484FF0084 88 84FF000000FFFFFFFFFFFFFFFFFF000000FF0000000000000000840000FF8400 89 00FF840000FF840000FF840000FF00000000000000FF008484FF008484FF0084 90 84FF000000FFFFFFFFFFFFFFFFFF000000FF00000000840000FF840000FF8400 91 00FF840000FF840000FF840000FF00000000000000FF008484FF008484FF0084 92 84FF000000FFFFFFFFFFFFFFFFFF000000FF0000000000000000840000FF8400 93 00FF840000FF840000FF840000FF00000000000000FF008484FF008484FF0084 94 84FF000000FFFFFFFFFFFFFFFFFF000000FF0000000000000000000000008400 95 00FF840000FF000000000000000000000000000000FF008484FF008484FF0000 96 00FF000000FFFFFFFFFFFFFFFFFF000000FF0000000000000000000000000000 97 0000840000FF000000000000000000000000000000FF008484FF008484FF0084 98 84FF000000FFFFFFFFFFFFFFFFFF000000FF0000000000000000000000000000 99 0000000000000000000000000000000000FF000000FF008484FF008484FF0084 100 84FF000000FF000000FF000000FF000000FF000000FF000000FF000000FF0000 101 00FF0000000000000000000000000000000000000000000000FF008484FF0084 102 84FF000000FF0000000000000000000000000000000000000000000000000000 103 0000000000000000000000000000000000000000000000000000000000FF0084 104 84FF000000FF0000000000000000000000000000000000000000000000000000 105 0000000000000000000000000000000000000000000000000000000000000000 106 00FF000000FF0000000000000000000000000000000000000000000000000000 107 0000000000000000000000000000000000000000000000000000000000000000 108 0000000000FF0000000000000000000000000000000000000000000000000000 109 0000000000000000000000000000A37B48FFA37B48FFA27A47FFA27946FFA178 110 45FFA07744FFA07643FF9F7542FF9E7441FF9E7340FF9D723FFF9C713EFF9C70 111 3DFF9B6F3CFF9A6E3BFF9A6D3AFFA37B48FFBEA27FFFBEA17EFFBDA17DFFBDA0 112 7CFFBD9F7CFFBC9F7BFFBB9E7AFFBB9D7AFFBB9D79FFBA9C78FFB99B78FFB99A 113 77FFB89A76FFB89975FF996C39FFA27A47FFFFFFFFFFFFFFFFFFFEFEFEFFFEFE 114 FEFFFDFDFDFFFDFDFCFFFCFCFBFFFCFBFBFFFBFBFAFFFBFAF9FFFAFAF9FFFAF9 115 F8FFF9F9F7FFF9F8F7FF986B37FFA17946FFFFFFFFFF878787FF5D5D5DFFA0A0 116 A0FFFDFCFCFFFCFCFBFFFCFBFBFFFBFBFAFFFBFAF9FFFAFAF9FFFAF9F8FFF9F8 117 F7FFF8F8F7FFF8F7F6FF976A36FFA17844FFFEFEFEFF5F5F5FFF949494FF5353 118 53FFFCFCFBFF7B7B7BFF797979FF757575FF727272FF6E6E6EFF6A6A69FF6666 119 66FF626262FFF7F7F5FF966935FFA07643FFFEFDFDFF8C8C8CFF525252FFA4A4 120 A4FFFBFBFAFFFBFBFAFFFAFAF9FFFAF9F8FFF9F9F8FFF9F8F7FFF8F8F6FFF8F7 121 F6FFF7F7F5FFF7F6F4FF966734FF9F7542FFFDFDFCFFFCFCFCFFFCFCFBFFFBFB 122 FAFFFBFAFAFFFAFAF9FFFAF9F8FFF9F9F8FFF9F8F7FFF8F8F6FFF8F7F6FFF7F6 123 F5FFF7F6F4FFF6F5F4FF956633FF9E7441FFFCFCFCFFB5B5B5FF848484FFBEBD 124 BDFFFAFAF9FFFAF9F8FFF9F9F7FFF9F8F7FFF8F8F6FFF8F7F5FFF7F6F5FFF7F6 125 F4FFF6F5F3FFF6F5F3FF946531FF9D7340FFFCFBFBFF818181FFC4C4C4FF8F8F 126 8FFFFAF9F8FF7B7B7AFF797979FF757574FF727171FF6D6D6DFF696969FF6666 127 65FF626261FFF5F4F2FF936430FF9D723EFFFBFBFAFF9F9F9EFF7F7F7FFFAEAE 128 ADFFF9F8F7FFF8F8F7FFF8F7F6FFF7F7F5FFF7F6F5FFF6F6F4FFF6F5F3FFF5F4 129 F3FFF5F4F2FFF4F3F1FF92622FFF9C703DFFFAFAF9FFFAF9F9FFF9F9F8FFF9F8 130 F7FFF8F8F7FFF8F7F6FFF7F7F5FFF7F6F5FFF6F5F4FFF6F5F3FFF5F4F3FFF5F4 131 F2FFF4F3F1FFF4F3F0FF92612EFF9B6F3CFFFAF9F8FFBEBEBDFF929292FFBCBC 132 BBFFF8F7F6FFF7F7F5FFF7F6F4FFF6F5F4FFF6F5F3FFF5F4F2FFF5F4F2FFF4F3 133 F1FFF4F2F0FFF3F2F0FF91602DFF9A6E3BFFF9F9F8FF7C7C7CFFC4C4C4FF8787 134 87FFF7F6F5FF7A7A7AFF787878FF747474FF717170FF6D6D6CFF696968FF6565 135 65FF616161FFF2F1EFFF905F2BFF996D3AFFF9F8F7FF959594FF878787FF9B9A 136 9AFFF7F6F4FFF6F5F3FFF6F5F3FFF5F4F2FFF4F3F1FFF4F3F1FFF3F2F0FFF3F2 137 EFFFF2F1EFFFF2F1EEFF8F5E2AFF996C38FFF8F7F6FFF8F7F5FFF7F6F5FFF6F6 138 F4FFF6F5F3FFF5F5F3FFF5F4F2FFF4F3F1FFF4F3F1FFF3F2F0FFF3F2EFFFF2F1 139 EFFFF2F0EEFFF1F0EDFF8E5D29FF986B37FF976A36FF966935FF966734FF9566 140 33FF946532FF946531FF936430FF92622FFF92612EFF91602DFF90602CFF905F 141 2BFF8F5D2AFF8E5C29FF8D5B28FF000000000000000000000000000000000000 142 0000000000000000000000000000000000000000000000000000000000000000 143 0000000000000000000000000000000000000000000000000000000000000000 144 000000000000000000000000000000000000000000FF000000FF000000FF0000 145 0000000000000000000000000000000000000000000000000000000000000000 146 0000000000000000000000000000000000FF0000000000000000000000000000 147 00FF00000000000000FF00000000000000000000000000000000000000000000 148 0000000000000000000000000000000000000000000000000000000000000000 149 0000000000FF000000FF0000000000000000000000FF000000FF000000FF0000 150 0000000000000000000000000000000000000000000000000000000000000000 151 00FF000000FF000000FF00000000000000FF00FFFFFFFFFFFFFF00FFFFFF0000 152 00FF000000FF000000FF000000FF000000FF000000FF000000FF000000000000 153 0000000000000000000000000000000000FFFFFFFFFF00FFFFFFFFFFFFFF00FF 154 FFFFFFFFFFFF00FFFFFFFFFFFFFF00FFFFFFFFFFFFFF000000FF000000000000 155 0000000000000000000000000000000000FF00FFFFFFFFFFFFFF00FFFFFFFFFF 156 FFFF00FFFFFFFFFFFFFF00FFFFFFFFFFFFFF00FFFFFF000000FF000000000000 157 0000000000000000000000000000000000FFFFFFFFFF00FFFFFFFFFFFFFF00FF 158 FFFF000000FF000000FF000000FF000000FF000000FF000000FF000000FF0000 159 00FF000000FF000000FF000000FF000000FF00FFFFFFFFFFFFFF00FFFFFF0000 160 00FF008484FF008484FF008484FF008484FF008484FF008484FF008484FF0084 161 84FF008484FF000000FF00000000000000FFFFFFFFFF00FFFFFF000000FF0084 162 84FF008484FF008484FF008484FF008484FF008484FF008484FF008484FF0084 163 84FF000000FF0000000000000000000000FF00FFFFFF000000FF008484FF0084 164 84FF008484FF008484FF008484FF008484FF008484FF008484FF008484FF0000 165 00FF000000000000000000000000000000FF000000FF008484FF008484FF0084 166 84FF008484FF008484FF008484FF008484FF008484FF008484FF000000FF0000 167 0000000000000000000000000000000000FF000000FF000000FF000000FF0000 168 00FF000000FF000000FF000000FF000000FF000000FF000000FF000000000000 169 0000000000000000000000000000000000000000000000000000000000000000 170 0000000000000000000000000000000000000000000000000000000000000000 171 0000000000000000000000000000000000000000000000000000000000000000 172 0000000000000000000000000000000000000000000000000000000000000000 173 0000000000000000000000000000000000000000000000000000000000000000 174 0000000000000000000000000000000000000000000000000000000000000000 175 000000000000000000000000000000000000000000FF000000FF000000FF0000 176 00FF000000FF000000FF000000FF000000FF000000FF000000FF000000FF0000 177 00FF000000FF000000FF0000000000000000000000FF008484FF000000FFFFFF 178 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000 179 00FFFFFFFFFF000000FF0000000000000000000000FF008484FF000000FFFFFF 180 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000 181 00FF000000FF000000FF0000000000000000000000FF008484FF000000FFFFFF 182 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000 183 00FF008484FF000000FF0000000000000000000000FF008484FF000000FFFFFF 184 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000 185 00FF008484FF000000FF0000000000000000000000FF008484FF000000FFFFFF 186 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000 187 00FF008484FF000000FF0000000000000000000000FF008484FF000000FFFFFF 188 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000 189 00FF008484FF000000FF0000000000000000000000FF008484FF008484FF0000 190 00FF000000FF000000FF000000FF000000FF000000FF000000FF000000FF0084 191 84FF008484FF000000FF0000000000000000000000FF008484FF008484FF0084 192 84FF008484FF008484FF008484FF008484FF008484FF008484FF008484FF0084 193 84FF008484FF000000FF0000000000000000000000FF008484FF008484FF0000 194 00FF000000FF000000FF000000FF000000FF000000FF000000FF000000FF0000 195 00FF008484FF000000FF0000000000000000000000FF008484FF008484FF0000 196 00FF000000FF000000FF000000FF000000FF000000FFFFFFFFFFFFFFFFFF0000 197 00FF008484FF000000FF0000000000000000000000FF008484FF008484FF0000 198 00FF000000FF000000FF000000FF000000FF000000FFFFFFFFFFFFFFFFFF0000 199 00FF008484FF000000FF0000000000000000000000FF008484FF008484FF0000 200 00FF000000FF000000FF000000FF000000FF000000FFFFFFFFFFFFFFFFFF0000 201 00FF008484FF000000FF000000000000000000000000000000FF000000FF0000 202 00FF000000FF000000FF000000FF000000FF000000FF000000FF000000FF0000 203 00FF000000FF000000FF00000000000000000000000000000000000000000000 204 0000000000000000000000000000000000000000000000000000000000000000 205 0000000000000000000000000000 206 } 12 207 end 13 208 end -
branches/generator/URules.pas
r111 r112 29 29 end; 30 30 31 TRuleType = (rtAnd, rtOr); 32 31 33 { TRuleItems } 32 34 … … 35 37 procedure LoadFromXmlNode(Node: TDOMNode); 36 38 procedure SaveToXmlNode(Node: TDOMNode); 37 end; 38 39 TRuleType = (rtAnd, rtOr); 39 function GetBNF(RuleType: TRuleType): string; 40 end; 40 41 41 42 { TRule } … … 190 191 end; 191 192 193 function TRuleItems.GetBNF(RuleType: TRuleType): string; 194 var 195 Item: TRuleItem; 196 begin 197 Result := ''; 198 for Item in Self do begin 199 if Item <> First then begin 200 if RuleType = rtAnd then Result := Result + ' ' 201 else if RuleType = rtOr then Result := Result + ' | '; 202 end; 203 Result := Result + Item.GetBNF; 204 end; 205 end; 206 192 207 procedure TRuleItems.LoadFromXmlNode(Node: TDOMNode); 193 208 var … … 221 236 222 237 function TRule.GetBNF: string; 223 var 224 Item: TRuleItem; 225 begin 226 Result := Name + ' ::= '; 227 for Item in Items do begin 228 if Item <> Items.First then begin 229 if RuleType = rtAnd then Result := Result + ' ' 230 else if RuleType = rtOr then Result := Result + ' | '; 231 end; 232 Result := Result + Item.GetBNF; 233 end; 238 begin 239 Result := Name + ' ::= ' + Items.GetBNF(RuleType); 234 240 end; 235 241
Note:
See TracChangeset
for help on using the changeset viewer.