Uploaded image for project: 'mdsal'
  1. mdsal
  2. MDSAL-312

Split BindingGeneratorImpl into two classes

XMLWordPrintable

      Binding runtime and codegen are sharing BindingGeneratorImpl, but their expectations around it are a bit different:

      • codegen needs the entire, thick, type definition to correctly generate classes along with their enforcement strategies.
      • runtime needs just skinny type definitions to understand the structure, without comments, descriptions, regexes, etc.

      We already have the beginnings of this split in the skinnyTypes flag passed to the constructor, but this needs to be extended so that we have three classes:

      • AbstractBindingGenerator with callouts
      • FullBindingGenerator which fills in things like comments, etc.
      • SkinnyBindingGenerator co-located with BindingRuntimeContext, which does not fill in unnecessary things

      This also needs to be extended to TypeProviderImpl, so that we get rid of method comments from the runtime environment.

      The upshot from this is a leader BindingRuntimeContext and a faster SkinnyBindingGenerator, because the FullBindingGenerator will never be loaded at runtime.

       

            rovarga Robert Varga
            rovarga Robert Varga
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: