Introduction

Business

Development

Core

Entity Definitions

asciidoctor diagram CategoryListerWidgetEntityDefinition

Via the respective getter-setter pairs, the following information can be retrieved/stored in the database:

Property Description

numberOfSubcategories

stores the number of subcategories for the lister

categories

stores a set of categories to list in the given lister

Spring Data JPA Repositories

CategoryListerWidgetRepository

The CategoryListerWidgetRepository extends the BaseEntityRepository and is the corresponding Spring Data JPA repository for the CategoryListerWidgetEntityDefinition:

asciidoctor diagram CategoryListerWidgetRepository

Facade

MapperFactoryConfigurers

CategoryListerWidgetMapperFactoryConfigurer

The CategoryListerWidgetMapperFactoryConfigurer implements the MapperFactoryConfigurer:

asciidoctor diagram CategoryListerWidgetMapperFactoryConfigurer

There are 2 registered conversions:

  • from CategoryListerWidgetEntityDefinition to CategoryListerWidgetDtoDefinition and

  • from CategoryEntityDefinition to CategoryListerCategoryDtoDefinition

Both of the conversions are done via the byDefault() method.

More about the mapping configurations you may read in the respective Orika guide.

Dto definitions

asciidoctor diagram CategoryListerCategoryDtoDefinition

This is the corresponding Dto object for the CategoryEntityDefinition.

CategoryListerWidgetDtoDefinition

The CategoryListerWidgetDtoDefinition extends the WidgetDtoDefinition, going further to the AbstractEntityDtoDefinition:

asciidoctor diagram CategoryListerWidgetDtoDefinition

This is the corresponding Dto object for the CategoryListerWidgetEntityDefinition.

Integration

The integration with the Nemesis platform is pretty straight-forward - just need to add the widget in your classpath:

<dependency>
    <groupId>io.nemesis.platform.module.widget</groupId>
    <artifactId>nemesis-widget-categorylister</artifactId>
</dependency>