2. IFML usage
• High-level description of a Web application
• Multiple views of the same content
• Repository of the meta-information collected during
the design process
• Data manipulation operations for
– updating the site content
– interacting with arbitrary external services
• Separate information content from composition into
pages, navigation, and presentation
• Explicit modelling of users and communities
2
Advanced Software Engineering Lesson7WebML
13. Models
• Data Model
– conceptual data organization
– compatible with ER and UML class diagrams.
• Derivation model
– extends structure model with calculated data
• Hypertext model
– specification of the front-end of the application
• Content Management Model
– extends hypertext model with operations and transactions
13
Advanced Software Engineering Lesson7WebML
14. Data Model
• Based on Entity-Relationship
– Entities, attributes, data types, relationships
• Entities
– Description of common features of set of objects
– Population: set of objects described by entity.
• Attributes
– relevant properties of real world objects
– entity instances characterized by same attributes
14
Advanced Software Engineering Lesson7WebML
15. Relationships
• Generalization
– Single inheritance among entities
– Instances from only one sub-entity
– Entities in at most one generalization hierarchy
• Relations
– Semantic connections between entities
– Entities have roles
– Minimum and maximum cardinality constraints
15
Advanced Software Engineering Lesson7WebML
17. Derivation model
• Extends the elements of the structure model with
calculated elements
– Augment entity content by adding attributes calculated
or imported from related objects
– Define populations of entities and relationships based
on some property of the involved objects
• WebML-OQL: set-oriented, navigational query
language
– Now the standard defines only the metamodel
• UML OCL and OQL path expressions
17
Advanced Software Engineering Lesson7WebML
19. WEBML-OQL filters
recentAlbumsCount =
count(Self.ArtistToAlbum as B
WHERE B.date > '1997-01-01')
totRecentTracksDuration =
sum(Self.ArtistToAlbum(as B).
AlbumToTrack.duration
WHERE B.date > '1997-01-01').
19
Advanced Software Engineering Lesson7WebML
20. WebML-OQL: derived relationships
• Concatenation of relationships
CoParticipation =
Self.ArtistToCompilation.CompilationToArtist
• Evaluation of predicates
CoParticipation = Self.ArtistToCompilation.CompilationToArtist
as A where Self.Affiliation = A.Affiliation
20
Advanced Software Engineering Lesson7WebML
21. Hypertext model
• Specifies organization of front-end interfaces
• Elements:
– units: atomic pieces of publishable content
– pages: interface elements delivered to users
– links: navigation and parameter passing
• Modularization constructs
– areas: clusters of pages with homogeneous purpose
– site view: coherent hypertext for set of requirements
21
Advanced Software Engineering Lesson7WebML
22. Units
• Data unit: information about single object.
• Multidata unit: information about set of objects
• Index unit: list of descriptive properties of objects.
• Scroller unit: browsing of ordered set
• Entry unit: entry forms for input gathering.
22
Advanced Software Engineering Lesson7WebML
23. Icons for units (WebML)
23
Advanced Software Engineering Lesson7WebML
29. Role of units
Multiplicity Role Operations
Data Single Presentation Publishing
Set Presentation Publishing
Index Set Selection Publishing
Set Selection Publishing
Entry Acquisition
Multidata
Scroller
29
Advanced Software Engineering Lesson7WebML
30. Getting content for data units
• Source: name of entity, type of object
providing content.
• Selector: predicate to determine the actual
objects of the source entity that contribute
– Conjunction / Disjunction of elementary
conditions, built from entity attributes and relations
and from constant or variable terms.
30
Advanced Software Engineering Lesson7WebML
31. Getting content for multidata units
• Name: user-defined name
• Source: entity providing content
• Selector: predicate selecting objects.
• Included attributes: set of attributes to be
visualized for each object
• Order clause: set of attributes used to sort
objects and sorting criterion
31
Advanced Software Engineering Lesson7WebML
32. Getting content for index units
• Name: user-defined name
• Source: entity providing content
• Selector: predicate selecting objects
• Included attributes: set of attributes used to display the index entries.
• Order clause: set of attributes used to sort objects and sorting criterion
• Variants:
– multi-choice index unit, checkbox associated with entries
– hierarchical index, index entries organised in a multi-level tree
32
Advanced Software Engineering Lesson7WebML
34. Variants of index units
IndexUnit AlbumIndex hierarchical
(source Album;
attributes Title;
orderby Title
NEST Track
selector AlbumToTrack;
attributes Title;
orderby Title)
IndexUnit AlbumIndex multi-choice
(source Album;
attributes Title;
orderby Title)
34
Advanced Software Engineering Lesson7WebML
35. Scroller units
• Name: user-defined name
• Source: entity providing content
• Selector: predicate selecting objects
• Block factor: number of objects scrolled together.
• Block window: maximum number of shown blocks
that preceed and follow the current block
• Order clause:set of attributes used to sort the objects
and sorting criterion
35
Advanced Software Engineering Lesson7WebML
36. Entry units
• Name: user-defined name
• Fields: set of fields for inputting values.
• Property of fields:
– Name: name of the field.
– Type: data type of the value input
– Initial value: default value initially proposed
– Modifiability: flag specifying if the user can modify the initial
field value or not
– Validity predicate: Boolean condition on the input
36
Advanced Software Engineering Lesson7WebML
38. Links
Inter-Page
Contextual CA CE
Non contextual NA NE
Intra-Page
parametric selector
link parameter
NE
CE
38
Advanced Software Engineering Lesson7WebML
41. Global parameters
• Context information not transferred point-to-
point during navigation, but available to all
the pages of a site
– e.g. multi-country Web site, user selects the
country of interest and then browses the site's
content relative to that country
– hypertext the same for all countries, actual content
varies country by country
• Use of set unit
41
Advanced Software Engineering Lesson7WebML
45. Content management model
• Operation unit: processing executed as result of link
navigation
– data manipulation
– execution of a generic external service.
• OK and KO-links: operation success and failure
– allow alternative courses after execution of an operation
• Transactions: clusters of operation units
– succeed or fail as a whole. Undone if one fails
45
Advanced Software Engineering Lesson7WebML
46. Operations
• Predefined
– Creation, deletion and modification of objects, and relationships.
• Generic
– Integration of external procedures of arbitrary complexity
• Operations:
– May have multiple incoming links.
– May be linked to form a sequence.
– One regular incoming link, and transport links. Navigates the
regular link and uses the parameters associated with input links.
– Have one OK link and one KO link
– May have any number of outgoing transport links
46
Advanced Software Engineering Lesson7WebML
52. Relation creation
User-defined name
Source relationship role
Two selectors, one for
objects of the source entity
and one for objects of the
destination entity.
52
Advanced Software Engineering Lesson7WebML
53. Relation deletion
User-defined name
Source relationship role
Two selectors, one for
objects of the source
entity and one for object
of the destination entity.
53
Advanced Software Engineering Lesson7WebML
54. Transactions
• ACID properties
– Atomicity: either all the involved operations are successfully
completed, producing a new database state, or the initial
database state is left unchanged.
– Consistency: carrying out a transaction should not violate the
integrity of data.
– Isolation: each transaction execution is independent of the
simultaneous execution of other transactions.
– Durability: effects of transactions that complete successfully are
recorded persistently.
• Operations chained by a sequence of OK links
• The last OK link leads to the (unique) hypertext page shown
after the successful completion of the transaction.
54
Advanced Software Engineering Lesson7WebML