New Features in Domino Designer 8

Exclusive offer: get 50% off this eBook here
IBM Lotus Notes and Domino 8.5.1

IBM Lotus Notes and Domino 8.5.1 — Save 50%

Upgrade your system and embrace the exciting new features of the IBM Lotus Notes and Domino 8.5.1 platform with this book and eBook

$29.99    $15.00
by Barry Max Rosen | January 2010 | Architecture & Analysis

In this article by Barry Rosen, we will learn about the new features in Domino Designer 8 which includes:

  • Composite Applications Support
  • Domino-Based Web Service Consumers
  • Domino IBM DB/2 Integration
  • View Enhancements: New column number format, Extending to use available window width, Defer index creation until first use, Show default items in right-mouse menu
  • Form Enhancements
  • Agent Enhancements
  • Formula Language and LotusScript Additions

With the addition of composite applications to the development strategy of Notes/ Domino 8, there are a number of changes required to Domino Designer 8 to allow for composite applications design, development, and use. Some additional new tools were also required.

These changes augment existing functionality. They were made without sacrificing supportability of existing applications. They allow legacy applications as well as new applications to play a part in an SOA by providing a platform that permits multiple technologies to be combined into a single application, side by side.

Composite applications support

New Domino Designer 8 features that support composite applications include the Property Broker Editor and the Composite Application Editor.

Property Broker Editor

One of the first things you will notice in Domino Designer 8 is the new support for composite application design elements. These design elements store the WSDL and XML files for wiring properties and applications. You can see these new design elements by selecting the Composite Applications item in the view.

New Features in Domino Designer 8

The Wiring Properties view is where Domino Designer stores the WSDL that defines the properties, types and actions for the application. These design elements are edited with the Property Broker Editor, which is new in Domino Designer 8. To edit wiring properties, select the wiring property from the new Notes 8 mail template and click the Open File button. This will bring up the Property Broker Editor.

New Features in Domino Designer 8

The Property Broker Editor allows you to create or edit the Properties , Types, or Actions for your applications. Once the Property Broker Editor has saved the WSDL as a design element, you will be able to associate the defined properties and actions with other design elements.

Composite Application Editor

Also within the Composite Applications view within Domino Designer 8, is the Applications listing. These design elements store the XML that defines the makeup of the composite applications and their associated wiring.

However, launching the Composite Application Editor is not done via the Domino Designer interface and may confuse new composite application developers. To launch the Composite Application Editor, open Notes and then select Actions | Edit Application.

New Features in Domino Designer 8

Once the Composite Application Editor is open, you can select a component and then edit the wires for this component.

New Features in Domino Designer 8

The illustration above shows the wiring properties for the Notes Calendar Navigator component.

Web service consumers

Web services were supported starting with Notes/Domino 7. However, the web services supported with Domino 7 could only be web service providers. They could be called as a normal web service from a remote computer and return information from Domino databases, or perform other Domino-related functions. It was also possible in release 7 to write web service consumers and have them hosted by Domino, but there was no specific support for web service consumers within Domino and creating them was a matter of Java development.

With the release of Notes and Domino 8, Domino-based web service consumers are supported. Notes/Domino applications can now call web services hosted on remote computers. Notes/Domino 8 makes it simple to call web services. Domino Designer will even import the WSDL and create the code required to use the web service for you.

Unlike web service providers in Domino, which are stored in special design elements, web service consumers in Domino 8 are stored in a special type of script library. This script library can be written in either Java or LotusScript. Just as with other script libraries, code that wants to use the web service consumer must use the script library that contains it.

Consuming a web service in Notes/Domino 8 is very simple. The high level steps are:

  1. Locate a web service that you would like to consume and acquire its WSDL file.
  2. Create a new script library to contain the web service consumer.
  3. Import the WSDL file into the new script library.
  4. Have your application call the script library so as to consume the web service.

For this example, we have selected a free stock quote web service that retrieves 20-minute-delayed quotes from Yahoo. The web service description and its WSDL file are located here:
http://www.webservicelist.com/webservices/f.asp?fid=37722

We will create a script library to contain the web service, create a form with a simple button to prompt the user for a company symbol, and then call or consume the web service and display the resultant stock quote.

New Features in Domino Designer 8

Once you have selected a web service to consume and have its WSDL file, you need to create a new script library to contain the web service code. Create a new application, and select Create | Design | Script Library. Select either LotusScript Library or Java Library depending on your language of choice. For this example, we will create a LotusScript Library. Save the script library and provide a name for it when prompted. For this example, we called the script library stockquote. Keep this script library open.

New Features in Domino Designer 8

You now have a new, empty script library. At the bottom of the code window in Domino Designer, you will see a button labeled WSDL. This button will allow you to import the WSDL file that describes the web service that you are going to consume and also generate the code for consuming this web service. This will save you a lot of time going through the WSDL file and crafting your classes!

Import the WSDL file that you downloaded for your selected service. Notice that Domino Designer generates the class required to consume the web service.

For the free stock quote service selected, the generated LotusScript code looks like this:

New Features in Domino Designer 8

Notice that Domino Designer did the hard work of decoding the WSDL file to create a class with functions to consume the web service. If you like, you may even decide to modify the generated code so as to make it a bit more readable—for example, by changing the class name.

It is a good idea at this time to inspect the code that was generated and become familiar with it. In this example, we can see the generated LotusScript created a class called NetxmethodsservicesstockquoteStockQu_n0 and a function called getQuote. Domino Designer got these values from the WSDL file that was imported. We will use the class name and the function name later within our button that will call the script library that consumes the web service.

Now, all we need is some code to consume the web service via the special web services enabled script library that we just created. To keep things simple, let's create a button on a form that will prompt the user for a stock symbol and then display the results.

Create a blank form. Within the Globals section of the form, place the following code, which disallows implicit variable declarations (a good practice) and identifies the script library stockquote as used within the form:

Option Public
Use "stockquote"

New Features in Domino Designer 8

On the same form, create a new button. Give the button a clever label like Get a stock quote, and then insert the code (as seen in the previous screenshot) into the button:

Save the form, and then open the application. Create a new instance of the form that contains the button.

New Features in Domino Designer 8

Now click on the button to invoke the code within it. You will be prompted to enter the stock symbol whose quote you would like to retrieve via the web service. For this example, we selected my favorite hamburger chain.

New Features in Domino Designer 8

When you click on OK, Notes will execute the code so as to invoke and consume the web service. Once that has been done, Notes will then process the Messagebox call so as to present the results.

New Features in Domino Designer 8

This is obviously a very simple example of consuming a web service, but it should open your mind to the possibilities. There are web services available for almost anything you can imagine. Some are free and others are available for a fee. You can use web services to retrieve grocery items by UPC number, perform credit card transaction processing, and even track packages shipped with FedEx or UPS.

Now that Notes/Domino 8 can consume web services, you have another data integration tool at your disposal.

Domino IBM DB/2 integration

The ability to use DB/2 as an alternative backend storage system for Domino was available in Domino 7 as a trial feature and also via a limited availability program. With the release of Notes/Domino 8, the integration with DB 2 will be generally available on certain Windows, IBM AIX, and Linux operating systems.

Using this integration, you can make data within your Domino databases available for use by relational database tools and show external relational data within Notes/Domino views and embedded views.

View enhancements

Domino Designer 8 view enhancements include new column number formats, extended to use available window width, defer index creation until first use, and show default items in right-mouse menu.

New column number format

There is a new number format for number columns that will display the column contents in kilobytes, megabytes, or gigabytes, which makes it much easier to determine the relative size of the number represented in the column. In this example, the size of file attachments is used.

New Features in Domino Designer 8

When displayed in Notes 7, the column shows just the size of the attachment for each document.

However, when the same column is displayed in Notes 8 with the Bytes (K/M/G) number format, the column displays a much friendlier format.

New Features in Domino Designer 8

Extending to use available window width

In Notes 8, you can select which column within a view will expand to utilize the available width of the window. In previous releases, this option was only available for the last column in a view.

New Features in Domino Designer 8

For this option to work, the view level option Extend last column to window width takes precedence and must be deselected. In addition, the column to be extended must be marked as Resizable. Multiple columns can be designated to extend to use the available window width. However, only the first column, which has this attribute set, will expand.

Defer index creation until first use

Index creation can now be deferred for Click on column header to sort view columns. Using this option, the view index won't be created until a user first clicks on the column to sort it. Only views that users click to sort will have their indexes built. This can help reduce the load on servers, as not all column indexes will be created automatically. They will only be created when they are used.

New Features in Domino Designer 8

Note that the deferred index creation feature requires the database to be using the new ODS (On-Disk Structure) for Notes/Domino 8. By default, Notes/Domino 8 still creates databases with ODS 43, which was introduced in release 6 and used through releases 7 and 8. To enable the creation of databases in ODS 48 format, use the Create_R8_Databases=1 Notes.ini parameter on the Domino 8 server or the Notes 8 client.

Show default items in right-mouse menu

Developers have been able to add custom actions to the right-mouse menu with previous versions of Notes/Domino. With release 8, you can choose not to have the default right-mouse menu items shown in the menu, allowing just the menu items you select to be displayed.

New Features in Domino Designer 8

The default is to show just default items. The picture above shows that we have deselected the option, allowing only the actions that we select to be shown in the menu. This will make it easier for the end user of the application to find the actions we have defined for the view or folder.

IBM Lotus Notes and Domino 8.5.1 Upgrade your system and embrace the exciting new features of the IBM Lotus Notes and Domino 8.5.1 platform with this book and eBook
Published: January 2010
eBook Price: $29.99
Book Price: $49.99
See more
Select your format and quantity:

Form enhancements

There is a new rich text lite field option that allows you to add a thumbnail picture to a form. This new feature is used in the Notes/Domino 8 address book templates. For example, in the personal address book template, you can add pictures of your contacts to their contact records. This is handy to help remember the face that goes with the name.

To add the thumbnail picture to a contact note in Notes 8, edit the contact record, click on the import icon, and select the picture.

New Features in Domino Designer 8

Once the picture has been selected, it will be displayed in place of the import button.

New Features in Domino Designer 8

To delete the picture, you should edit the document, select the thumbnail, and press the Delete key.

To enable thumbnails in your rich text lite field, select the second tab of the properties box, and then select Thumbnail in the Only allow selection field. When Thumbnail is selected, all of the other options will automatically be deselected for you. Also, you may only select Thumbnail in the First display property.

New Features in Domino Designer 8

You can also have Notes resize the thumbnail image by selecting the Width and Height in pixels.

Agent enhancements

Agents can now be tagged so as to determine when the server starts. These agents will start the server a few minutes after the Domino server boots up. They should not be relied upon to start immediately.

Agents triggered to start when the server starts will not run when just the agent manager itself is restarted. They will only run when the entire Domino server is started. This allows agents to perform actions that should only occur after a server has started and not be repeated each time agent manager starts up.

To trigger an agent this way, select When server starts for the On event trigger type.

New Features in Domino Designer 8

Agents that are triggered when the server starts can also be given dates to start and stop running. This could be helpful if the agent is implementing a date-driven business process.

To edit these agents' schedule properties, click the Edit settings button on the Agent properties box.

New Features in Domino Designer 8

Formula language and LotusScript additions

Domino Designer 8.5 includes several enhancements to formula language and LotusScript.

Formula language additions

The following are some selected new commands that are available within Notes/Domino 8.

@Command([CopySelectedAsTable]): This new command performs the same action as its menu command counterpart, Edit | Copy As | Table, which copies one or more selected view entries into a table. It places the table of the selected view entries on the clipboard. It also includes a link to each of the documents in the table. This is very useful when sending co-workers links to documents from a database in a preformatted table.

@Command([OpenInNewWindow]): This new command allows your formula language code to open a document from a view, folder, or calendar in a new window instead of opening it within a new tab within Lotus Notes.

LotusScript additions

The following are some selected new classes, methods, and events available within Notes/Domino 8. The NotesProperty and NotesPropertyBroker classes, and the Onselect event were added to support the new composite application-programming model.

MarkAllRead and MarkAllUnread methods: Finally, within the NotesView, NotesViewEntryCollection, and NotesViewNavigator classes, two new methods dealing with read/unread marks are available. Using these classes, you can mark documents as having been read or unread using the MarkAllRead or MarkAllUnread methods. These methods will affect the documents within the collection or navigator. There are, of course, Java counterparts available.

NotesDirectory class: Objects created with this new class correspond to the directories on a specific Domino server or Notes client. The objects are contained within a NotesSession object, and they contain one or more NotesDirectoryNavigator objects. The following properties are available in the NotesDirectory class. Unless otherwise specified, these properties are read-only.

Property

Type

Description

AvailableItems

 

Variant array

 

This property is set by the methods LookupNames and LookupAllNames. If a NotesDirectory object has been created but no lookups have been performed with it, this property will be null.

AvailableNames

 

Variant array

 

This property will contain the names returned from the most recent LookupAllNames or LookupNames call. If a NotesDirectory object has been created but no lookups have been performed with it, this property will be null.

AvailableView

 

String

 

This property contains the name of the view specified in the most recent LookupAllNames or LookupNames call. If a NotesDirectory object has been created but no lookups have been performed with it, this property will be null.

GroupAuthorizationOnly

Boolean

 

Read/write property. This property controls which directories will be used during lookups. If the property is True, only directories marked "Enable for Group Authorization" will be searched. If set to False, the default lookups performed will search all directories available.

LimitMatches

 

Boolean

 

Read/write property. If True, directory lookups will be limited to fifty entries. If False then lookups performed will return all matches.

PartialMatches

 

Boolean

 

Controls whether or not lookups will match on partial names. If True, partial names will match. If False, the default, lookups will not match on partial names.

SearchAllDirectories

 

Boolean

 

Read/write property. If True, the default, all directories will be searched during lookups. If False, lookups will cease after the first directory containing the view name specified.

Server

 

String

 

This property contains the name of the server represented by the instance of NotesDirectory.

 

TrustedOnly

 

Boolean

 

Read/write property. This property controls which directories will be used during lookups. If True, lookups will search only directories which contain trust information. If False, the default, the lookups will search all directories.

UseContextServer

 

Boolean

 

Read/write property. This property controls whether the server of the context database or the server specified in the lookup methods will be used. If True, the server context database will be used. If False, the default, and then the server specified in the lookup method will be used.

The following methods are available for the NotesDirectory class.

Method

Returns

Description

CreateNavigator

 

NotesDirectoryNavigator

 

Used to create additional DirectoryNavigators to allow multiple DirectoryNavigators to be used.

FreeLookupBuffer

 

N/A

 

Since the resultant name lookup buffers can be quite large, this method can be used to free memory in the current lookup buffer, in effect resetting all navigators. Used for memory management.

LookupAllNames

 

NotesDirectoryNavigator

 

Performs a lookup of designated items contained within the specified view.

LookupNames

 

NotesDirectoryNavigator

 

Performs a lookup of designated items contained within the specified view for the specified items.

NotesDirectoryNavigator class: NotesDirectoryNavigator objects are returned by methods of the NotesDirectory class and allow the developer to navigate the items returned by a directory search. The following properties are available for the NotesDirectoryNavigator class. Unless otherwise specified, these properties are read-only.

IBM Lotus Notes and Domino 8.5.1 Upgrade your system and embrace the exciting new features of the IBM Lotus Notes and Domino 8.5.1 platform with this book and eBook
Published: January 2010
eBook Price: $29.99
Book Price: $49.99
See more
Select your format and quantity:

Property

Type

Description

CurrentItem

 

String

 

This property will contain the current item for the NotesDirectoryNavigator and is updated with subsequent calls of GetNextItemValue and GetNthItemValue methods.

CurrentMatch

 

Long

 

An index to the current match for the NotesDirectoryNavigator and is updated by subsequent calls to FindFirstMatch, FindNextMatch and FindNthMatch methods.

CurrentName

 

String

 

The name of the current match indicated by the CurrentMatch property index for NotesDirectoryNavigators created with the LookupNames method.

CurrentView

 

String

 

Contains the name of the directory view used to create the NotesDirectoryNavigator object. This property is updated when directory lookups are performed.

MatchLocated

 

Boolean

 

If True, a match was successful. If False, the match was not successful.

NameLocated

 

Boolean

 

If True, a name was located. If False, the name was not located.

The following methods are available for the NotesDirectoryNavigator class.

Method

Returns

Description

FindFirstMatch

 

Boolean

 

Moves the navigator of the first match of the current name in the NotesDirectoryNavigator. Returns True if a match was found otherwise returns False indicating no match was found.

FindNextMatch

 

Boolean

 

Moves the navigator of the next match of the current name in the NotesDirectoryNavigator. Returns True if a match was found otherwise returns False indicating no match was found.

FindNthMatch

 

Boolean

 

Moves the navigator of the nth match of the current name in the NotesDirectoryNavigator. Returns True if a match was found, otherwise returns False indicating no match was found.

FindFirstName

 

Long

 

Moves the navigator to the first name in the NotesDirectoryNavigator returning the number of matches found.

FindNextName

 

Long

 

Moves the navigator to the next name in the NotesDirectoryNavigator returning the number of matches found.

FindNthName

 

Long

 

Moves the navigator to the nth name in the NotesDirectoryNavigator returning the number of matches found.

GetFirstItemValue

 

Variant

 

Returns the value of the first item of the current match.

GetNextItemValue

 

Variant

 

Moves the navigator to the next item within the current match and returns the value of that match.

GetNthItemValue

 

Variant

 

Moves the navigator to the nth item within the current match and returns the value of that match.

NotesProperty class: This class represents a single component property within the composite application. Component properties are data items that a given component produces and the NotesProperty class allows your application to manage the publishing of the defined properties within an application.

The methods for the NotesProperty class are only active when used within the Notes 8 Standard configuration. They are not available when used by applications running on Domino server or from within the Notes 8 Basic configuration. The following properties are available for the NotesProperty class. Unless otherwise specified, the properties are read-only.

 

Property

Type

Description

Description

 

String

 

This class property returns the description for the NotesProperty object.

IsInput

 

Boolean

 

If True, the property is an input property. If False, the property is an output property.

Name

 

String

 

This class property returns the name of the NotesProperty.

NameSpace

 

String

 

This class property returns the namespace for the NotesProperties data type.

Title

 

String

 

This class property returns the title of the NotesProperty.

TypeName

 

String

 

This class property returns the type name of the NotesProperty. When combined with the NameSpace property, it provides a unique identifier for the NotesProperty type.

Values

 

Variant array of Strings, Integer, Real, or NotesDateTime

 

This read/write class property sets or returns the array of values for the NotesProperty. The array items must be of all the same data type and input properties by definition cannot be set using this property. The Publish method must be called after using this property to set values or the values will not persist.

 

The following methods are available for the NotesProperty class.

Method

Returns

Description

Clear

 

N/A

 

For output properties only, this method clears the new or modified values of the specified property from the temporary cache used for publishing via the property broker. If called from an input type NotesProperty the method will have no effect.

Publish

 

N/A

 

Publishes to the property broker the new values for the NotesProperty object.

NotesPropertyBroker class: The following properties are available for the NotesPropertyBroker class. This is where all the composite application magic occurs in Notes/Domino 8.

The current implementation of the property broker for Notes/Domino 8 only supports a single input property. The InputPropertyContext is, however, declared as an array to allow for future expansion of the property broker to support multiple input properties in the future.

Unless otherwise specified, the properties are read-only.

Property

Type

Description

InputPropertyContext

 

Array of NotesProperty

 

Returns an array of NotesProperty objects, with only the first item of the array populated.

The methods for the NotesPropertyBroker class are only active when used within the Notes 8 Standard configuration. They are not available when used by applications running on Domino server or from within the Notes 8 Basic configuration.

The following methods are available for the NotesPropertyBroker class.

Method

Returns

Description

ClearProperty

 

N/A

 

Clears the new or modified values of a specified property from the temporary cache used for publishing.

GetProperty

 

NotesProperty

 

Returns a NotesPropery object for a specified property.

GetPropertyValue

 

Variant array of String, Integer, Real, or NotesDateTime

 

Returns the value of a specified input property. Used when implementing an action.

HasProperty

 

Boolean

 

If True, the specified property is associated
with the property broker. If False, the property broker does not have a property with the specified name.

Publish

 

N/A

 

If values of the NotesPropertyBroker have been modified, this method will publish them.

 

SetPropertyValue

 

NotesProperty

 

Returns a NotesProperty object with the value of a specified output property.

Onselect event: This new event was added to the NotesUIView class to give developers the trigger needed to have other components respond to selected documents within a view. The Onselect event is used to contain code that publishes properties to the property broker based on the documents selected.

Summary

In this article by Barry Rosen, we learnt about the new features in Domino Designer 8 which includes:

  • Composite Applications Support
  • Domino-Based Web Service Consumers
  • Domino IBM DB/2 Integration
  • View Enhancements: New column number format, Extending to use available window width, Defer index creation until first use, Show default items in right-mouse menu
  • Form Enhancements
  • Agent Enhancements
  • Formula Language and LotusScript Additions

About the Author :


Barry Max Rosen

Barry Rosen is an IBM Senior IT Certified Managing Consultant with IBM Software Services for Collaboration . During the last six years, he has worked on several global messaging and migration projects as well as performing Domino upgrades, messaging assessments, and client deployments. Currently, Barry is heavily involved in IBM SmartCloud for social business migrations and hybrid deployments. Prior to IBM Software Services for Collaboration, he was a Software Engineer in Lotus Support for over five years. While in support, Barry was on several teams specializing in mail routing, Lotus Notes Client, calendaring and scheduling, and server core. Barry is an SME on clustering, Lotus Notes for Macintosh, and rooms and resources. He is also a published author with several articles and books written on Lotus products.

Books From Packt

Maximize Your Investment: 10 Key Strategies for Effective Packaged Software Implementations
Maximize Your Investment: 10 Key Strategies for Effective Packaged Software Implementations

Backbase 4 RIA Development
Backbase 4 RIA Development

IBM Cognos 8 Planning
IBM Cognos 8 Planning

SAP Business ONE Implementation
SAP Business ONE Implementation

Oracle SOA Suite Developer's Guide
Oracle SOA Suite Developer's Guide

RESTful PHP Web Services
RESTful PHP Web Services

ASP.NET 3.5 Application Architecture and Design
ASP.NET 3.5 Application Architecture and Design

SOA Governance
SOA Governance

No votes yet

Post new comment

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
t
8
u
D
7
D
Enter the code without spaces and pay attention to upper/lower case.
Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software