MODELLING LOCATION-AWARE BEHAVIOUR
IN WEB-GIS USING ASPECTS
Ana Oliveira
1
, Matias Urbieta
2
, João Araújo
1
, Armanda Rodrigues
1
Ana Moreira
1
, Sílvia Gordillo
2
and Gustavo Rossi
2
1
CITI/FCT Universidade Nova de Lisboa, Monte de Caparica, Portugal
2
Lifia, Facultad de Informatica, UNLP, Argentina
Keywords: Location-awareness, Aspect-oriented software development, Geographical information systems.
Abstract: Web-GIS applications evolve fast as new requirements emerge constantly. Some of these requirements,
particularly those related with spatial behaviours, might crosscut previous core application requirements.
Conventional modelling techniques, which ignore the effect of crosscutting concerns (such as tangling and
scattered behaviours) affect negatively the modularity and thus compromise application maintenance. In this
paper we present and aspect-oriented approach to model crosscutting concerns in Web-GIS applications,
particularly those related with spatial features. The process introduced in this paper starts with the
identification and specification of crosscutting concerns, followed by the composition of these concerns,
using the MATA language.
1 INTRODUCTION
Nowadays, web applications are more volatile than
ever due to new requirements that are either
requested by service providers or even by final
users. In particular Geographical Information
Systems (GIS) also has to deal with the requirements
volatility A reasonable way to deal with adding new
requirements into an application is to keep in
separate modules scattered behaviours by using
aspect-oriented techniques (Filman et al., 2005).
Our goal is to use aspect-orientation to deal with
GIS concerns in an oblivious fashion, modularizing
tangled and scattered behaviour, known as
crosscutting concerns. Concerns may be functional
or non-functional properties that represent needs of
the system. Crosscutting concerns are later
composed, or weaved, in different points, or
joinpoints, of the same or other applications. Typical
crosscutting concerns arise when dealing with
spatial data (e.g., user’s location) in Web Software.
Web-GIS applications tend to be complex as they
combine the volatile nature of Web software with
the inherent complexity of dealing with spatial data.
Location-aware behaviour, typical of Web-GIS,
usually cuts across other application concerns, since
it is likely to have an impact across different applica-
tion features (Munnelly et al, 2007).
Therefore, this paper introduces an aspect-
oriented approach to model common concerns in
Web-GIS applications, specifically those related
with spatial features. This approach is based on
aspect-orientation (Filman et al, 2005) and uses the
MATA language (Whittle and Jayaraman, 2007) to
specify aspects. We will demonstrate how spatial
behaviour can be isolated from other concerns to
improve modularity in our application domain.
The rest of the paper is structured as follows.
Section 2 presents a motivating example and
describes the background of our work. Section 3
introduces our approach for modelling GIS using a
running example. Section 7 presents related work.
Finally, Section 8 draws some conclusions and
describes future work.
2 CROSSCUTTING IN WEB GIS
A typical new requirement which may be added to a
Web GIS application is the “indoor representation”.
Figure 2 shows a web application for a shopping
centre that provides Indoor map support for
presenting store locations. The application offers a
“search function” to provide information about
416
Oliveira A., Urbieta M., Araújo J., Rodrigues A., Moreira A., Gordillo S. and Rossi G. (2009).
MODELLING LOCATION-AWARE BEHAVIOUR IN WEB-GIS USING ASPECTS.
In Proceedings of the 11th International Conference on Enterprise Information Systems - Information Systems Analysis and Specification, pages
416-419
DOI: 10.5220/0002018604160419
Copyright
c
SciTePress
stores such as their address, their location inside the
shopping centre (Indoor position) – using the map
pointed with a dashed ellipse. This Figure also
shows an Outdoor map, which indicates the location
of the shopping centre in a global map. Both
examples (Figure 1 and Figure 2) reveal how the
same GIS requirements may be present in
applications of different nature, contemplating many
occurrences during one execution of the same
application.
The inclusion of this new requirement (indoor
representation) will create scattered and tangled
concerns in the application among its core or base
concerns. To make matters worse, adding other
concerns increases the application complexity
compromising its maintenance. (Section 5 describes
how to deal with these new requirements in more
detail).
Figure 1 illustrates how the introduction of new
requirements might impact in the application’s
structure. This Figure shows a UML sequence
diagram for “Show Store”, showing information
about a store. This is taken from the Web-GIS
application Maps@Web It contains tangled
behaviour as a consequence of composing several
GIS requirements such as Indoor Representation,
Location Sensing and Points of Interest. We can see
that the behaviour of each requirement is scattered
along the sequence diagram and crosscuts other
behaviour. For example, Location-aware crosscuts
Indoor and Outdoor representation, due to the
current user position that can be either in a global
map or into a specific building. Our goal is to
propose an approach for isolating and then
modelling these GIS concerns.
The concept of aspect was introduced by Aspect-
Oriented Programming (AOP) to modularize
concerns that could not be modularized using object-
orientation (Filman et al, 2005). Concerns may be
functional or non-functional properties that represent
needs of the system. In other words, a concern
comprises any coherent set of requirements, e.g., all
requirements referring to a particular functionality
(Baniassad et al, 2006). Crosscutting concerns are
concerns that cut across other concerns, creating
tangled and scattered representations of the program
that are difficult to understand and maintain (Rashid
et al, 2003). Aspect-Oriented Software Development
(AOSD) (Filman et al, 2005) appeared to handle
crosscutting concerns in all stages of the software
lifecycle. The MATA aspect-oriented modelling tool
is based on UML, allowing aspects composition
using class diagrams, sequence diagrams, etc.
To specify an aspectual scenario in MATA, three
stereotypes where created to define the composition
Figure 1: Sequence diagram with tangled behaviour due to
crosscutting concerns.
rules: <<create>> (states that the element will be
created in the base scenario), <<delete>> (states that
the element will be deleted of the base scenario),
<<context>> (states that the element will not be
affected by the other two stereotypes).Variables in
MATA are prefixed by a bar “|”, meaning that “|X”
will match to any class.
After specifying both kinds of scenarios, base
and aspectual, a pattern matching is made between
them. This means that the tool tries to establish a
connection between elements of each scenario,
always respecting the composition rules defined in
the aspectual scenario. The resulting composed
scenario describes, therefore, the behaviour of both
scenarios, according to the rules defined.
GIS applications are usually modelled using
simple approaches that are limited to the
identification of requirements and system functional-
ities, ignoring crosscutting concerns modularization,
as can be seen in (Longley et al, 2005).
The approach introduced in this paper aims at
improving the modularization of GIS Web
applications by modularizing typical GIS concerns.
The starting point is the identification and
specification of crosscutting concerns, which is
followed by the composition of the concerns
previously identified, using the MATA language.
3 MODELLING GIS CONCERNS
WITH ASPECTS
Figure 2 defines a process for modelling spatial con-
MODELLING LOCATION-AWARE BEHAVIOUR IN WEB-GIS USING ASPECTS
417
cerns using aspects in Web-GIS applications. The
process is divided into three main activities:
Identification, Specification and Composition.
Figure 2: Process for modelling GIS concerns with
aspects.
We will explain our approach using the GIS web
application Maps@Web, which is a Web application
providing a set of varied location-based services,
including services related with Cinemas, Hotels, or
Universities with the aim of helping users in their
daily activities. For instance, if the user wants to go
to the university and the cinema on the same
evening, this application will calculate an
appropriate path to access all these places.
To better demonstrate the contributions of our
approach, let’s add the new requirement “Indoor
Representation”. This requirement changes the
user’s application context, taking him to an indoor
representation of space. Next we show how to apply
the three activities of our approach.
Identification of Use Cases and Crosscutting
Relationships. This designs the use cases and
represents the relations among crosscutting use cases
using the stereotypes <<include>> and <<extend>>,
i.e., a use case that is included by several use cases
or a use case that extends several ones is considered
as crosscutting. In addition, we adopt a new
stereotype, <<trigger>>, to be used when a use case
activates one or more use cases. Figure 3 shows a
partial use case diagram, with the use case “Show
Service” and the crosscutting concerns “Change
Scale” and “Context Switch”. With the introduction
of the Indoor Representation requirement, we now
have two kinds of maps, Indoor Map and Outdoor
Map. In this example, when we want to see any
service, it starts with an outdoor representation of
the service location. That is why the use case “Show
Service” is connected with the concern “View
Outdoor Map”, with an <<include>> relationship.
This last concern will be extended with “Change
Scale” every time the map tool bar is changed.
When the scale reaches the maximum zoom
available, there will be a switch in the user’s
application context. We represent this relationship
between “Change Scale” and “Context Switch” with
an <<extend>> stereotype. When the scale reaches
the maximum and the context changes, the “View
Indoor Map” will be triggered.
Figure 3: Partial Use Case Diagram for Show Service; use
cases are enhanced with possible crosscutting concerns.
“Change Scale” and “Context Switch” are
crosscutting concerns and they crosscut other use
cases of the system (e.g. Edit Favourite Places,
Search by Service) not shown here due to space
limitations. They also interact with each other.
Use Case Refinement and Aspect Modelling. The
second activity of the approach specifies the base
scenarios (Figure 4) and the crosscutting concerns
with sequence diagrams (Figure 5 and 6). Figure 4
illustrates the “Show Suggestion” use case, chosen
by its importance to this example. Figure 5 shows
the crosscutting concern “Change Scale” represented
with the MATA sequence diagram. The first
message in this sequence diagram matches with the
same one in the base scenario. Figure 6 shows the
crosscutting concern “Context Switch” that will be
activated by the concern “Change Scale”. The first
message of the sequence diagram in Figure 6
matches with the equivalent one in the base scenario.
In this particular case, the base scenario is the aspect
“Change Scale”. This sequence diagram shows that
every time the user performs a change in the scale,
the system will verify if a change in the spatial
context is required. If this change is needed, the
system accesses the information about the new
context (in this case it is the indoor location). The
“any” fragment allows the base scenario to continue
its behaviour, with a sequence of messages.
Composition. It composes the aspectual scenarios
with the base scenarios using the MATA language.
The composition activity shows that the crosscutting
concerns can be isolated in aspects and then
composed into one or more base scenarios, without
ICEIS 2009 - International Conference on Enterprise Information Systems
418
changing the application execution. By isolating the
crosscutting concerns, we promote modularization,
reuse, and evolution possibilities of the application.
Figure 4: Base Scenario "Show Suggestion".
Figure 5: Aspectual Scenario "Change Scale".
Figure 6: Aspectual Scenario "Context Switch".
4 RELATED WORK
The use of advanced separation of concerns
techniques and particularly the use of aspects have
been recently proposed for the development of
complex Web applications, mainly to provide
adaptation behaviours (Baumeister et al 2005).
Munnelly (Munnelly et al, 2007) presents an
approach for modularizing context-aware systems by
encapsulating different types of context using an
aspect-oriented approach. While Munnelly divides
the overall context space into eight sub-categories
and proposes an aspect-oriented approach for the
adaptation of the application to a specific context,
our approach presents a process for modelling
spatial concerns in a more abstract way.
In (Zipf and Merdes, 2003) the authors discuss
the use of aspects in GIS applications. However,
they only focus on the programming level, though
their analysis of spatial concerns is similar to ours.
5 CONCLUSIONS AND FUTURE
WORK
We have shown that in Web-GIS applications,
always in constant change, it is crucial to modularize
concerns to eliminate crosscutting of these concerns
in the application models. Our view represents a step
forward with respect to existing approaches in which
the spatial concerns are mixed with other
crosscutting application concerns.
Currently we are working on the identification
and modelling of more typical and recurrent GIS
concerns to obtain a catalogue which will let us get
new applications by composition following the style
shown in the paper. For the near future, we plan to
address crosscutting at the user interface level .
REFERENCES
Baniassad, E., Clements, P., Araújo, J., Moreira, A.,
Rashid, A., Tekinerdogan, B. (2006). Discovering
Early Aspects. IEEE Software 23(1), pp 61 - 70 .
Baumeister, H., Knapp, A., Koch, N. And Zhang, G.
(2005). Modelling Adaptivity with Aspects. ICWE'05.
Springer LNCS, Volume 3579/2005.
Filman, R., Elrad, T., Clarke, S., Aksit, M. (2005). Aspect-
Oriented Software Development. Addison-Wesley.
Longley, P., Goodchild, M., Maguire, D., Rhind, D.
(2005). Geographical Information Systems and
Science. WILEY.
Munelly, J., Fritsch, S.,Clarke, S. (2007). An Aspect-
Oriented Approach to the Modularisation of Context.
5th IEEE International Conference on Pervasive
Computing and Communications,USA.
Rashid, A., Moreira, A.,Araújo, J. (2003). Modularisation
and Composition of Aspectual Requirements. 2nd
AOSD’03, ACM.
Whittle, J., Jayaraman, P. (2007). Mata: A Tool for
Aspect-Oriented Modelling based on Graph
Transformations. AOM Workshop at MODELS’07.
Zipf, A., Merdes, M. (2003). Is aspect-orientation a new
paradigm for GIS development?. 6
th
Agile Conference
on Geographic Information Science, Lyon, 2003.
MODELLING LOCATION-AWARE BEHAVIOUR IN WEB-GIS USING ASPECTS
419