From 9a3bce1e783086d3c6353df125c383fc3da79260 Mon Sep 17 00:00:00 2001 From: Bruder John Date: Thu, 2 May 2024 14:55:04 +0200 Subject: [PATCH] added ast --- .gitignore | 103 ++++++++++++++------ .idea/compiler.xml | 13 +++ .idea/jarRepositories.xml | 20 ++++ .idea/uiDesigner.xml | 124 ++++++++++++++++++++++++ src/main/java/ast/AccessModifier.java | 5 + src/main/java/ast/ClassDeclaration.java | 5 +- src/main/java/ast/Identifier.java | 13 +++ src/main/java/ast/Type.java | 7 ++ 8 files changed, 257 insertions(+), 33 deletions(-) create mode 100644 .idea/compiler.xml create mode 100644 .idea/jarRepositories.xml create mode 100644 .idea/uiDesigner.xml create mode 100644 src/main/java/ast/AccessModifier.java create mode 100644 src/main/java/ast/Identifier.java create mode 100644 src/main/java/ast/Type.java diff --git a/.gitignore b/.gitignore index 5ff6309..d16bbbe 100644 --- a/.gitignore +++ b/.gitignore @@ -1,38 +1,77 @@ -target/ -!.mvn/wrapper/maven-wrapper.jar -!**/src/main/**/target/ -!**/src/test/**/target/ +# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider +# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 -### IntelliJ IDEA ### -.idea/modules.xml -.idea/jarRepositories.xml -.idea/compiler.xml -.idea/libraries/ +# User-specific stuff +.idea/**/workspace.xml +.idea/**/tasks.xml +.idea/**/usage.statistics.xml +.idea/**/dictionaries +.idea/**/shelf + +# AWS User-specific +.idea/**/aws.xml + +# Generated files +.idea/**/contentModel.xml + +# Sensitive or high-churn files +.idea/**/dataSources/ +.idea/**/dataSources.ids +.idea/**/dataSources.local.xml +.idea/**/sqlDataSources.xml +.idea/**/dynamic.xml +.idea/**/uiDesigner.xml +.idea/**/dbnavigator.xml + +# Gradle +.idea/**/gradle.xml +.idea/**/libraries + +# Gradle and Maven with auto-import +# When using Gradle or Maven with auto-import, you should exclude module files, +# since they will be recreated, and may cause churn. Uncomment if using +# auto-import. +# .idea/artifacts +# .idea/compiler.xml +# .idea/jarRepositories.xml +# .idea/modules.xml +# .idea/*.iml +# .idea/modules +# *.iml +# *.ipr + +# CMake +cmake-build-*/ + +# Mongo Explorer plugin +.idea/**/mongoSettings.xml + +# File-based project format *.iws -*.iml -*.ipr -### Eclipse ### -.apt_generated -.classpath -.factorypath -.project -.settings -.springBeans -.sts4-cache +# IntelliJ +out/ -### NetBeans ### -/nbproject/private/ -/nbbuild/ -/dist/ -/nbdist/ -/.nb-gradle/ -build/ -!**/src/main/**/build/ -!**/src/test/**/build/ +# mpeltonen/sbt-idea plugin +.idea_modules/ -### VS Code ### -.vscode/ +# JIRA plugin +atlassian-ide-plugin.xml -### Mac OS ### -.DS_Store \ No newline at end of file +# Cursive Clojure plugin +.idea/replstate.xml + +# SonarLint plugin +.idea/sonarlint/ + +# Crashlytics plugin (for Android Studio and IntelliJ) +com_crashlytics_export_strings.xml +crashlytics.properties +crashlytics-build.properties +fabric.properties + +# Editor-based Rest Client +.idea/httpRequests + +# Android studio 3.1+ serialized cache file +.idea/caches/build_file_checksums.ser \ No newline at end of file diff --git a/.idea/compiler.xml b/.idea/compiler.xml new file mode 100644 index 0000000..ba644bd --- /dev/null +++ b/.idea/compiler.xml @@ -0,0 +1,13 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml new file mode 100644 index 0000000..712ab9d --- /dev/null +++ b/.idea/jarRepositories.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/uiDesigner.xml b/.idea/uiDesigner.xml new file mode 100644 index 0000000..2b63946 --- /dev/null +++ b/.idea/uiDesigner.xml @@ -0,0 +1,124 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/java/ast/AccessModifier.java b/src/main/java/ast/AccessModifier.java new file mode 100644 index 0000000..87a76de --- /dev/null +++ b/src/main/java/ast/AccessModifier.java @@ -0,0 +1,5 @@ +package ast; + +public enum AccessModifier { + Public,Private +} diff --git a/src/main/java/ast/ClassDeclaration.java b/src/main/java/ast/ClassDeclaration.java index 7a26679..abf46c9 100644 --- a/src/main/java/ast/ClassDeclaration.java +++ b/src/main/java/ast/ClassDeclaration.java @@ -1,4 +1,7 @@ package ast; -public class ClassDeclaration { +public abstract class ClassDeclaration { + public AccessModifier accessModifier; + + } diff --git a/src/main/java/ast/Identifier.java b/src/main/java/ast/Identifier.java new file mode 100644 index 0000000..fd15728 --- /dev/null +++ b/src/main/java/ast/Identifier.java @@ -0,0 +1,13 @@ +package ast; + +public class Identifier { + private String name; + + public Identifier(String name) { + this.name = name; + } + + public String getName() { + return this.name; + } +} diff --git a/src/main/java/ast/Type.java b/src/main/java/ast/Type.java new file mode 100644 index 0000000..c412781 --- /dev/null +++ b/src/main/java/ast/Type.java @@ -0,0 +1,7 @@ +package ast; + +public interface Type { + +} + +