Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chfuchte/java-smallbasic-interpreter
Java program to interpret .sb (Microsoft Small Basic) files. The original compiles it into executeables and workes is writen in C#. This program is writen in Java, which makes it running on some systems without the required .NET version. It is also more customizeable. You can change the syntax if you want to.
https://github.com/chfuchte/java-smallbasic-interpreter
Last synced: about 5 hours ago
JSON representation
Java program to interpret .sb (Microsoft Small Basic) files. The original compiles it into executeables and workes is writen in C#. This program is writen in Java, which makes it running on some systems without the required .NET version. It is also more customizeable. You can change the syntax if you want to.
- Host: GitHub
- URL: https://github.com/chfuchte/java-smallbasic-interpreter
- Owner: chfuchte
- License: mit
- Created: 2023-07-27T17:08:30.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2023-09-02T19:20:09.000Z (about 1 year ago)
- Last Synced: 2024-05-18T14:49:26.628Z (6 months ago)
- Language: Java
- Size: 7.81 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# "SmallBasic" Java
Java program to interpret .sb (Microsoft Small Basic) files.
The original compiles it into executeables and workes is writen in C#.
This program is writen in Java, which makes it running on some systems without the required .NET version.
It is also more customizeable. You can change the syntax if you want to.## Changes than the original from MS
- Comments are no longer done with singlequoates --> use //
- While-loops end with a `Do`
- Booleans are no longer writen with a capital `True` or a `False` --> use `true` and `false` instead## ToDos
⚠ you have to add your own lib classes. That will create some more differences to the original ⚠
**No Arrays** --> maybe I will add them in a later version## Customize
Just add a your compiled `.class` files to the `lib` directory.
**Please mind:** Your classes have to start width _"SB"_ this will be added automaticly by finding the class.
In your `.sb`-file you can then just write the className without the _"SB"_ and without the _"lib."_!## Running it
```bash
cd src # go into the src folder
javac Main.java
javac ... # compile every java File
java Main "path\to\your\file.sb" # run the program with the path to your .sb file in the args
```## Docs
### Comments
```php
// This is a comment
```### Variables
```php
a = "Hallo"
b = 1
c = 0.1
d = false
```### Built-In-Methods
```java
result = Class.Method(...args)
```### If-Condition
```php
If true Then
// code
EndIfIf false Then
// code
Else
// code
EndIf
```### While-Loop
```php
a = 0
While a < 10 Do
a = a + 1
EndWhile
```