A Sketch of a Model-Driven Approach to Develop Smart Tourism Mobile Applications †

: Several approaches have been proposed to accelerate software development. Model-driven engineering (MDE) is one approach that aims to abstract and automate the development process using models and transformations as the main artifacts. This paper presents our model-driven approach to developing smart tourism mobile applications.


Introduction
The tourism sector represents an essential source of income for a country's economy. In the case of Morocco, several investments have been made to improve the infrastructure to attract more tourists. In addition, the Moroccan Ministry of Tourism has launched an initiative to increase the visibility of Moroccan tourism destinations on social media [1]. These efforts have helped place Morocco among the most visited African countries [2]. However, much remains to be done globally, and innovative strategies are needed to increase the attractiveness of Moroccan destinations. In this sense, we have conducted a research project to create a software factory to develop mobile applications in the tourism sector. In this paper, we present our model-driven approach through a case study, where we generate the backend of smart tourism mobile applications using clean architecture. This paper is organized as follows. Section 2 presents the background of our approach, and Section 3 describes the approach. Section 4 presents the case study, while Section 5 concludes the paper and presents future work.

Model Driven Architecture (MDA)
MDA is an approach proposed by the Object Management Group (OMG) [3] that implements MDE and provides a set of standards for developing software using models. Its main models are the Platform Independent Model (PIM), which represents the problem domain of the system, and the Platform Specific Model (PSM), which describes the solution domain of the system. In addition, the Platform Description Model (PDM) presents the concepts of a particular platform or architecture. In the MDA process, one or multiple PDMs are applied to the PIM to create the corresponding PSMs, from which the system's source code is generated. The transition from one model to another at different levels of abstraction is performed using model transformations.

Smart Tourism
Smart tourism [4] uses technology and innovative solutions to create a personalized travel experience for tourists. In this sense, the Six As [5] framework helps developers create mobile applications that enhance the tourism experience. The six As are Attraction, Accessibility, Ancillary Services, Activities, Amenities, and Available Packages. Attraction creates personalized and compelling experiences to attract tourists, while Accessibility makes it easier to get to a destination. Ancillary Services include additional services a tourist may need, such as insurance and currency exchange. Activities provide different experiences to suit tourist interests. Amenities offer hotels, restaurants, shopping, and entertainment services. In contrast, Available Packages provide various tour packages such as adventure sports and cultural experiences. Employing the Six As in smart tourism applications can provide personalized and transparent travel experiences.

Clean Architecture
Clean architecture [6] is a modern approach to developing software based on domaindriven design (DDD) [7] and follows the best design principles. It allows the creation of systems independent of frameworks, user interfaces, databases, and any external thirdparty services. One of the main rules of the architecture is the dependency rule, which states that application dependencies must point toward the core of the application, which represents the business logic (policies), and not toward the infrastructure or UI layers (mechanisms). This dependency can be achieved through defining abstractions or interfaces in the application core and their implementations in the application infrastructure [8].

Overview of the Approach
This research project aims to develop a software factory implementing an MDE approach for smart tourism mobile applications. It consists of several assets. In this paper, we focus on the domain model and the catalog of PDM assets.

Domain Model
The domain model provides an overview of the components and their interactions in the smart tourism application. It uses a UML class diagram to represent the concepts and their relationships. The domain model is organized in packages according to the Six As. We find the base, attractions, amenities, available packages, user profile, ancillary services, activities, accessibility, and visit plans. In addition, it highlights the dependencies between the packages, which allows a clear understanding of the relationships and interactions between the different components and facilitates the development of robust smart tourism applications.

Platform Description Model
Our approach defines a PDM in two views: the UML profile [3] and a set of transformation templates. The UML profile is a mechanism that extends the UML metamodel to support a platform or domain through defining concepts and constraints between them. It is used in the PIM parameterization step to mark a model with various design decisions. Transformation templates are used in the code generation step to implement the concepts of a system architecture or platform.
To implement the clean architecture, we need to specify its PDM. For simplicity, we generate only the core layer of the architecture in the case study. The UML profile of the PDM includes concepts such as Entity, AggregateRoot, Repository, Service, and Specification. An example of a constraint is the dependency between Entity and Repository.

Case Study
To evaluate the effectiveness of the proposed approach, a case study is presented to develop the backend of a mobile application using a subset of the domain model representing the PIM of the system. In this case study, we generate the source code for the backend of smart tourism mobile applications, using clean architecture and the Microsoft .NET 7 platform (Redmond, WA, USA). The process included architecture specification using the PDM, parameterization of the PIM, and code generation.

Platform Independent Model
The PIM of the system is a subset of the domain model that manages the attractions and amenities of tourist destinations in a region. It contains nine classes and three enumerations, as shown in Figure 1. We find the Accessibility, Amenity, AmenityRoom, Attraction, Hotel, Location, LocationImage, PhysicalAttraction, and CulturalAttraction classes and the Phys-icalAttractionType, AccessibilityType, and RoomBedType enumerations. The Location base class represents a geographic location that may interest a visitor and is accessible by foot, car, bike, and/or bus. A location can be an attraction site that tourists can visit during their trip or an amenity such as hotels where they can stay during their vacation.
To evaluate the effectiveness of the proposed approach, a case study is presented to develop the backend of a mobile application using a subset of the domain model representing the PIM of the system. In this case study, we generate the source code for the backend of smart tourism mobile applications, using clean architecture and the Microsoft .NET 7 platform (Redmond, WA, USA). The process included architecture specification using the PDM, parameterization of the PIM, and code generation.

Platform Independent Model
The PIM of the system is a subset of the domain model that manages the attractions and amenities of tourist destinations in a region. It contains nine classes and three enumerations, as shown in Figure 1. We find the Accessibility, Amenity, AmenityRoom, Attraction, Hotel, Location, LocationImage, PhysicalAttraction, and CulturalAttraction classes and the PhysicalAttractionType, AccessibilityType, and RoomBedType enumerations. The Location base class represents a geographic location that may interest a visitor and is accessible by foot, car, bike, and/or bus. A location can be an attraction site that tourists can visit during their trip or an amenity such as hotels where they can stay during their vacation. Figure 1. A PIM of the case study. UML standard: "*" indicates the "many" multiplicity in an association. "Triangle" indicates the direction of the association.

PIM Parameterization
The PIM parameterization step consists of marking the PIM with design decisions from the implemented architecture. In this step, we use the UML profile of the PDM, where each defined concept is associated with a set of design concerns that specify the type of marking (stereotype or tagged value) and the concerned UML elements (class, operation, attribute, association…). The user can simultaneously parameterize the PIM Figure 1. A PIM of the case study. UML standard: "*" indicates the "many" multiplicity in an association. "Triangle" indicates the direction of the association.

PIM Parameterization
The PIM parameterization step consists of marking the PIM with design decisions from the implemented architecture. In this step, we use the UML profile of the PDM, where each defined concept is associated with a set of design concerns that specify the type of marking (stereotype or tagged value) and the concerned UML elements (class, operation, attribute, association . . . ). The user can simultaneously parameterize the PIM with multiple UML profiles. Figure 2 presents the parameterization of the Location and Accessibility classes with stereotypes such as AggregateRoot and Entity.
with multiple UML profiles. Figure 2 presents the parameterization of the Location and Accessibility classes with stereotypes such as AggregateRoot and Entity. Figure 2. PIM parameterization of the Location and Accessibility classes. UML standard: "*" indicates the "many" multiplicity in an association. "Triangle" indicates the di-rection of the association.

Code Generation
The final step in our approach is code generation, where we apply the transformation templates from the PDM to the parameterized PIM. In this step, we generate the system's source code or the Platform Specific Model (PSM) through applying model-to-text or model-to-model transformations to the parameterized PIM, respectively. Each transformation template is applied to the model based on a condition. The condition is related to the implemented concept that specifies the concerned UML elements and the type of design concern. For example, the Entity transformation template, which is responsible for implementing the business logic classes of the application, is applied to the UML elements of the type class and parameterized with the Entity stereotype. Figure  3 presents the PSM of the core layer when the transformations of the clean architecture PDM are applied. The core layer is organized into four packages: the Entities package encapsulates the business logic of the application, the Interfaces package contains the definition of services and repositories, the Services package contains the implementation of the application services, and the Specifications package contains the implementations for searching entities with advanced searching criteria.

Code Generation
The final step in our approach is code generation, where we apply the transformation templates from the PDM to the parameterized PIM. In this step, we generate the system's source code or the Platform Specific Model (PSM) through applying model-to-text or model-to-model transformations to the parameterized PIM, respectively. Each transformation template is applied to the model based on a condition. The condition is related to the implemented concept that specifies the concerned UML elements and the type of design concern. For example, the Entity transformation template, which is responsible for implementing the business logic classes of the application, is applied to the UML elements of the type class and parameterized with the Entity stereotype. Figure 3 presents the PSM of the core layer when the transformations of the clean architecture PDM are applied. The core layer is organized into four packages: the Entities package encapsulates the business logic of the application, the Interfaces package contains the definition of services and repositories, the Services package contains the implementation of the application services, and the Specifications package contains the implementations for searching entities with advanced searching criteria.

Conclusion and Future Work
The complexity of software development can be facilitated using MDE. This paper presents a sketch of our approach to developing mobile applications to help increase Moroccan tourist destinations' attractiveness. The approach will be integrated as a

Conclusion and Future Work
The complexity of software development can be facilitated using MDE. This paper presents a sketch of our approach to developing mobile applications to help increase Moroccan tourist destinations' attractiveness. The approach will be integrated as a software factory asset containing other artifacts needed by mobile applications such as recommender systems and conversational agents.