Class EntityModel.Builder

java.lang.Object
com.vaadin.hilla.generator.model.EntityModel.Builder
Enclosing interface:
EntityModel

public static final class EntityModel.Builder extends Object
What the walk says about an entity beyond the class it is written from and the properties the walk carries below it, which is the target of the node standing for the entity. The declaration is built from it once the walk leaves the node, when the properties are known.
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • getDiscriminator

      public Optional<EntityModel.Discriminator> getDiscriminator()
      The property saying which subtype of a polymorphic type a value is, which an entity has where it belongs to such a hierarchy.
    • setDiscriminator

      public void setDiscriminator(EntityModel.Discriminator discriminator)
    • bean

      public EntityModel.Bean bean(String javaClass, List<String> typeParameters, List<TypeModel.EntityRef> superTypes, List<PropertyModel> properties)
      The declaration of a type whose values are objects with properties. The discriminator is written as the ids it accepts rather than as the type the class declares it with, so it is left out of the properties: TypeScript would have the name twice.