<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="/stylesheets/rss.css" type="text/css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>JMatter Blog: Sneak Preview:  Naked Members?</title>
    <link>http://jmatter.org/articles/2006/11/29/sneak-preview-naked-members</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Simplify</description>
    <item>
      <title>Sneak Preview:  Naked Members?</title>
      <description>&lt;p&gt;A new JMatter release is overdue and coming soon!
I need to tie together the loose ends, such as
updating the documentation to reflect what's changed
(there's a lot coming!), and making sure everything
is in sync, that everything works together.&lt;/p&gt;

&lt;p&gt;This blog entry is about one of the features that
you will find in the upcoming release of JMatter:
the fact that administrators now have the ability
to view and edit Member metadata directly from the
GUI.&lt;/p&gt;

&lt;p&gt;What does this mean?  And more specifically, what 
metadata?  Let's fire up our trusty &lt;code&gt;ContactMgr&lt;/code&gt;
demo application (bundled with JMatter) and take
a look.&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig1.png" alt="A Contact"/&gt;&lt;/p&gt;

&lt;p&gt;In the above figure we're viewing a model object:
a contact.  Here's what's new:  fields'
commands are exposed in a context menu on each field's
caption:&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig2.png" alt="Field Context Menu"/&gt;&lt;/p&gt;

&lt;p&gt;Let's take a look at the "Home Phone" field:&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig3.png" alt="Home Phone Field Metadata"/&gt;&lt;/p&gt;

&lt;p&gt;Let's edit this information.  We'll customize the label 
for this field to "Home Tel.".  Let's also mark the 
field as required, specify a mnemonic, even provide 
a description (which will appear as a tooltip
on the field):&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig4.png" alt="Editing the Home Phone Meta-Info"/&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Usability side note&lt;/em&gt;:  note how the user interface for
doing all this is precisely the same mechanism used for
editing any old JMatter object.  End users (administrators
in this case) are already familiar with the gestures, how
to go about manipulating their information.&lt;/p&gt;

&lt;p&gt;Ok, let's now save our changes and dismiss the view.
We notice the changes take place immediately:&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig5.png" alt="View Changes"/&gt;&lt;/p&gt;

&lt;p&gt;Pretty neat eh?  All this information is saved to the
database, just like any other old JMatter object.
So, we now have multiple ways for designers to specify
metadata:  there are annotations and conventions in 
the code.  You can even use ultraviolet's designer
to specify graphically some of this information.  UV
will faithfully generate the proper code for you.
Here we see a different approach to code generation:
the meta objects are part of the system and as such
can be viewed, edited and managed.&lt;/p&gt;

&lt;p&gt;Ryan (the author of ultraviolet) and I have had a discussion
or two along these lines.  Perhaps some day, full design capabilities
will exist as a JMatter application proper:  Type definitions,
modeling, code generation, auto-compiling of the code, and
finally, running the application.&lt;/p&gt;

&lt;h3&gt;One more round:  Commands&lt;/h3&gt;

&lt;p&gt;We have two types of members:  fields and commands.  Let's do
for commands what we just did for fields.  Let's right-click on
a command button to expose its context menu:&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig11.png" alt="Command MetaData"/&gt;&lt;/p&gt;

&lt;p&gt;Let's open the &lt;code&gt;Edit&lt;/code&gt; command and edit some of the information
about it:&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig12.png" alt="Editing a command"/&gt;&lt;/p&gt;

&lt;p&gt;In this case, I didn't change the label or mnemonic, but I did
add a tooltip, and marked the command as &lt;em&gt;sensitive&lt;/em&gt;.  Sensitive
commands are ones that you want to guard, perhaps with a lock.
The &lt;code&gt;Delete&lt;/code&gt; command is a good candidate:  to guard against
inadvertant deletions, you have to first unlock the command
and then invoke it (a sort of &lt;em&gt;are you sure?&lt;/em&gt; mechanism).&lt;/p&gt;

&lt;p&gt;Ok, let's save the object and view the change in action:&lt;/p&gt;

&lt;p&gt;&lt;img src="/tips/nm/fig13.png" alt="Viewing the Changes"/&gt;&lt;/p&gt;

&lt;p&gt;We see here the tooltip showing.  Also, the command was
locked;  I first unlocked it before producing the above
snapshot.&lt;/p&gt;

&lt;p&gt;There you have it:  the new &lt;em&gt;Naked Members&lt;/em&gt; feature (in subversion),
available in the upcoming JMatter release.&lt;/p&gt;

&lt;h3&gt;A note on Authorization&lt;/h3&gt;

&lt;p&gt;Since these features are really design features, they're
accessible only if you login as a user with administrative
privileges.  In order to make this work, I've been hard at work
on supporting authorization in JMatter.  I've made a lot of
progress on this front, but am not completely finished.&lt;/p&gt;

&lt;p&gt;More information on authorization will follow.&lt;/p&gt;

&lt;p&gt;Let us know what you think.&lt;/p&gt;</description>
      <pubDate>Wed, 29 Nov 2006 12:36:00 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:64256ec0-c02d-4a3b-8492-c40515b06c17</guid>
      <author>Eitan Suez</author>
      <link>http://jmatter.org/articles/2006/11/29/sneak-preview-naked-members</link>
    </item>
    <item>
      <title>"Sneak Preview:  Naked Members?" by Eitan</title>
      <description>&lt;blockquote&gt;
    &lt;p&gt;&lt;em&gt;If this is your line of thinking then&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;no, it's not my line of thinking.&lt;/p&gt;

&lt;p&gt;i'm just suggesting that perhaps some aspects of development are better suited for the ide (after all, it is called a 'development' environment).&lt;/p&gt;

&lt;p&gt;typically, thinking about the tradeoffs of doing things one way or another helps me form a better opinion.  i hope that makes sense.&lt;/p&gt;

&lt;p&gt;ultimately i do believe that the domain of software development is just that:  another business domain.  and so perhaps we too can use the same type of environment we deliver our customers for doing our work.  and if that environment is not good enough, then maybe it's not good enough for our customers either and we should improve upon it.  :-)&lt;/p&gt;</description>
      <pubDate>Wed, 29 Nov 2006 23:07:09 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:66fc22bb-63fc-4274-8878-7b001100c9c6</guid>
      <link>http://jmatter.org/articles/2006/11/29/sneak-preview-naked-members#comment-13</link>
    </item>
    <item>
      <title>"Sneak Preview:  Naked Members?" by peter qwerty</title>
      <description>&lt;p&gt;"changing a field type from a gui, or directly in a text editor or ide"&lt;/p&gt;

&lt;p&gt;If this is your line of thinking then, why not leave the metadata changes you just implemeneted in the text editor rather than the gui?&lt;/p&gt;

&lt;p&gt;At the end of the day, it is cumbersome to change a few things in the gui while others in a text editor, while having a 3rd party application do other changes.&lt;/p&gt;

&lt;p&gt;The same can be said of changing properties files here while changing xml files in another place to configure your application.&lt;/p&gt;</description>
      <pubDate>Wed, 29 Nov 2006 22:51:06 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:2433b674-2cde-42d0-9609-4698329f1177</guid>
      <link>http://jmatter.org/articles/2006/11/29/sneak-preview-naked-members#comment-12</link>
    </item>
    <item>
      <title>"Sneak Preview:  Naked Members?" by Eitan</title>
      <description>&lt;p&gt;thanks!  Complete modeling/design capabilities are really the domain of UltraViolet.  and i hope that's where it'll eventually go.  actually field types can be specified in ultraviolet right now.  also, which is easier:  changing a field type from a gui, or directly in a text editor or ide?  :-)&lt;/p&gt;</description>
      <pubDate>Wed, 29 Nov 2006 22:10:02 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:ff38a1de-d31d-4f71-997e-275caf97f53c</guid>
      <link>http://jmatter.org/articles/2006/11/29/sneak-preview-naked-members#comment-11</link>
    </item>
    <item>
      <title>"Sneak Preview:  Naked Members?" by peter qwerty</title>
      <description>&lt;p&gt;Not a bad effort, but seems only limited to trivial changes - more useful if you can edit field validation rules in the gui, add fields or change the field type from string to integer.&lt;/p&gt;</description>
      <pubDate>Wed, 29 Nov 2006 21:08:26 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:363d032f-5cea-4180-bca9-3751333976a7</guid>
      <link>http://jmatter.org/articles/2006/11/29/sneak-preview-naked-members#comment-10</link>
    </item>
  </channel>
</rss>
