SlideShare une entreprise Scribd logo
1  sur  57
Télécharger pour lire hors ligne
CARA Applications
                                            Modelling
                                    Case Study Model
                                         Other Issues




     Model Driven Context Aware Reactive Applications

          Tony Clark (with Dean Kramer and Samia Oussena, UWL)

              School of Engineering and Information Sciences, Middlesex University


                                          October 5, 2011




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Contents

    1   CARA Applications
          Definitions
          Research
          Case Study
    2   Modelling
         Diagrams
         Widget Calculus
    3   Case Study Model
    4   Other Issues
          Types
          Implementation

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Context Aware Reactive Applications

           Context aware applications are: intelligent applications
           that can monitor the user’s context and, in case of
           changes in this context, consequently adapt their
           behaviour in order to satisfy the user’s current needs or
           anticipate the user’s intentions.
    L.M. Daniele, E. Silva, L.F. Pires, and M. Sinderen. A SOA-based Platform-
    specfic Framework for Context-Aware Mobile Applications. Enterprise
    Interoperability, 2009.
           Reactive applications must deal with events that are
           received from their environment and react accordingly.
    D. Harel and A. Pnueli. On the development of reactive systems. Weizmann
    Institute of Science, Dept. of Computer Science, 1985.

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


The Rise of CARA




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


The Rise of CARA




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


The Rise of CARA




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Model Driven Development



           Use models as the primary system artifact.
           Focus on key aspects of systems.
           Use standards to support interoperability and tools.
           Use meta-modelling to construct domain-specific abstractions.
           Analyse, verify and validate the models.
           Generate (parts of) the system from models.




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Knowledge Connext and KTP




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Knowledge Connext and KTP




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Problem and Proposal




           MDD should be available for CARA applications - right?




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Problem and Proposal




           MDD should be available for CARA applications - right?
           Some attempts:




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Problem and Proposal




           MDD should be available for CARA applications - right?
           Some attempts:
                  Complex or tool specific.




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Problem and Proposal




           MDD should be available for CARA applications - right?
           Some attempts:
                  Complex or tool specific.
                  Incomplete, lacks execution.




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Problem and Proposal




           MDD should be available for CARA applications - right?
           Some attempts:
                  Complex or tool specific.
                  Incomplete, lacks execution.
           Can we design a simple, universal MDD solution?




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


CARA Overview




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.




    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.
           A phone is always in contact with its network provider.




    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.
           A phone is always in contact with its network provider.
           Each phone has a unique address, e.g. tony@widget.org.




    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.
           A phone is always in contact with its network provider.
           Each phone has a unique address, e.g. tony@widget.org.
           Each phone maintains a database of contacts.




    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.
           A phone is always in contact with its network provider.
           Each phone has a unique address, e.g. tony@widget.org.
           Each phone maintains a database of contacts.
           Users want to know about contacts in their database that are
           co-located.




    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.
           A phone is always in contact with its network provider.
           Each phone has a unique address, e.g. tony@widget.org.
           Each phone maintains a database of contacts.
           Users want to know about contacts in their database that are
           co-located.
           When one phone moves into the vicinity of the other then
           both phones are told of the availability of the other in terms
           of the contact address.



    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Buddy
           Mobile phones have address lists.
           A phone is always in contact with its network provider.
           Each phone has a unique address, e.g. tony@widget.org.
           Each phone maintains a database of contacts.
           Users want to know about contacts in their database that are
           co-located.
           When one phone moves into the vicinity of the other then
           both phones are told of the availability of the other in terms
           of the contact address.
           If the address is in the user’s database then the phone flashes
           the contact.
    L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach
    for Behaviour Modelling of Context-aware Mobile Applications. In Model
    Driven Architecture-Foundations and Applications. Springer, 2009.
Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Tony’s Phone




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Tony Knows Sally




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                                        Definitions
                                            Modelling
                                                        Research
                                    Case Study Model
                                                        Case Study
                                         Other Issues


Context Aware




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Contents

    1   CARA Applications
          Definitions
          Research
          Case Study
    2   Modelling
         Diagrams
         Widget Calculus
    3   Case Study Model
    4   Other Issues
          Types
          Implementation

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Domain Analysis


       GUI Trees GUI elements are organized in trees.
            Events Elements generate events and listeners handle them.
         Platform Each platform provides a different collection of event
                  generators.
    Object-Orientation Implementation technologies are mostly OO.
    Transitional Behaviour Application execute by performing state
                  transitions.
    Data Persistence Applications manage simple databases.
    Static Typing Generally lacked by most implementation
                 technologies for platforms.


Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


UML Profile



    <<external>> Application components supplied by platform.
    <<widget>> User defined components, tree-shaped.
    Containership Associations, black-diamond.
               Root Root containers define application states.
     <<event>> Generated by the platform, context events.
    <<handler>> Process events.
        Machines State transitions.




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Single Button Model




                     c o n t e x t Push i n v :
                        label = ’ PUSHME ’

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle Button Model




        c o n t e x t Main1 i n v :
            display . label = ’ PUSHME ’

        c o n t e x t Main2 i n v :
            display . label = ’ PUSHED ’

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Widget Calculus: Key Features


    Take a standard λ-calculus and add:
           widgets tree-structured records that generate and handle
                   events.
         externals each platform provides some built-in widgets.
      commands change the state of the world.
          methods each external provides some built-in commands.
               cycle eval, command, wait
    CARA models translate onto the widget-calculus. The calculus
    provides the action-language for the models.



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


A Button (1)



      events            ids     eval

                                main =
                                  w i d g e t self       ( screen (50 ,50 ,50 ,50 , push )) {
                                      move (x , y )      = do { r e t u r n self }
                                  };
      0<-push(0)
                                push =
                                  w i d g e t self       ( button ( ’ PUSHME ’)) {
                                      push ( i ) =       do { r e t u r n self }
                                  }




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


A Button (2)



      events            ids     command

                                < w i d g e t self ( screen (50 ,50 ,50 ,50 ,
                                   w i d g e t self ( button ( ’ PUSHME ’)) {
                                        push ( i ) = do { r e t u r n self }
      0<-push(0)
                                   }) {
                                   move (x , y ) = do { r e t u r n self }
                                }>




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


A Button (3)



      events            ids      wait

                                 w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 ,
                                     w i d g e t (1) self ( button (0 , ’ PUSHME ’)) {
                                         push ( i ) = do { r e t u r n self }
      0<-push(0) 0 1
                                     }) {
                        2 3          move (x , y ) = do { r e t u r n self }
                                 }




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


A Button (4)



      events       ids      eval

                            w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 ,
                                < w i d g e t (1) self ( button (0 , ’ PUSHME ’)) {
                                    push ( i ) = do { r e t u r n self }
                   0 1
                                }. push (0) >) {
                   2 3          move (x , y ) = do { r e t u r n self }
                            }




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


A Button (5)


      events       ids      command

                            w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 ,
                                <do {
                                    r e t u r n w i d g e t (1) self ( button (0 , ’ PUSHME ’))
                                        push ( i ) = do { r e t u r n self }
                   0 1
                                   }
                   2 3          } >) {
                                move (x , y ) = do { r e t u r n self }
                            }




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


A Button (6)



      events       ids      wait

                            w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 ,
                                w i d g e t (1) self ( button (0 , ’ PUSHME ’)) {
                                    push ( i ) = do { r e t u r n self }
                   0 1
                                }) {
                   2 3          move (x , y ) = do { r e t u r n self }
                            }




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (1)

      events            ids     eval

                                main =
                                  w i d g e t self ( screen (50 ,50 ,50 ,50 , push )) {
                                      move (x , y ) = do { r e t u r n self }
                                  };
                                push =
      0<-push(0)                  w i d g e t ( button ( ’ PUSHME ’)) {
      1<-push(1)                      push ( i ) = do { r e t u r n pushed }
                                  };
                                pushed =
                                  w i d g e t ( button ( ’ PUSHED ’)) {
                                      push ( i ) = do { r e t u r n push }
                                  }



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (2)


      events            ids      command

                                 < w i d g e t self ( screen (50 ,50 ,50 ,50 ,
                                    w i d g e t ( button ( ’ PUSHME ’)) {
                                         push ( i ) = do {
                                             r e t u r n w i d g e t ( button ( ’ PUSHED ’)) {
      0<-push(0)                                 push ( i ) = do { r e t u r n push }
      1<-push(1)                            }
                                         }
                                    })) {
                                    move (x , y ) = do { r e t u r n self }
                                 }>




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (3)

      events            ids wait

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  w i d g e t (3) ( button (0 , ’ PUSHME ’)) {
                                      push ( i ) = do {
                                          r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) {
      0<-push(0)                              push ( i ) = do { r e t u r n push }
                        0
      1<-push(1)                          }
                        1             }
                        2         })) {
                        3         move (x , y ) = do { r e t u r n self }
                              }
                        4
                        5



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (4)

      events            ids eval

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  < w i d g e t (3) ( button (0 , ’ PUSHME ’)) {
                                      push ( i ) = do {
                                          r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) {
                                              push ( i ) = do { r e t u r n push }
      1<-push(1) 0
                                          }
                        1            }
                        2         }. push (0) >)) {
                        3         move (x , y ) = do { r e t u r n self }
                              }
                        4
                        5



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (5)


      events            ids command

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  <do {
                                      r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) {
      1<-push(1) 0                        push ( i ) = do { r e t u r n push }
                        1         } >)) {
                                  move (x , y ) = do { r e t u r n self }
                        2
                              }
                        3
                        4
                        5




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (6)


      events            ids wait

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  w i d g e t (2) ( button (1 , ’ PUSHED ’)) {
                                      push ( i ) = do { r e t u r n push }
      1<-push(1) 0
                                  })) {
                        1         move (x , y ) = do { r e t u r n self }
                        2     }
                        3
                        4
                        5




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (7)


      events            ids eval

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  < w i d g e t (2) ( button (1 , ’ PUSHED ’)) {
                                      push ( i ) = do { r e t u r n push }
                        0
                                  }. push (1) >)) {
                        1         move (x , y ) = do { r e t u r n self }
                        2     }
                        3
                        4
                        5




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (8)


      events            ids command

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  <do { r e t u r n push } >)) {
                        0
                                  move (x , y ) = do { r e t u r n self }
                        1     }
                        2
                        3
                        4
                        5




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Toggle (9)

      events            ids wait

                              w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 ,
                                  w i d g e t (3) ( button (0 , ’ PUSHME ’)) {
                                      push ( i ) = do {
                                          r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) {
                                              push ( i ) = do { r e t u r n push }
                        0
                                          }
                        1             }
                        2         })) {
                        3         move (x , y ) = do { r e t u r n self }
                              }
                        4
                        5



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Diagrams
                                    Case Study Model    Widget Calculus
                                         Other Issues


Commands


    Commands can:
           Create widgets.
           Create, access or update variables.
           Read or write files and databases.
           Access local context, e.g. orientation, battery charge, light
           levels.
           Connect to servers.
           Write to servers.
           Send emails.



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling
                                    Case Study Model
                                         Other Issues


Contents

    1   CARA Applications
          Definitions
          Research
          Case Study
    2   Modelling
         Diagrams
         Widget Calculus
    3   Case Study Model
    4   Other Issues
          Types
          Implementation

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling
                                    Case Study Model
                                         Other Issues


Main Screen




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling
                                    Case Study Model
                                         Other Issues


Add New Contacts




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling
                                    Case Study Model
                                         Other Issues


Notify




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling
                                    Case Study Model
                                         Other Issues


Execution




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Types
                                    Case Study Model    Implementation
                                         Other Issues


Contents

    1   CARA Applications
          Definitions
          Research
          Case Study
    2   Modelling
         Diagrams
         Widget Calculus
    3   Case Study Model
    4   Other Issues
          Types
          Implementation

Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Types
                                    Case Study Model    Implementation
                                         Other Issues


Widget Types


    Standard functional types:
             Atoms int, str, bool
        Functions α → β
               Lists [α]
      Definitions type name = α
    Extra types:
            Widget Widget(α){x : β; . . .}
      Commands <α>
            Events ∗



Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                              Modelling   Types
                                      Case Study Model    Implementation
                                           Other Issues


 Simple Button (with types)
e x t e r n a l w i d g e t . Screen ;
e x t e r n a l w i d g e t . Button ;

t y p e Push = r e c B . Widget ( Button ) { push :( int ) - > <B > }

t y p e Main = r e c M . Widget ( Screen [ < Push >]){ move :( int , int ) - > <M > }

r e c v a l main : < Main > =
          f o l d [ < Main >]
              w i d g e t self : Main ( screen [ < Push >](50 ,50 ,50 ,50 , push )) {
                  move ( x : int , y : int ): < Main > = do { r e t u r n self }
              };
      v a l push : < Push > =
          f o l d [ < Push >]
              w i d g e t self : Push ( button ( ’ PUSHME ’)) {
                  push ( i : int ): < Push > = do { r e t u r n self }
              }

  Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Types
                                    Case Study Model    Implementation
                                         Other Issues


Java




           Java parser for language.
           Java type-checker for Widget.
           Java interpreter for Widget.
           Swing-based external library.
           Phone ’platform’ in Swing.




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA
CARA Applications
                                            Modelling   Types
                                    Case Study Model    Implementation
                                         Other Issues


Next Steps




           Implement the profile using standard UML tools.
           Link CARA models and Widget calculus via model
           transformations.
           More external libraries (Swing, HTML, Android).
           Simplify types.




Tony Clark (with Dean Kramer and Samia Oussena, UWL)    CARA

Contenu connexe

En vedette

Structured system analysis
Structured system analysisStructured system analysis
Structured system analysislearnt
 
Entity-Relationship Diagrams ERD
Entity-Relationship Diagrams ERDEntity-Relationship Diagrams ERD
Entity-Relationship Diagrams ERDtorp42
 
Entity Relationship Diagram
Entity Relationship DiagramEntity Relationship Diagram
Entity Relationship DiagramSiti Ismail
 
SE_Lec 05_System Modelling and Context Model
SE_Lec 05_System Modelling and Context ModelSE_Lec 05_System Modelling and Context Model
SE_Lec 05_System Modelling and Context ModelAmr E. Mohamed
 
Software Engineering- ERD DFD Decision Tree and Table
Software Engineering- ERD DFD Decision Tree and TableSoftware Engineering- ERD DFD Decision Tree and Table
Software Engineering- ERD DFD Decision Tree and TableNishu Rastogi
 
Entity Relationship Diagram
Entity Relationship DiagramEntity Relationship Diagram
Entity Relationship DiagramRakhi Mukherji
 
SOC System Design Approach
SOC System Design ApproachSOC System Design Approach
SOC System Design ApproachA B Shinde
 
Introduction to embedded system design
Introduction to embedded system designIntroduction to embedded system design
Introduction to embedded system designMukesh Bansal
 
Lecture 03 data abstraction and er model
Lecture 03 data abstraction and er modelLecture 03 data abstraction and er model
Lecture 03 data abstraction and er modelemailharmeet
 
Database - Entity Relationship Diagram (ERD)
Database - Entity Relationship Diagram (ERD)Database - Entity Relationship Diagram (ERD)
Database - Entity Relationship Diagram (ERD)Mudasir Qazi
 
Active Story System - design methodology for transmedia storytelling
Active Story System - design methodology for transmedia storytellingActive Story System - design methodology for transmedia storytelling
Active Story System - design methodology for transmedia storytellingRobert Pratten
 
Dick &amp; carey instructional design model sabri elamin
Dick &amp; carey instructional design model sabri elaminDick &amp; carey instructional design model sabri elamin
Dick &amp; carey instructional design model sabri elaminMemorial University
 
Software Engineering- Requirement Elicitation and Specification
Software Engineering- Requirement Elicitation and SpecificationSoftware Engineering- Requirement Elicitation and Specification
Software Engineering- Requirement Elicitation and SpecificationNishu Rastogi
 
Communication concepts
Communication conceptsCommunication concepts
Communication conceptsRatish Kakad
 

En vedette (20)

Structured system analysis
Structured system analysisStructured system analysis
Structured system analysis
 
Entity-Relationship Diagrams ERD
Entity-Relationship Diagrams ERDEntity-Relationship Diagrams ERD
Entity-Relationship Diagrams ERD
 
Erd (info sys)
Erd (info sys)Erd (info sys)
Erd (info sys)
 
Erd
ErdErd
Erd
 
Erd chapter 3
Erd chapter 3Erd chapter 3
Erd chapter 3
 
Entity Relationship Diagram
Entity Relationship DiagramEntity Relationship Diagram
Entity Relationship Diagram
 
SE_Lec 05_System Modelling and Context Model
SE_Lec 05_System Modelling and Context ModelSE_Lec 05_System Modelling and Context Model
SE_Lec 05_System Modelling and Context Model
 
Software Engineering- ERD DFD Decision Tree and Table
Software Engineering- ERD DFD Decision Tree and TableSoftware Engineering- ERD DFD Decision Tree and Table
Software Engineering- ERD DFD Decision Tree and Table
 
Archimate Viewpoints
Archimate ViewpointsArchimate Viewpoints
Archimate Viewpoints
 
Entity Relationship Diagram
Entity Relationship DiagramEntity Relationship Diagram
Entity Relationship Diagram
 
SOC System Design Approach
SOC System Design ApproachSOC System Design Approach
SOC System Design Approach
 
Introduction to embedded system design
Introduction to embedded system designIntroduction to embedded system design
Introduction to embedded system design
 
Erd practice exercises
Erd practice exercisesErd practice exercises
Erd practice exercises
 
Lecture 03 data abstraction and er model
Lecture 03 data abstraction and er modelLecture 03 data abstraction and er model
Lecture 03 data abstraction and er model
 
Database - Entity Relationship Diagram (ERD)
Database - Entity Relationship Diagram (ERD)Database - Entity Relationship Diagram (ERD)
Database - Entity Relationship Diagram (ERD)
 
Active Story System - design methodology for transmedia storytelling
Active Story System - design methodology for transmedia storytellingActive Story System - design methodology for transmedia storytelling
Active Story System - design methodology for transmedia storytelling
 
Dick &amp; carey instructional design model sabri elamin
Dick &amp; carey instructional design model sabri elaminDick &amp; carey instructional design model sabri elamin
Dick &amp; carey instructional design model sabri elamin
 
System design
System designSystem design
System design
 
Software Engineering- Requirement Elicitation and Specification
Software Engineering- Requirement Elicitation and SpecificationSoftware Engineering- Requirement Elicitation and Specification
Software Engineering- Requirement Elicitation and Specification
 
Communication concepts
Communication conceptsCommunication concepts
Communication concepts
 

Plus de ClarkTony

The Uncertain Enterprise
The Uncertain EnterpriseThe Uncertain Enterprise
The Uncertain EnterpriseClarkTony
 
Actors for Behavioural Simulation
Actors for Behavioural SimulationActors for Behavioural Simulation
Actors for Behavioural SimulationClarkTony
 
Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...
Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...
Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...ClarkTony
 
LEAP A Language for Architecture Design, Simulation and Analysis
LEAP A Language for Architecture Design, Simulation and AnalysisLEAP A Language for Architecture Design, Simulation and Analysis
LEAP A Language for Architecture Design, Simulation and AnalysisClarkTony
 
A Common Basis for Modelling Service-Oriented and Event-Driven Architecture
A Common Basis for Modelling Service-Oriented and Event-Driven ArchitectureA Common Basis for Modelling Service-Oriented and Event-Driven Architecture
A Common Basis for Modelling Service-Oriented and Event-Driven ArchitectureClarkTony
 
Model Slicing
Model SlicingModel Slicing
Model SlicingClarkTony
 
Patterns 200711
Patterns 200711Patterns 200711
Patterns 200711ClarkTony
 
Kings 120711
Kings 120711Kings 120711
Kings 120711ClarkTony
 
Iswim for testing
Iswim for testingIswim for testing
Iswim for testingClarkTony
 
Iswim for testing
Iswim for testingIswim for testing
Iswim for testingClarkTony
 
Kiss at oopsla 09
Kiss at oopsla 09Kiss at oopsla 09
Kiss at oopsla 09ClarkTony
 
Mcms and ids sig
Mcms and ids sigMcms and ids sig
Mcms and ids sigClarkTony
 
Reverse engineering and theory building v3
Reverse engineering and theory building v3Reverse engineering and theory building v3
Reverse engineering and theory building v3ClarkTony
 
Onward presentation.en
Onward presentation.enOnward presentation.en
Onward presentation.enClarkTony
 
Formalizing homogeneous language embeddings
Formalizing homogeneous language embeddingsFormalizing homogeneous language embeddings
Formalizing homogeneous language embeddingsClarkTony
 
Filmstrip testing
Filmstrip testingFilmstrip testing
Filmstrip testingClarkTony
 
Dsm as theory building
Dsm as theory buildingDsm as theory building
Dsm as theory buildingClarkTony
 

Plus de ClarkTony (20)

The Uncertain Enterprise
The Uncertain EnterpriseThe Uncertain Enterprise
The Uncertain Enterprise
 
Actors for Behavioural Simulation
Actors for Behavioural SimulationActors for Behavioural Simulation
Actors for Behavioural Simulation
 
Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...
Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...
Context-Aware Content-Centric Collaborative Workflow Management for Mobile De...
 
LEAP A Language for Architecture Design, Simulation and Analysis
LEAP A Language for Architecture Design, Simulation and AnalysisLEAP A Language for Architecture Design, Simulation and Analysis
LEAP A Language for Architecture Design, Simulation and Analysis
 
A Common Basis for Modelling Service-Oriented and Event-Driven Architecture
A Common Basis for Modelling Service-Oriented and Event-Driven ArchitectureA Common Basis for Modelling Service-Oriented and Event-Driven Architecture
A Common Basis for Modelling Service-Oriented and Event-Driven Architecture
 
Model Slicing
Model SlicingModel Slicing
Model Slicing
 
Patterns 200711
Patterns 200711Patterns 200711
Patterns 200711
 
Kings 120711
Kings 120711Kings 120711
Kings 120711
 
Iswim for testing
Iswim for testingIswim for testing
Iswim for testing
 
Iswim for testing
Iswim for testingIswim for testing
Iswim for testing
 
Kiss at oopsla 09
Kiss at oopsla 09Kiss at oopsla 09
Kiss at oopsla 09
 
Mcms and ids sig
Mcms and ids sigMcms and ids sig
Mcms and ids sig
 
Ocl 09
Ocl 09Ocl 09
Ocl 09
 
Scam 08
Scam 08Scam 08
Scam 08
 
Reverse engineering and theory building v3
Reverse engineering and theory building v3Reverse engineering and theory building v3
Reverse engineering and theory building v3
 
Onward presentation.en
Onward presentation.enOnward presentation.en
Onward presentation.en
 
Hcse pres
Hcse presHcse pres
Hcse pres
 
Formalizing homogeneous language embeddings
Formalizing homogeneous language embeddingsFormalizing homogeneous language embeddings
Formalizing homogeneous language embeddings
 
Filmstrip testing
Filmstrip testingFilmstrip testing
Filmstrip testing
 
Dsm as theory building
Dsm as theory buildingDsm as theory building
Dsm as theory building
 

Dernier

Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 

Dernier (20)

Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 

Context Aware Reactive Applications

  • 1. CARA Applications Modelling Case Study Model Other Issues Model Driven Context Aware Reactive Applications Tony Clark (with Dean Kramer and Samia Oussena, UWL) School of Engineering and Information Sciences, Middlesex University October 5, 2011 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 2. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Contents 1 CARA Applications Definitions Research Case Study 2 Modelling Diagrams Widget Calculus 3 Case Study Model 4 Other Issues Types Implementation Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 3. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Context Aware Reactive Applications Context aware applications are: intelligent applications that can monitor the user’s context and, in case of changes in this context, consequently adapt their behaviour in order to satisfy the user’s current needs or anticipate the user’s intentions. L.M. Daniele, E. Silva, L.F. Pires, and M. Sinderen. A SOA-based Platform- specfic Framework for Context-Aware Mobile Applications. Enterprise Interoperability, 2009. Reactive applications must deal with events that are received from their environment and react accordingly. D. Harel and A. Pnueli. On the development of reactive systems. Weizmann Institute of Science, Dept. of Computer Science, 1985. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 4. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues The Rise of CARA Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 5. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues The Rise of CARA Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 6. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues The Rise of CARA Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 7. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Model Driven Development Use models as the primary system artifact. Focus on key aspects of systems. Use standards to support interoperability and tools. Use meta-modelling to construct domain-specific abstractions. Analyse, verify and validate the models. Generate (parts of) the system from models. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 8. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Knowledge Connext and KTP Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 9. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Knowledge Connext and KTP Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 10. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Problem and Proposal MDD should be available for CARA applications - right? Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 11. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Problem and Proposal MDD should be available for CARA applications - right? Some attempts: Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 12. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Problem and Proposal MDD should be available for CARA applications - right? Some attempts: Complex or tool specific. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 13. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Problem and Proposal MDD should be available for CARA applications - right? Some attempts: Complex or tool specific. Incomplete, lacks execution. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 14. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Problem and Proposal MDD should be available for CARA applications - right? Some attempts: Complex or tool specific. Incomplete, lacks execution. Can we design a simple, universal MDD solution? Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 15. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues CARA Overview Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 16. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 17. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. A phone is always in contact with its network provider. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 18. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. A phone is always in contact with its network provider. Each phone has a unique address, e.g. tony@widget.org. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 19. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. A phone is always in contact with its network provider. Each phone has a unique address, e.g. tony@widget.org. Each phone maintains a database of contacts. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 20. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. A phone is always in contact with its network provider. Each phone has a unique address, e.g. tony@widget.org. Each phone maintains a database of contacts. Users want to know about contacts in their database that are co-located. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 21. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. A phone is always in contact with its network provider. Each phone has a unique address, e.g. tony@widget.org. Each phone maintains a database of contacts. Users want to know about contacts in their database that are co-located. When one phone moves into the vicinity of the other then both phones are told of the availability of the other in terms of the contact address. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 22. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Buddy Mobile phones have address lists. A phone is always in contact with its network provider. Each phone has a unique address, e.g. tony@widget.org. Each phone maintains a database of contacts. Users want to know about contacts in their database that are co-located. When one phone moves into the vicinity of the other then both phones are told of the availability of the other in terms of the contact address. If the address is in the user’s database then the phone flashes the contact. L. Daniele, L. Ferreira Pires, and M. van Sinderen. An MDA-based Approach for Behaviour Modelling of Context-aware Mobile Applications. In Model Driven Architecture-Foundations and Applications. Springer, 2009. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 23. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Tony’s Phone Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 24. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Tony Knows Sally Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 25. CARA Applications Definitions Modelling Research Case Study Model Case Study Other Issues Context Aware Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 26. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Contents 1 CARA Applications Definitions Research Case Study 2 Modelling Diagrams Widget Calculus 3 Case Study Model 4 Other Issues Types Implementation Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 27. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Domain Analysis GUI Trees GUI elements are organized in trees. Events Elements generate events and listeners handle them. Platform Each platform provides a different collection of event generators. Object-Orientation Implementation technologies are mostly OO. Transitional Behaviour Application execute by performing state transitions. Data Persistence Applications manage simple databases. Static Typing Generally lacked by most implementation technologies for platforms. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 28. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues UML Profile <<external>> Application components supplied by platform. <<widget>> User defined components, tree-shaped. Containership Associations, black-diamond. Root Root containers define application states. <<event>> Generated by the platform, context events. <<handler>> Process events. Machines State transitions. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 29. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Single Button Model c o n t e x t Push i n v : label = ’ PUSHME ’ Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 30. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle Button Model c o n t e x t Main1 i n v : display . label = ’ PUSHME ’ c o n t e x t Main2 i n v : display . label = ’ PUSHED ’ Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 31. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Widget Calculus: Key Features Take a standard λ-calculus and add: widgets tree-structured records that generate and handle events. externals each platform provides some built-in widgets. commands change the state of the world. methods each external provides some built-in commands. cycle eval, command, wait CARA models translate onto the widget-calculus. The calculus provides the action-language for the models. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 32. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues A Button (1) events ids eval main = w i d g e t self ( screen (50 ,50 ,50 ,50 , push )) { move (x , y ) = do { r e t u r n self } }; 0<-push(0) push = w i d g e t self ( button ( ’ PUSHME ’)) { push ( i ) = do { r e t u r n self } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 33. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues A Button (2) events ids command < w i d g e t self ( screen (50 ,50 ,50 ,50 , w i d g e t self ( button ( ’ PUSHME ’)) { push ( i ) = do { r e t u r n self } 0<-push(0) }) { move (x , y ) = do { r e t u r n self } }> Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 34. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues A Button (3) events ids wait w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 , w i d g e t (1) self ( button (0 , ’ PUSHME ’)) { push ( i ) = do { r e t u r n self } 0<-push(0) 0 1 }) { 2 3 move (x , y ) = do { r e t u r n self } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 35. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues A Button (4) events ids eval w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 , < w i d g e t (1) self ( button (0 , ’ PUSHME ’)) { push ( i ) = do { r e t u r n self } 0 1 }. push (0) >) { 2 3 move (x , y ) = do { r e t u r n self } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 36. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues A Button (5) events ids command w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 , <do { r e t u r n w i d g e t (1) self ( button (0 , ’ PUSHME ’)) push ( i ) = do { r e t u r n self } 0 1 } 2 3 } >) { move (x , y ) = do { r e t u r n self } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 37. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues A Button (6) events ids wait w i d g e t (3) self ( screen (2 ,50 ,50 ,50 ,50 , w i d g e t (1) self ( button (0 , ’ PUSHME ’)) { push ( i ) = do { r e t u r n self } 0 1 }) { 2 3 move (x , y ) = do { r e t u r n self } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 38. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (1) events ids eval main = w i d g e t self ( screen (50 ,50 ,50 ,50 , push )) { move (x , y ) = do { r e t u r n self } }; push = 0<-push(0) w i d g e t ( button ( ’ PUSHME ’)) { 1<-push(1) push ( i ) = do { r e t u r n pushed } }; pushed = w i d g e t ( button ( ’ PUSHED ’)) { push ( i ) = do { r e t u r n push } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 39. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (2) events ids command < w i d g e t self ( screen (50 ,50 ,50 ,50 , w i d g e t ( button ( ’ PUSHME ’)) { push ( i ) = do { r e t u r n w i d g e t ( button ( ’ PUSHED ’)) { 0<-push(0) push ( i ) = do { r e t u r n push } 1<-push(1) } } })) { move (x , y ) = do { r e t u r n self } }> Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 40. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (3) events ids wait w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , w i d g e t (3) ( button (0 , ’ PUSHME ’)) { push ( i ) = do { r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) { 0<-push(0) push ( i ) = do { r e t u r n push } 0 1<-push(1) } 1 } 2 })) { 3 move (x , y ) = do { r e t u r n self } } 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 41. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (4) events ids eval w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , < w i d g e t (3) ( button (0 , ’ PUSHME ’)) { push ( i ) = do { r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) { push ( i ) = do { r e t u r n push } 1<-push(1) 0 } 1 } 2 }. push (0) >)) { 3 move (x , y ) = do { r e t u r n self } } 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 42. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (5) events ids command w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , <do { r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) { 1<-push(1) 0 push ( i ) = do { r e t u r n push } 1 } >)) { move (x , y ) = do { r e t u r n self } 2 } 3 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 43. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (6) events ids wait w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , w i d g e t (2) ( button (1 , ’ PUSHED ’)) { push ( i ) = do { r e t u r n push } 1<-push(1) 0 })) { 1 move (x , y ) = do { r e t u r n self } 2 } 3 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 44. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (7) events ids eval w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , < w i d g e t (2) ( button (1 , ’ PUSHED ’)) { push ( i ) = do { r e t u r n push } 0 }. push (1) >)) { 1 move (x , y ) = do { r e t u r n self } 2 } 3 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 45. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (8) events ids command w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , <do { r e t u r n push } >)) { 0 move (x , y ) = do { r e t u r n self } 1 } 2 3 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 46. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Toggle (9) events ids wait w i d g e t (5) self ( screen (4 ,50 ,50 ,50 ,50 , w i d g e t (3) ( button (0 , ’ PUSHME ’)) { push ( i ) = do { r e t u r n w i d g e t (2) ( button (1 , ’ PUSHED ’)) { push ( i ) = do { r e t u r n push } 0 } 1 } 2 })) { 3 move (x , y ) = do { r e t u r n self } } 4 5 Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 47. CARA Applications Modelling Diagrams Case Study Model Widget Calculus Other Issues Commands Commands can: Create widgets. Create, access or update variables. Read or write files and databases. Access local context, e.g. orientation, battery charge, light levels. Connect to servers. Write to servers. Send emails. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 48. CARA Applications Modelling Case Study Model Other Issues Contents 1 CARA Applications Definitions Research Case Study 2 Modelling Diagrams Widget Calculus 3 Case Study Model 4 Other Issues Types Implementation Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 49. CARA Applications Modelling Case Study Model Other Issues Main Screen Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 50. CARA Applications Modelling Case Study Model Other Issues Add New Contacts Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 51. CARA Applications Modelling Case Study Model Other Issues Notify Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 52. CARA Applications Modelling Case Study Model Other Issues Execution Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 53. CARA Applications Modelling Types Case Study Model Implementation Other Issues Contents 1 CARA Applications Definitions Research Case Study 2 Modelling Diagrams Widget Calculus 3 Case Study Model 4 Other Issues Types Implementation Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 54. CARA Applications Modelling Types Case Study Model Implementation Other Issues Widget Types Standard functional types: Atoms int, str, bool Functions α → β Lists [α] Definitions type name = α Extra types: Widget Widget(α){x : β; . . .} Commands <α> Events ∗ Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 55. CARA Applications Modelling Types Case Study Model Implementation Other Issues Simple Button (with types) e x t e r n a l w i d g e t . Screen ; e x t e r n a l w i d g e t . Button ; t y p e Push = r e c B . Widget ( Button ) { push :( int ) - > <B > } t y p e Main = r e c M . Widget ( Screen [ < Push >]){ move :( int , int ) - > <M > } r e c v a l main : < Main > = f o l d [ < Main >] w i d g e t self : Main ( screen [ < Push >](50 ,50 ,50 ,50 , push )) { move ( x : int , y : int ): < Main > = do { r e t u r n self } }; v a l push : < Push > = f o l d [ < Push >] w i d g e t self : Push ( button ( ’ PUSHME ’)) { push ( i : int ): < Push > = do { r e t u r n self } } Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 56. CARA Applications Modelling Types Case Study Model Implementation Other Issues Java Java parser for language. Java type-checker for Widget. Java interpreter for Widget. Swing-based external library. Phone ’platform’ in Swing. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA
  • 57. CARA Applications Modelling Types Case Study Model Implementation Other Issues Next Steps Implement the profile using standard UML tools. Link CARA models and Widget calculus via model transformations. More external libraries (Swing, HTML, Android). Simplify types. Tony Clark (with Dean Kramer and Samia Oussena, UWL) CARA