From the screenshot -- on the left side in the structure pane -- you can't just put .java files inside the content repository and expect it to run. That's not how this works. Java source needs to be compiled into its CLASS file and those are all magically assembled into a JAR file (an executable program) that adheres to the OSGI specification so it can run inside AEM.
Your Java code needs to be in an AEM maven project and compiled into a deployable artefact.