Friday, 25 March 2011

Maestro 3.0: A comprehensive walkthrough (part 2)

Here's part 2 of the comprehensive walkthrough for Maestro 3.0. This part will showcase the meat of the Maestro application: The resource editors

New Resource Dialog

Creating a new resource in previous versions of Maestro required navigating some menus. For this release, I've taken a different approach:

The design is heavily inspired by Microsoft Visual Studio (It's what I used almost every day!). As you can see, new resource templates are grouped by category. (Note: This dialog will get some tweaks for the next beta)

The dialog is version aware. For example, say you are connecting to a MapGuide Open Source 1.2 server, you will not see the Application Definition resource template as that did not exist in that version. Simply put, you can only create resources that can be supported by the version of MapGuide you are connecting to.

Load Procedure Editor

Load Procedure Support debuted in the previous version, with support for bulk loading SDF and SHP files into MapGuide. For this version, I've added extra support for loading SQLite files (MGOS 2.2/MGE 2011 and newer only) and DWF files. However the same limitations apply from the previous version:
  • No SDF2 to SDF3 conversion support
  • No convert to SDF support
  • No generalization support
  • No DWG support (Not gonna happen)
  • No raster support (Very unlikely to happen)
Despite these limitations, the bulk loading options have been expanded should you need to do a "quick and dirty" loading of data into MapGuide.

As for the user interface, it's still pretty much the same as before

You may be wondering that that pale yellow bar is.

When you open a resource in MapGuide Studio, it will silently upgrade that resource to the latest schema version. This is okay sometimes as your resource can immediately take advantage of any new features exposed in the latest schema version. However if you were to package this data up and load it into an older version of MapGuide, chances are it will fail because it won't recognise your silently upgraded resources.

Maestro on the other hand, will always open the resource as-is. It will never silently upgrade your resources. So suppose we actually do want to upgrade an edited resource, how can we find out if it's upgradeable? Enter the yellow notification bar.

The bar will show if you open a resource and Maestro has determined that a newer version of this resource is supported. You may notice the Upgrade button is disabled. This is because it is currently not implemented yet, but it should give you a clear idea of how I intend for this notification bar to work.

One final thing to note about this bar is that all resource editors support this feature.

Feature Source Editor

The Feature Source editor has had a major makeover from the previous version:

This screenshot is of the SDF feature source editor. Most commonly-used FDO providers have a specialized feature source editor for them, but just like I've done with FDO Toolbox there is a generic editor fallback for lesser known or used providers.

The editor is for the most part similar to its MapGuide Studio counterpart, but if you look down below:

You can launch the Feature Source Preview tool to take a more fine-grained look at the data in that Feature Source. This space will be reserved for other feature source centric tools and functionality in the future.

Layer Definition Editor

The Layer Defintion hasn't changed much. The outer shell has changed but the meat of the editor (all those controls and dialogs to edit the various aspects of the Layer Definition) remains the same. One thing to note is that this does cleanly support all versions of the Layer Definition schema unlike the previous version of Maestro.

Map Definition Editor

Here's another editor that's been given another makeover in the visual department

Functionality-wise, there's nothing much to write home about. It does the same thing as the previous version did, only in more productive ways. For example, you can now drag/drop multiple layers into the editor and you can drag/drop reorder and reorganise layers as well. It beats using those up/down arrows to reorder layers!

Web Layout Editor

The Web Layout Editor has also had a makeover

But one particularly useful feature in this version (which didn't exist in previous versions of Maestro or MapGuide Studio) is down below

For those who can't see it. The Web Layout editor allows you to export your custom commands to a XML file, which can then be easily transferred to another layout by importing this XML file. Now you have an easy mechanism to move your custom commands between Web Layouts!

Print Layout Editor

New in this version is a specialized editor for Print Layouts

I don't really know if this resource is used that much, but given the schema is actually quite simple to create an editor for, I'm surprised that it took this long for such an editor to finally spring up, but here it is at long last!

Fusion Editor

Frankly, I didn't use the Fusion editor in the previous version of Maestro that much because I didn't really use Fusion itself that much. But I've been exposed to Fusion more and more in my line of work, and subsequently finding out the Fusion editor in the previous version wasn't up to snuff, the Fusion Editor in Maestro also received an overhaul

Unlike the editor in MapGuide Studio with its bajillion different tabs, the Fusion Editor in Maestro is simplified into 4 main areas:
  • Template selection
  • Map Group management
  • Container management of widget references
  • Widget management and configuration
The main editor covers the first 3, a Widget Management dialog (accessible via the cog icon in the Widgets toolbar) covers the 4th.

A fair chunk of widgets have specialized editors. But for those that don't, there's always the XML editor fallback

One thing to note as well. If you delete a widget here, it will also remove all widget references from all containers. Because one thing Maestro will always strive do is to preserve the integrity of your resources.

Other Resources

What about Symbol Libraries? Unfortunately, symbol libraries use a DWF file as a backing store and there is no portable .net library out there to manipulate DWF files. So a specialized editor will never happen.

What about Symbol Definitions? Well this is what we all should be using instead of Symbol Libraries, but having not used Symbol Definitions much myself and not being intimately familiar with the Symbol Definition schema has meant that I haven't really been able to quite figure out what is the best user interface for this type of resource. I'll get something happening on this eventually so watch this space.

What about Watermarks? Well this new resource type just came out! Those on Autodesk subscription will soon be receiving their copy of the next MapGuide Enterprise (ahem! I mean: Autodesk Infrastructure Map Server 2012) and will have an updated MapGuide Studio (ahem! I mean: Autodesk Infrastructure Studio) that can create and edit this new type of resource. For us open source folks, the next release that will have Watermark support is quite some time away. That means I'll have plenty of time to get the proper support in.


One of the standout features of Maestro over MapGuide Studio is the ability to validate resources. Validation is one of the easiest ways to detect common problems with your MapGuide repository (eg. Broken resource references, Layers referencing non-existent feature classes)

In this release, I've added many more validation rules. In fact each validation rule now comes with an error code attached, allowing users of the Maestro API to programatically act against validation failures.

Stay tuned for part 3. Where I dive deep into the internals of the Maestro API.

No comments: