Skip to content
Rebel 4 StarUML edited this page Jun 25, 2019 · 5 revisions

Welcome to the addressbook wiki!

This page briefly introduces features of addressbook application, whose purpose is to demonstrate the possibility to quickly and easily create Spring Boot application using model-driven development and StarUML with Rebel, our Java code generator.

The vast majority of the code in this simple project has been generated from the UML model, with the very simple exception of several methods that perform some actions over the generated, persistent concepts.

Another purpose of this project is to serve as an example of a well-documented and well-structured project, that is easy to understand, get started with, or even upgrade.

For more information about the used tools and approach, please visit our website.

Overview

The addressbook application is a very simple RESTfull service, developed using Spring Boot, Hibernate/JPA, and H2 in-memory database.

Project Structure

This project is structured using standard Maven directory layout. To be a bit more concrete, you will find the following files and directories under the root folder:

  • model,
  • src and
  • pom.xml.

Model folder contains the UML model of the project, that you can open and edit using the StarUML, while the src contains the source files of the project.

When it comes to organization of the project sources, it is very simple. Everything is placed under the package com.archetype.addressbook. Just beneath this root structure, you will find:

  • domain,
  • controllers and
  • repositories.

While the domain package contains persistent classes that are described in the section below, controllers and repositories packages contain Spring controllers and Spring Data Repositories respectively.

Conceptual Model

The main concept of the address book is the Person.

A Person represents a real-world person and an entry in our address book. The Person has her name and optionally birthday and note. Sometimes it is desirable to add additional qualifiers to the address book entries and the organization is one of the most useful ones.

There could be very different ways to contact persons. For instance, we can make phone calls, send e-mails or send postcards to their home or work addresses. Contact is the base concept for all of these.

At the moment, our application supports different kinds of Contacts:

  • Phone,
  • Email,
  • Address,
  • Website and
  • Instant messenger.

Each one of these concepts has its attributes, that are rather intuitive and are displayed on the diagram above.

Every contact may be further qualified using ContactCategory. For instance, Address can be either a home or work address, while a phone number may be either mobile or work or home.

Clone this wiki locally