Class ModelType<S,T>

java.lang.Object
ch.raffael.meldioc.model.ModelType<S,T>

public final class ModelType<S,T> extends Object
A rich representation of a Meld model type.

This class also does all the analysis and validations and reports errors to the model's MessageSink. If there are validation errors, it tries to keep the model as consistent as possible, errors are only reported but won't cause building the model type to fail.

Consequently, its contents may cause a code generator to generate BS. It's up to the code generator to watch the message sink for errors. A generator will usually not generate any code if there are model errors.

OTOH, this way, we can collect as many errors as possible in one analysis run.

  • Constructor Details

    • ModelType

      public ModelType(Model<S,T> model, T type)
  • Method Details

    • model

      public Model<S,T> model()
    • type

      public T type()
    • element

      public SrcElement<S,T> element()
    • superTypes

      public io.vavr.collection.Seq<ModelType<S,T>> superTypes()
    • isImported

      public boolean isImported(ModelType<S,T> type)
    • allMethods

      public io.vavr.collection.Seq<ModelMethod<S,T>> allMethods()
    • provisionMethods

      public io.vavr.collection.Seq<ModelMethod<S,T>> provisionMethods()
    • extensionPointMethods

      public io.vavr.collection.Seq<ModelMethod<S,T>> extensionPointMethods()
    • mountMethods

      public io.vavr.collection.Seq<ModelMethod<S,T>> mountMethods()
    • setupMethods

      public io.vavr.collection.Seq<ModelMethod<S,T>> setupMethods()
    • parameterMethods

      public io.vavr.collection.Seq<ModelMethod<S,T>> parameterMethods()
    • supportsParameters

      public boolean supportsParameters()
    • toString

      public String toString()
      Overrides:
      toString in class Object