Code Monkey home page Code Monkey logo

annotations-source-code-modification's Introduction

Hi there ๐Ÿ‘‹

Daniel-Pfeffer's github stats

Top Langs

annotations-source-code-modification's People

Contributors

daniel-pfeffer avatar

Watchers

 avatar  avatar  avatar

annotations-source-code-modification's Issues

Compiler Plugin - Class Builder

Create the Kotlin Plugin ClassBuilder so that:

  • checked that all annotated methods are modifiable
  • checked that all annotated classes are modifiable
  • checked that all annotated field are modifiable
  • checked that all annotated local variables are modifiable
  • checked that all annotated parameter are modifiable

Compiler Plugin - Gradle Plugin

Created the infrastructure of the Gradle Plugin and finalise the minor development effort.
This includes:

  • A Class implementing KotlinCompilerPluginSupportPlugin

Compiler Plugin - Create verification Pool

Add a dynamically created pool of classes that can be used for verification.
E.g.: A Program uses NotNegativeVerifier and NotPositiveVerifier, the ClassPool then creates fields for both verifier like

object VerifierPool{
    val notNegativeVerifier = NotNegativeVerifier()
    val notPositiveVerifier = NotNegativeVerifier()
}

As all verifier must be statless we can use a pool to reuse verifier instances, to not waste performance

Compiler Plugin - ByteCode for ClassAnnotations

Create the required ByteCode for Class Annotations.
For simplicity we won't analyse what fields are verified.
The verification procedure will be called after

  • Constructor invocation
  • field modifications

Java Agent - Verification Pool

Add a dynamically created pool of classes that can be used for verification.
E.g.: A Program uses NotNegativeVerifier and NotPositiveVerifier, the ClassPool then creates fields for both verifier like

object VerifierPool{
    val notNegativeVerifier = NotNegativeVerifier()
    val notPositiveVerifier = NotNegativeVerifier()
}

As all verifier must be statless we can use a pool to reuse verifier instances, to not waste performance

Java Agent - Param Annotations

Create the required Code for Parameter Annotations.
The verification procedure will be called after

  • method invocation

Java Agent - Local Variable Annotations

Create the required Code for Local Variable Annotations.
The verification procedure will be called after

  • Local Variable invocation
  • Local Variable modification

Compiler Plugin - General Infrastructure

Create the general Infrastructure for the Compiler Plugin, including

  • annotation module
  • buildSrc module
  • gradle-plugin module
  • kotlin-plugin module
  • sample module

Additionally, organise the modules so they work correctly without a potential future problem

Compiler Plugin - Kotlin Plugin Infrastructure

Create the Kotlin Plugin Infrastructure including:

  • CompilerPluginRegistrar: Controls the registration of the Compiler Plugin
  • CLIProcessor: Maps command line options to more useful configuration options
  • ClassGenerationInterceptor: Intercepts the class building to allow for custom ClassBuilder
  • ClassBuilder: Custom ClassBuilder that controls how a class is created

Java Agent - Field Annotations

Create the required Code for Field Annotations.
The verification procedure will be called after

  • modification of the annotated field

Java Agent - Class Annotations

Create the required Code for Class Annotations.
For simplicity we won't analyse what fields are verified.
The verification procedure will be called after

  • Constructor invocation
  • field modifications

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.