Browse Source

init

tags/0.0.1
aligator 2 years ago
commit
d5721026e4

+ 73
- 0
build.xml View File

@@ -0,0 +1,73 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!-- You may freely edit this file. See commented blocks below for -->
3
+<!-- some examples of how to customize the build. -->
4
+<!-- (If you delete it and reopen the project it will be recreated.) -->
5
+<!-- By default, only the Clean and Build commands use this build script. -->
6
+<!-- Commands such as Run, Debug, and Test only use this build script if -->
7
+<!-- the Compile on Save feature is turned off for the project. -->
8
+<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
9
+<!-- in the project's Project Properties dialog box.-->
10
+<project name="brainfuck" default="default" basedir=".">
11
+    <description>Builds, tests, and runs the project brainfuck.</description>
12
+    <import file="nbproject/build-impl.xml"/>
13
+    <!--
14
+
15
+    There exist several targets which are by default empty and which can be 
16
+    used for execution of your tasks. These targets are usually executed 
17
+    before and after some main targets. They are: 
18
+
19
+      -pre-init:                 called before initialization of project properties
20
+      -post-init:                called after initialization of project properties
21
+      -pre-compile:              called before javac compilation
22
+      -post-compile:             called after javac compilation
23
+      -pre-compile-single:       called before javac compilation of single file
24
+      -post-compile-single:      called after javac compilation of single file
25
+      -pre-compile-test:         called before javac compilation of JUnit tests
26
+      -post-compile-test:        called after javac compilation of JUnit tests
27
+      -pre-compile-test-single:  called before javac compilation of single JUnit test
28
+      -post-compile-test-single: called after javac compilation of single JUunit test
29
+      -pre-jar:                  called before JAR building
30
+      -post-jar:                 called after JAR building
31
+      -post-clean:               called after cleaning build products
32
+
33
+    (Targets beginning with '-' are not intended to be called on their own.)
34
+
35
+    Example of inserting an obfuscator after compilation could look like this:
36
+
37
+        <target name="-post-compile">
38
+            <obfuscate>
39
+                <fileset dir="${build.classes.dir}"/>
40
+            </obfuscate>
41
+        </target>
42
+
43
+    For list of available properties check the imported 
44
+    nbproject/build-impl.xml file. 
45
+
46
+
47
+    Another way to customize the build is by overriding existing main targets.
48
+    The targets of interest are: 
49
+
50
+      -init-macrodef-javac:     defines macro for javac compilation
51
+      -init-macrodef-junit:     defines macro for junit execution
52
+      -init-macrodef-debug:     defines macro for class debugging
53
+      -init-macrodef-java:      defines macro for class execution
54
+      -do-jar:                  JAR building
55
+      run:                      execution of project 
56
+      -javadoc-build:           Javadoc generation
57
+      test-report:              JUnit report generation
58
+
59
+    An example of overriding the target for project execution could look like this:
60
+
61
+        <target name="run" depends="brainfuck-impl.jar">
62
+            <exec dir="bin" executable="launcher.exe">
63
+                <arg file="${dist.jar}"/>
64
+            </exec>
65
+        </target>
66
+
67
+    Notice that the overridden target depends on the jar target and not only on 
68
+    the compile target as the regular run target does. Again, for a list of available 
69
+    properties which you can use, check the target you are overriding in the
70
+    nbproject/build-impl.xml file. 
71
+
72
+    -->
73
+</project>

+ 3
- 0
manifest.mf View File

@@ -0,0 +1,3 @@
1
+Manifest-Version: 1.0
2
+X-COMMENT: Main-Class will be added automatically by build
3
+

+ 1420
- 0
nbproject/build-impl.xml
File diff suppressed because it is too large
View File


+ 8
- 0
nbproject/genfiles.properties View File

@@ -0,0 +1,8 @@
1
+build.xml.data.CRC32=f574e2d4
2
+build.xml.script.CRC32=50dff12d
3
+build.xml.stylesheet.CRC32=8064a381@1.75.2.48
4
+# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
5
+# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
6
+nbproject/build-impl.xml.data.CRC32=f574e2d4
7
+nbproject/build-impl.xml.script.CRC32=3b252623
8
+nbproject/build-impl.xml.stylesheet.CRC32=830a3534@1.80.1.48

+ 75
- 0
nbproject/project.properties View File

@@ -0,0 +1,75 @@
1
+annotation.processing.enabled=true
2
+annotation.processing.enabled.in.editor=false
3
+annotation.processing.processors.list=
4
+annotation.processing.run.all.processors=true
5
+annotation.processing.source.output=${build.generated.sources.dir}/ap-source-output
6
+application.title=brainfuck
7
+application.vendor=johannes
8
+build.classes.dir=${build.dir}/classes
9
+build.classes.excludes=**/*.java,**/*.form
10
+# This directory is removed when the project is cleaned:
11
+build.dir=build
12
+build.generated.dir=${build.dir}/generated
13
+build.generated.sources.dir=${build.dir}/generated-sources
14
+# Only compile against the classpath explicitly listed here:
15
+build.sysclasspath=ignore
16
+build.test.classes.dir=${build.dir}/test/classes
17
+build.test.results.dir=${build.dir}/test/results
18
+# Uncomment to specify the preferred debugger connection transport:
19
+#debug.transport=dt_socket
20
+debug.classpath=\
21
+    ${run.classpath}
22
+debug.test.classpath=\
23
+    ${run.test.classpath}
24
+# Files in build.classes.dir which should be excluded from distribution jar
25
+dist.archive.excludes=
26
+# This directory is removed when the project is cleaned:
27
+dist.dir=dist
28
+dist.jar=${dist.dir}/brainfuck.jar
29
+dist.javadoc.dir=${dist.dir}/javadoc
30
+endorsed.classpath=
31
+excludes=
32
+includes=**
33
+jar.compress=false
34
+javac.classpath=
35
+# Space-separated list of extra javac options
36
+javac.compilerargs=
37
+javac.deprecation=false
38
+javac.processorpath=\
39
+    ${javac.classpath}
40
+javac.source=1.7
41
+javac.target=1.7
42
+javac.test.classpath=\
43
+    ${javac.classpath}:\
44
+    ${build.classes.dir}
45
+javac.test.processorpath=\
46
+    ${javac.test.classpath}
47
+javadoc.additionalparam=
48
+javadoc.author=false
49
+javadoc.encoding=${source.encoding}
50
+javadoc.noindex=false
51
+javadoc.nonavbar=false
52
+javadoc.notree=false
53
+javadoc.private=false
54
+javadoc.splitindex=true
55
+javadoc.use=true
56
+javadoc.version=false
57
+javadoc.windowtitle=
58
+main.class=brainfuck.Brainfuck
59
+manifest.file=manifest.mf
60
+meta.inf.dir=${src.dir}/META-INF
61
+mkdist.disabled=false
62
+platform.active=default_platform
63
+run.classpath=\
64
+    ${javac.classpath}:\
65
+    ${build.classes.dir}
66
+# Space-separated list of JVM arguments used when running the project.
67
+# You may also define separate properties like run-sys-prop.name=value instead of -Dname=value.
68
+# To set system properties for unit tests define test-sys-prop.name=value:
69
+run.jvmargs=
70
+run.test.classpath=\
71
+    ${javac.test.classpath}:\
72
+    ${build.test.classes.dir}
73
+source.encoding=UTF-8
74
+src.dir=src
75
+test.src.dir=test

+ 15
- 0
nbproject/project.xml View File

@@ -0,0 +1,15 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project xmlns="http://www.netbeans.org/ns/project/1">
3
+    <type>org.netbeans.modules.java.j2seproject</type>
4
+    <configuration>
5
+        <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
6
+            <name>brainfuck</name>
7
+            <source-roots>
8
+                <root id="src.dir"/>
9
+            </source-roots>
10
+            <test-roots>
11
+                <root id="test.src.dir"/>
12
+            </test-roots>
13
+        </data>
14
+    </configuration>
15
+</project>

+ 21
- 0
src/brainfuck/Brainfuck.java View File

@@ -0,0 +1,21 @@
1
+/*
2
+ * To change this license header, choose License Headers in Project Properties.
3
+ * To change this template file, choose Tools | Templates
4
+ * and open the template in the editor.
5
+ */
6
+package brainfuck;
7
+
8
+/**
9
+ *
10
+ * @author johannes
11
+ */
12
+public class Brainfuck {
13
+
14
+    /**
15
+     * @param args the command line arguments
16
+     */
17
+    public static void main(String[] args) {
18
+        MainFrame.main(args);
19
+    }
20
+    
21
+}

+ 85
- 0
src/brainfuck/ConsoleFrame.form View File

@@ -0,0 +1,85 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+
3
+<Form version="1.3" maxVersion="1.9" type="org.netbeans.modules.form.forminfo.JFrameFormInfo">
4
+  <Properties>
5
+    <Property name="defaultCloseOperation" type="int" value="3"/>
6
+    <Property name="title" type="java.lang.String" value="Brainfuck Console"/>
7
+  </Properties>
8
+  <SyntheticProperties>
9
+    <SyntheticProperty name="formSizePolicy" type="int" value="1"/>
10
+    <SyntheticProperty name="generateCenter" type="boolean" value="false"/>
11
+  </SyntheticProperties>
12
+  <Events>
13
+    <EventHandler event="windowOpened" listener="java.awt.event.WindowListener" parameters="java.awt.event.WindowEvent" handler="formWindowOpened"/>
14
+  </Events>
15
+  <AuxValues>
16
+    <AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="0"/>
17
+    <AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="false"/>
18
+    <AuxValue name="FormSettings_generateFQN" type="java.lang.Boolean" value="true"/>
19
+    <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
20
+    <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
21
+    <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
22
+    <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
23
+    <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
24
+    <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
25
+  </AuxValues>
26
+
27
+  <Layout>
28
+    <DimensionLayout dim="0">
29
+      <Group type="103" groupAlignment="0" attributes="0">
30
+          <Group type="102" attributes="0">
31
+              <Component id="textFieldIn" max="32767" attributes="0"/>
32
+              <EmptySpace max="-2" attributes="0"/>
33
+              <Component id="buttonRerun" min="-2" max="-2" attributes="0"/>
34
+          </Group>
35
+          <Component id="jScrollPane1" pref="623" max="32767" attributes="0"/>
36
+      </Group>
37
+    </DimensionLayout>
38
+    <DimensionLayout dim="1">
39
+      <Group type="103" groupAlignment="0" attributes="0">
40
+          <Group type="102" alignment="0" attributes="0">
41
+              <Component id="jScrollPane1" pref="360" max="32767" attributes="0"/>
42
+              <EmptySpace max="-2" attributes="0"/>
43
+              <Group type="103" groupAlignment="3" attributes="0">
44
+                  <Component id="buttonRerun" alignment="3" min="-2" max="-2" attributes="0"/>
45
+                  <Component id="textFieldIn" alignment="3" min="-2" max="-2" attributes="0"/>
46
+              </Group>
47
+              <EmptySpace max="-2" attributes="0"/>
48
+          </Group>
49
+      </Group>
50
+    </DimensionLayout>
51
+  </Layout>
52
+  <SubComponents>
53
+    <Container class="javax.swing.JScrollPane" name="jScrollPane1">
54
+      <AuxValues>
55
+        <AuxValue name="autoScrollPane" type="java.lang.Boolean" value="true"/>
56
+      </AuxValues>
57
+
58
+      <Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/>
59
+      <SubComponents>
60
+        <Component class="javax.swing.JTextArea" name="textAreaOut">
61
+          <Properties>
62
+            <Property name="columns" type="int" value="20"/>
63
+            <Property name="rows" type="int" value="5"/>
64
+          </Properties>
65
+          <Events>
66
+            <EventHandler event="keyTyped" listener="java.awt.event.KeyListener" parameters="java.awt.event.KeyEvent" handler="textAreaOutKeyTyped"/>
67
+          </Events>
68
+        </Component>
69
+      </SubComponents>
70
+    </Container>
71
+    <Component class="javax.swing.JTextField" name="textFieldIn">
72
+      <Events>
73
+        <EventHandler event="keyTyped" listener="java.awt.event.KeyListener" parameters="java.awt.event.KeyEvent" handler="textFieldInKeyTyped"/>
74
+      </Events>
75
+    </Component>
76
+    <Component class="javax.swing.JButton" name="buttonRerun">
77
+      <Properties>
78
+        <Property name="text" type="java.lang.String" value="Run again"/>
79
+      </Properties>
80
+      <Events>
81
+        <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="buttonRerunActionPerformed"/>
82
+      </Events>
83
+    </Component>
84
+  </SubComponents>
85
+</Form>

+ 203
- 0
src/brainfuck/ConsoleFrame.java View File

@@ -0,0 +1,203 @@
1
+/*
2
+ * To change this license header, choose License Headers in Project Properties.
3
+ * To change this template file, choose Tools | Templates
4
+ * and open the template in the editor.
5
+ */
6
+package brainfuck;
7
+
8
+
9
+/**
10
+ *
11
+ * @author johannes
12
+ */
13
+public class ConsoleFrame extends javax.swing.JFrame {
14
+    
15
+    private static String code;
16
+    private static String codeSaved;
17
+    private static boolean twoBytes;
18
+    private boolean twoBytesSaved;
19
+    private Interpreter interpreter;
20
+    private boolean needInput = false;
21
+    /**
22
+     * Creates new form Console
23
+     */
24
+    public ConsoleFrame() {
25
+        initComponents();
26
+        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
27
+        textFieldIn.grabFocus();
28
+    }
29
+
30
+    /**
31
+     * This method is called from within the constructor to initialize the form.
32
+     * WARNING: Do NOT modify this code. The content of this method is always
33
+     * regenerated by the Form Editor.
34
+     */
35
+    @SuppressWarnings("unchecked")
36
+    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
37
+    private void initComponents() {
38
+
39
+        jScrollPane1 = new javax.swing.JScrollPane();
40
+        textAreaOut = new javax.swing.JTextArea();
41
+        textFieldIn = new javax.swing.JTextField();
42
+        buttonRerun = new javax.swing.JButton();
43
+
44
+        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
45
+        setTitle("Brainfuck Console");
46
+        addWindowListener(new java.awt.event.WindowAdapter() {
47
+            public void windowOpened(java.awt.event.WindowEvent evt) {
48
+                formWindowOpened(evt);
49
+            }
50
+        });
51
+
52
+        textAreaOut.setColumns(20);
53
+        textAreaOut.setRows(5);
54
+        textAreaOut.addKeyListener(new java.awt.event.KeyAdapter() {
55
+            public void keyTyped(java.awt.event.KeyEvent evt) {
56
+                textAreaOutKeyTyped(evt);
57
+            }
58
+        });
59
+        jScrollPane1.setViewportView(textAreaOut);
60
+
61
+        textFieldIn.addKeyListener(new java.awt.event.KeyAdapter() {
62
+            public void keyTyped(java.awt.event.KeyEvent evt) {
63
+                textFieldInKeyTyped(evt);
64
+            }
65
+        });
66
+
67
+        buttonRerun.setText("Run again");
68
+        buttonRerun.addActionListener(new java.awt.event.ActionListener() {
69
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
70
+                buttonRerunActionPerformed(evt);
71
+            }
72
+        });
73
+
74
+        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
75
+        getContentPane().setLayout(layout);
76
+        layout.setHorizontalGroup(
77
+            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
78
+            .addGroup(layout.createSequentialGroup()
79
+                .addComponent(textFieldIn)
80
+                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
81
+                .addComponent(buttonRerun))
82
+            .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 623, Short.MAX_VALUE)
83
+        );
84
+        layout.setVerticalGroup(
85
+            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
86
+            .addGroup(layout.createSequentialGroup()
87
+                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 360, Short.MAX_VALUE)
88
+                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
89
+                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
90
+                    .addComponent(buttonRerun)
91
+                    .addComponent(textFieldIn, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
92
+                .addContainerGap())
93
+        );
94
+
95
+        pack();
96
+    }// </editor-fold>//GEN-END:initComponents
97
+
98
+    private void formWindowOpened(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowOpened
99
+        
100
+        codeSaved = ConsoleFrame.code;
101
+        twoBytesSaved = twoBytes;
102
+        
103
+        run();
104
+    }//GEN-LAST:event_formWindowOpened
105
+
106
+    private void buttonRerunActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonRerunActionPerformed
107
+        interpreter.interrupt();
108
+        
109
+        while(interpreter.isAlive()) {
110
+            
111
+        }
112
+        textFieldIn.grabFocus();
113
+        run();
114
+    }//GEN-LAST:event_buttonRerunActionPerformed
115
+
116
+    private void textFieldInKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_textFieldInKeyTyped
117
+        evt.consume();
118
+        if(needInput) {
119
+                needInput = false;
120
+                
121
+                textFieldIn.setText(textFieldIn.getText() + evt.getKeyChar());
122
+                
123
+                sendInput(evt.getKeyChar());
124
+        }
125
+    }//GEN-LAST:event_textFieldInKeyTyped
126
+
127
+    private void textAreaOutKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_textAreaOutKeyTyped
128
+        evt.consume();
129
+    }//GEN-LAST:event_textAreaOutKeyTyped
130
+            
131
+    private void run() {
132
+        clearText();
133
+        interpreter = new Interpreter(codeSaved, twoBytesSaved, this);
134
+        interpreter.start();
135
+    }
136
+    
137
+    private void clearText() {
138
+        textAreaOut.setText("");
139
+        textFieldIn.setText("");
140
+    }
141
+    
142
+    public void addText(char chr) {
143
+        textAreaOut.setText(textAreaOut.getText() + String.valueOf(chr));
144
+    }
145
+    
146
+    public void requestInput() {
147
+        needInput = true;
148
+    }
149
+    
150
+    public void sendInput(char chr) {
151
+        interpreter.setInput(chr);
152
+    }
153
+    
154
+    /**
155
+     * 
156
+     * @param code
157
+     * @param twoBytes
158
+     */
159
+    public static void main(String code, boolean twoBytes) {
160
+        /* Set the Nimbus look and feel */
161
+        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
162
+        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
163
+         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
164
+         */
165
+        try {
166
+            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
167
+                if ("Nimbus".equals(info.getName())) {
168
+                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
169
+                    break;
170
+                }
171
+            }
172
+        } catch (ClassNotFoundException ex) {
173
+            java.util.logging.Logger.getLogger(ConsoleFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
174
+        } catch (InstantiationException ex) {
175
+            java.util.logging.Logger.getLogger(ConsoleFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
176
+        } catch (IllegalAccessException ex) {
177
+            java.util.logging.Logger.getLogger(ConsoleFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
178
+        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
179
+            java.util.logging.Logger.getLogger(ConsoleFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
180
+        }
181
+        //</editor-fold>
182
+        //</editor-fold>
183
+
184
+        /* Create and display the form */
185
+        java.awt.EventQueue.invokeLater(new Runnable() {
186
+            @Override
187
+            public void run() {
188
+                new ConsoleFrame().setVisible(true);
189
+            }
190
+        });
191
+        
192
+        ConsoleFrame.code = code;
193
+        ConsoleFrame.twoBytes = twoBytes;
194
+        
195
+    }
196
+
197
+    // Variables declaration - do not modify//GEN-BEGIN:variables
198
+    private javax.swing.JButton buttonRerun;
199
+    private javax.swing.JScrollPane jScrollPane1;
200
+    private javax.swing.JTextArea textAreaOut;
201
+    private javax.swing.JTextField textFieldIn;
202
+    // End of variables declaration//GEN-END:variables
203
+}

+ 190
- 0
src/brainfuck/Interpreter.java View File

@@ -0,0 +1,190 @@
1
+/*
2
+ * To change this license header, choose License Headers in Project Properties.
3
+ * To change this template file, choose Tools | Templates
4
+ * and open the template in the editor.
5
+ */
6
+package brainfuck;
7
+
8
+/**
9
+ *
10
+ * @author johannes
11
+ */
12
+public class Interpreter extends Thread{
13
+   
14
+    private final ConsoleFrame cf;
15
+    private final char[] code; 
16
+    private final boolean twoBytes;
17
+    private int pointer;
18
+    private int[] openBrackets;
19
+    private int[] closedBrackets;
20
+    private char input;
21
+    private final Object sync = new Object();
22
+    
23
+    private final char[] array = new char[30000];
24
+    
25
+    public Interpreter(String input, boolean twoBytes, ConsoleFrame cf) {
26
+        this.cf = cf;
27
+        this.pointer = 0;
28
+        this.code = input.toCharArray();
29
+        this.twoBytes = twoBytes;
30
+    }
31
+        
32
+    
33
+    private void incrementData() {
34
+        char value = array[pointer];
35
+        if(twoBytes) {
36
+            if(value < Character.MAX_VALUE)
37
+                value += 1;
38
+        } else {
39
+            if(value < Byte.MAX_VALUE)
40
+                value += 1;
41
+        }
42
+        array[pointer] = value;
43
+    }
44
+    
45
+    private void decrementData() {
46
+        char value = array[pointer];
47
+        
48
+        if(twoBytes) {
49
+            if(value > Character.MIN_VALUE)
50
+                value -= 1;
51
+        } else {
52
+            if(value > Byte.MIN_VALUE)
53
+                value -= 1;
54
+        }
55
+        
56
+        array[pointer] = value;
57
+    }
58
+    
59
+    private void incrementPointer() {
60
+        if(pointer < array.length - 1)
61
+            pointer += 1;
62
+    }
63
+  
64
+    private void decrementPointer() {
65
+        if(pointer > 0)
66
+            pointer -= 1;
67
+    }
68
+    
69
+    private void output() {
70
+        cf.addText((char)array[pointer]);
71
+    }
72
+    
73
+    private char getChar() {
74
+        return array[pointer];
75
+    }
76
+    
77
+    private boolean getInput() {
78
+        boolean kill = false;
79
+        
80
+        cf.requestInput();
81
+        
82
+        synchronized (this.sync) {
83
+            try {
84
+                this.sync.wait();
85
+            } catch (InterruptedException ex) {
86
+                kill = true;
87
+            }
88
+        }
89
+        
90
+        if(!kill) {
91
+            if(!twoBytes && this.input > Byte.MAX_VALUE) {
92
+                    array[pointer] = Byte.MAX_VALUE;
93
+            } else {
94
+                array[pointer] = this.input;
95
+            }
96
+        }
97
+        return kill;
98
+    }
99
+    
100
+    public void setInput(char input) {
101
+        this.input = input; 
102
+        
103
+        synchronized(this.sync) {
104
+            this.sync.notify();
105
+        }
106
+    }
107
+    
108
+    private void prepareCode() {
109
+        int counter = 0;
110
+                
111
+        for(char chr : code) {
112
+            if(chr == '[') {
113
+                counter++;
114
+            }
115
+        }
116
+        
117
+        openBrackets = new int[counter];
118
+        closedBrackets = new int[counter];
119
+        
120
+        counter = 0;
121
+        int i = 0;
122
+        for(char chr : code) {
123
+            if(chr == '[') {
124
+                openBrackets[counter] = i;
125
+                int loops = 1;
126
+                int loopPointer = i;
127
+                
128
+                while(loops > 0) {
129
+                    loopPointer++;
130
+                    if(code[loopPointer] == '[')
131
+                        loops++;
132
+                    if(code[loopPointer] == ']')
133
+                        loops--;
134
+                }
135
+                closedBrackets[counter] = loopPointer;
136
+                counter++;
137
+            }
138
+            i++;
139
+        }
140
+    }
141
+    
142
+    @Override
143
+    public void run() {
144
+        prepareCode();
145
+        boolean kill = false;
146
+        
147
+        int i=0;
148
+        while(i<code.length && !kill) {
149
+            char chr = code[i];
150
+            switch(chr) {
151
+                case '>':
152
+                    incrementPointer();
153
+                    break;
154
+                case '<':
155
+                    decrementPointer();
156
+                    break;
157
+                case '+':
158
+                    incrementData();
159
+                    break;
160
+                case '-':
161
+                    decrementData();
162
+                    break;
163
+                case '.':
164
+                    output();
165
+                    break;
166
+                case ',':
167
+                    kill = getInput();
168
+                    break;
169
+                case '[':
170
+                    if(getChar() == (char)0) {
171
+                        int j = 0;
172
+                        while(openBrackets[j] != i) {
173
+                            j++;
174
+                        }
175
+                        i = closedBrackets[j];
176
+                    }
177
+                    break;
178
+                case ']':
179
+                    int j = 0;
180
+                        while(closedBrackets[j] != i) {
181
+                            j++;
182
+                        }
183
+                        i = openBrackets[j] - 1;
184
+                    break;
185
+                
186
+            }
187
+            i++;
188
+        }
189
+    }
190
+}

+ 127
- 0
src/brainfuck/MainFrame.form View File

@@ -0,0 +1,127 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+
3
+<Form version="1.3" maxVersion="1.9" type="org.netbeans.modules.form.forminfo.JFrameFormInfo">
4
+  <NonVisualComponents>
5
+    <Container class="javax.swing.JScrollPane" name="jScrollPane2">
6
+      <AuxValues>
7
+        <AuxValue name="autoScrollPane" type="java.lang.Boolean" value="true"/>
8
+      </AuxValues>
9
+
10
+      <Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/>
11
+      <SubComponents>
12
+        <Component class="javax.swing.JTextArea" name="jTextArea2">
13
+          <Properties>
14
+            <Property name="columns" type="int" value="20"/>
15
+            <Property name="rows" type="int" value="5"/>
16
+          </Properties>
17
+        </Component>
18
+      </SubComponents>
19
+    </Container>
20
+  </NonVisualComponents>
21
+  <Properties>
22
+    <Property name="defaultCloseOperation" type="int" value="3"/>
23
+    <Property name="title" type="java.lang.String" value="Brainfuck"/>
24
+  </Properties>
25
+  <SyntheticProperties>
26
+    <SyntheticProperty name="formSizePolicy" type="int" value="1"/>
27
+    <SyntheticProperty name="generateCenter" type="boolean" value="false"/>
28
+  </SyntheticProperties>
29
+  <Events>
30
+    <EventHandler event="windowOpened" listener="java.awt.event.WindowListener" parameters="java.awt.event.WindowEvent" handler="formWindowOpened"/>
31
+  </Events>
32
+  <AuxValues>
33
+    <AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="0"/>
34
+    <AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="false"/>
35
+    <AuxValue name="FormSettings_generateFQN" type="java.lang.Boolean" value="true"/>
36
+    <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
37
+    <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
38
+    <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
39
+    <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
40
+    <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
41
+    <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
42
+  </AuxValues>
43
+
44
+  <Layout>
45
+    <DimensionLayout dim="0">
46
+      <Group type="103" groupAlignment="0" attributes="0">
47
+          <Group type="102" attributes="0">
48
+              <EmptySpace max="-2" attributes="0"/>
49
+              <Component id="buttonRun" min="-2" max="-2" attributes="0"/>
50
+              <EmptySpace max="-2" attributes="0"/>
51
+              <Component id="checkBox2Bytes" min="-2" max="-2" attributes="0"/>
52
+              <EmptySpace max="32767" attributes="0"/>
53
+              <Component id="buttonSave" min="-2" max="-2" attributes="0"/>
54
+              <EmptySpace max="-2" attributes="0"/>
55
+              <Component id="buttonLoad" min="-2" max="-2" attributes="0"/>
56
+          </Group>
57
+          <Component id="jScrollPane1" pref="427" max="32767" attributes="0"/>
58
+      </Group>
59
+    </DimensionLayout>
60
+    <DimensionLayout dim="1">
61
+      <Group type="103" groupAlignment="0" attributes="0">
62
+          <Group type="102" attributes="0">
63
+              <EmptySpace max="-2" attributes="0"/>
64
+              <Group type="103" groupAlignment="3" attributes="0">
65
+                  <Component id="buttonRun" alignment="3" min="-2" max="-2" attributes="0"/>
66
+                  <Component id="checkBox2Bytes" alignment="3" min="-2" max="-2" attributes="0"/>
67
+                  <Component id="buttonSave" alignment="3" min="-2" max="-2" attributes="0"/>
68
+                  <Component id="buttonLoad" alignment="3" min="-2" max="-2" attributes="0"/>
69
+              </Group>
70
+              <EmptySpace max="-2" attributes="0"/>
71
+              <Component id="jScrollPane1" pref="357" max="32767" attributes="0"/>
72
+          </Group>
73
+      </Group>
74
+    </DimensionLayout>
75
+  </Layout>
76
+  <SubComponents>
77
+    <Container class="javax.swing.JScrollPane" name="jScrollPane1">
78
+      <AuxValues>
79
+        <AuxValue name="autoScrollPane" type="java.lang.Boolean" value="true"/>
80
+      </AuxValues>
81
+
82
+      <Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/>
83
+      <SubComponents>
84
+        <Component class="javax.swing.JTextArea" name="textAreaCode">
85
+          <Properties>
86
+            <Property name="columns" type="int" value="20"/>
87
+            <Property name="rows" type="int" value="5"/>
88
+            <Property name="autoscrolls" type="boolean" value="false"/>
89
+          </Properties>
90
+        </Component>
91
+      </SubComponents>
92
+    </Container>
93
+    <Component class="javax.swing.JButton" name="buttonRun">
94
+      <Properties>
95
+        <Property name="text" type="java.lang.String" value="Run"/>
96
+        <Property name="actionCommand" type="java.lang.String" value="buttonRun"/>
97
+      </Properties>
98
+      <AccessibilityProperties>
99
+        <Property name="AccessibleContext.accessibleDescription" type="java.lang.String" value=""/>
100
+      </AccessibilityProperties>
101
+      <Events>
102
+        <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="buttonRunActionPerformed"/>
103
+      </Events>
104
+    </Component>
105
+    <Component class="javax.swing.JCheckBox" name="checkBox2Bytes">
106
+      <Properties>
107
+        <Property name="text" type="java.lang.String" value="use 2 Bytes for Chars"/>
108
+      </Properties>
109
+    </Component>
110
+    <Component class="javax.swing.JButton" name="buttonSave">
111
+      <Properties>
112
+        <Property name="text" type="java.lang.String" value="Save"/>
113
+      </Properties>
114
+      <Events>
115
+        <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="buttonSaveActionPerformed"/>
116
+      </Events>
117
+    </Component>
118
+    <Component class="javax.swing.JButton" name="buttonLoad">
119
+      <Properties>
120
+        <Property name="text" type="java.lang.String" value="Load"/>
121
+      </Properties>
122
+      <Events>
123
+        <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="buttonLoadActionPerformed"/>
124
+      </Events>
125
+    </Component>
126
+  </SubComponents>
127
+</Form>

+ 300
- 0
src/brainfuck/MainFrame.java View File

@@ -0,0 +1,300 @@
1
+/*
2
+ * To change this license header, choose License Headers in Project Properties.
3
+ * To change this template file, choose Tools | Templates
4
+ * and open the template in the editor.
5
+ */
6
+package brainfuck;
7
+
8
+import java.io.BufferedReader;
9
+import java.io.BufferedWriter;
10
+import java.io.File;
11
+import java.io.FileReader;
12
+import java.io.FileWriter;
13
+import java.io.IOException;
14
+import java.util.logging.Level;
15
+import java.util.logging.Logger;
16
+import javax.swing.JFileChooser;
17
+
18
+/**
19
+ *
20
+ * @author johannes
21
+ */
22
+public class MainFrame extends javax.swing.JFrame {
23
+
24
+    /**
25
+     * Creates new form MainFrame
26
+     */
27
+    public MainFrame() {
28
+        initComponents();
29
+    }
30
+
31
+    /**
32
+     * This method is called from within the constructor to initialize the form.
33
+     * WARNING: Do NOT modify this code. The content of this method is always
34
+     * regenerated by the Form Editor.
35
+     */
36
+    @SuppressWarnings("unchecked")
37
+    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
38
+    private void initComponents() {
39
+
40
+        jScrollPane2 = new javax.swing.JScrollPane();
41
+        jTextArea2 = new javax.swing.JTextArea();
42
+        jScrollPane1 = new javax.swing.JScrollPane();
43
+        textAreaCode = new javax.swing.JTextArea();
44
+        buttonRun = new javax.swing.JButton();
45
+        checkBox2Bytes = new javax.swing.JCheckBox();
46
+        buttonSave = new javax.swing.JButton();
47
+        buttonLoad = new javax.swing.JButton();
48
+
49
+        jTextArea2.setColumns(20);
50
+        jTextArea2.setRows(5);
51
+        jScrollPane2.setViewportView(jTextArea2);
52
+
53
+        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
54
+        setTitle("Brainfuck");
55
+        addWindowListener(new java.awt.event.WindowAdapter() {
56
+            public void windowOpened(java.awt.event.WindowEvent evt) {
57
+                formWindowOpened(evt);
58
+            }
59
+        });
60
+
61
+        textAreaCode.setColumns(20);
62
+        textAreaCode.setRows(5);
63
+        textAreaCode.setAutoscrolls(false);
64
+        jScrollPane1.setViewportView(textAreaCode);
65
+
66
+        buttonRun.setText("Run");
67
+        buttonRun.setActionCommand("buttonRun");
68
+        buttonRun.addActionListener(new java.awt.event.ActionListener() {
69
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
70
+                buttonRunActionPerformed(evt);
71
+            }
72
+        });
73
+
74
+        checkBox2Bytes.setText("use 2 Bytes for Chars");
75
+
76
+        buttonSave.setText("Save");
77
+        buttonSave.addActionListener(new java.awt.event.ActionListener() {
78
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
79
+                buttonSaveActionPerformed(evt);
80
+            }
81
+        });
82
+
83
+        buttonLoad.setText("Load");
84
+        buttonLoad.addActionListener(new java.awt.event.ActionListener() {
85
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
86
+                buttonLoadActionPerformed(evt);
87
+            }
88
+        });
89
+
90
+        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
91
+        getContentPane().setLayout(layout);
92
+        layout.setHorizontalGroup(
93
+            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
94
+            .addGroup(layout.createSequentialGroup()
95
+                .addContainerGap()
96
+                .addComponent(buttonRun)
97
+                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
98
+                .addComponent(checkBox2Bytes)
99
+                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
100
+                .addComponent(buttonSave)
101
+                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
102
+                .addComponent(buttonLoad))
103
+            .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 427, Short.MAX_VALUE)
104
+        );
105
+        layout.setVerticalGroup(
106
+            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
107
+            .addGroup(layout.createSequentialGroup()
108
+                .addContainerGap()
109
+                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
110
+                    .addComponent(buttonRun)
111
+                    .addComponent(checkBox2Bytes)
112
+                    .addComponent(buttonSave)
113
+                    .addComponent(buttonLoad))
114
+                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
115
+                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 357, Short.MAX_VALUE))
116
+        );
117
+
118
+        buttonRun.getAccessibleContext().setAccessibleDescription("");
119
+
120
+        pack();
121
+    }// </editor-fold>//GEN-END:initComponents
122
+
123
+    private void buttonRunActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonRunActionPerformed
124
+        ConsoleFrame.main(textAreaCode.getText(), checkBox2Bytes.isSelected());
125
+    }//GEN-LAST:event_buttonRunActionPerformed
126
+
127
+    private void formWindowOpened(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowOpened
128
+        textAreaCode.setText("[ This program prints \"Hello World!\" and a newline to the screen, its\n" +
129
+                            "  length is 106 active command characters [it is not the shortest.]\n" +
130
+                            " \n" +
131
+                            "  This loop is a \"comment loop\", it's a simple way of adding a comment\n" +
132
+                            "  to a BF program such that you don't have to worry about any command\n" +
133
+                            "  characters. Any \".\", \",\", \"+\", \"-\", \"<\" and \">\" characters are simply\n" +
134
+                            "  ignored, the \"[\" and \"]\" characters just have to be balanced.\n" +
135
+                            "]\n" +
136
+                            "+++++ +++               Set Cell #0 to 8\n" +
137
+                            "[\n" +
138
+                            "    >++++               Add 4 to Cell #1; this will always set Cell #1 to 4\n" +
139
+                            "    [                   as the cell will be cleared by the loop\n" +
140
+                            "        >++             Add 2 to Cell #2\n" +
141
+                            "        >+++            Add 3 to Cell #3\n" +
142
+                            "        >+++            Add 3 to Cell #4\n" +
143
+                            "        >+              Add 1 to Cell #5\n" +
144
+                            "        <<<<-           Decrement the loop counter in Cell #1\n" +
145
+                            "    ]                   Loop till Cell #1 is zero; number of iterations is 4\n" +
146
+                            "    >+                  Add 1 to Cell #2\n" +
147
+                            "    >+                  Add 1 to Cell #3\n" +
148
+                            "    >-                  Subtract 1 from Cell #4\n" +
149
+                            "    >>+                 Add 1 to Cell #6\n" +
150
+                            "    [<]                 Move back to the first zero cell you find; this will\n" +
151
+                            "                        be Cell #1 which was cleared by the previous loop\n" +
152
+                            "    <-                  Decrement the loop Counter in Cell #0\n" +
153
+                            "]                       Loop till Cell #0 is zero; number of iterations is 8\n" +
154
+                            " \n" +
155
+                            "The result of this is:\n" +
156
+                            "Cell No :   0   1   2   3   4   5   6\n" +
157
+                            "Contents:   0   0  72 104  88  32   8\n" +
158
+                            "Pointer :   ^\n" +
159
+                            " \n" +
160
+                            ">>.                     Cell #2 has value 72 which is 'H'\n" +
161
+                            ">---.                   Subtract 3 from Cell #3 to get 101 which is 'e'\n" +
162
+                            "+++++++..+++.           Likewise for 'llo' from Cell #3\n" +
163
+                            ">>.                     Cell #5 is 32 for the space\n" +
164
+                            "<-.                     Subtract 1 from Cell #4 for 87 to give a 'W'\n" +
165
+                            "<.                      Cell #3 was set to 'o' from the end of 'Hello'\n" +
166
+                            "+++.------.--------.    Cell #3 for 'rl' and 'd'\n" +
167
+                            ">>+.                    Add 1 to Cell #5 gives us an exclamation point\n" +
168
+                            ">++.                    And finally a newline from Cell #6");
169
+    }//GEN-LAST:event_formWindowOpened
170
+
171
+    private void buttonSaveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonSaveActionPerformed
172
+        writeFile();
173
+    }//GEN-LAST:event_buttonSaveActionPerformed
174
+
175
+    private void buttonLoadActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonLoadActionPerformed
176
+        readFile();
177
+    }//GEN-LAST:event_buttonLoadActionPerformed
178
+        
179
+    private File fileDialog(boolean open) {
180
+        JFileChooser fileDialog = new JFileChooser();
181
+        int result;
182
+        if(open) {
183
+            result = fileDialog.showOpenDialog(this);
184
+        } else {
185
+            result = fileDialog.showSaveDialog(this);
186
+        }
187
+        
188
+        if(result == JFileChooser.APPROVE_OPTION) {
189
+            return fileDialog.getSelectedFile();
190
+        }
191
+        
192
+        return null;
193
+    }
194
+    
195
+    private void readFile() {
196
+        File file = fileDialog(true);
197
+        String text = "";
198
+        
199
+        if(file != null) {
200
+            if(file.exists()) {
201
+                BufferedReader br = null;
202
+                try {
203
+                    String currentLine;
204
+                    br = new BufferedReader(new FileReader(file));
205
+                    
206
+                    boolean firstLine = true;
207
+                    while((currentLine = br.readLine()) != null) {
208
+                        if(!firstLine) {
209
+                            text += "\n";
210
+                        } else {
211
+                            firstLine = false;
212
+                        }
213
+                        
214
+                        text += currentLine;
215
+                    }
216
+                } catch (IOException ex) {
217
+                    Logger.getLogger(Interpreter.class.getName()).log(Level.SEVERE, null, ex);
218
+                } finally {
219
+                    try {
220
+                        if(br != null)
221
+                            br.close();
222
+                    } catch(IOException ex) {
223
+                        Logger.getLogger(Interpreter.class.getName()).log(Level.SEVERE, null, ex);
224
+                    }
225
+                    
226
+                    textAreaCode.setText(text);
227
+                }
228
+            }
229
+        }
230
+    }
231
+    
232
+    private void writeFile() {
233
+        File file = fileDialog(false);
234
+        String text = textAreaCode.getText();
235
+        
236
+        if(file != null) {
237
+            
238
+            BufferedWriter bw = null;
239
+            try {
240
+                bw = new BufferedWriter(new FileWriter(file));
241
+                bw.write(text);
242
+            } catch (IOException ex) {
243
+                Logger.getLogger(Interpreter.class.getName()).log(Level.SEVERE, null, ex);
244
+            } finally {
245
+                try {
246
+                    if(bw != null)
247
+                        bw.close();
248
+                } catch(IOException ex) {
249
+                    Logger.getLogger(Interpreter.class.getName()).log(Level.SEVERE, null, ex);
250
+                }
251
+            }
252
+        }
253
+    }    
254
+    
255
+    /**
256
+     * @param args the command line arguments
257
+     */
258
+    public static void main(String args[]) {
259
+        /* Set the Nimbus look and feel */
260
+        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
261
+        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
262
+         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
263
+         */
264
+        try {
265
+            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
266
+                if ("Nimbus".equals(info.getName())) {
267
+                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
268
+                    break;
269
+                }
270
+            }
271
+        } catch (ClassNotFoundException ex) {
272
+            java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
273
+        } catch (InstantiationException ex) {
274
+            java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
275
+        } catch (IllegalAccessException ex) {
276
+            java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
277
+        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
278
+            java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
279
+        }
280
+        //</editor-fold>
281
+
282
+        /* Create and display the form */
283
+        java.awt.EventQueue.invokeLater(new Runnable() {
284
+            public void run() {
285
+                new MainFrame().setVisible(true);
286
+            }
287
+        });
288
+    }
289
+
290
+    // Variables declaration - do not modify//GEN-BEGIN:variables
291
+    private javax.swing.JButton buttonLoad;
292
+    private javax.swing.JButton buttonRun;
293
+    private javax.swing.JButton buttonSave;
294
+    private javax.swing.JCheckBox checkBox2Bytes;
295
+    private javax.swing.JScrollPane jScrollPane1;
296
+    private javax.swing.JScrollPane jScrollPane2;
297
+    private javax.swing.JTextArea jTextArea2;
298
+    private javax.swing.JTextArea textAreaCode;
299
+    // End of variables declaration//GEN-END:variables
300
+}

Loading…
Cancel
Save