java.net: Wiki

The Source for Java Technology Collaboration


 <<O>>  Difference Topic JMakiMenuDataModel (30 - 12 Jun 2008 - Main.gmurray71)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model page

Line: 28 to 28
  }, { label:'Click me for fun!', action:{message: '/fun.jsp'}}, { label:'Disabled!', disabled:true },
Changed:
<
<
{ label:'Sun Microsystems', href: 'http://www.sun.com', action:{topic: '/my/topic',message:'http://www.sun.com'} }, { label:'Oracle', href: 'http://www.oracle.com', action:{message:'http://www.oracle.com' }}
>
>
{ label:'Sun Microsystems', href: 'http://www.sun.com',
action:{topic
'/my/topic/setInclude', message: { url : 'http://www.sun.com'} } }, { label:'Oracle', href: 'http://www.oracle.com',
action:{topic
'/my/topic/setInclude', message: { url : 'http://www.oracle.com'} } }
  ]}
Line: 103 to 107
 The href property indicates that the string following the property is a URL and that navigation should go to that URL.
Changed:
<
<
The action property is used to provide the name of the page that is then published on the topic. If this property is present, a click on this node will cause the message to be published on the topic. There must be a listener (most likely a dcontainer) which actually loads the page but that is outside the scope of this model.
>
>
The action is the way to override the default event that is published if a menu item is selected.
 The topic property overrides the publish arg at the tag level for the particular item identified by label.

 <<O>>  Difference Topic JMakiMenuDataModel (29 - 06 Jun 2008 - Main.carlavmott)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model page

Line: 33 to 33
  ]}
Added:
>
>

(2) Data Model

Incorporating the feedback from the team here is the latest rev of the data model. We wanted to add an action property which allows users to specify the message to publish and the topic to publish to. If no topic is specified then the default topic is used. We want the message to be a string or JavaScript object literal and this may need additional specification. Also we want to be able to specify CSS which is passed through to the underlying widget.

    menuBar ::= "{"  {<menu>} "}"
    menu ::= "menu:"  "["  {<label>}  "]" 
    label ::=  "{" "label:"  <string>, [<menu> | <href>  [<action>] ] [<disabled>] [<style> ]  "},"
    href ::= "href:" <string> ,  
    action ::= "action:" "{" [<topic>] <message>  "},"
    topic ::=  "topic:" <string>,
    message ::= "message:" <obj>
    obj ::= <string> | <JavaScript object literal>
    style ::= "style:" "{"  < CSS markup> "}"
    disabled ::=  "disabled: true"
 JSON Schema for mat is:
{
Line: 63 to 84
  "action" : {"type" : "object","optional":true,
"properties"
{
"topic"
{"type" : "string", "optional" : true},
Changed:
<
<
"message": {"type" : "string", "optional" : true}
>
>
"message": {"type" : ["string","object"], "optional" : true}
  } } }
Line: 73 to 94
  }
Deleted:
<
<

(2) Data Model

Incorporating the feedback from the team here is the latest rev of the data model. We wanted to add an action property which allows users to specify the message to publish and the topic to publish to. If no topic is specified then the default topic is used. We want the message to be a string or JavaScript object literal and this may need additional specification. Also we want to be able to specify CSS which is passed through to the underlying widget.

    menuBar ::= "{"  {<menu>} "}"
    menu ::= "menu:"  "["  {<label>}  "]" 
    label ::=  "{" "label:"  <string>, [<menu> | <href>  [<action>] ] [<disabled>] [<style> ]  "},"
    href ::= "href:" <string> ,  
    action ::= "action:" "{" [<topic>] <message>  "},"
    topic ::=  "topic:" <string>,
    message ::= "message:" <obj>
    obj ::= <string> | <JavaScript object literal>
    style ::= "style:" "{"  < CSS markup> "}"
    disabled ::=  "disabled: true"
 

(2.2) Property Descriptions


 <<O>>  Difference Topic JMakiMenuDataModel (28 - 30 May 2008 - Main.carlavmott)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model page

Line: 33 to 33
  ]}
Added:
>
>
JSON Schema for mat is:
{
       "description" : "jMaki Menu",
         "type":"object",
         "properties": { 
          "menu" : {
             "type" : "array",
               "items" : { 
                 "type" : "object", 
                 "properties" : {
                    "id" : {"type": "string", "optional":true,},
                  "label" : {"type": "string"},
                  "menu" :  {"type" : "object","optional":true,
                        "properties": {
                           "id" : {"type": "string", "optional":true,},
                        "label" : {"type": "string"},
                            "href" : {"type": "string","optional":true},
                         "action" :  {"type" : "object","optional":true,
                              "properties": {
                                 "topic": {"type" : "string", "optional" : true},
                                  "message": {"type" : "string", "optional" : true}                            
                                }
                           }
                            }
                   },
                  "href" : {"type": "string","optional":true},
                  "action" :  {"type" : "object","optional":true,
                        "properties": {
                           "topic": {"type" : "string", "optional" : true},
                            "message": {"type" : "string", "optional" : true}                            
                            }
                   }
                  }
               }
           }
         }       
  }
 

(2) Data Model

Incorporating the feedback from the team here is the latest rev of the data model. We wanted to add an action property which allows users to specify the message to publish and the topic to publish to.

 <<O>>  Difference Topic JMakiMenuDataModel (27 - 20 Nov 2007 - Main.carlavmott)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model page

Line: 70 to 70
 

(3) Event Handling

Changed:
<
<
This still needs alot of work and discussions are happening on the dev alias of the ajax project ajax.dev.java.net.
>
>
There is only one event for that model that causes a message to be published to the communication bus.
 Events that trigger a payload to be published are:
Changed:
<
<
event type payload
>
>
event type payload contents
 
onclick widget id, topic name, href or message

 <<O>>  Difference Topic JMakiMenuDataModel (26 - 18 Jul 2007 - Main.gmurray71)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007
Changed:
<
<
Main data model discussion page
>
>
Main data model page
 

Menu Data Model


 <<O>>  Difference Topic JMakiMenuDataModel (25 - 18 Jul 2007 - Main.gmurray71)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model discussion page


 <<O>>  Difference Topic JMakiMenuDataModel (24 - 17 Jul 2007 - Main.gmurray71)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model discussion page


 <<O>>  Difference Topic JMakiMenuDataModel (23 - 13 Jul 2007 - Main.carlavmott)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model discussion page

Line: 57 to 57
 
Changed:
<
<

(2.2) Element Descriptions

>
>

(2.2) Property Descriptions

 
Changed:
<
<
The outermost menu element or elements identify the labels of the menu bar. As you will see below, the label element allows nodes to be nested to an arbitrary level. Note that there are no restrictions on the order of subordinate elements.
>
>
The outermost menu property or properties identify the labels of the menu bar. As you will see below, the label element allows nodes to be nested to an arbitrary level. Note that there are no restrictions on the order of subordinate properties.
 
Changed:
<
<
The label element defines the text that will be displayed for this particular node. This element is required.
>
>
The label property defines the text that will be displayed for this particular node. This property is required.
 
Changed:
<
<
The href element indicates that the string following the element is a URL and that navigation should go to that URL.
>
>
The href property indicates that the string following the property is a URL and that navigation should go to that URL.
 
Changed:
<
<
The action element is used to provide the name of the page that is then published on the topic. If this element is present, a click on this node will cause the message to be published on the topic. There must be a listener (most likely a dcontainer) which actually loads the page but that is outside the scope of this model.
>
>
The action property is used to provide the name of the page that is then published on the topic. If this property is present, a click on this node will cause the message to be published on the topic. There must be a listener (most likely a dcontainer) which actually loads the page but that is outside the scope of this model.
 
Changed:
<
<
The topic element overrides the publish arg at the tag level for the particular item identified by label.
>
>
The topic property overrides the publish arg at the tag level for the particular item identified by label.
 

(3) Event Handling


 <<O>>  Difference Topic JMakiMenuDataModel (22 - 12 Jul 2007 - Main.carlavmott)
Line: 1 to 1
 -- Main.carlavmott - 06 Jun 2007

Main data model discussion page

Line: 26 to 26
  ] } ] },
Changed:
<
<
{ label:'Click me for fun!', inlcude: '/fun.jsp' },
>
>
{ label:'Click me for fun!', action:{message: '/fun.jsp'}},
  { label:'Disabled!', disabled:true }, { label:'Sun Microsystems', href: 'http://www.sun.com', action:{topic: '/my/topic',message:'http://www.sun.com'} }, { label:'Oracle', href: 'http://www.oracle.com', action:{message:'http://www.oracle.com' }}
Line: 44 to 44
 
    menuBar ::= "{"  {<menu>} "}"
    menu ::= "menu:"  "["  {<label>}  "]" 
Changed:
<
<
label ::= "{" "label:" , [ | | [] ] [] [