Professional Documents
Culture Documents
Guide
HP OpenView Integration Series
Windows NT Operating System, HP-UX, and Solaris
Legal Notices
Hewlett-Packard makes no warranty of any kind with regard to this
manual, including, but not limited to, the implied warranties of
merchantability and fitness for a particular purpose. Hewlett-Packard
shall not be held liable for errors contained herein or direct, indirect,
special, incidental or consequential damages in connection with the
furnishing, performance, or use of this material.
Warranty. A copy of the specific warranty terms applicable to your
Hewlett- Packard product and replacement parts can be obtained from
your local Sales and Service Office.
Restricted Rights Legend. All rights are reserved. No part of this
document may be photocopied, reproduced, or translated to another
language without the prior written consent of Hewlett-Packard
Company. The information contained in this document is subject to
change without notice.
Use, duplication or disclosure by the U.S. Government is subject to
restrictions as set forth in subparagraph (c) (1) (ii) of the Rights in
Technical Data and Computer Software clause at DFARS 252.227-7013
for DOD agencies, and subparagraphs (c) (1) and (c) (2) of the
Commercial Computer Software Restricted Rights clause at FAR 52.22719 for other agencies.
HEWLETT-PACKARD COMPANY
3404 E. Harmony Road
Fort Collins, CO 80528 U.S.A.
Use of this manual and flexible disk(s), tape cartridge(s), or CD-ROM(s)
supplied for this pack is restricted to this product only. Additional copies
of the programs may be made for security and back-up purposes only.
Resale of the programs in their present form or with alterations, is
expressly prohibited.
Copyright Notices. Copyright 1983-2000 Hewlett-Packard Company,
all rights reserved.
Reproduction, adaptation, or translation of this document without prior
written permission is prohibited, except as allowed under the copyright
laws.
Contains software from AirMedia, Inc.
Contents
Contents
100
100
103
109
114
Contents
Contents
158
159
159
160
168
168
168
169
169
Creating Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Using the FRF versus the API to Create Fields . . . . . . . . . . . . . . . .
Creating Fields Programmatically. . . . . . . . . . . . . . . . . . . . . . . . . . .
Converting between Field Names and Field IDs . . . . . . . . . . . . . . .
Defining Enumeration Values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Retrieving Field Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Predefined Fields. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
170
170
170
171
172
173
175
Creating Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
The Field Value Data Structures . . . . . . . . . . . . . . . . . . . . . . . . . . . .
The Selection Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Creating an Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Generating Unique Names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Creating Objects by Hostname or Selection Name . . . . . . . . . . . . . .
176
176
178
179
181
181
Contents
Contents
218
218
219
220
229
229
229
230
10
246
246
252
254
259
Contents
11
Contents
300
300
302
306
307
316
317
319
320
321
321
Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 324
9. Supporting Management Consoles
Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327
Server File Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329
OVW Server Identification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329
Communication with Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 330
Distributed OVw API . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
Connecting to a Remote GUI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
The Application Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
12
Contents
13
Contents
361
361
361
362
389
389
389
390
391
395
395
396
398
399
402
14
Contents
15
Contents
16
Figures
17
Figures
18
Tables
19
Tables
20
366
379
387
389
390
391
443
448
Conventions
The following typographical conventions are used in this manual.
Font
Example
To provide emphasis.
Bold
Computer
Italic
/usr/bin/X11
Process names.
Computer
Bold
Keycap
Keyboard keys.
Press Return.
[Button]
Menu
Items
Select Locate:Objects->by
Comment
21
Contact Information
Technical Support Technical support information can be found on the HP OpenView World
Wide Web site at:
http://www.hp.com/openview/support.html
________________________________
Documentation
Feedback
Training
Information
22
23
24
Chapter 1
Chapter 1
25
26
Chapter 1
Chapter 1
27
28
Chapter 1
NOTE
Chapter 1
29
30
Chapter 1
OVwwwIntro
OVwEventIntro(5)
OVwRegIntro(5)
LauncherRegIntro
NetworkPresenterRegIntro
Chapter 1
31
32
Chapter 1
Chapter 1
33
34
Chapter 1
Chapter 1
35
36
Chapter 1
Summary
Developers need to make use of two major components to implement HP
OpenView Windows applications: registration files and the OVw API.
Registration files are used to statically configure HP OpenView Windows
behavior. Developers can control application process behavior and menus
with the application registration file. The symbol type registration file is
used to define new symbol classes and subclasses, while the field
registration file is used to define new fields in the OVW object database.
Many applications can be integrated into HP OpenView Windows using
only the registration files.
The OVw API is required to implement more sophisticated
HP OpenView Windows applications. The OVw API contains over 200
routines and callback definitions, which allow you to control all aspects
of an applications behavior. The OVw API is the subject of much of the
rest of this manual.
Last, the HP OpenView Application Style Guide provides
recommendations for application consistency. Developers are expected to
consult the style guide as they are developing HP OpenView Windows
applications.
Chapter 1
37
38
Chapter 1
39
40
Chapter 2
Overview
This chapter explains how to:
support internationalized and localized user interface components
integrate applications into the HP OpenView user interface using
application registration files
define graphical symbols using symbol type registration files
define fields for objects using field registration files.
This chapter introduces the registration files, complete with some simple
examples. If you need more information, refer to the OVwRegIntro(5),
LauncherRegIntro(5), and NetworkPresenterRegIntro(5) reference pages.
Table 2-1 lists the locations for registration files.
Table 2-1
Platform
Registration
File
Pathname
UNIX systems
Application
/etc/opt/OV/share/registration/$LANG
Symbol
/etc/opt/OV/share/symbols/$LANG
Bitmap
/etc/opt/OV/share/bitmaps/$LANG
Field
/etc/opt/OV/share/fields/$LANG
Launcher
/etc/opt/OV/share/www/registration/launcher/
$LANG
Network
Presenter
/etc/opt/OV/share/www/registration/jovw/
$LANG
Application
\OpenView\registration\$LANG
Windows NT
operating system
Chapter 2
41
Pathname
Symbol
\OpenView\symbols\$LANG
Bitmap
\OpenView\bitmaps\$LANG
Field
\OpenView\fields\$LANG
Launcher
\OpenView\www\registration\jovw\$LANG
Network
Presenter
\OpenView\www\registration/launcher\$LANG
1. $LANG represents the language preference of the user. $LANG can be set as
an environment variable on UNIX systems. On Windows NT operating
system the end user sets the language preference via the Control Panel. In
this book $LANG is represented as an environment variable.
42
Chapter 2
Chapter 2
43
44
Chapter 2
Chapter 2
45
Chapter 2
Chapter 2
47
Application Block
Applications integrate into HP OpenView using a structure in an ARF
called an application block. Each ARF contains a single application block
that represents a single application. An application can be defined only
once, and its name must be unique.
Registration file entries use a C-like syntax. The application block has
the syntax:
Application "application_name"{
/*
**APPLICATION DESCRIPTION
*/
DisplayString "localizable string for application name";
Version "localizable string";
Description {
"localizable string for application information",
"localizable string for application Information"
48
Chapter 2
/*
**NAME FIELD STATEMENT
*/
NameField "name", "name";
/*
** MENU BLOCK
*/
MenuBar <precedence> "localizable menu_name" _mnemonic
{
<precedence> "localizable menuItem"
Context (context_expression)
f.action "actionId";
<precedence> "localizable menuItem"
Context (context_expression)
f.menu "menuId";
}
Menu "menuId"
{
<precedence> "localizable menuItem" _mnemonic
Context (context_expression)
f.action "actionId";
}
/*
** ACTION BLOCK
*/
Chapter 2
49
50
Chapter 2
Chapter 2
51
Global Statements
Field
If Not Registered
Overrides
Description
None
Version
None
Copyright
None
DisplayString
None
Command
Optional
Action Statements
HelpDirectory
None
NameField
Optional
Namefield in Action
Statements
Application Description
At run-time, end users can view an applications version string,
description, and copyright by selecting the Help -> About OpenView and
clicking on the [Applications] button. For this information to be
displayed properly, it must be preconfigured in the ARF.
The version is specified as a string in a Version section. The
applications purpose is specified in a Description block. The copyright
is defined in a Copyright block. The following example demonstrates:
/*
52
Chapter 2
The version string text must be a single line. The Description and
Copyright blocks are composed of one or more text strings separated by
commas. All of these strings may be localized. For example, if your
application will be run in German language mode, these strings would be
specified as German text.
Command
The Command section lists the complete command line used to invoke an
application. By being defined at the application block level, the command
is considered global. In other words, the application command will be
invoked the same way every time, even if the user selects the application
in different ways. Regardless of whether the user selects the application
through a menu item or through an executable map symbol, this
command will be used to invoke the program.
As you will see later, commands can also be defined on an individual, per
action basis. This allows applications to be invoked in slightly different
ways (for example, with different arguments) depending on the
particular user selection. Per-action commands will be discussed later in
Defining Actions on page 78.
Commands are delimited by quotes as shown in the following format
statement. Programs that are non-GUI applications, such as console
applications (Windows NT operating system) or tty-based applications
(UNIX systems), must be run in a console window on the Windows NT
operating system or an X terminal on UNIX systems.
The form for a command statement is:
Chapter 2
53
You should use the full path to the command although part of the path
may be an environment variable such as $OV_MAIN/bin/mailmgr. The
following example illustrates a command declaration for UNIX systems:
Application "editor" {
Command "xterm -e /usr/bin/vi";
..
}
Three flags are defined: Initial, Shared, and Restart. Table 2-3
describes their use.
Table 2-3
Process Flag
Purpose
Initial
Tells ovw to start the application when ovw is started. The application will be
invoked by the command specified in the <command string>.
Shared
Tells ovw that only a single instance of this application command should be
running at any time. Further, this application instance will be shared, servicing
multiple action requests.
54
Chapter 2
Process Flag
Restart
Purpose
Tells ovw to restart the application if it should ever exit. This flag is intended for
applications that are required for normal NNM operation, such as those managing
the semantics of NNM maps.
Environment Variables HP OpenView provides a run-time
environment for applications. This run-time environment allows
applications to access values set for NNM environment variables.
Applications have access to a number of key items, including the menu
items used to invoke the application and the object selection list.
These environment variables can appear on the command line that
invokes the application. This example demonstrates a command that is
invoked with the first element in the selection list:
Application "Telnet" {
...
Command "/usr/bin/telnet $OVwSelection1";
...
}
Table 2-4 shows the environment variables that are available for your
use.
Table 2-4
Environment Variables
Purpose
OVwSelections
OVwNumSelections
OVwSelectionn (n=1...10)
OVwActionID
Chapter 2
55
Environment Variables
Purpose
OVwMenuItem
OVwAppName
This is the name of the application that has started and is connecting
to a GUI server.
OVServer
This is the name of the object database server host that stores the
map database and runs the object database daemon.
OVwSessionID
Chapter 2
Chapter 2
57
In this example, the command would be enabled only if all objects in the
selection list have an IP Hostname name field. The command would be
invoked using the first object in the selection list as an argument.
Menu Registration
A key feature of HP OpenView is its ability to integrate network and
systems management applications with common menu and tool bar
interfaces. This is accomplished through the application registration file.
This section shows you how to integrate applications into Network Node
Manager menus by adding pull-down menu items, symbol pop-up menu
items, and tool bar buttons. Their specifications in the ARF are similar.
All text labels for menu and tool bar items can be localized. For example,
if your application will be run in German language mode, labels would be
specified as German text. Refer to Application Registration File Support
for Internationalization and Localization on page 46 for general
information about localizing your application registration file.
Refer to Defining Symbol Pop-up Menus for instructions for creating
pop-up menus for symbols.
Defining the Pull-Down Menu Structure
Two sections of the application registration file provide specification for
menu registration: MenuBar and Menu.
MenuBar
Menu
58
Chapter 2
Menu "GetMail"
{
<100> "Open Mail"
_O
Context (WantMailMenus)
f.action "OpenMail";
<100> "Forward Mail"
_F
Context (WantMailMenus)
f.action "ForwardMail";
<100> "Delete Unopened Mail" _D
Context (WantMailMenus)
f.action "DeleteMail";
}
Figure 2-1 relates statements from the menu block of a registration file
to a completed menu. The following sections describe the syntax for these
statements and explain how to attach executable commands to both
pull-down and pop-up menu items.
Menu Bar Registration Application integration begins in the main
menu bar. A MenuBar block is defined that specifies the menu label on the
main menu bar under which the application will eventually appear. If
the menu bar item does not exist, NNM creates it for you. If it already
exists, NNM makes the association to the pre-existing menu item. The
menu bar declaration has the following format:
Chapter 2
59
You can define where your menu name will appear on the menu bar by
assigning a precedence to it. Menu bar precedence is from left (<100>) to
right (<0>). The default precedence value is <50>. When menu items
have the same precedence, NNM will place any of its registered menu
items first followed by the remaining menu items in alphabetical order
by application name.
You can specify an optional mnemonic character that allows users to
make a menu bar selection by typing a single character. The character
should correspond to one of the letters in the menu name. In the Mail
Manager example, we cannot use M as the mnemonic, because we know
that it is the mnemonic character for the Map menu provided by NNM.
Instead, well use an _a. The case of the mnemonic character
specification in the registration file should match the case of the
corresponding character in the menu name. For that reason, the
mnemonic character in our example will be a lower case a. For example:
Application "Mail Manager" _a {
...
MenuBar <100> "Receive Mail" _R
...
}
...
}
Chapter 2
Chapter 2
61
Menu Item
Components
Precedence
Purpose
A precedence value indicating how the menu item should be ordered.
Menu items are displayed according to the ordered precedence, and, within items
of equal precedence, in alphabetical order by application name. Precedence of
items on a pull-down menu is top <100> to bottom <0>. The default value is 50.
MenuItem
This string is the label for the menu item as it should appear in a menu. This string
can be localized. For example, if your application will be run in German language
mode, labels would be specified as German text. Refer to Application
Registration File Support for Internationalization and Localization on page 46
for more information on localization and internationalization.
Mnemonic
Accelerator
A keystroke sequence that invokes the menu selection without displaying the
menu. This is also called a keyboard accelerator. The syntax for these options are
specified in the OVwRegIntro reference page.
Context
Expression
The context expression is a placement rule that defines which submap contexts
should include the pull-down menu item. This is optional for pull-down menu
items. If it is omitted, the menu item is implicitly generic and will appear on all
submaps that havent blocked it by including NoGeneric or NoDefault in their
contexts.
Otherwise, the rule is specified with the keyword Context followed by a context
expression. The context expression is made up of context identifiers, parenthesis,
logical ANDs (&&), and logical ORs (||). The reserved context identifier
AllContexts may be used in the expression to indicate that the item should be
placed generically on all submaps that dont include NoGeneric in their context.
62
Chapter 2
Menu Item
Components
Function
Purpose
Describes the behavior of each menu selection:
f.separator
f.menu
f.action
Chapter 2
63
/*
** MENU BLOCK
*/
MenuBar <100> "Mail Manager" _a
{
<100>
"Receive Mail" _R
Context (WantMailMenus)
f.menu "GetMail";
}
Menu "GetMail"
{
<100> "Open Mail" _O
Context (WantMailMenus)
f.action "OpenMail";
<100> "Forward Mail" _F
Context (WantMailMenus)
f.action "ForwardMail";
<100> "Delete Unopened Mail" _D
Context (WantMailMenus)
f.action "DeleteMail";
}
64
Chapter 2
65
surround the context identifier with quotation marks only when required
for delimiting. When changing context through the NNM graphical user
interface, use unquoted context identifiers only.
ovwAllContexts and ovwAnySymbol are C constants for use with the
OVw API. The advantage of using one of these constants is that it allows
the compiler to catch spelling errors. The OVw API calls also accept
quoted identifier strings for reserved and non-reserved context
identifiers. You must have the HP OV NNM Developers Kit to use the
OVw APIs.
Table 2-6
Definition
NoDefault
NoGeneric
Chapter 2
Generic menu items and tool bar buttons can be excluded from a
special-use submap if the submap context includes the reserved context
identifier, NoGeneric.
A reserved context expression, AllContexts, is also available to specify a
generic menu item or tool bar button that should be placed in all
submaps that do not include NoGeneric in their contexts.
A generic menu item might have a definition such as:
"Add Object to Keylist" Context(AllContexts)
f.action "Add_keylist";
Pop-up Menu Items Symbol pop-up menu items are placed in a given
symbols pop-up menu based on target context and the symbols type.
Chapter 2
67
68
Chapter 2
<60>
<60>
"Diagnose Printer"
Context (WantPrintMenus)
f.action "diag_pr";
"Diagnose Plotter"
Context (WantPlotMenus && (IsIP || IsIPX))
f.action diag_plot";
"Query Node"
_Q
Context (IsIP) f.action "query_node";
}
...
}
Table 2-7
Context Example
Submap Context
Submap B,
Context={SysAdmin}
This submap will accept generic menu items and any menu item
targeted to the context identifier, SysAdmin. Of the items above,
only the generic menu items qualify: Create Box, the separator,
and Event Mgr.
Submap C, Context={IsIP,
WantPrintMenus,
NoGeneric}
This submap will allow only items specifically targeted with IsIP
and/or WantPrintMenus. Diagnose Printer and Query
Node are both satisfied by this context. The generic menu items
are explicitly blocked from this submap.
Submap D, Context={IsIPX,
SysAdmin, WantPrintMenus,
WantPlotMenus, NoDefault}
Adding Items to the Help Menu You can add links to online help to
the Help menu or to a dialog box button. For example, an NNM help topic
entry on the Help Menu might be f.help_browser "nnm:goto". In this
example, "nnm" is the name of the CDE or WinHelp file containing the
help topic and "goto" is the ID name of the topic as it is defined in the
CDE Help or WinHelp file. Refer to the ovw, nnm, and ovwnavigator
registration files for more examples.
Chapter 2
69
70
Chapter 2
Table 2-8
Menu Item
Components
Precedence
Purpose
A precedence value indicating how the menu item should be ordered.
Menu items are displayed according to the ordered precedence, and, within items of
equal precedence, in the application name order. Precedence is specified as an
unsigned integer value; 100 is the highest precedence, 0 is the lowest.
Menu Label
This is the label for the menu item as it should appear in a menu. This string can be
localized. For example, if your application will be run in German language mode,
labels would be specified as German text. Refer to Application Registration File
Support for Internationalization and Localization on page 46 for more information
on localization and internationalization.
Context
Expression
The context expression is a placement rule defining which symbols should have the
menu item. Refer to Targeting Menu Items and Toolbar Buttons to Submap Context
on page 65 for a general discussion about setting and using submap context and to
Pop-up Menu Items on page 67 for additional information about using context in
pop-up menus.
The target symbol type is specified with the keyword TargetSymbolType, followed
by a symbol type. The symbol type may be set to Any, <symbol name>:Any, or a
fully specified <class name>:<subclass>. The keyword Any is used to
generalize the target symbol type.
Chapter 2
71
Menu Item
Components
function
Purpose
Describes the behavior of each menu selection:
f.separator
f.menu
f.action
/*
** POPUP MENU BLOCK
*/
PopupItem <60> "PopupSeparator2"
Context (AllContexts || WantPopupMenus ||
WantMailMenus)
TargetSymbolType ANY f.separator;
PopupItem <50> "Configure Mailbox"
72
Chapter 2
NOTE
Symbol alert pop-up menu registration is used along with the application
programming interfaces to provide menus for symbol alerts.
Administrators should have no need to create or modify pop-up menus
for symbol alerts.
The symbol alert pop-up menu differs from a symbol pop-up menu in two
ways:
Chapter 2
73
Cascade menus are also supported for symbol alert pop-up menus.
Registration is similar to that used for symbol pop-up cascade menus.
Table 2-9
Parameter
Description
Label
This is the text for the label. This string can be localized. For example, if your
application will be run in German language mode, labels would be specified as
German text. Refer to Application Registration File Support for
Internationalization and Localization on page 46 for more information on
localization and internationalization.
Context
Expression
The context expression is a placement rule defining which symbols should have
the menu item. Refer to Targeting Menu Items and Toolbar Buttons to Submap
Context on page 65 for a general discussion about setting and using submap
context and to Pop-up Menu Items on page 67 for additional information about
using context in pop-up menus.
The target symbol type is specified with the keyword TargetSymbolType,
followed by a symbol type. The symbol type may be set to Any, <symbol class
name>:Any, or a fully specified <class name>:<subclass>. The keyword
Any is used to generalize the target symbol type.
Type
74
Chapter 2
Parameter
actionId
Description
A popupItem for a symbol alert must be an action (f.action). For symbol alert
actions (both default action and menu item actions) the registration is limited to an
action name. Symbol alert actions do not need or use a command, a selection rule,
or minimums and maximums for selected items since the selection list is ignored.
Example:
Application "FireFighter" {
PopupItem <100> "Ack Fire Alert"
Context (AllContexts)
TargetSymbolType SymbolAlert:MajorAlert
f.action "Extinguish";
}
Action "Extinguish"{
}
NOTE
Because end users can disable the display of the tool bar, application
developers must make their tool bar functionality accessible from the
pull-down menus as well.
Function;
Chapter 2
75
If you are registering a tool bar image for an application on the Windows
NT operating system, you can include tool tips text by using the syntax:
@ "toolbar\icon,tool tips text" as shown in the following
example:
/*
** TOOL BAR BLOCK
*/
ToolbarButton <100> @"toolbar/mailbox.bmp,Forward Mail"
Context "AllContexts"
f.action "ForwardMail";
Here the tool tip text is Forward Mail. It appears over the mailbox
bitmap when the cursor is left over it for more than a few milliseconds.
76
Chapter 2
Table 2-10
Menu Item
Components
Purpose
Precedence
Value
Buttons are ordered from left to right according to the precedence value and, within
items of equal precedence, according to application name order. 100 is the highest
precedence, 0 is the lowest.
Label
This string is required for all buttons. A text label string specifies the words on the
button (ignored for separators). A label starting with "@" specifies the image file to be
displayed on the button. This string can be localized. For example, if your application
will be run in German language mode, labels would be specified as German text.
Refer to Application Registration File Support for Internationalization and
Localization on page 46 for more information on localization and
internationalization. On the Windows NT operating system applications, you can
include a tool tip for the button by appending a comma and text for the tool tip to the
path name for the bitmap.
Context
Expression
The context expression is a placement rule defining which submap contexts should
include the tool bar button. This required field is specified with the keyword
Context followed by a context expression. The context expression is explained in
the pull-down menu item registration components. Refer to Targeting Menu Items
and Toolbar Buttons to Submap Context on page 65 for a general discussion of
setting and using submap context.
Chapter 2
77
Menu Item
Components
function
Purpose
Describes the behavior of each button selection:
f.separator
f.action
Defining Actions
The Action block is used to define actions that an application can
perform. Actions can then be associated with menu items via the
registration file, to symbol alerts via the OVw API, or to executable
symbols via the user interface. An action block declaration has the
following form (Table 2-11 explains each action block entry):
Action "actionId"
{
DisplayString "localizable string"
MinSelected n;
MaxSelected n;
SelectionRule (rule);
NameField "field", "field";
CallbackArgs "arg"
Command "-process_flags command $environment_variables";
}
Through the OVw API, an application can be notified that an action has
been requested by registering a callback for the action. This is
78
Chapter 2
Action Block
Entries
Purpose
DisplayString
This is a localizable string that is used to display the action name if the
application is running in a localized environment. For example, if your
application will be run in German language mode, the string would be specified
as German text. Refer to Application Registration File Support for
Internationalization and Localization on page 46 for more information on
localization and internationalization.
MaxSelected
Specifies the maximum number of objects that can be selected on the map for
the action to be enabled. If not specified, any number of objects may be selected
for the action. If set to 0, no objects may be selected.
MinSelected
Specifies the minimum number of objects that must be selected on the map for
the action to be enabled. If MinSelected is set to some value, then the
selection list must contain at least that number of objects. If MinSelected is
not set, then any number of objects can be selected. (If MinSelected is not set
and a SelectionRule is set, the selection list must contain at least one object.
If MinSelected is set to 0 and a SelectionRule is set, the selection list can
contain 0 or more objects.)
Chapter 2
79
Action Block
Entries
SelectionRule
Purpose
Provides a mechanism to guarantee that the application is invoked only if the
selected objects meet predefined criteria.
The selection rule is a logical expression involving capability fields. The logical
expression can use logical AND (&&), logical OR (||), or logical NOT (!)
operators.
Command
Specifies the command line used to invoke the application on a per-action basis.
Commands specified in an Action block override commands specified globally
in the Application block. If no command is specified globally, a command must
be specified for each action defined.
Process Flags
NameField
The NameField entry provides the same object name field validation as
described in the Application section, but on a per-action basis.
CallbackArgs
This is a string that is broken into an argument vector and passed to the
applications action callback in the argc and argv parameters from the
registration file to specific application action callbacks. The CallbackArgs
are not available to applications that do not use the OVw API.
The following example demonstrates an action block specification:
Application "Mail Manager" {
..
MenuBar "Mail Manager" _a {
"Receive Mail" _R Context (WantMailMenus)
f.menu "GetMail";
}
Menu "GetMail"
{
"Open Mail" _O f.action MailQueueAction;
}
Action MailQueueAction {
SelectionRule isNode;
MinSelected 1;
MaxSelected 1;
80
Chapter 2
In this example, the user can select the Open Mail menu item from the
menu cascades to request that the application be invoked. NNM executes
the application only if there is a single object selected on the map, and
that object has the isNode capabilities. If these qualifications are met,
the application is invoked with the name of the selected item.
Invoking Remote Applications (HP-UX and Solaris)
When an application is launched on a host other than the host running
the GUI, NNM uses a remote launcher. The grammar for the Command
statement for invocation of a remote application is:
Command ::= "Command" ProcessFlags String RemoteSpec ";"
| "Command" String RemoteSpec ";"RemoteSpec ::= "On"
HostSpec
RemoteSpecs ::= "On" HostSpec
| "On" HostSpec "StartedBy" LaunchSpec ";"
| Empty
HostSpec ::= StringOrIdentifier
LaunchSpec ::= String
ProcessFlags ::=ProcFlag | ProcessFlags ProcFlag
ProcFlag ::= "-Initial" | "-Shared" | "-Restart"
81
This starts the command on the server system using the default remote
application launcher when the application action is requested.
Note that, as in the previous example, if the application is an X-based
program, your registration should also specify the current X display on
the command line.
If you wanted to start the application via some other mechanism, such as
remsh (rsh on Solaris):
Application "Server App"
{
...
Command "/usr/bin/xserverapp -s $OVwSessionID -display
$DISPLAY"
On "$OVServer" StartedBy "remsh %1$s %2$s";
Action "Server Action"
{
82
Chapter 2
Chapter 2
83
DropAction Registration
DropAction Components
Purpose
Operations
SelectionRule
HelpString
Chapter 2
NOTE
If you have particular dialog box needs that are not met by NNMs
enrollment capability, you will need to implement your own dialog box
directly using Motif or Win32.
Enroll Block
Dialog boxes are defined using enroll blocks. A separate enroll block is
used for each dialog box type that you define. The format for enroll block
declarations is:
Enroll <Dialog_Type> {
if <Rule> {
InitialVerify <On/Off> ;
Scale <n>
Help <Browser/Quick> "HelpVolume:Keyword" ;
Field <Field specifications>{
NoDisplay <On/Off> ;
ImmediateVerify <On/Off> ;
Label "Label :";
EditPolicy <Edit/NoEdit/EditOnCreation> ;
Geometry <X,Y,W,H> ;
SelectionListPolicy <None/Single/Multiple> ;
IntegerDisplayPolicy <Integer/Unsigned/Hex/Octal/IPAddr> ;
}
...
}
}
Each enroll block is composed of three sections: the rule that specifies
what objects are accessible via the dialog box, any global rule options,
and the enrollment section. Rules are defined within enroll blocks, and
specifications are defined within rules.
Chapter 2
85
Describe
Connect
86
Chapter 2
In this case, the first end-point must be an object that has either isNode
or isRouter capabilities, while the other end-point must have the
isRouter capability. Selection order is not important.
Chapter 2
87
Scale
Help
88
Chapter 2
Option
Description
Label
A string used as a field label in the dialog box. By default, the label is
the same as the field name. This is a localizable string. For example, if
your application will be run in German language mode, the string would
be specified as German text. Refer to Application Registration File
Support for Internationalization and Localization on page 46 for more
information on localization and internationalization.
EditPolicy
An editing policy for the field. By default, fields are always writable.
You may specify that the field is read-only (NoEdit) or that the field may
only be edited upon use in a new map (EditOnCreation).
IntegerDisplayPolicy
NoDisplay
If on, allows the application to be sent the field value but it is not
displayed in the dialog box.
ImmediateVerify
If on, initiates the process of sending all enrolled fields and their values
to the application immediately after a value has been entered in this
field.
Geometry
Specifies the geometry of the field with four integers. They are, in order
specified: X Position, Y Position, Width, Height. If setting is specified,
the grammar requires all parameters, but only width is applied.
FieldListSelectionPolicy
Specifies the behavior of the list of fields displayed in the attributes box.
Valid parameters are: None (the default) no specific items may be
selected. Single--only one item in the list can be selected.
Multiple-more than one item in the list can be selected.
FieldDefaultValue
Lets you specify a default value for the field. This default value is
supported only for application configuration fields.
The following example demonstrates how to define fields
Application "Mail Manager" {
...
Chapter 2
89
In the previous example, the dialog box contains a single field that
displays the IP address. The IP Address field in the object database is
stored internally as a 32-bit integer, but is displayed using the IP
address format. The field cannot be edited by the user.
In general, most enroll blocks contain multiple field definitions. You can
examine the application registration files provided with NNM for more
examples. See the OVwRegIntro(5) reference page for a complete
description of entries within enroll blocks.
90
Chapter 2
Action NNMalarms {
URL "/OvDocs/nnm/NNMcat.html";
Access NTAdmin NetworkAdmin
WebWindow "OvWWWAlarm" {
Type full;
Toolbar off;
Status off
}
}
Action
Block
List
Block
List FaultsAndAlarms
{
NNM Alarms
Icon launcher/msgbr16.gif
ActiveHelp { FaultsAndAlarms }
f.action FaultsAndAlarms;
}
Tab
Block
Tab <70> Information and Reports Icon launcher/info.20.gif
Active Help { Information and Reports}
Chapter 2
91
Application Block
The basic statements of the application block are supported. The values
for the Application Name, Version, Copyright, and Description are
not displayed by the Launcher, but they provide useful comment
92
Chapter 2
Tab Block
The Tab block corresponds to the MenuBar block in the application
registration files.
Instead of an optional mnemonic as in the MenuBar, the Tab block allows
an icon to display on the tab.
The Tab block also contains optional active help text. This active help is
presented in a help text box when the user selects the tab.
The syntax for a tab block is:
Tab <precedence>"Title Icon "image_name" ActiveHelp
{"help_text"}
Table 2-14
Purpose
precedence
tab_id
Chapter 2
93
Purpose
image_name
This is a locale-dependent icon that is displayed for the tab. The form for
icons is 16x16 GIF files. The file name is relative to
/opt/OV/www/htdocs/$LANG/images/ on UNIX systems or
\OpenView\www\htdocs\$LANG\images on the Windows NT
operating system. If one is not specified, a default is used. Optional.
help text
The help statement is optional. It specifies the text that is displayed when
the list item is active. You can provide multiple help statements within
the braces {}. Optional.
List Block
List blocks declare a set of contained list items that are displayed
together when the list is activated.
<list_item_precedence> "list_item_label" Icon
"icon_statement.gif"
ActiveHelp { "help_statement"}
f.list "list_function";
List Item statements can appear as part of either tab or list blocks. When
part of a tab block, list item statements declare items that appear in the
tabbed property page.
Table 2-15
Purpose
List_Item_Precedence
List_Item_Label
This is the label for the list item as it should appear in a list. It is a
required field.
Icon_Statement
94
Chapter 2
Purpose
Help_Statement
List_Function
List Blocks
List Blocks declare a set of contained list items that are displayed
together when the list is activated
Action Block
An Action block is used to define an action that an application can
perform. Actions can then be hooked to list items via the f.action
List_Function specification. It lists the URL that should be used to
perform the action.
The generic form of an action block is:
Action <Action_ID> {
URL "url";
WebWindow "name"{
Type full | intermediate | limited;
Status on | off;
Scrollbars on | off;
Toolbar on | off;
Location on | off;
Resizable on | off;
Width pixels;
Height pixels;
}
Chapter 2
95
Table 2-16
Purpose
Action_ID
URL
The URL to launch for the action. The URL may contain the special
variable $OVwWebServer. This variable will be substituted with
the name of the system from which the Launcher was loaded.
Access
A list of the user roles that have access to this action. If the Access
statement is not present, all users have access.
WebWindow
Type
Type specifies the type of the window and determines which features
it supports. These are the values: full, intermediate, limited.
Status
Scrollbars
Toolbar
Location
Resizable
96
Chapter 2
Purpose
Width
Height
ARF
Windows NT
operating
system and
UNIX systems
Network
Presenter
Documented
Description
Copyright
Version
HelpDirectory
N/A
Command
N/A
MenuBar
Menu Item
PopupMenu
Chapter 2
97
ARF
Windows NT
operating
system and
UNIX systems
Network
Presenter
Documented
SymbolAlert Popup
N/A
Action Block
Must be URLs
DropAction Block
UNIX systems
Only
N/A
Remote Application
Invocation
UNIX systems
Only
N/A
N/A
WebWindow
N/A
$OVwNumSelections
98
Chapter 2
$OVwMenuItem
$OVwAppName
$OVwActionID
WebWindow
The WebWindow declaration allows specification of attributes of
application window. If the WebWindow statement is not present, the
URL will be loaded into an unnamed full Web browser window. The
definition for WebWindow is described in Table 2-16.
Chapter 2
99
Creating Symbols
Symbols are graphical representations of objects in HP OpenView.
Symbols can either be icon symbols or connection symbols. Icon symbols
represent network or system management elements, while connection
symbols represent connections between elements.
Each symbol is identified by its symbol type. The symbol type is defined
by a symbol class/subclass pair. The symbol class defines the symbol
category, while the symbol subclass defines a particular element within
that class. Network Node Manager provides you with a rich set of
predefined symbol classes and subclasses.
Symbol type registration files are used to define symbol classes and
subclasses in HP OpenView. The predefined NNM symbol classes and
subclasses are themselves defined using various symbol type registration
files in \OpenView\symbols\$LANG on the Windows NT operating
system or $OV_SYMBOLS/$LANG/ on UNIX systems. You are encouraged
to use these predefined symbol classes and subclasses in your
applications.
You may find, however, that existing classes and subclasses are not
adequate for your needs. You can add new symbol subclasses to existing
symbol classes or you can define your own symbol classes. This portion of
the chapter shows how to define symbol classes and subclasses. Only icon
symbol classes and subclasses are described here, as they are the most
commonly used symbol variety. If you need to define connection symbols,
see the OVwRegIntro(5) reference page. (All references to the terms
symbol classes and symbol subclasses throughout the remainder of
this section refer to icon symbol classes and subclasses.)
Chapter 2
Chapter 2
101
Chapter 2
Chapter 2
103
(-1,1)
(1,1)
(0,0)
(-1,-1)
(1,-1)
SymbolClass "Computer" {
Segment (-1,-1) to (1,-1) to (1,1) to (-1,1) to (-1,-1);
}
By default, the scale is 1. In other words, the integer point values may
range from -1 to 1 on both the X and Y axes. A scale of 1 limits you,
though, to simple, uninteresting shapes.
You can create more complex shapes by increasing the scale and,
therefore, using more points. NNM will interpret your points relative to
your scale and will display your shape in a standard size. The following
example demonstrates how to use the scale entry.
104
Chapter 2
SymbolClass "House" {
Scale 5;
Segment (-4,0) to (-5,0) to (0,5) to (3,2) to (3,3) to (4,3)
to (4,1) to (5,0) to (4,0) to (4,-5) to (-4,-5);
}
Note that the example segment definition is not closed explicitly. NNM
completes the definition by drawing a line from the last point to the
starting point.
You have much freedom in defining symbol class shapes. There are,
however, some aspects of shape definition you should be aware of:
Chapter 2
105
Keyword
Purpose
Size
This is the width and height of a conceptual rectangle in which the line will rotate. If
the width and height are equal, the arc will have a constant radius. Elliptical arcs may
be achieved using height and width values that are unequal.
Origin
Specifies an origin for rotation within the conceptual rectangle. The center of the
conceptual rectangle is assumed to have the coordinates (0,0).
Rotation
This specifies the starting angle and number of degrees of rotation. A starting angle of
0 degrees is equated to a three-oclock position, and rotation occurs in a clockwise
direction.
The following example demonstrates how to define a symbol class with a
circular shape.
SymbolClass "Network" {
Scale 2;
Arc Origin(0,0) Size(2,2) Rotation 0, 360;
}
If you need further information about defining symbol classes using arcs,
consult the OVwRegIntro(5) reference page.
106
Chapter 2
NOTE
Default Capabilities
An object can be added to the map by selecting a symbol type on the
symbol palette and dragging it to a submap. NNM automatically
creates an object that is associated with the symbol. By default, the
Chapter 2
107
Variety
There are actually two forms of symbol classes: icons and connections.
To this point, only icons have been shown. It is possible, though, to
create symbol classes that connect other symbols. These are called
connection classes. You can specify that a class is a connection by
using the Variety definition and specifying that the class has the
value Connection. (The default is Icon). The following example
demonstrates:
SymbolClass "Connection" {
Variety Connection;
}
DisplayString
The DisplayString is a localizable string that is used when NNM
must display the name of a symbol class from within its user
interface. For example, if your application will be run in German
language mode, the string would be specified as German text. If no
DisplayString is specified, the ASCII SymbolClass string is
displayed.
For further information about connection symbol classes, see the
OVwRegIntro (5) reference page.
108
Chapter 2
The class name is the name of an existing symbol class. The subclass
name is a unique name for the new subclass. The subclass specifications
define the bitmaps that are used for the subclass as well as other
characteristics of symbol subclass behavior.
The symbols provided by NNM use the RGB values listed in Table 2-19.
Using other colors may overload the color map and can create problems
for the user.
Table 2-19
Chapter 2
Red
Green
Blue
Grays
200
200
200
175
175
175
150
150
150
125
125
125
100
100
100
75
75
75
50
50
50
109
Red
Green
Blue
White
255
255
255
Black
Red
255
Green
255
Blue
255
Yellow
255
255
Magenta
255
255
Cyan
255
255
Chapter 2
Chapter 2
111
Overlay graphics must be X pixmap format. The sizes for the overlay
graphics on a UNIX system must be 11, 12, 17, 21, 25 or 29 pixels.
Refer to the HP OpenView Application Style Guide for usage
guidelines for connection symbol overlay graphics.
Subclass Specifications for the Windows NT Operating System
Applications on the Windows NT operating system require a filebase
specification for the symbol subclass definition to define the base name
for a symbol subclass icon. No cursor size specification is required.
Bitmaps are stored in \OpenView\bitmaps\$LANG on the Windows NT
operating system.
For example, the symbol type definition in $OV_SYMBOLS\C\Computer
might look like this:
SymbolType "Computer" : "WindowsNT"
{
Filebase "winnt";
Capabilities {
isPC = 1;
}
}
112
Chapter 2
Chapter 2
113
Thickness
This statement is used to specify the thickness of the connection in
pixels. The thickness of the connection cannot exceed the width of the
connected symbols.
For further symbol subclass examples, consult the symbol registration
files provided with HP OpenView (in the\OpenView\symbols\$LANG on
the Windows NT operating system or $OV_SYMBOLS/$LANG/ on UNIX
systems).
114
Chapter 2
For example:
SymbolAlert FireDanger {
PixmapBaseName critical_alert;
PixmapSize 85;
TextRegion {
RegionCenter (43,45);
RegionHeight 46;
RegionWidth 75;
}
}
Component
Description
SymbolAlertTypeName
Chapter 2
115
Component
Description
PixmapBaseName
Specifies the filebase name of the pixmap file used to display the
symbol alert type. Only the X pixmap format is supported.
PixmapSize
The size of the pixmap in pixels. The pixmap must be square; its size
is specified by the length, in pixels, of one of its sides. Because the
symbol alert does not scale with the submap, the graphic is needed in
only a single size, one pixmap file per symbol alert type.
116
Chapter 2
Component
Description
TextRegion
Chapter 2
117
NOTE
Note that you can only add fields, you cannot delete them. After they are
added, you must rebuild the database.
Defining Fields
There are three components to a field definition:
the field name
the data type of the field
flags that indicate how the field is used.
The field name and field type are required.
Every field must have a data type and a unique name. Flags can be
optionally supplied to alter how the field is treated by NNM.
Use the field block structure to define fields. The FRF contains one or
more field blocks, where each field block defines a single field. The field
block has the syntax:
Field "non-localizable string" {
Type "field type";
[Enumeration <field enumeration>;]
[Flags "field flags";]
DisplayString "localizable string";
}
118
Chapter 2
Field Type
Every field has an associated data type. The Type entry declares the
fields data type. Type is a required entry, and must be set to one of four
possible types:
Boolean. This type can only have the values True or False.
String. A standard character string, limited to 256 characters in
length.
Enumeration. Declares the field to be an enumerated type. All
possible values for the enumerated type are declared in a separate
Enumeration statement.
Integer32. A 32-bit signed integer.
Field Flags
While the Type field specifies the data type of the field, the Flags field
specifies how the field is treated by HP OpenView. NNM gives you the
flexibility to treat fields in different ways. For instance, you can specify
that a particular field is a name field, which means that the value of
the field is unique across all objects that contain the field. You can also
specify that a particular field should appear in the Edit:Find->Objects
By Attribute dialog box on the NNM menu. These behaviors, as well as
others, are defined in the field registration file.
There are five types of flags (behavior) that can be applied to fields:
List
Specifies that the field contains a list of fields of the same type, rather
than just a single field. The list flag allows you to associate multiple
values of the same type with a single field definition. The list flag is
valid for string and integer data types. However, user interface
support is available only for lists of strings, not for lists of integers.
Chapter 2
119
NOTE
Do not use the name flag for a field unless you require the values
assigned to that field to be unique across all objects in the database.
Locate
By specifying this flag in the field definition, the field name shows up
in the Edit:Find->Objects By Attribute dialog box when end
users attempt to locate an object.
You should use care in setting this field. If you do not specify the
locate flag, end users wont be able to locate an object based on your
field. Alternatively, indiscriminate use of the locate field will result
in an overabundance of locate entries, making that dialog box harder
to use effectively. Set this flag only if end users have a strong need to
locate objects through this field. This flag cannot be used together
with the list flag.
Capability
By setting this flag, the field is considered by NNM to be an object
120
Chapter 2
Chapter 2
121
You can see that these three fields are used to determine an objects
capabilities. An object could have device, computer, or node capabilities.
In fact, an object could even have a combination of these capabilities.
Capability fields are used to classify objects in NNM and, therefore,
cannot be used to uniquely identify (or name) an object.
The next example demonstrates how to define enumerated types, as well
as how to use the locate flag:
Field "IP status" {
Type enumeration;
Enumeration "Unknown",
"Normal",
"Marginal",
"Critical",
"Unmanaged";
Flags locate;
}
This example shows how you might use enumerated types to classify the
status of nodes on a network. Each node on a network would have a
status value from this set. By setting the locate flag, end users have the
ability to search for, or locate, all nodes on the network with a particular
status. It would not be valid to set the name flag for this field.
The next example demonstrates how to use a field as a name field.
Because the hostname of a computer would be unique for all nodes on the
network, the name flag can be set for the field.
Field "IP Hostname" {
Type string;
Flags name;
}
The following example demonstrates how to use the list flag in field
definitions.
Field "Service Contacts" {
Type string;
Flags list;
}
122
Chapter 2
Combinations of Flags
Flags can be applied to different data types and for different purposes.
The examples above do not use combinations of flags, but there may be
occasions where you want to use flags in combination. Flags can be used
in the following ways:
All flags can be used individually.
The name and locate flags can be used together (for string fields).
The capability and locate flags can be used together (for Boolean
and enumeration).
The general flag can be used with the other valid combinations
described here.
If a combination is not listed here then it is not permitted. For example,
you cannot combine the name, capability and locate flags in a single
flags statement. Because name fields must be strings, and capability
fields must be Boolean or enumeration, there is no field that would be
valid for both.
Chapter 2
123
Here the DisplayString statement specifies the localized string for the
field name. The string specified by the word Field must be ASCII
characters and must be identical in all language versions of this
applications field registration files. Whenever HP OpenView is started
up in German language mode, the DisplayString is displayed as the
field name. If no DisplayString is specified, the ASCII string specified
for Field is displayed.
For additional information about internationalizing and localizing
applications refer to:
Application Registration File Support for Internationalization and
Localization on page 48.
Symbol Registration File Support For Internationalization and
Localization on page 92.
HP OpenView Application Style Guide for design guidelines.
HP OpenView Windows Developers Guide, Chapter 10 , Developing
Internationalized and Localized Applications, for implementation
guidelines.
the OVwRegIntro(5) reference page.
124
Chapter 2
Summary
The application, symbol type, and field registration files provide a static
mechanism to configure HP OpenView behavior.
Application registration files are used to integrate applications into the
HP OpenView user interface. ARFs define all aspects of an applications
interaction with Network Node Manager, including how applications are
added to the menu structure, how applications are invoked and
application processes managed, and where application-specific help
information is located.
Symbol type registration files are used to define symbol classes and
symbol subclasses. Symbol classes can represent either icon or
connection symbols. Icon symbol classes are defined using line segments
or arcs, while icon symbol subclasses are defined by standard pixmaps.
Connection symbol classes and subclasses are described in the reference
pages. Network Node Manager provides you with a large set of
predefined symbol classes and subclasses, but you can define your own as
well.
Field registration files are used to define fields, which are attributes of
objects. Field registration files define the data type and behavior for
fields.
Chapter 2
125
126
Chapter 2
127
This chapter describes the HP OpenView Windows help for HP-UX and
Solaris systems and explains how to use it. Developers should provide
application help information to assist users with their tasks. HP
OpenView Windows on the Windows NT operating systems uses the
native WinHelp functionality.
HP recommends that all HP OpenView applications on UNIX systems
provide on-line help information as described in this chapter. You are not
required to implement online help, nor are you required to follow the
exact recommendations described here. The guidelines presented in this
chapter are simply recommendations. There are, however, many
advantages to following these recommendations. End-users benefit by
having a help system that behaves consistently across applications
developed by multiple vendors. This makes application help information
easier to access, both for novice and advanced users.
Common Desktop Environment (CDE) Help, the help system provided
for HP-UX and Solaris by HP OpenView Windows, lets help authors
provide help that includes formatted text, graphics, hyperlinks, and
communication with the application. This enables development of
context sensitive help that displays information specific to the area of the
application which is currently in use.
CDE Help also provides a programmers toolkit for integrating the help
facilities into an application.
This chapter covers the following material:
an introduction to the CDE help system
deciding whether to use the CDE help system
building and integrating CDE help information with HP OpenView
Windows.
128
Chapter 3
Chapter 3
129
130
Chapter 3
Chapter 3
131
Documentation
HP OpenView Application Style Guide
CDE Help System Developers Guide
This chapter.
This chapter.
The Help menu in the OVW main menu bar contains the following items:
Overview
Display Legend
Mouse & Keyboard
On Window
Whats New With OVW
Using Help
Misc->
Tasks
Functions
NNM->
Overview
Tasks
Whats New with NNM
About NNM
About OpenView
132
Chapter 3
Note how, later in the file, the contents of the Help pull-down menu are
defined. The help browser is called to display a topic in a help window,
via the entry f.help_browser "volumeName:helpTopicId". In the
following excerpt from the ovw registration file, the first item on the Help
menu is Overview. The help system will look in the help volume ovw for
the help topic named overv.
MenuBar <100> "Help" _H
{
<100> "Overview" _V
Context (AllContexts || WantHelpMenus
f.help_browser "ovw:overv";
<100> "Display Legend" _D Context (AllContexts ||
WantHelpMenus)
f.disp_legend;
<100> "Mouse and Keyboard" _M
Context (AllContexts || WantHelpMenus)
f.help_browser "ovw:mousenkeyboard";
<100> "On Window" _W Context (AllContexts || WantHelpMenus)
f.help_browser "ovw:OnWindow";
<100> "Whats New with OVW" _N
Context (AllContexts || WantHelpMenus)
f.help_browser "ovw:whatsnewOVW";
<100> "Using Help" _U Context (AllContexts || WantHelpMenus
f.on_help;
<100> "Misc" Context (AllContexts || WantHelpMenus)
f.menu "Misc Help";
<98> "About OpenView" _A Context (AllContexts ||
WantHelpMenus)
f.about_ovw;
}
Menu "Misc Help"
{
<98> "Tasks" _T Context (AllContexts || WantHelpMenus)
f.task_index;
<98> "Functions"
_F
f.function_index;
}
The Quick Navigator menu definition shows how to use the context
definitions to exclude the help topics defined for the main help menu.
Chapter 3
133
Note in this example that the help topic for Overview is defined as
ovw:goto. The context for this Overview item on the Help pull-down
menu is limited to the Quick Navigator window by the context
expression:
Context (OVwNavigator)
134
Chapter 3
Chapter 3
135
136
Chapter 3
Documentation
HP OpenView Application Style Guide
CDE Help System Developers Guide
This chapter.
/usr/OV/help/$LANG/app_name
Developer links help volume to:
This chapter.
/usr/dt/appconfig/help/$LANG
Developer customizes Help menu on application
menu bar to provide access to help topics by
editing the application registration file.
Chapter 3
137
138
Chapter 3
Summary
This chapter described how to integrate application help information
into the CDE help system on HP-UX and Solaris. Developers can
integrate application help into HP OpenView Windows in one of three
ways: through the OVW main menu bar, through OVW-generated dialog
boxes, and through application-specific user interfaces.
Developers should follow the HP OpenView Application Style Guide
recommendations for content and format of help text files. This ensures
consistency for the user when viewing help information generated by
different applications.
The most general way to integrate application help information into
OVW is through the Help menu on the OVW main menu bar. Help
information available through the menu bar is general in nature.
Developers can use enroll blocks in application registration files to
define OVW-generated dialog boxes for Add, Describe, Connect, and
Configure map operations. Applications that use enroll blocks should
provide dialog box help information.
Applications that use a custom user interface (such as a custom menu or
dialog box) should also provide application-specific help through that
interface. The application, not OVW, is responsible for determining how
and when users request this help information. Developers can then call
OVw API routines to display the appropriate help information through
the OVW- provided help file viewer.
Chapter 3
139
140
Chapter 3
141
This chapter presents application design concepts and OVw API routines
that are found, in some form, in almost all OVW applications. After
reading this chapter, you will know how to initialize your application,
how to structure your application, and how to exit once processing is
complete.
This chapter relies on information presented in Chapter 1 , Developing
Applications for HP OpenView Windows, and Chapter 2 , Creating and
Using Registration Files. Concepts and techniques presented in this
chapter appear throughout the remainder of this manual.
142
Chapter 4
Overview
This chapter describes:
the OVW programming model
connecting applications to HP OpenView Windows
defining callback routines for events
processing events
error handling
getting the application name
getting the selection list
highlighting objects on the map
using the OVw API help routines.
Chapter 4
143
144
Chapter 4
Chapter 4
145
OVW Events
HP OpenView Windows defines approximately 30 events for application
use. Applications can choose to register for as many events as desired.
The full set of OVW events is defined in the file
\OpenView\include\OV\ovw.h (Windows NT operating system) or
$OV_HEADER/OV/ovw.h (UNIX systems). The following list contains a
sample of OVW events:
ovwEndSession
OVw terminated.
ovwSelectListChange
ovwMapOpen
ovwMapClose
ovwQueryAddSymbol
ovwConfirmAddSymbol
146
Chapter 4
Chapter 4
147
Action Events
In addition to receiving events, OVW applications can also receive
notification when end users invoke application-provided actions from
either OVW menu items or from executable symbols. These are special
events we call action events.
Callback registration for action events is very similar to event
registration described previously. Action events are registered with a
similar call, OVwAddActionCallback(). It has the following function
prototype:
int OVwAddActionCallback(char *actionID,
OVwActionCallbackProc callbackProc, void *userData);
148
Chapter 4
Chapter 4
149
150
Chapter 4
Processing Events
The third and last major step that an HP OpenView Windows
application must perform is to process events. Events are processed
differently on HP-UX and Solaris than on the Windows NT operating
system.
Chapter 4
151
152
Chapter 4
Chapter 4
153
154
Chapter 4
Error Handling
Retrieving a Routines Result Code
OVW stores an internal result code for every OVw API call you make.
This internal result code contains an integer value that represents either
success or, if an error occurs, the cause of the error.
You can request this value by calling the OVwError()OVw API routine.
OVwError() returns the result code of the last OVw routine called by the
application. All error values are defined in the file
\OpenView\include\OV\ovw_errs.h (Windows NT operating system) or
$OV_HEADER/OV/ovw_errs.h (UNIX systems). Refer to the reference
pages to determine how particular OVw API routines return errors.
Since OVW allocates the memory for the character string from a static
buffer, you should not attempt to free the string memory after use.
The following example shows one way to use the OVwError() and
OVwErrorMsg() routines:
#include <OV/ovw.h>
...
main(argc, argv)
int argc;
char **argv;
{
if (OVwInit() < 0) {
if (OVwError() == OVw_OVW_NOT_RUNNING) {
printf("OVW must be running prior to running this
application!\n");
} else {
printf("%s\n", OVwErrorMsg(OVwError()));
}
Chapter 4
155
Though you could bypass these functions and implement these tests
yourself, we recommend using these functions. They hide the underlying
ID data types, making your program more portable in the event that an
ID implementation changes in the future.
156
Chapter 4
Chapter 4
157
158
Chapter 4
Objects and object IDs are described in detail later in this manual.
To use the above selection rule in your program, you pass the "Trends"
argument to your OVwGetSelections() call. OVwGetSelections()
returns the current selection list only if the selection rule in the
"Trends" action is valid for all the objects in the selection list.
Chapter 4
159
and
int OVwSelectObjects(OVwMapInfo *map,
OVwObjectIdList objectList, OVwBoolean clearPrevious)
160
Chapter 4
Highlighting Objects
Applications can highlight one or more objects on a map as a result of a
user-initiated action (e.g., identifying all objects with a particular
characteristic). All symbols representing highlighted objects are
graphically displayed with symbol labels in reverse video. After
highlighting, users can select highlighted objects with the Select
Highlighted OVW menu item to make them input for another
operation.
The highlighting routines have the following function prototypes:
int OVwHighlightObject(OVwMapInfo *mapInfo,
OVwObjectId object,OVwBoolean clearPrevious);
int OVwHighlightObjects(OVwMapInfo *mapInfo,
OVwObjectIdList *objectList,OVwBoolean clearPrevious);
Chapter 4
161
162
Chapter 4
Chapter 4
163
Summary
This chapter described the basic OVw API routines that are important to
most OVW applications. Most typical applications must perform three
steps: 1) connect to HP OpenView Windows, 2) define callback routines to
be invoked when specific events occur, and 3) enter a loop that waits for
and processes events. Applications connect to HP OpenView Windows by
calling the OVwInit() or the OVwInitSession() routine. Applications
then register callback routines to be invoked when specific events occur.
HP OpenView Windows supports different types of event processing. HPUX and Solaris applications that have no graphical user interface and
the Windows NT operating system console applications can use the
simple OVwMainLoop() routine. HP-UX and Solaris applications that use
X Windows and have a graphical user interface process events using
OVwXtMainLoop(). On the Windows NT operating system,
graphical-user-interface applications process OVW events automatically.
Applications that need advanced control over event processing can use
the OVW event processing primitives to implement customized event
processing.
Other general purpose routines were then described. These routines
perform such functions as: checking for OVw API errors, getting the
application name, getting the object selection list, highlighting objects,
and, for applications on HP-UX and Solaris, using the OVw API help
routines.
164
Chapter 4
165
This chapter introduces the OVw API object database routines. These
routines create and manipulate objects and fields in the HP OpenView
Windows object database.
You should read this chapter if you want to create and/or manipulate
objects in the HP OpenView Windows object database.
166
Chapter 5
Overview
Topics in this chapter include:
the HP OpenView Windows object database
creating fields
creating objects
getting/setting object field values
deleting objects.
Chapter 5
167
Fields
Fields are object attributes stored in the OVW object database. Fields are
the building blocks from which objects are constructed.
Fields can have one of the following four data types:
32-bit integer
Boolean
character string
enumerated value.
168
Chapter 5
Objects
In OVW, an object is an internal representation of a logical or physical
entity or resource that exists somewhere in a computer network. An
OVW object consists of a unique object identifier and a set of fields that
specify all the characteristics of the object.
The OVw API provides routines that create and delete objects, as well as
routines that change the object fields. Other OVw API routines perform
such functions as retrieving the list of all fields associated with an object
and searching the object database for objects that contain specific field
values.
Chapter 5
169
Creating Fields
Fields are created using either the field registration file (FRF) or the
OVwDbCreateField() routine. Field values are set using other API
routines described later in this chapter. You are free to use existing fields
or to create new ones as your application needs dictate.
170
Chapter 5
Chapter 5
171
Applications that create fields using the field registration file will need to
use the OVwDbFieldNameToFieldId() routine at some time. As
mentioned before, many of the OVW object database routines take a field
ID, not a field name, as an argument. To use these types of routines, you
will need to first convert the field name in the field registration file to a
field ID using OVwDbFieldNameToFieldId().
See the reference pages if you need more information about these
routines.
172
Chapter 5
each name */
"red";
"green";
"blue";
Chapter 5
173
Chapter 5
Predefined Fields
Two name fields are predefined by OVW and are available for application
use
Selection Name
IP Hostname (IP networks only)
Applications should not attempt to redefine or change these predefined
OVW fields.
The field creation routines presented in this section let you create fields
and retrieve field information from the object database. They do not,
however, let you define field values. The next section describes how to
create objects and assign initial field values for fields in the object.
Chapter 5
175
Creating Objects
When you create an object, an object definition is added to the OVW
object database. The object definition is created with a selection name
and an optional field value. Before describing how to create objects, some
discussion of the field value data structures and the selection name is
necessary.
When used for simple data types, the is_list Boolean value is set to
FALSE, and the field value is stored as an integer, Boolean, string, or
enumerated value. The field_type entry specifies which union entry is
used.
The modified entry is not used during field creation and can be
temporarily ignored.
If the field value is a list, then the is_list entry is set to TRUE and
list_val points to a structure that heads the list.
The following additional data structures define the list head and the list
entries:
typedef struct {
union {
176
Chapter 5
Note that for lists the data type is not specified in the
OVwListFieldEntry data structure. Since all items in the list must be
the same type, it is sufficient to specify the data type in the
OVwFieldValue structure.
The selected entry in the OVwListFieldEntry can be ignored
temporarily.
The following example shows how the OVwFieldValue,
OVwListFieldValue, and OVwListFieldEntry data structures are
related.
Chapter 5
177
OVwListFieldEntry
union {
int
boolean
string val
enum_val
OVwFieldValue
isList
field_type
union {
int
boolean
string val
enum_val
list_val
}
modified
}
selected
OVwListFieldValue
count
list
union {
int
boolean
string val
enum_val
}
selected
...
union {
int
boolean
string val
enum_val
}
selected
Note that the list of values is not implemented as a standard linked list.
The OVwListFieldValue structure that heads the list contains an
integer count of the number of list entries, followed by a pointer to a
contiguous array of list entries. For internal memory management
reasons, most OVW list data structures are implemented in this way.
Chapter 5
Creating an Object
With the field value data structure and selection name background
behind us, we can proceed with an example of object creation. Three OVw
API routines are available to create objects:
A generic routine that can create any type of OVw object
(OVwDbCreateObject()).
Two convenience routines that create objects by their hostname or
selection name (OVwDbCreateObjectByHostname() and
OVwDbCreateObjectBySelectionName()).
In general, objects are created with the OVwDbCreateObject() routine.
It has the following function prototype:
OVwObjectId OVwDbCreateObject(OVwFieldBinding *name);
Chapter 5
179
180
Chapter 5
Chapter 5
181
182
Chapter 5
Since the memory used to store the returned field value is allocated by
OVW, you should free the memory when no longer needed. This is done
by calling the OVwDbFreeFieldValue() routine.
The following example shows how to retrieve the selection name field
value from the OVW object database. This example converts the field
name to a field ID, then calls OVwDbGetFieldValue() to retrieve the
field value information.
Chapter 5
183
Chapter 5
This structure follows the list scheme used by other OVw list data
structures. The fields pointer points to the first entry in a contiguous
array of count data structures (in this case, OVwFieldBinding data
structures).
Chapter 5
185
OVwFieldValue
OVwFieldBindList
count
FieldBinding
OVwFieldBinding
isList
field_type
union {
int
boolean
string val
enum_val
list_val
field_id
field_val
}
modified
field_id
field_val
isList
field_type
union {
int
boolean
string val
enum_val
list_val
...
field_id
field_val
}
modified
isList
field_type
union {
int
boolean
string val
enum_val
list_val
}
modified
186
Chapter 5
Convenience Routines
The OVw API provides many convenience routines that, in some
situations, are easier to use than the basic calls. These convenience
routines depend on data structures and concepts presented in this
Chapter 5
187
Convenience Routines
Routine
OVwDbGetFieldIntegerValue()
OVwDbGetFieldBooleanValue()
OVwDbGetFieldStringValue()
OVwDbGetFieldEnumByValue()
Purpose
These routines take an object ID and field ID as
arguments and return the appropriate field value.
They save you the trouble of having to dereference pointers into the OVwFieldValue
structure.
OVwDbGetFieldEnumByName()
OVwDbSetFieldIntegerValue()
OVwDbSetFieldBooleanValue()
OVwDbSetFieldStringValue()
OVwDbSetFieldEnumByValue()
OVwDbSetFieldEnumByName()
OVwDbSetSelectionName()
OVwDbSetHostname()
OVwDbGetCapabilityFieldValues()
OVwDbGetNameFieldValues()
OVwDbNameToObjectId()
OVwDbSelectionNameToObjectId()
OVwDbObjectIdToSelectionName()
OVwDbHostnameToObjectId()
OVwDbObjectIdToHostname()
OVwDbListObjectsByFieldValue()
OVwDbListObjectsByFieldValues()
OVwDbFreeObjectIdList()
188
Chapter 5
Convenience Routines
Routine
OVwDbGetFieldValuesByObjects()
OVwDbFreeObjectFieldList()
Purpose
These routines get a list of values for a certain
field for a list of objects.
These routines are not described here since their use is straightforward
once the basic calls are understood. See the reference pages if you want
more information on these routines.
Chapter 5
189
Deleting Objects
Objects should be deleted from the OVW object database when they are
no longer needed. OVWs process for deleting an object addresses the
possibility that the object might still be used by another application. The
OVw API provides a set of routines that applications can call to
cooperatively delete an object. This process guarantees that an object is
not deleted while still being used by another application.
190
Chapter 5
Chapter 5
191
Summary
This chapter described how to use the OVw object database routines to
create fields and objects in the OVW object database.
Fields are object attributes. Fields are created using either the field
registration file or the OVwDbCreateField() OVw API routine. Objects
are created with the OVwDbCreateObject() routine or one of its
convenience versions. When objects are created, a value is assigned to a
single field and, if necessary, a selection name is assigned. The
OVwDbGetUniqObjectName() routine generates values for name fields
that are guaranteed to be unique.
The OVw API data structures used for object manipulation were
presented. The OVwFieldValue data structure contains either a single
value or a pointer to a list of values. Lists are implemented using
pointers to contiguous areas of memory containing the list items. Lists
within a field value must contain objects of the same type. The
OVwFieldBindList data structure is used to create lists of field values.
A variety of OVw API convenience routines are available and are based
on their basic counterparts. They ease your programming task by
incorporating the actions of multiple calls into a single call or by
reducing the number of data structures you must use.
Applications delete objects through a two-step process. Applications first
unset each field that they control, then applications call an OVw API
routine to delete the object. OVW removes the object from the OVW
object database only if the object is no longer in active use by any
application.
192
Chapter 5
193
194
Chapter 6
Maps
A map is a collection of OVW objects and their relationships. Users dont
view maps directly they view windows called submaps that display a
subset of map information.
Users, not applications, create maps. Users can create several maps, and
they can also control which applications operate on the various maps.
Whereas users create maps and define their scope, applications
dynamically update maps to reflect the state of the management
environment.
Among all the maps that might exist, users can select one map to be the
open map. The open map is the only map that can be updated. If
updates are needed for other maps, the updates are made at the time the
map is opened. Only one map can be open at a time in any given OVW
session.
Different users can open the same map through different OVW sessions.
The first user that opens a map is given read/write privileges on the map.
Users and applications can freely update and modify a map that has
read-write permissions. Subsequent users who open the map are given
read-only privileges on the map. Read-only maps are intended for
viewing purposes only and cannot be updated by users or applications.
Changes made to the read-write display of the map are not immediately
reflected on any read-only display. (Using the Refresh Map menu item, a
user can request that their read-only display be updated to reflect the
latest information.) There is, however, one exception to this policy of not
updating read-only displays, and it relates to status updates.
Applications can set status on a map that is opened with read-only
permissions. The status is not saved with the map, but it does allow for
timely status updates that mirror the read-write map.
Submaps
A submap is a collection of related symbols that are displayed in a single
Chapter 6
195
196
Chapter 6
197
198
Chapter 6
MAP
SUBMAP 1
SUBMAP 2
...
SUBMAP n
ROOT SUBMAP
SUBMAP 2
SYMBOL
SYMBOLS
SUBMAP 3
SYMBOLS
SUBMAP 3a
SUBMAP 3b
SYMBOLS
In Figure 6-1, submap 1 is the root submap for the map. Submaps 3A
and 3B are child submaps of the objects whose symbols appear in
submap 3. Submap 2 is an orphaned submap. Each submap contains
symbols that represent objects on the map. The map is a collection of
Chapter 6
199
Algorithm
Purpose
No Layout
Use for unrelated objects or objects whose only relationship is having the same
parent object. You can also use this layout algorithm for applications that need to
specify the exact placement of symbols (e.g., when using background graphics).
Point to Point
Bus
Use for network connections on a bus segment or for showing multiple objects that
tie into a common relationship.
Star
Use for network connections on a star segment or for showing multiple objects
connected into a common master or hub object.
Ring
Use for network connections on a ring segment or for showing multiple objects
with equal connectivity between all objects.
Row/Column
Use for submaps of unrelated objects, or objects whose only relationship is having
the same parent object. This layout algorithm is preferred over no layout algorithm
as it provides order for the user.
Multiple
Connections
Use for submaps that primarily contain a set of connections between two objects
(e.g., the logical channels of a physical link).
OVW uses the submap layout algorithm to automatically determine
symbol placement within the submap. Though automatic placement is
adequate for most applications, you can override the default symbol
layout algorithm and place symbols at particular locations in the
submap. This feature is described in Chapter 7 , Creating and Using
Symbols.
200
Chapter 6
Submap Planes
When users look at a submap, they see a graphical window containing
symbols, connections between the symbols, and, optionally, a special
window background. But in fact, submaps are actually composed of three
separate planes that are superimposed on one another. OVW manages
the graphical information maintained in these planes. The three planes
are:
a background plane, which contains either a solid color or a
user/developer supplied graphical image
an application plane, where applications add symbols
a user plane, where users add symbols.
The background plane is fairly straightforward. Applications can select
an image to serve as a backdrop for the submap. The image resides in the
background plane. If the background plane is empty, OVW displays a
solid color.
Symbols added by applications go on the submap application plane. The
presence of a symbol on the application plane indicates that the
underlying object has semantic meaning to the application.
Symbols added by users go on the user plane, at least initially.
Applications can request notification whenever a user adds a symbol to
the user plane. If the application judges that the symbol is appropriate
for that submap, then the application can move the symbol from the user
plane to the application plane, where it will be managed by the
application. Applications should not normally add, modify, or delete
symbols on the user plane, although the OVw API permits this.
Chapter 8 , Map Editing and Map Events, explains how applications
can determine when symbols or connections are added to submaps. See
that chapter if your application needs to determine when icon or
connection symbols are added to submaps.
Chapter 6
201
Chapter 6
Submap Presentation
The presentation of submaps in an OVW session is determined by two
features: submap overlay and submap geometry. When submap
overlay is on, the content in a parent submap window is overlaid when
its child submap is accessed. Alternatively a user can choose to display a
new submap window for each child submap. Submap overlay allows
users to browse through a submap hierarchy without having to explicitly
close unwanted submaps.
Submap geometry is the size and location of submap windows on the
display. Users can use the submap geometry features to construct
workspaces by arranging frequently-used windows in known locations.
Developers can change the default state of overlay and geometry. Refer to
Setting Submap Overlay on page 215 and Setting Submap Geometry
on page 216 for a description of the relevant APIs and data structures.
Chapter 6
203
NOTE
Submap Overlay
The behavior for submap overlay is based on how a submap is accessed.
When a user accesses a submap directly by double-clicking on a parent
symbol in a submap or by selecting root, parent, home or navigator from
the menus or the tool bar, the parent submap is overlaid by the child
submap.
Alternatively, when a user accesses a submap indirectly as a result of the
locate functionality or by selecting a submap from the Submap List
dialog, the new submap is redisplayed in the last location where it was
displayed or, if it has never been displayed or is transient, it is displayed
in a default location.
When a map is first open, all submaps, except the navigator submap, are
set to have overlay On. Users can turn submap overlay off or on for a
submap using the View->Submap Overlay menu items. For read/write
maps, this setting does not change until the user specifically changes the
value again. It is retained across submap closings for persistent submaps
and across sessions.
Submap Geometry
Users can also affect submap presentation by saving the
geometrysize and locationof a submap. A user who moves a submap
or resizes the submap window can save the new geometry using the
View->Window Geometry menu item. Geometry is saved only when an
operator uses View->Window Geometry-> Save For This Submap to
explicitly save it.
Typically, Window Geometry menu items force a submap to be open at
the same size and location as it was when the Window Geometry menu
items were selected; however, if the position and size specified for a
window is inappropriate for the current display screen, the window
manager determines where the window is placed.
204
Chapter 6
Chapter 6
205
Creating Submaps
As already described, submaps are the means by which users view
network and system management objects. From a programming point of
view, the creation of a submap and the display of a submap are actually
two separate operations. Applications can create submaps at any time
and have them available to service a user need. Users control when the
submap is displayed by some interaction with OVW, such as selection of
a menu item or double-clicking on an explodable symbol.
Creating a Submap
You can programmatically create submaps using the
OVwCreateSubmap() OVw API routine. OVwCreateSubmap() creates a
submap on the open map. It has the function prototype
OVwSubmapId OVwCreateSubmap(OVwMapInfo *mapInfo,
OVwObjectId parentObject,int submapPolicy,
int submapType, char *submapName,
int layout,unsigned int flags);
Chapter 6
Chapter 6
207
At this point, the submap has been created and is internally known by
OVW. No symbols have yet been placed on the submap, and the submap
has not been displayed to the user.
NOTE
Displaying a Submap
There are two ways for submaps to be displayed, depending on how users
interact with OVW:
If the user performs any of the following steps, OVW automatically
displays the submap:
The user double-clicks the mouse on an explodable symbol.
The user selects a submap through the OVW submap list box.
The user selects the open operation on a symbols pop-up menu.
If the user performs one of these steps and the submap does not
already exist, OVW will notify the user of this and prompt for
208
Chapter 6
209
Closing a Submap
There are several ways for submaps to be closed, depending on how users
interact with OVW.
If the user performs any of the following steps, OVW automatically closes
the submap; the application does not need to issue a call to the OVw API
to close the submap:
The user double-clicks the window menu button.
The user selects Map->Close Submap.
210
Chapter 6
Chapter 6
211
where:
map specifies a pointer to a map structure for an open map
parentID specifies the parent symbol id of the loaded submap
212
Chapter 6
The parameters display and layout apply to all of the loaded submaps.
The return value is a list of loaded submaps.
OVwLoadSubmaps() returns a pointer to an OVwSubmapLoadAckList
structure. The OVwSubmapLoadAckList data structure uses the standard
OVw API list form: it contains a integer count of the number of entries in
the list, and a pointer to the first in a contiguous array of entries.
typedef struct
int count;
OVwSubmapLoadAckInfo
} OVwSubmapLoadAckList;
*submaps;
Chapter 6
213
Chapter 6
Chapter 6
215
216
Chapter 6
Deleting a Submap
The OVwDeleteSubmap() routine deletes a submap. You can delete any
submap that has the shared submap policy, or you can delete an
exclusive submap if your application created the submap. The
OVwDeleteSubmap() routine has the function prototype
int OVwDeleteSubmap(OVwMapInfo *mapInfo,
OVwSubmapId submapId);
NOTE
When you delete a submap, OVW assumes that all symbols in the
submap should be deleted as well. OVW will delete all symbols in that
submap. If a symbol is deleted that is the last symbol that represents an
underlying object, then the object will be deleted also. Also, since an
object might serve as a parent object of a child submap, deleting an object
might result in the deletion of a child submap. Deleting a submap can set
off a series of symbol, object, and submap deletions. This recursive
deletion guarantees that unneeded symbols, objects, and submaps are
removed when no longer needed. Applications should not delete submaps
created by other applications.
Chapter 6
217
*/
*/
*/
*/
218
Chapter 6
Chapter 6
219
This routine is useful for setting the values of general fields that may
change. The default values for application configuration fields can be set
in the configuration enroll block in the application registration file. See
the reference pages if you need more information on this call.
220
*/
*/
*/
*/
*/
*/
*/
*/
*/
*/
*/
Chapter 6
*/
*/
*/
*/
*/
*/
Chapter 6
221
222
Chapter 6
Using OVwListOpenSubmaps()
This API returns the list of open submaps. This list of open submaps can
be filtered on an application name. Using this list, developers can bring
up an application to be in the same state it was when the user finished
using it. This API could be used to create a save session feature in an
application.
The signature for this API is:
OVwSubmapList *OVwListOpenSubmaps (OVwMapInfo *mapInfo,
char *appName)
Chapter 6
223
224
Chapter 6
Chapter 6
225
226
Chapter 6
Chapter 6
227
NOTE
Applications must acknowledge the map close event. OVW uses a timer
to detect unacknowledged close events, but that timer duration is
typically infinite.
The map close event callback routine and the map close acknowledgment
routines have the following function prototypes:
void (*OVwMapCloseCB) (void *userData, OVwEventType type,
OVwMapInfo *mapInfo,
time_t closing_time,
OVwEventSource source);
int OVwAckMapClose(OVwMapInfo *mapInfo, time_t close_time);
See the reference pages if you need more information about these calls.
228
Chapter 6
Chapter 6
229
Image Formats
Graphic files are quite large and may significantly increase the time
required to open each submap and significantly increase the amount of
memory required to view a submap. If the submap is transient, it
becomes persistent when you add a background graphic. Supported file
formats for background graphics are as follows:
NNM for all platforms:
GIF (CompuServe Graphics Interchange Form)
NNM for Windows NT and UNIX: Supports these graphic file formats
(not displayed when accessing NNM over the web):
BMP (Bitmap)
TIFF (Tag Image File Format
NNM for UNIX only: Supports these graphic file formats (not
displayed in NNM for Windows NT or NNM on the web):
XBM (X11 monochrome bitmap format)
PCX
Image
Starbase
XPM (X Pixmap format)
XWD (X Window Dump)
NNM for UNIX and NNM on the web only: Supports these graphic file
formats (not displayed in NNM for Windows NT):
JPEG (Joint Photographics Experts Group)
230
Chapter 6
Chapter 6
231
Summary
This chapter presented important OVW map and submap concepts. It
explained how submaps are related to maps, and how submaps provide
exploded views of objects. OVW provides a number of submap layout
algorithms that applications can choose from. The three submap planes
were described. Each submap has an application, user and background
plane.
To create a submap, a developer must specify a parent object, a submap
layout algorithm, a submap policy (shared vs. exclusive), a submap type,
and a submap name. Determining the application submap hierarchy is
an important part of designing an OVW application, and this chapter
described ways for developers to structure their submap hierarchy.
Applications that will be creating large numbers of submaps should
consider creating transient submaps on demand, to minimize the overall
size of the map database.
Numerous routines that retrieve map and submap information were
described. Developers can retrieve information about the open map or
any of the submaps in the open map.
Background graphics images were explained. Developers can use OVw
API routines to programmatically set or clear submap background
graphics.
Application integration was mentioned last. Applications are encouraged
to leverage existing map applications that provide useful services. For
example, the HP IP Map application performs many functions that other
map applications might be able to build upon. Map application
integration is addressed in Appendix A , Guidelines for Documenting
Map Applications, as well as in the HP OpenView Application Style
Guide.
232
Chapter 6
233
This chapter introduces the OVw API symbol routines. These routines
create, manipulate, and delete symbols in HP OpenView Windows.
You should read this chapter if your application deals with symbols in
HP OpenView Windows. You should already be familiar with
HP OpenView Windows objects, maps, and submaps, which were the
subjects of previous chapters.
234
Chapter 7
Overview
Topics in this chapter include:
characteristics of symbols
creating symbols
changing symbol appearance and behavior
retrieving symbol information
retrieving object information.
Chapter 7
235
Characteristics of Symbols
This section reviews basic symbol concepts that you must know before
you can create and manipulate symbols.
Symbol Characteristics
Every symbol has an assortment of attributes that apply directly to the
symbol, rather than to the underlying object the symbol represents. This
section describes the concepts behind these symbol attributes.
236
Chapter 7
Chapter 7
237
Chapter 7
Form
What It Does
No Position
The symbol has no specific position on the submap. OVW will use the default
symbol placement algorithm if you choose this placement value. This position is
valid for any layout algorithm.
Coordinate
Position
The symbol has an X, Y coordinate position within a grid of given width and
height. This position is valid for any layout algorithm.
Sequence Position
Star Center
The symbol is the center of a star layout. This position is valid only for the star
layout algorithm.
Note that not every position form is valid for every submap default
layout algorithm. Specifically, the Sequence Position and Star Center
Position are valid for only some layout algorithms. You should use care in
selecting a position form that is compatible with your submap default
layout algorithm.
Symbol Status
Each symbol within HP OpenView Windows can display status
information through the use of color. Each of the different possible status
values has an associated color that indicates the status of the symbol.
Chapter 7
239
Status Meaning
Icon Color/
Connection
Color
Administrative
Unmanaged
Off-white/Black
Administrative
Testing
Salmon/Salmon
Administrative
Restricted
Tan /Tan
Administrative
Disabled
Operational
Unknown
Blue/Black
Operational
Normal
Green/Black
Operational
Warning
Cyan/Cyan
Operational
Minor/ Marginal
Yellow/Yellow
240
Chapter 7
Icon Color/
Connection
Color
Status Meaning
Operational
Major
Orange/Orange
Operational
Critical
Red/Red
These status colors are preset by OVW. For UNIX system applications,
developers or users can, however, change these colors through the X
resource file (see the ovw(1) reference page).
OVW Status Types - ISO 10164 Severity Levels If you are familiar
with the ISO 10164 standard for alarm reporting functions, use the
following list to map the ISO severity levels to their OVW equivalents:
Table 7-3
none
unmanaged
cleared
normal
indeterminate
unknown
critical
critical
major
critcal
minor
minor/marginal
warning
minor/marginal
Status Sources Symbols can receive status from one of three sources:
Status by Object This status source causes the symbol to reflect the
status for the underlying object. This status source allows multiple
Chapter 7
241
242
Chapter 7
Chapter 7
243
Attribute
Description
Flashing symbols
Applications can present symbols that have normal status and size
so that only the inside graphic is visible. This results in a less
cluttered submap where non-normal status is more easily
perceived. Operators can disable this feature by changing a setting
in an X resource file. Refer to Transparent Symbol Background
on page 270.
244
Chapter 7
Attribute
Description
Text annotation
Chapter 7
245
Creating Symbols
This section describes how to create icon and connection symbols. Once
you understand the symbol characteristics presented in the previous
section (label, position, status, status source, type, etc.), symbol creation
is quite straightforward. You should read this section even if you dont
plan to create your own symbols. This section describes other elements
that are important later in this chapter, such as symbol placement.
246
Chapter 7
Chapter 7
247
These routines let you identify the object by one of its names, instead of
by its object ID. If the object does not yet exist, these routines will first
create the object for you using OVwDbCreateObject():
OVwCreateComponentSymbol(), OVwCreateComponentSymbolByName()
These two routines let you create symbols on a submap by identifying the
parent object of the submap, rather than by identifying the submap ID. If
the submap does not exist, OVW will create it for you.
These convenience routines use many of the same parameters as the
general purpose OVwCreateSymbol() routine and are quite similar in
concept. See the reference pages if you need more information on these
calls.
Symbol Creation Flags
Flags control miscellaneous aspects of symbol creation. You can use one
of the following flags when you create a symbol:
ovwNoSymbolFlags
This is equivalent to passing a NULL value for the flags parameter
to OVwCreateSymbol().
248
Chapter 7
struct {
placement;
ovwNoPosition
ovwCoordPosition
ovwSequencePosition
Chapter 7
0
1
2
*/
*/
*/
*/
249
/* star center */
/* ovwCoordPosition */
/* x position on grid */
/* y position on grid */
/* width of grid */
/* height of grid */
/* ovwSequencePosition */
un.coords.x
un.coords.y
un.coords.width
un.coords.height
un.pred_symbol
The placement field is set to one of the four position forms. If you use
either the ovwCoordPosition or ovwSequencePosition, you will also
need to set the appropriate values within the un union.
NOTE
250
Chapter 7
Chapter 7
251
252
Chapter 7
Chapter 7
253
254
Chapter 7
Chapter 7
255
*/
*/
*/
*/
*/
*/
*/
*/
The following example shows how to create multiple symbols with the
OVwCreateSymbols() routine (assuming that it is compiled with
OVwAPILevel=4):
#include <OV/ovw.h>
#define BUILD_ICON(sym,sid,oid,stype,slabel,stat,src,pos,flgs)
{\
sym.submap_name_style = ovwSubmapIdValue; \
sym.sc_submap_id = sid; \
sym.object_name_style = ovwObjectIdValue; \
sym.sc_object_id = oid; \
sym.label = slabel; \
sym.status = stat; \
sym.status_source = src; \
sym.symbol_type = stype; \
sym.symbol_variety = ovwIconSymbol; \
sym.flags = flgs; \
sym.sc_icon_position = pos; \
sym.object_comments = "No comment"; \
sym.error = 0; \
sym.symbol_id = ovwNullSymbolId; \
}
#define BUILD_CONNECTION(sym, oid, stype, slabel,
svalue,src,sym1,sym2,flgs) {\
sym.object_name_style = ovwObjectIdValue; \
sym.sc_object_id = oid; \
sym.label = slabel; \
sym.status = svalue; \
sym.status_source = src; \
256
Chapter 7
Chapter 7
257
258
Chapter 7
Deleting Symbols
The OVw API provides two routines to delete symbols. The
OVwDeleteSymbol() routine deletes a single symbol from the open map,
while the OVwDeleteSymbols() routine deletes a list of symbols. Either
routine can be used to delete icon or connection symbols.
These routines have the function prototypes:
int OVwDeleteSymbol(OVwMapInfo *mapInfo,
OVwSymbolId symbolId);
int OVwDeleteSymbols(OVwMapInfo *mapInfo,
OVwSymbolIdList *symbolList);
Chapter 7
259
260
Chapter 7
Chapter 7
261
262
Chapter 7
Symbol Alert
3
Text Annotation for
Symbol Alert
Pop-Up Menu
4
Default Action
5
Alert Action 2
Alert Action 3
A Base Symbol
Chapter 7
263
264
Chapter 7
Chapter 7
265
NOTE
Symbol alerts are not stored when a map is closed. When the map is
closed all symbol alert information for that map disappears.
266
Chapter 7
Chapter 7
267
userData is the return user data provided when callback was added.
type is the event type which invoked the callback.
mapInfo is the map structure for the open map.
symbolInfo is the OVwSymbolInfo of the symbol whose alert was
deleted.
source returns an OVwEventSource value, as defined in ovw.h. For
OVwConfirmDeleteSymbolAlertCB(), source is always 5
ovwEventSourceApp.
268
Chapter 7
Chapter 7
269
270
Chapter 7
Chapter 7
271
An executable symbol visual cue is disabled only if the user has the X
resource set to True and the developer has specified that the symbol
should not show the executable cue. The default X resource for this
functionality is:
OVw*enableExecCueRemoval:True
Flashing Symbols
To provide developers additional ability to draw attention to specific
symbols OVW provides capability to set a symbol to flashing. A flashing
symbols appearance alternates between two states. The first state has
the normal status color. The second state displays the symbol with the
background color instead of the status color. The alternation of these two
states does not exceed two flashes per second.
Flashing symbols have special behavior during map editing operations.
Dragging a flashing symbol makes a copy of the symbol on the target
submap; it does not remove the symbol from the original submap. A
message is displayed to inform users that a flashing symbol cannot be
moved to another submap.
Cutting a flashing symbol is denied. If a user attempts to cut a flashing
symbol, OVW displays a message explaining that the operation is not
possible.
Developers can specify symbol flashing via the OVwModifySymbol and
OVwModifySymbols APIs. The update flag is:
ovwUpdateSymbolFlashing
A symbol will be flashing if the developer has specified that the symbol
should be flashing and the user has enabled the functionality in the appdefaults file. If the X resource is not specified in the app-defaults file, the
functionality is enabled by default. The default X resource for this
functionality is:
OVw*enableFlashing:True
272
Chapter 7
Chapter 7
273
NOTE
274
Chapter 7
Chapter 7
275
You can use application-defined symbol types or you can use the symbol
types provided with OVW. The header file
\OpenView\include\OV\sym_types.h (Windows NT operating system)
or $OV_HEADER/OV/sym_types.h (UNIX systems), which is
automatically included by \OpenView\include\OV\ovw.h (Windows NT
operating system) or $OV_HEADER/OV/ovw.h (UNIX systems), contains
localized string definitions for symbol types shipped with OVW.
276
Chapter 7
NOTE
Chapter 7
277
278
Chapter 7
NOTE
You should use discretion when using this routine. In most cases, an
application should not change a label that has been modified by the user.
It is usually safe to change the label if the application originally set the
label and the user has not modified it (the label still has the value set by
the application). The OVwGetSymbolInfo() routine, which is described
later, can retrieve the symbol label for a given symbol.
Chapter 7
279
The statusSource field can contain any of the three status sources
described earlier in this manual: ovwSymbolStatusSource,
ovwObjectStatusSource, or ovwCompoundStatusSource.
You should change status source only for symbols that you create or for
symbols that users add to submaps that you create. Do not change status
source for symbols created by other applications. Further, if end users
have modified the status source for an application-created symbol, you
should not alter the users preference.
Changing the Status Value
You have two ways to set status:
on the symbol if the status source is ovwSymbolStatusSource
on the object if the status source is ovwObjectStatusSource.
You cannot directly set the status for a symbol that has compound status
source. If the symbol has compound status, you can set symbol or object
status only on the contained symbols or objects. As a result, the
compound status may change. The algorithm for determining how to
propagate compound status is managed internally within OVW.
The OVw API routines that set status values on a symbol or object have
the following function prototypes:
int OVwSetStatusOnSymbol(OVwMapInfo *mapInfo,
OVwSymbolId symbolId, OVwStatusType status);
280
Chapter 7
The symbolList and objectList data structures have the same form as
other common list structures in the OVw API. They contain a count of
the number of elements in the list, and a pointer to the first in a
contiguous array of list entries.
Chapter 7
281
282
var_un.position
var_un.conninfo.endpoint1_id
var_un.conninfo.endpoint2_id
Chapter 7
var_un.conninfo.is_meta_conn
int behavior;
/* ovwSymbolExplodable,
ovwSymbolExecutable */
OVwAppList apps;
/* applications interested in symbol */
OVwSymbolBehavior behavior_info; /* Details of symbol behavior */
#if (OVwAPILevel > 4)
char *drop_app_name;
char *drop_action;
OVwBoolean exec_vis_cue; /* whether executable symbol has box around it */
OVwBoolean transparent; /* whether symbol is transparent */
OVwBoolean flashing;
/* whether symbol is flashing */
OVwStatusType secondary_status; /* secondary status of a symbol */
int percent_full;
/* the fill percentage of a symbol */
char *text_annotation; /* text annotation text */
OVwSymAlertType symbol_alert_type; /* symbol alert (s alert) type */
char *symbol_alert_creating_app;
/* application that created the s alert */
char *symbol_alert_action_app;
/* s alert default action - app id */
char *symbol_alert_action;
/* s alert default action - action id */
char *symbol_alert_text;
/* s alert text annotation */
OVwAlertTextAlignment symbol_alert_text_alignment;
/* s alert text align */
#endif
} OVwSymbolInfo;
Most of the fields have already been used in previously described OVw
API symbol routines.
Two fields in particular in this data structure, however, deserve
comment. The symbol_variety field serves as a tag for the union that
follows it (var_un). If the symbol is an icon, then the position field
contains icon-specific symbol information (the symbol position in this
Chapter 7
283
284
Chapter 7
The following code fragment shows how to list the connections of a metaconnection submap.
<OV/ovw.h>
...
int i;
OVwSymbolInfo *syminfo;
OVwSymbolList *symlist;
OVwMapInfo *map = OVwGetMapInfo();
OVwSymbolId from_id, to_id;
syminfo = OVwGetConnSymbol(map, from_id, to_id);
if (!syminfo) {
printf("No connection!\n");
} else if (!syminfo->var_un.conninfo.is_meta_conn) {
printf("Single connection.\n");
/* symbol represents the object syminfo->object */
} else {
Chapter 7
285
286
Chapter 7
Chapter 7
287
/*
/*
/*
/*
/*
/*
/*
object ID */
child submap of object */
number of symbols on open map */
object-specific status */
compound (propagated) status */
ovwNotApplicable, ovwOpenMapScope,... */
object capability field values */
Note that all of the fields in this structure are map-specific. In other
words, these fields apply only to the object as it relates to the current
map. They do not apply to instances of the object on other maps. Most of
the fields in the data structure are self-explanatory. Two fields, however,
require further description.
288
Chapter 7
Chapter 7
289
290
Chapter 7
Chapter 7
291
Summary
This chapter described how to use the OVw symbol routines to create,
manipulate, and delete symbols.
The distinction between symbols and objects was reviewed. Important
symbol characteristics were described, including symbol type, variety,
behavior, position, and status. Symbol creation was presented, both for
icon and connection symbols. Examples showed how to use
OVwCreateSymbol() to create an icon symbol with the default position.
Later, sequence and coordinate symbol position were described, as were
the symbol flags.
Various OVw API symbol routines were presented that change symbol
appearance or behavior. These included routines to change symbol
position, symbol label, symbol behavior, symbol type, symbol status, and
symbol status source.
The chapter described how to retrieve symbol information using the
OVwGetSymbolInfo() routine and various other related routines. The
chapter concluded by describing how to retrieve map-specific object
information. Objects have both global and map-specific object attributes.
The map-specific object attributes include object status, the submap ID
for a child submap, and the compound status of the object.
292
Chapter 7
293
This chapter introduces the OVw API map editing routines. Map editing
routines support applications in interacting with end users who perform
such operations as adding objects, creating submaps, or deleting
symbols.
You should read this chapter if your application needs to be notified
when users or other applications modify the map, or if your application
supports any of the four map editing operations (that is, you have
registered enroll blocks in your applications application registration
file).
This chapter addresses these topics:
receiving notification of map changes
participating in map changes
cut and paste operations
drag and drop operations (HP-UX and Solaris only)
how to participate in map locates
considerations for transient submaps.
294
Chapter 8
Chapter 8
295
Table 8-1
ovwEndSession
ovwSelectionListChange
ovwMapOpen
ovwMapClose
ovwConfirmDeleteSymbols
ovwConfirmDeleteObjects
ovwConfirmDeleteSubmaps
ovwConfirmCreateSymbols
ovwConfirmCreateObjects
ovwConfirmCreateSubmaps
ovwConfirmMoveSymbol
ovwConfirmManageObjects
ovwConfirmUnmanageObjects
ovwConfirmHideSymbols
296
Chapter 8
ovwConfirmUnhideSymbols
ovwConfirmSymbolStatusChange
ovwConfirmObjectStatusChange
ovwConfirmCompoundStatusChange
ovwConfirmCapabilityChange
As you can see from the table, the names of the callback routine function
prototypes are derived from the event name. For example, the
ovwConfirmSymbolStatusChange event has the callback routine
(*OVwConfirmSymbolStatusChangeCB)(). This naming convention lets
you easily translate between event types and function prototypes.
The concepts behind most of these events have been presented earlier in
this manual. Object, symbol, and submap creation, deletion, and
modification are described in previous chapters. You can refer to those
chapters if you need to review those operations. There are, however, two
new concepts that have not been described yet hidden symbol events
and unmanaged object events. These are described next.
Chapter 8
297
Manage/Unmanage Events
Through the OVW user interface, users can control whether an object is
managed. Applications can dynamically manage and unmanage objects
via the OVW API (see Managing Objects on page 313). Symbols
representing unmanaged objects do not receive status updates from
applications. Applications will receive errors if they attempt to change
the status on an unmanaged object or on the symbol that represents the
unmanaged object. An unmanaged object remains unmanaged until it is
explicitly re-managed through the OVW user interface or the
OVwManageObject() or OVwManageObjects() API. The manage and
unmanage operations are disabled during map synchronization.
All symbols representing an unmanaged object have the same status
color to reflect the unmanaged status. By default, unmanaged icon
symbols are off-white in color, and unmanaged connection symbols are
black. See Chapter 7 , Creating and Using Symbols, if you need more
information about status colors and their meaning.
Note that all symbols representing an object on a particular map,
regardless of the symbol status source, are changed to unmanaged status
if the underlying object is unmanaged.
By registering for the ovwConfirmUnmanageEvent, applications can
298
Chapter 8
Chapter 8
299
300
Chapter 8
NOTE
For this form of map editing to work correctly, an application must have:
1) defined one or more enroll blocks in the ARF, and 2) registered both
Query and Confirm callback routines. If an enroll block does not exist,
OVW cannot construct the application-specific dialog box. If the callback
routines are not registered, OVW cannot communicate with the
application.
Chapter 8
301
Query-Verify-Confirm Transactions
User Action
Time
User presses
[Verify] or
dialog box is
enrolled for
automatic
verification.
Responsible Application
OVwQueryAddSymbol event
Other Applications
Application checks if
user-supplied
information is valid.
Application responds to
OVW, setting a lag to
indicate if the valid.
Query-Verify-Confirm Routines
The following list contains the callback routine and verify routine
function prototypes that apply for each of the four map operations. The
function prototypes are grouped by map operation.
302
Chapter 8
Chapter 8
303
If your application supports any of these four map operations, you should
register the appropriate enroll blocks in your applications ARF, as well
as registering the appropriate callback routines.
NOTE
If your application registers for any of the query callback routines, your
application must call the associated OVW verify routine as part of the
query callback processing. Users may experience unnecessary delays if
your application does not call the verify routine as part of query event
processing.
See the reference pages if you need more information about these calls.
The following short code segments show how to use the Query-VerifyConfirm routines. This example shows how an application might handle
Describe operations. Assume the following entry is present in the
applications application registration file:
Application "User Management" {
...
Enroll Describe {
if isUser {
Field "User Name" {
EditPolicy NoEdit;
}
Field "Default Shell" {
}
Field "User Information" {
}
}
}
304
Chapter 8
Chapter 8
305
306
Chapter 8
Deleting a Symbol
Symbol deletion through the user interface uses the
Query-Verify-Confirm transaction, though in a slightly different way.
Unlike the dialog boxes presented in the other map operations, the delete
symbol dialog box does not have a [Verify] button. Users can simply
press [OK] to proceed, or [Cancel] to cancel the symbol deletion.
If the user presses [OK], OVW sends the ovwQueryDeleteSymbol event
to all applications registered for the event. The applications then
Chapter 8
307
308
Chapter 8
/*Located object */
/*Parent obj of submap
where the object exists */
} OVwLocateResultObject;
typedef struct {
int count;
/* number of items on list */
OVwLocateResultObject *results;/* contiguous list of items */
} OVwLocateResultList;
Chapter 8
309
Information Received
Information Returned
OVwAttributeLocateCB
OVwSymbolStatusLocateCB
OVwSymbolTypeLocateCB
OVwSymbolLabelLocateCB
Locating Symbols
NNM provides functionality to programmatically locate symbols within
the OVW object database. This functionality duplicates the locate
functionality available from the OVW GUI.
The OVwLocateBySelectionName(), OVwLocateByAttribute(),
OVwLocateBySymbolStatus(), OVwLocateByComment(),
OVwLocateBySymbolType(), and OVwLocateBySymbolLabel() routines
return a list of symbol or object locations that match the search criteria.
The OVwLocateResultSymbol() structure describes the located symbol
or object:
typedef struct {
OVwObjectId object_id;
OVwSymbolID symbol_id;
310
Chapter 8
NOTE
If you want your application to use Locate APIs before ipmap is started,
then the application should register for ovwAttributeLocate events
even if it does nothing in the callback function handling the event.
Chapter 8
311
312
Chapter 8
Managing Objects
OVW provides several APIs to let you programmatically manage or
unmanage an object or list of objects on a map. Unlike the object
management functionality available to operators via the user interface,
these calls are not recursive; that is. they do not manage or unmanage
objects contained in the child submap of an object managed via these
calls.
The signatures for OVwManageObject() and OVwManageObjects() are:
int OVwManageObject(OVwMapInfo *mapInfo,
OVwObjectId objectId);
int OVwManageObjects(OVwMapInfo *mapInfo,
OVwObjectManageList *objects);
Chapter 8
313
314
Chapter 8
NOTE
OVW assigns new symbol IDs to pasted symbols. Symbols in a cut and
paste operation are identical except for their symbol IDs. Be aware that
if the user cuts multiple symbols that have the same underlying object,
you may not be able to distinguish the symbols in the paste operation
without some other contextual information such as the submap ID or
other unique application identifier.
Chapter 8
315
316
Chapter 8
Chapter 8
317
318
Chapter 8
Customization Steps
The following steps, which are discussed in detail throughout the
remainder of this section, explain how to customize drop target behavior.
Chapter 8
319
320
Chapter 8
321
322
Chapter 8
Chapter 8
323
Summary
This chapter described OVW map editing. Applications that need to be
notified of map changes can register callback routines using the
OVwAddCallback() routine. Table 8-1 listed some of the possible map
editing events.
Applications that support symbol deletion, or any of the four OVW map
editing operations (Add, Connect, Configure, and Describe), must also
register callback routines to interact with OVW to control whether the
user changes are allowed. The interaction between OVW and the
application follows a Query-Verify-Confirm process. OVW invokes an
application callback routine that checks the proposed values. The
application responds with a Boolean value indicating whether the values
are acceptable. OVW gives the user the opportunity to cancel the
operation or to proceed. If the user proceeds, OVW makes the changes
and then invokes a second application callback routine to confirm that
the changes were made.
A special dialog between OVW and the application occurs when the user
requests to delete a symbol. OVW queries the application to determine if
the symbol should be deleted. If a user does not want to view a symbol
that cannot be deleted, the user can hide the symbol through the OVW
user interface. Applications can operate on hidden symbols just as if they
were visible.
The OVW user interface cut and paste operations were then described.
To an application, the cut and paste operations appear as unrelated
delete and add events. The application is responsible for buffering any
information relating to the delete event that might be needed later. The
application is also responsible for determining if the add event actually
represents a paste operation.
Customization of drag and drop operations allows HP-UX and Solaris
application developers to assign drop targets and associate actions with
drop operations.
324
Chapter 8
Supporting Management
Consoles
325
326
Chapter 9
Overview
The HP OpenView management server supports distributed
management consoles. Management consoles are systems that use the
same object, topology, and map databases as the management server.
Each management console actually runs the OVW user interface and its
related processes, thereby off-loading significant memory and CPU
resources from the management station. As a result, the management
station is able to focus its resources (memory and CPU) on the
management station processes and responsibilities.
By running ovwsetupclient, a user configures a system as a
management console that shares common configuration and data with
the management server. The following universal path names are shared
between client and server:
$OV_BACKGROUNDS
$OV_BITMAPS
$OV_DB
$OV_FIELDS
$OV_HELP
$OV_LRF
$OV_REGISTRATION
$OV_SHARE_CONF
$OV_SHARE_LOG
$OV_SHARE_TMP
$OV_SNMP_MIBS
$OV_SYMBOLS
The only database directly accessed over the shared file system is the
OVW map database. The object and topology databases are accessed
transparently over TCP/IP sockets.
Applications built with OVW 4.X or 5.X libraries can run on
management consoles in this distributed environment. These libraries
handle locating the management server and connecting to the object
database transparently. Applications must also be executable on the
Chapter 9
327
Distributing Applications
OVwSessionID=Juliet:0
Management
Console
Management
Console
OVwSessionID=Romeo:0
ovw
socket
ovw
socket
Management Server
ovwdb
daemon
Shared file
system
Shared file
system
socket
socket
map
database
Shared file
system
object
database
socket
OVW Application
OVwSessionID=Juliet:0
ovw
OVwSessionID=Antonio:0
Management
Console
328
Chapter 9
Chapter 9
329
330
Chapter 9
Chapter 9
331
332
Chapter 9
Chapter 9
333
334
Chapter 9
10
Developing Internationalized
and Localized Applications
335
This chapter
introduces the basic concepts of software internationalization and
localization, and explains how they are supported within
HP OpenView Windows.
explains the set of programming techniques application developers
should use to produce internationalized and localized C and C++
applications.
discusses special considerations for C and C++ applications that have
been internationalized or localized in the past.
The HP OpenView Application Style Guide provides additional
guidelines for designing HP OpenView applications for
internationalization and localization.
This chapter does not explain internationalization and localization
information for Web-based applications, Java applications, or applets.
This chapter does not explain general guidelines for designing or
developing internationalized or localize software.For more information
on these subjects refer to these books:
McFarland, Tom; X Windows On The World: Developing
Internationalized Software with X, Motif and CDE, Prentice Hall
PTR, New Jersey, 1996.
ODonnell, Sandra Martin; Programming for the World: A Guide to
Internationalization, Prentice Hall PTR, New Jersey, 1994.
336
Chapter 10
Internationalization
To produce software for multiple countries, the software must be
designed to support cultural and linguistic conventions of those
countries. This typically implies that the software allows a user to
interact with the software in his or her native language (such as,
German or Japanese), processes input and output characters that belong
to the users native language, and follows various linguistic and cultural
conventions and rules that are applicable to the software.
There are various approaches for designing software to meet the various
linguistic and cultural conventions. One approach is to produce a
different binary version of a software per language: one version for
German, one version for French, one version for Japanese, and so on.
This methodology is usually very inefficient. A better approach is to
internationalize the software.
Internationalization is a design technique in which the software has
been sufficiently generalized so that a single binary can support various
linguistic and cultural conventions. Internationalized software uses the
ANSI locale model.
Locale is a collective term for the language of the user, the location or
territory of the user (which determines local customs, such as currency
formats), and the code set in which the users data is represented. The
locale is also a physical data file and/or collection of routines that are
used to initialize an applications language sensitive environment. The
definitions are often used interchangeably since the physical file is an
implementation or instantiation of the language, territory, and code set.
In the locale model, the software user announces their desired
language at application start up. An initialization routine placed in the
software then loads tables and run-time procedures appropriate for that
language. Generic routines in the software then base their behavior on
the tables and run-time procedures. For example, when sorting (or
ordering) a list of names to be displayed to the user, an application might
call strcoll() or wcscoll() functions (for more information on these
commands, refer to string(3C) on HP-UX or Solaris systems). These
routines use the conventions of the users announced language.
Applications that integrate with HP OpenView Windows are expected to
follow this basic internationalization model.
Chapter 10
337
Localization
Once the software is internationalized, it is possible to produce a
localized version of that software. Localization refers collectively to all
work needed to make a product acceptable and functional for use in a
specific locale. This includes translating all text to be displayed to the
user, translating documentation, and providing fonts and other special
functionality when needed.
For example, the Japanese product is internationalized and its user
interface (menu labels, warnings, and error messages), manuals, and
online help have been translated into Japanese.
Even if software is not localized to a specific countrys language, it is still
important to internationalize the software so that it can process the
users local language data and operate according to the rules and
customs of his/her language.
338
Chapter 10
Chapter 10
339
340
Chapter 10
String Overloading
Commonly, non-internationalized software uses a single string as both
the internal reference to an object and as the string displayed for that
object. In essence, a single string is overloaded to serve these two
separate purposes. When such software is internationalized, it is
necessary to remove such overloading. The application needs a single,
consistent string name to use when internally referencing an object. This
string not only must be consistent between different language versions of
the application but between the application and all language versions of
NNM. At the same time, localized versions of the software need to
translate the string to be displayed in the language of each locale.
For this reason HP OpenView Windows provides a DisplayString
attribute, described in the following sections. If your software similarly
uses a single string as both an internal reference and as a string
displayed to the user, consider replacing the single string with a
structure, such as:
typedef struct _MyObject{
/* constant name used to identify the object;*/
/* guaranteed to be the same across all locales */
char * internal_name;
/* localizable name, displayed to the user */
char * display_name;
} My Object, *MyObjectPtr;
Chapter 10
341
Application Integration
An application developer needs to ensure that the application can
integrate with HP OpenView Windows even when an end-user is
running OVW under a non-English language.
If a localized version of the applications registration file does not exist
(typically the case if the application has not been localized in general),
the English version of the registration file should be stored under the
\OpenView\registration\C directory (Windows NT operating system)
or under the /etc/opt/OV/share/registration/C (UNIX systems)
directory.
NOTE
342
Chapter 10
Chapter 10
343
344
Chapter 10
OVwSymbolType Argument
When an application needs to specify the OVwSymbolType type argument
to call the various OVw APIs, such as OVwCreateSymbol() or
OVwCreateConnSymbol(), it is important to specify the non-localized
name associated with the symbol class and type regardless of the locale
that the application specifies.
For example:
#include <OV/ovw.h>
OVwSymbolId symid;
Chapter 10
345
346
Chapter 10
Chapter 10
347
to obtain symbol
OVwGetAction()
OVwGetApp()
Chapter 10
Chapter 10
349
NOTE
350
Chapter 10
With 5.X and 6.X releases, the Japanese characters in the SymbolType
field should be replaced with ASCII characters and a DisplayString
statement should be added containing the Japanese characters for
display purposes:
SymbolType "Computer" : "Custom PC"
{
DisplayString "Custom PC in Japanese";
}
Chapter 10
351
Chapter 10
OVwGetAppName(), OVwGetFirstAction(),
OVwGetNextAction(), OVwGetSymbolInfo(),
OVwListSymbolTypes()
You must modify any application obtaining a localized string for
application, action, or symbol type names with any of the following OVw
APIs OVwGetAppName(), OVwGetFirstAction(), OVwGetNextAction(),
OVwGetSymbolInfo(), OVwListSymbolTypes(). To make the required
modifications do the following:
To obtain the localized strings for application names, replace
OVwGetAppName() calls with a reference to the displayString field
of OVwAppRegInfo struct. This struct can be obtained via
OVwGetApp().
To obtain the localized strings for action names, replace
OVwGetAppName() calls and OVwGetNextAction() calls with a
reference to the displayString field of OVwActionRegInfo struct. This
struct can be obtained via OVwGetAction().
To obtain the localized strings for symbol type names, replace
OVwListSymbolTypes() and OVwGetSymbolInfo() calls with
OVwFormatSymbolType().
Chapter 10
353
354
Chapter 10
In general, we recommend that you not attempt to integrate noninternationalized applications with HP OpenView Windows and other
internationalized applications. If an application is a map-writer
application and is highly integrated with HP OpenView Windows, the
application can potentially corrupt the internationalized data generated
by HP OpenView Windows, by other internationalized applications, and
by the end user. For example, HP OpenView Windows can create an
object with a selection name that contains European and/or Asian
language characters. If a non-internationalized application operates on
selection names, the application may corrupt the name.
English Windows NT operating system applications are expected to run
on non-English versions of the Windows NT operating system.
On UNIX systems, if you want to integrate a non-internationalized
application with HP OpenView Windows and other internationalized
applications, consider the following:
Determine whether the non-internationalized application operates on
any potentially localized data generated by HP OpenView Windows
or other internationalized applications. If so, the application can be
supported only when HP OpenView Windows and other applications
are all running under the C localethat is, under English.
Determine whether the non-internationalized application operates on
any localized data generated by itself or by an end-user. For example,
if an application is running under a European and/or Asian locale, the
date and time format (generated by the underlying system functions)
may be different from the C locale format. A non-internationalized
application may not know how to display or read those formats
correctly. On UNIX systems, the workaround is to customize the
application to start up using the C locale at all times. For example, in
Chapter 10
355
356
Chapter 10
Summary
An application should be internationalized even if it is not localized.
An application should maintain a level of indirection whenever
accessing localizable data internally from within the application code.
That is, use message catalogs or resource files to obtain the
localizable data for internal use.
Use a DisplayString statement in configuration files, application
registration files, symbol registration files, and field registration files
to specify localized strings for Application, Action, SymbolClass,
SymbolType, and Field names.
Use displayString field in OVwAppRegInfo and OVwActionRegInfo
structs to specify localized strings for Application and Action
names, when calling OVwCreateApp() and OVwCreateAction().
Use OVwGetApp(), OVwGetAction(), and OVwFormatSymbolType() to
obtain the localized strings of Application, Action, and SymbolType
names.
Chapter 10
357
358
Chapter 10
11
359
This chapter provides an overview of the use model for the HP OpenView
Web applications, lists the integration points available to administrators
and developers, and describes the OVwww API for accessing web session
information. Because the integration points are available in registration
files, details for integrating applications with the HP OpenView Web
Launcher and the Network Presenter are in Managing Your Networks.
The HP OpenView Application Style Guide explains the guidelines for
designing applications for integration with the HP OpenView Web
Launcher.
As an application developer, you need to
understand the use model for the HP OpenView Web Launcher and
the web applications
understand the security model for the Launcher and web applications
understand what a Launcher session is
know what APIs are available to you to access session information.
360
Chapter 11
Model of Operation
User Model
The HP OpenView web applications provide access to NNM management
information from a remote client system that is running a web browser.
The applications run on the management station, but can be accessed
from anywhere. Because these applications can be accessed from
anywhere, a security model is provided to ensure that only authenticated
users log in to an NNM management station.
The HP OpenView Web Launcher is the entry point for users who are
accessing web applications such as the Network Presenter. A user begins
a web session by specifying the ovlaunch.exe URL, or by selecting
Tools->HP OpenView Launcher from the NNM menus. If security is
enabled and configured for the HP OpenView Web, the user must enter
their name and a password before the Launcher is displayed.
Security
The HP OpenView Web provides security in the form of user
authentication and authorization. Security can be globally disabled
through the configuration file \OpenView\www\conf\session.conf on
the Windows NT operating system or
/etc/opt/OV/share/www/conf/session.conf on UNIX systems.
Security is set up via several configuration files:
the user password file:\OpenView\www\etc\htpasswd on the
Windows NT operating system or
/etc/opt/OV/share/www/etc/htpasswd on UNIX systems.
the user roles file: \OpenView\www\etc\htgroup on the Windows NT
operating system or /etc/opt/OV/share/www/etc/htgroup on
UNIX systems.
the session configuration file: \OpenView\www\conf\session.conf
on the Windows NT operating system or
/etc/opt/OV/share/www/conf/sesson.conf on UNIX systems.
Chapter 11
361
Network
Presenter
Web
Launcher
Alarm
Browser
Web Browser
OVW Server
httpd
ovw
ovalarmsrv
ovwdb
CGI Programs
pmd
Map
database
Event
database
ovsessionmgr.exe
config. files
Object
database
configuration file
background service
If the session times out and the user logs back in with different values,
the application will not be notified of this. The application will continue
running with the old values.
362
Chapter 11
Chapter 11
363
Description
jovw.exe
jovwreg.exe
jovgraph.exe
snmpviewer.exe
webappmon.exe
ovlaunchreg.exe
ovlaunch.exe
Launches the Launcher and opens the user login screen, when
UserLogin is set.
ovlogin.exe
ovsessioninfo.exe
ovalarm.exe
ovwebdata.exe
OvWebHelp.exe
printsession.exe
364
Chapter 11
Chapter 11
365
Configuration or
Integration Point
File
authentication
UNIX systems
Definition: /etc/opt/OV/www/etc/htpasswd
On/off :/etc/opt/OV/share/www/conf/session.conf
Windows NT operating system
Definition: \OpenView\www\etc\htpasswd
On/off: \OpenView\www\conf\session.conf
authorization
UNIX systems
Definition: /etc/opt/OV/www/etc/htgroup
On/off: /etc/opt/OV/share/www/conf/session.conf
Windows NT operating system
Definition: \OpenView\www\etc\htgroup
On/off: \OpenView\www\conf\session.conf
auditing
UNIX systems
Definition: /var/opt/OV/www/logs/launcher/access_log
Definition: /var/opt/OV/www/logs/launcher/login_log
On/off: /etc/opt/OV/share/www/conf/session.conf
Windows NT operating system
Definition: \OpenView\www\logs\launcher\login_log
Definition: \OpenView\www\logs\launcher\access_log
On/off: \OpenView\www\conf\session.conf
366
Chapter 11
Configuration or
Integration Point
File
session timeout
UNIX systems
/etc/opt/OV/share/www/conf/session.conf
Windows NT operating system
\OpenView\www\conf\session.conf
locale mapping
UNIX systems
/opt/OV/bin/ovchange_locale_mapping
Windows NT operating system
Not available
installed locale
UNIX systems
/etc/opt/OV/share/www/conf/locales.installed
Windows NT operating system
\OpenView\www\conf\locales.installed
parameter
configuration
UNIX systems
/opt/OV/www/htdocs/$LANG/nnm/launcher/browser.html
Windows NT operating system
\OpenView\www\htdocs\$LANG\nnm\launcher\browser.html
application
integration into the
Launcher
UNIX systems
/etc/opt/OV/share/www/registration/launcher/<LANG>
Windows NT operating system
\OpenView\www\registration\launcher\<LANG>
application
integration into
Network Presenter
UNIX systems
/etc/opt/OV/share/www/registration/jovw/<LANG>
Windows NT operating system
\OpenView\www\registration\jovw\<LANG>
Chapter 11
367
368
Chapter 11
Chapter 11
369
OVwwwIsLoginEnabled()checks in
/etc/opt/OV/share/www/conf/session.conf on UNIX systems or
\OpenView\www\conf\session.conf on the Windows NT operating
system to determine whether user login is enabled. It returns TRUE
when the Launcher requires user login before use and FALSE when
Launcher use is unrestricted. It has the function prototype:
boolean OVwwwIsLoginEnabled()
370
Chapter 11
371
372
Chapter 11
Chapter 11
373
374
Chapter 11
93
94
Chapter 5
Tracing
The OVuTL API is provided to let you integrate your application with the
common logging and tracing facility called nettl. This facility uses
daemon processes to receive log and trace data from network
applications (including the platform itself), and to direct that data to its
appropriate destination.
For more information about the nettl subsystem, see the nettl (1M)
manpage, as well as other manpages to which it refers.
Chapter 5
95
96
Chapter 5
OVuTLInit()
Initializes the name of the calling software and the hostname for the logging and
tracing output. You must call OVuTLInit() once only, before any calls to
OVuLog() or OVuTrace().
OVuLog()
OVuTrace()
Chapter 5
97
98
Chapter 5
99
NOTE
The Local Registration File (LRF) is an important file for your process.
This chapter discusses only the first and second line of that file, since
these lines pertain to process management. Any additional lines in this
file are not relevant to Network Node Manager.
100
Chapter 6
NOTE
Chapter 6
101
Process Management
Administrative Commands:
LRF
ovaddobj
command
ovresume, ovstatus
Requests
Responses
ovsuf
ovsmpd
Tracing &
Logging
Subsystem
Well-behaved
Process
Well-behaved
Process
Non-well-behaved
Process
Daemon
Process
Figure 6-1 illustrates how the ovspmd process operates. Note that the
diagram shows three kinds of processes:
Well-behaved Processes
A well-behaved process uses the OVsPMD API the
topic of the next section to communicate with
ovspmd. It sends ovspmd status information regarding
successful and unsuccessful initialization, normal and
abnormal termination, and pause and resume
information if configured to do so. ovspmd considers a
well-behaved process to have initialized successfully
only when it explicitly reports that it has. A
well-behaved process also exits when it receives the
command OVS_CMD_EXIT from ovspmd. If the process
fails to respond, the exit command is escalated to
SIGTERM, and eventually to SIGKILL. It will respond to
OVS_CMD_PAUSE and OVS_CMD_RESUME commands if it
is configured to receive them.
The status information passed by the managed process
to ovspmd is used by ovstart, ovstop, ovstatus,
ovpause or ovresume, if currently running. The last
message received from each managed process is saved,
102
Chapter 6
Chapter 6
103
104
Chapter 6
Function
Description
OVsInit()
OVsInitComplete()
OVsReceive()
OVsDone()
OVsResponse()
See the reference page for OVsPMD_API (3) for additional details. In
general, use these rules to create a well-behaved process:
1. Call OVsInit() when your process begins initialization. This gives
you a socket for later communication with the ovspmd process.
2. After initialization is completeand regardless of whether it was
successful or notyou must call OVsInitComplete(). A parameter
to OVsInitComplete() indicates the initialization status; if
initialization failed, your process should call OVsInitComplete()
and exit (do not call OVsDone()).
3. Your processs control thread should be organized around a select()
loop, waiting for input from managers or from the managed object.
Select for reading on the file descriptor returned by OVsInit().
Chapter 6
105
106
Chapter 6
Description
First
Second
General Syntax
Each line in an LRF contains two or more fields. Each field is terminated
by a colon, including the last field. Some fields are optional; it is
recommended that you still include the colon terminator for the missing
fields.
The number symbol (#) indicates the beginning of a comment, which
Chapter 6
107
NOTE
You must put a backslash in front of the colon that specifies the drive
specification on the Windows NT operating system. This prevents the
colon in the path from being interpreted as a field terminator.
Syntax
Default
1: Name
None (must be
specified).
2: Path
A character string.
None (must be
specified).
Field 1: Name
Specifies the name of the process being registered. You are responsible
for ensuring the uniqueness of the process name.
For example, you could append your companys name:
IPMgr_A.017.0_MegaCorp_International
The name must be the same name used in the session parameter to the
mp_bind() function call, and is the name used when invoking ovstart,
ovstop, ovstatus, and ovisrunning.
Field 2: Path
Specifies the location of the process executable code. Specify the full
(absolute) pathname. If you have set up universal path names, you can
specify the partial pathname relative to the path \OPENVIEW\BIN or
108
Chapter 6
NOTE
You must put a backslash in front of the colon that specifies the drive
specification on the Windows NT operating system. This prevents the
colon in the path from being interpreted as a field terminator. For
example,
IPMgr_A.017.0_MegaCorp_International:C\:\OpenView\bin\netmon:
Chapter 6
Syntax
A character string;
optional.
Default
OVs_NO_START
109
Syntax
Default
2: Dependencies
A series of character
strings, separated by
commas; optional.
3: Arguments
A series of character
strings, separated by
commas; optional.
4: Behavior
A character string;
optional.
OVs_NON_WELL_BEHAVED
5: Timeout
An integer; optional.
5 seconds.
6: Pause
A character string;
optional.
NOPAUSE
7: Daemon Stop
A character string;
optional
Empty string
110
Chapter 6
Chapter 6
111
112
Chapter 6
NOTE
Chapter 6
113
114
Chapter 6
Backup
Data Copy
Stage
initiate
backup
Operational
Phase
pause
processes
copy
operational data
to staging area
Analytical
Phase
resume
processes
Data Archive
Stage
copy data to
permanent
archive
Data Restore
Stage
copy data
from
permanent
archive
copy
analytical data
to staging area
Chapter 6
115
116
Chapter 6
Evaluating An Application
To make it easy to integrate with automated backup this section provides
the information to help you determine which means of integrating are
relevant to your application. Then, you can focus on those sections of the
documentation which provide the integration information needed by
your application, while skipping the other sections.
For each decision tree, answer the question in the diamonds based on
what you know about the internals of your application.
When you reach the end of each decision tree you will know if that form
of integration is relevant to your application. The sections referenced at
the end points of the decision trees are the parts of the documentation
which provide additional information about how to integrate. Note that
the three means of integrating are not mutually exclusive. For a
particular application one, two, or all three may be appropriate.
Script Integration
Script integration is done by adding scripts to the backup script
directories. It is a way for an application to get its data backed up along
with the NNM data.
Chapter 6
117
NO
YES
118
Chapter 6
NO
YES
Consider ovwMapClose integration.
See Integration Via ovwMapClose.
Chapter 6
119
Background process
integration
does not apply.
NO
YES
NO
Does that background
process have dependencies
on other NNM background
processes?
NO
YES
YES
120
Chapter 6
Backup Scripts
ovbackup.ovpl
runs:
Operational
Phase
pre-pause
scripts
pause
system
copy
operational
data to staging
area
operational
scripts
copy data to
permanent
archive
initiate
restore
resume
system
Analytical
Phase
post-resume
scripts
analytical
scripts
copy
analytical data
to staging area
administrator
runs restore
script
restore
operational
data
restore
analytical
data
Chapter 6
121
122
Chapter 6
Chapter 6
123
initiate
backup
ovwMapClose
pause
system
Acknowledge
and respond
copy data to
permanent
archive
ovwAckMapClose
copy
operational data
to staging area
Place
application in
appropiate state
initiate
restore
ovwMapOpen
resume
system
Resume
communication
with NNM
copy
analytical data
to staging area
restore
operational
data
restore
analytical
data
124
Chapter 6
pause
processes
OVS_CMD_PAUSE
OVS_RSP_PAUSE_ACK
wellbehaved
process
copy
operational data
to staging area
resume
processes
OVS_CMD_RESUME
OVS_RSP_RESUME_ACK
wellbehaved
process
copy
analytical data
to staging area
Chapter 6
125
126
Chapter 6
409
410
Appendix A
Appendix A
411
Registration Files
Since OVW places all registration files for all applications under a
common directory structure, it can be difficult to determine which
registration files are associated with each application. If your application
uses registration files, you should document which registration files
belong to your application. Specifically, document which application,
symbol type, or field registration files you use.
412
Appendix A
Fields
If your application creates fields, you should document each of your fields
and how they are used. You should describe
the purpose of the field
the data type of the field
what values are valid for the field
whether the field has any flags associated with it (e.g., whether it is a
capability)
which fields can be used by other applications and which fields are
private to your application
where fields appear in dialog boxes and the permissions on those
fields (read-only vs. read-write).
This section should describe fields created through the Field Registration
File and fields created programmatically.
Appendix A
413
Symbol Types
You should document
any symbol types or symbol alert types required by your application
any default capabilities needed and whether they can be changed
whether a symbols behavior can be changed from explodable to
executable and vice-versa.
414
Appendix A
Submaps
You should fully describe the submap hierarchy used by your application.
Describe the different types of submaps, their purpose, and their
relationship to each other.
You must provide enough detail so that other developers can
programmatically distinguish the submaps created by your application.
One way to do this is to define different values for each of the types of
submaps that your application creates. You can use these values for the
type argument when you create a submap. You can then expose the
submap type values to other developers.
You should describe whether your submaps are shared or exclusive.
Your application might allow only certain types of symbols to be present
on particular submaps. If this is the case, you should document which
symbol types are acceptable for each submap type.
Map applications control whether symbols added to a submap remain on
the user plane or are moved to the application plane. To move a symbol
from the user plane to the application plane, map applications might
require that the objects contain particular fields. (For example, the HP IP
Map application requires that objects representing computers contain
the isNode field.). If your application requires that objects added to
submaps contain particular fields, you should document those
requirements.
Appendix A
415
Dialog Boxes
You should completely describe the purpose of each map-editing dialog
box used by your application. (These are dialog boxes defined through
enroll blocks in the Application Registration File). Based on a description
of how your application uses OVW-generated dialog boxes, other
developers can determine if they should register callback routines to be
invoked when the dialog box operation is confirmed.
If your application depends on one or more fields for verification in a
dialog box, you should document those fields here. Applications should
not share read-write access to fields if another application verifies the
fields in dialog boxes.
416
Appendix A
Appendix A
417
418
Appendix A
An Example Application
419
An Example Application
420
Appendix B
An Example Application
Example
Example
#include
#include
#include
#include
#include
#include
#include
<stdio.h>
<unistd.h>
<string.h>
<stdlib.h>
<ctype.h>
<sys/types.h>
<OV/ovw.h>
#define
#define
#define
#define
#define
#define
False 0
True 1
CHUNK 10
TYPE_MALLOC(x) (x *) malloc (sizeof (x)) /* easier mallocing */
GIF_FILE "/usr/OV/prg_samples/ovw_examples/app7/bears.gif"
USE_FILE 1 /* creates and uses the TESTDATA file. Change to 0
to turn off the use of TESTDATA.
*/
#define TESTDATA "/tmp/app7data"
#define
#define
#define
#define
MsgNfsOn "The nfs map functionality will be enabled for this map"
MsgNfsOff "The nfs map functionality will NOT be enabled for this map"
MsgNfsErr "The NFSMap Enabled field must be set to True or False"
MsgVerDesc "Editing not allowed for this field. Press Cancel"
OVwMapInfo
static OVwBoolean
*map;
enabledForThisMap;
/*------------------------------------+--------------------------------------*/
/*------------------------------- MAKE_STR ----------------------------------*/
/* This short little routine just makes the space for a string and fills it */
/* in.
*/
/*------------------------------------+--------------------------------------*/
char *make_str (char *s)
{
char *new_str;
if (new_str = (char *) malloc(strlen(s)+1))
(void) strcpy(new_str, s);
return new_str;
}
/*------------------------------------+--------------------------------------*/
/*------------------------------ PRINTOVWERR --------------------------------*/
Appendix B
421
An Example Application
Example
/* This short little routine just prints the ovw error and error msg
*/
/*------------------------------------+--------------------------------------*/
void printOvwErr (char *ovwCall)
{
int err;
err = OVwError();
printf ("%s failed: error %d %s\n", ovwCall, err, OVwErrorMsg (err));
}
/*------------------------------------+--------------------------------------*/
/*------------------------------ CONCAT_STR ---------------------------------*/
/* This routine concatenates two strings together.
*/
/*------------------------------------+--------------------------------------*/
char *concat_str (char *str1, char *str2)
{
int
len1;
char *newname;
len1 = strlen (str1);
if ((newname = (char *) malloc (len1 + strlen (str2) + 1)) != NULL) {
strcpy (newname, str1);
strcpy (&newname[len1], str2);
}
return (newname);}
/*------------------------------------+--------------------------------------*/
/*------------------------------ BUILD_LIST ---------------------------------*/
/* This routine builds a list to be put into the database. It is passed
*/
/* the command to execute, it executes the command and then builds a list
*/
/* appropriate for input to the OVw database.
*/
/*------------------------------------+--------------------------------------*/
OVwListFieldValue *build_list (char *cmd)
{
int
max;
char
*cr;
char
response[1024];
FILE
*cmd_file;
OVwListFieldValue *list;
OVwListFieldEntry *temp;
list = TYPE_MALLOC (OVwListFieldValue);
list->count = 0;
422
Appendix B
An Example Application
Example
list->list
max
= NULL;
= 0;
#if USE_FILE
if ((cmd_file = fopen(cmd, "r")) == NULL) {
printf("error condition - couldn't fopen %s - check errno\n", cmd);
exit (1);
}
#else
if ((cmd_file = popen(cmd, "r")) == NULL) {
printf("error condition - couldn't popen %s - check errno\n", cmd);
exit (1);
}
#endif
while (fgets(response, 1024, cmd_file)) {
if (cr = strchr(response, '\n'))
*cr = '\0';
/* get rid of CR */
Appendix B
423
An Example Application
Example
/*------------------------------ SHOWMOUNT ----------------------------------*/
/* This routine creates the showmount command to be executed. It is passed */
/* to build_list which actually executes the command and builds the list.
*/
/* The list is returned to here and then it is returned again to the calling */
/* routine.
*/
/*------------------------------------+--------------------------------------*/
OVwListFieldValue *showmount(char *hostname)
{
char
cmd[100];
#if USE_FILE
return (build_list (TESTDATA));
#else
sprintf(cmd, "/usr/etc/showmount -a %s", hostname);
return (build_list (cmd));
#endif
}
/*------------------------------------+--------------------------------------*/
/*-------------------------------- RPCINFO ----------------------------------*/
/* This routine determines if the host is capable of being an nfs server
*/
/* by doing an rpcinfo. It looks to see if an nfs daemon is running.
*/
/* return: -1 on error; 0 if nfs not running; > 0 if nfs running
*/
/* If the supplied test data is being used, it immediately returns 1
*/
/* implying that the system is a server.
*/
/*------------------------------------+--------------------------------------*/
int rpcinfo (char *hostname)
{
FILE *rpcinfo_file;
char cmd[1024];
char response[1024];
int
count = -1;
#if USE_FILE
return (1);
#else
sprintf(cmd, "/usr/etc/rpcinfo -p %s | grep nfs | wc -l", hostname);
if ((rpcinfo_file = popen(cmd, "r")) == NULL) {
fprintf(stderr, "error condition - rpcinfo - check errno\n");
}
else {
424
Appendix B
An Example Application
Example
if (fgets(response, 1024, rpcinfo_file))
sscanf(response, "%d", &count);
else
printf ("errno is %d\n", errno);
}
return (count);
#endif
}
/*------------------------------------+--------------------------------------*/
/*--------------------------------- ISNFS -----------------------------------*/
/* This routine is given the object id of the system of interest. However, it*/
/* needs the textual name of the object so the OVwDbObjectIdToSelectionName */
/* is used. It would be ideal to obtain the "hostname" but that field is
*/
/* set by the IPMap application. Since this is an application to illustrate */
/* the use of the OVw product, there is no guarantee that the IPMap
*/
/* application will be running on your system.
*/
/*
*/
/* Once the hostname has been obtained, determine if the host is running any */
/* nfs daemons. This is done by calling the rpcinfo routine. If it is an
*/
/* nfs server, set the "isNfsServer" field for this object to be true. Then */
/* call the showmount routine to obtain the information about which systems */
/* this system serves. Then save that information in the database. This
*/
/* step is done to illustrate the use of the OVwDbSetFieldValue routine.
*/
/* The nfs submap could have been created directly from this information.
*/
/*------------------------------------+--------------------------------------*/
int isNfs (OVwObjectId objId)
{
int
server;
int
ret;
int
count;
char
*host;
OVwFieldValue
fieldValue;
/* If you are using real data, be sure that the selection name is a valid */
/* host on the network
*/
if ((host = OVwDbObjectIdToSelectionName (objId)) == NULL) {
printOvwErr ("OVwDbObjectIdToSelectionName");
}
if ((count = rpcinfo(host)) == -1) {
printf ("error: rpcinfo routine returned a count of -1\n");
server = False;
}
Appendix B
425
An Example Application
Example
else if (count)
server = True;
else {
server= False;
printf ("rpcinfo failed:host not configured or unknown host\n");
}
if ((ret = OVwDbSetFieldBooleanValue (objId,
OVwDbFieldNameToFieldId("isNfsServer"),
server)) < 0)
printOvwErr ("OVwDbSetFieldBooleanValue");
if (server) {
fieldValue.is_list = True;
fieldValue.field_type = ovwStringField;
fieldValue.modified = False;
fieldValue.un.list_val = showmount(host);
if ((ret = OVwDbSetFieldValue (objId,
OVwDbFieldNameToFieldId("serves"),
&fieldValue)) < 0)
printOvwErr ("OVwDbSetFieldValue");
}
return (server);
}
/*------------------------------------+--------------------------------------*/
/*----------------------------- CREATENFSMAP---------------------------------*/
/* This routine creates the submap for the nfs component symbol. This submap */
/* is displayed by ovw when the nfs component is double-clicked by the user. */
/* This routine works with the object id and the textual name for that
*/
/* object. Therefore, the first thing it does is to obtain the selection
*/
/* name for the object. The textual name is used as part of the label
*/
/* for the submap.
Then set the background graphic for this submap.
*/
/*
*/
/* The star configuration is used for this submap to display the server/
*/
/* client relationship. The first symbol put on the map is for the object
*/
/* that is the nfs server.
It is placed at the star center position of the */
/* submap. Next obtain from the database the list of clients for this
*/
/* nfs server. This information was put in the database in the "isNfs"
*/
/* routine. Now cycle through the client information placing the points
*/
/* onto the star and connecting the point to the star center. Each point
*/
/* represents a client system.
*/
/*
*/
/* This routine also sets the status of the object representing the most
*/
/* client systems on the submap. Although, this is not a particularly valid */
426
Appendix B
An Example Application
Example
/* use of the status of an object, it is done to illustrate the use of
*/
/* setting the status of symbols/objects.
*/
/*------------------------------------+--------------------------------------*/
void createNfsmap (OVwObjectInfo *compObjInfo, OVwObjectInfo *sysObjInfo)
{
int
i;
int
ret;
char
*host;
char
*pointhost;
char
*submapname;
OVwSubmapId
submapId;
OVwSymbolId
symbolId;
OVwSymbolId
star;
OVwSymbolId
connId;
OVwSymbolInfo
*connSym;
OVwSymbolInfo
*syminfo;
OVwSymbolPosition
*pos;
OVwSymbolPosition
*center_pos;
OVwObjectId
tmpobjid;
OVwObjectInfo
maxObjInfo;
OVwObjectInfo
*objInfo;
OVwFieldValue
*points;
OVwFieldBinding
conn;
maxObjInfo.num_symbols = 0;
host = OVwDbObjectIdToSelectionName (sysObjInfo->object_id);
submapname = concat_str (host, " Nfs Submap");
if ((submapId = OVwCreateSubmap (map, compObjInfo->object_id,
ovwSharedSubmap,
ovwNoSubmapType, submapname,
ovwStarLayout, 0))
== ovwNullSubmapId) {
printOvwErr ("OVwCreateSubmap");
return;
}
if ((ret = OVwSetBackgroundGraphic (map, submapId, GIF_FILE)) != 0)
printOvwErr ("OVwSetBackgroundGraphic");
/* add the center of the star which is the host of interest to the submap */
center_pos=TYPE_MALLOC (OVwSymbolPosition);
center_pos->placement=ovwStarCenterPosition;
if ((star = OVwCreateSymbol (map, submapId, sysObjInfo->object_id,
Appendix B
427
An Example Application
Example
"Computer:Workstation", host,
ovwUnknownStatus,
ovwSymbolStatusSource,
center_pos, ovwNoSymbolFlags))
== ovwNullSymbolId) {
printOvwErr ("OVwCreateSymbolByHostname");
return;
}
/* Now add the systems off of the center of the star to make the points
/* of the star. Need to add the connections also.
*/
*/
428
*/
*/
Appendix B
An Example Application
Example
tmpobjid = syminfo->object.object_id;
OVwFreeSymbolInfo (syminfo);
if ((objInfo = OVwGetObjectInfo (map, tmpobjid)) == NULL)
printOvwErr ("OVwGetObjectInfo");
else {
if (objInfo->num_symbols > maxObjInfo.num_symbols)
maxObjInfo = *objInfo;
OVwFreeObjectInfo(objInfo);
}
}
/* now create the connection between the end point and the star center */
if ((connId = OVwCreateConnSymbolByName (map, &conn, star, symbolId,
NULL, "", ovwUnknownStatus,
ovwSymbolStatusSource,
ovwNoSymbolFlags))
== ovwNullSymbolId) {
printOvwErr ("OVwCreateConnSymbolByName");
}
else {
/* this just shows an example of using the OVwGetConnSymbol call
*/
if ((connSym = OVwGetConnSymbol (map, star, symbolId)) == NULL)
printOvwErr ("OVwGetConnSymbol");
OVwFreeSymbolInfo (connSym);
}
}
}
if ((ret = OVwSetStatusOnObject (map, maxObjInfo.object_id,
ovwCriticalStatus)) !=0)
printOvwErr ("OVwSetStatusOnObject");
OVwDbFreeFieldValue (points);
}
}
/*------------------------------------+--------------------------------------*/
/*----------------------------- ENDSESSIONCB---------------------------------*/
/* This routine handles the endSession event from ovw. This event occurs
*/
/* when the OVw session is existing. Regardless, of the reason for OVw
*/
/* exiting, an OVwDone is performed to disconnect the application from OVw. */
/*------------------------------------+--------------------------------------*/
static void endSessionCB (void *userData, OVwEventType type,
OVwBoolean normalEnd)
{
#if USE_FILE
unlink (TESTDATA);
Appendix B
429
An Example Application
Example
#endif
OVwDone();
if (normalEnd == True) {
exit (0);
}
else {
exit(1);
}
}
/*------------------------------------+--------------------------------------*/
/*---------------------------- COMPONENTSYMBOL ------------------------------*/
/* This routine creates an nfs component symbol on the child submap of an
*/
/* object. By the time this routine is called, it has been determined that */
/* an nfs component symbol should exist for the object. It will only
*/
/* create one, however, if one does not already exist. A by-product of
*/
/* the OVwCreateComponentSymbolByName routine is that it will create a
*/
/* child submap for the object if one does not already exist.
*/
/*
*/
/* If the component symbol is created successfully, the createNfsmap routine */
/* is called to create the child submap of the nfs component symbol. That
*/
/* map will contain a graphical representation of the relationships between */
/* the nfs server and its clients.
*/
/*------------------------------------+--------------------------------------*/
void *componentSymbol (OVwObjectInfo *objInfo, OVwMapInfo *map)
{
int
ret;
int
i;
int
j;
int
k;
OVwSymbolId
nfsSym;
OVwSymbolList
*symbolList;
OVwSymbolInfo
*syminfo;
symbolList = NULL;
/* add a component symbol for nfs if one doesn't exist */
if (objInfo->child_submap_id != 0) {
symbolList = OVwListSymbols(map, objInfo->child_submap_id,
ovwAppPlane, OVwGetAppName() );
}
if ((symbolList->count == 0) || (objInfo->child_submap_id == 0)) {
if ((nfsSym = OVwCreateComponentSymbolByName (map,
objInfo->object_id, NULL,
430
Appendix B
An Example Application
Example
"Server:Nfs", "Nfs",
ovwUnknownStatus,
ovwObjectStatusSource,
NULL, ovwNoSymbolFlags))
== ovwNullSymbolId)
printOvwErr ("OVwCreateComponentSymbolByName");
else {
syminfo = OVwGetSymbolInfo (map, nfsSym);
createNfsmap(&(syminfo->object), objInfo);
OVwFreeSymbolInfo(syminfo);
}
}
}
/*------------------------------------+--------------------------------------*/
/*------------------------------- MAKEFIELD ---------------------------------*/
/* This routine is used to make one of the field bindings in a field bind
*/
/* list.
*/
/*------------------------------------+--------------------------------------*/
void makefield (OVwFieldBinding *fieldBind, OVwFieldId id,
OVwBoolean islist, int fieldType, int val)
{
fieldBind->field_id = id;
fieldBind->field_val = TYPE_MALLOC (OVwFieldValue);
fieldBind->field_val->is_list = islist;
fieldBind->field_val->field_type= fieldType;
if (fieldType == ovwBooleanField)
fieldBind->field_val->field_bool_val = val;
else if (fieldType == ovwEnumField)
fieldBind->field_val->field_enum_val = val;
}
/*------------------------------------+--------------------------------------*/
/*--------------------------- MAKEFIELDBINDLIST------------------------------*/
/* This routine makes a field bind list. It is used by routines that need
*/
/* to create a list of items on which to filter the list of objects on a map.*/
/* It currently operates on field values that are booleans. In particular,
*/
/* it creates a filter based on the "isNode" field. As currently coded,
*/
/* it could also be used to create a capability list for other field
*/
/* values that are booleans since the field name and value are parameters
*/
/* to the routine.
*/
/*------------------------------------+--------------------------------------*/
OVwFieldBindList *makeFieldBindList (char *fieldname, int val)
Appendix B
431
An Example Application
Example
{
int
numFields;
OVwFieldBindList *fbl;
OVwFieldBinding *afield;
numFields = 1;
fbl = TYPE_MALLOC (OVwFieldBindList);
fbl->count = numFields;
fbl->fields = (OVwFieldBinding *) malloc
(numFields * sizeof (OVwFieldBinding));
afield = fbl->fields;
makefield (afield, OVwDbFieldNameToFieldId (fieldname),
False, ovwBooleanField, val);
return (fbl);
}
/*------------------------------------+--------------------------------------*/
/*------------------------------ MAPCLOSECB ---------------------------------*/
/* This routine is invoked when OVw issues a map close event. This could be */
/* initiated by the user creating a new map or opening an existing map.
*/
/* This application has an application configuration parameter that is
*/
/* specified at map creation time. What happens at the closing of the map
*/
/* depends on whether the map is configured with this application. If the
*/
/* map is configured with this application and this map is being closed,
*/
/* this application is no longer interested in knowing about objects
*/
/* being added to the map. Therefore, remove the callback related to the
*/
/* event "ovwConfirmCreateObjects". The callback was added in the
*/
/* mapOpenCB routine.
*/
/*------------------------------------+--------------------------------------*/
void *mapCloseCB (void *userData, int event, OVwMapInfo *closeMap,
time_t closing_time)
{
OVwFieldBindList *capabilities;
if (enabledForThisMap) {
capabilities = makeFieldBindList("isNode", True);
OVwRemoveCallback (ovwConfirmCreateObjects, capabilities);
}
OVwAckMapClose (map, closing_time);
}
,/*------------------------------------+--------------------------------------*/
/*------------------------------- MAKE_NFS ----------------------------------*/
/* This routine cycles through the list of objects it is given and calls
*/
432
Appendix B
An Example Application
Example
/* the routine that determines if the system is a server. If it is a server,*/
/* then it calls the routine that creates the nfs component symbol on the
*/
/* object's submap.
*/
/*------------------------------------+--------------------------------------*/
void make_nfs (OVwObjectList *objlist)
{
int
i;
int
server;
OVwObjectInfo *loop;
for (i=0, loop = objlist->objects; i <objlist->count; i++, loop++) {
server = isNfs (loop->object_id);
if (server)
componentSymbol(loop, map);
}
}
/*------------------------------------+--------------------------------------*/
/*------------------------------ CREATEOBJCB --------------------------------*/
/* This routine is the callback to handle the event caused by the addition
*/
/* of an object to the map. It is given the list of objects added to the
*/
/* map. Since there is already a routine that handles a list of objects
*/
/* that already exist on the map, just call that routine.
*/
/*------------------------------------+--------------------------------------*/
void createObjCB (void *userData, OVwEventType type, OVwMapInfo *map,
OVwObjectList *objectList)
{
make_nfs (objectList);
}
/*------------------------------------+--------------------------------------*/
/*------------------------------- MAPOPENCB ---------------------------------*/
/* This routine is the callback for the map open event.
The first thing
*/
/* is does is invoke the OVwBeginMapSync command which causes the
*/
/* "Synchronizing" phrase to appear on the OVw submap. The name of the
*/
/* opened map and all of its accompanying information is saved in the global */
/* variable "map" since the opened map is used throughout this application. */
/* The routine OVwCopyMapInfo conveniently saves all of the inform for us.
*/
/*
*/
/* The parameter "configParams" contains the information about how this
*/
/* map has been configured. We cycle through the items in that list to
*/
/* determine if this map has been configured to discover nfs information.
*/
/* In particular we are looking to see if the field "NFSMap Enabled" is set */
/* to true. If it is, then we also want to make sure that we discover the
*/
/* nfs information about objects that are later added to the map and not just*/
Appendix B
433
An Example Application
Example
/* objects that exist on the map when it was opened. If this application
*/
/* is not configured for this map, we end synchronizing and return. We
*/
/* also specifiy a global variable that indicates the configuration for this */
/* map so we can do what is necessary when this map is closed.
*/
/*
*/
/* If this map is configured for nfs discovery, then we find all the objects */
/* on the map that have the field "isNode" set to true.
We are using the
*/
/* field "isNode" here but in fact we would prefer to also use the field
*/
/* "isIP" to filter on the applicable objects. However, the field "isIP"
*/
/* is set by the IPMap application which is not guaranteed to be running
*/
/* on your system when you try out this application. Just filtering on
*/
/* the "isNode" field is very vague and will in all likelihood not get you
*/
/* the objects that really meet the criteria for this application. However, */
/* the purpose of this application, is to illustrate the use of many of
*/
/* the calls available with this product and to illustrate some of the
*/
/* data structures.
*/
/*
*/
/* This sample application does not periodically update the database with
*/
/* the most recent information while a map is opened. Nor does it update
*/
/* the information for existing objects when a map is reopened.
*/
/*------------------------------------+--------------------------------------*/
void *mapOpenCB (void *userData, int event, OVwMapInfo *openedMap,
OVwFieldBindList *configParams)
{
int
i;
int
ret;
OVwObjectList
*objlist;
OVwFieldBinding *field;
OVwFieldBindList *capabilities;
OVwFieldBindList *filterList;
if ((ret = OVwBeginMapSync (openedMap)) < 0 ) {
printOvwErr ("OVwBeginMapSync");
return;
}
map = OVwCopyMapInfo (openedMap);
for (i = 0, field=configParams->fields; i<configParams->count; i++, field++) {
if (field->field_id == OVwDbFieldNameToFieldId ("NFSMap Enabled")) {
if (field->field_val->field_bool_val == True) {
capabilities = makeFieldBindList("isNode", True);
if ((ret = OVwAddCallback (ovwConfirmCreateObjects, capabilities,
(OVwCallbackProc) createObjCB, NULL )) < 0)
printOvwErr ("OVwAddCallback");
enabledForThisMap = True;
434
Appendix B
An Example Application
Example
}
else {
OVwEndMapSync(map);
enabledForThisMap = False;
return;
}
}
}
filterList = makeFieldBindList("isNode", True);
if ((objlist = OVwListObjectsOnMap (map, filterList)) != NULL) {
make_nfs (objlist);
}
OVwEndMapSync (map);
}
/*------------------------------------+--------------------------------------*/
/*---------------------------- CONFIGCHANGECB -------------------------------*/
/* The user has the option of specifying whether the discovery of nfs
*/
/* information should be enabled for a new map.
By default it is enabled. */
/* This routine is invoked when the ovwQueryAppConfigChange event is
*/
/* generated by OVw in response to the user choosing this application in the */
/* "Configurable Applications" section of the "New Map" window.
*/
/*
*/
/* This routine generates appropriate feedback to the user based on whether */
/* the user selected "True" or "False".
This is done by sending OVw an
*/
/* OVwVerifyAppConfigChange command with the appropriate response.
*/
/*------------------------------------+--------------------------------------*/
void configChangeCB ( void *userData, OVwEventType type, OVwMapInfo *map,
OVwFieldBindList *configParams)
{
int
i;
int
ret;
char
*errorMsg;
OVwBoolean
verified;
OVwFieldBinding *field;
verified = False;
errorMsg=make_str("");
for (i = 0, field=configParams->fields; i<configParams->count; i++, field++) {
if (field->field_id == OVwDbFieldNameToFieldId ("NFSMap Enabled")) {
if (field->field_val->field_bool_val == True) {
verified = True;
errorMsg = make_str (MsgNfsOn);
Appendix B
435
An Example Application
Example
} else if (field->field_val->field_bool_val == False) {
verified = True;
errorMsg = make_str (MsgNfsOff);
} else
errorMsg=make_str (MsgNfsErr);
}
}
if ((ret = OVwVerifyAppConfigChange (map, configParams, verified, errorMsg))
< 0)
printOvwErr ("OVwVerifyAppConfigChange");
}
/*------------------------------------+--------------------------------------*/
/*----------------------------- QUERYDESCCB ---------------------------------*/
/* This query callback must exist for the "serves" field info to appear
*/
/* in the describe dialog box for an object even though the field has a no
*/
/* edit policy. That policy was specified in the application registration
*/
/* file. Since the field is no edit, we always want to deny any changes to
*/
/* the information related to the "serves" field that is presented in the
*/
/* object's describe box.
*/
/*------------------------------------+--------------------------------------*/
void queryDescCB (void *userData, OVwEventType type, OVwMapInfo *map,
OVwObjectInfo *object, OVwFieldBindList *dialogBoxFields)
{
OVwVerifyDescribeChange (map, object, dialogBoxFields, False, MsgVerDesc);
}
/*------------------------------------+--------------------------------------*/
/*--------------------------------- MAIN ------------------------------------*/
/* This application registers for the following OVw events: ovwEndSession, */
/* ovwMapOpen, ovwMapClose, ovwQueryAppConfigChange, and
*/
/* ovwQueryDescribeChange. Since ovw does not issue a map open callback when*/
/* ovw is first brought up, we need a way to execute this application against*/
/* the first map. This is done by obtaining the configuration parameters for*/
/* this map and then invoking the mapOpenCB as if ovw was doing it itself.
*/
/*------------------------------------+--------------------------------------*/
void main (int argc, char *argv[])
{
FILE
*fp;
OVwMapInfo
*firstMap;
OVwFieldBindList *configParams;
436
Appendix B
An Example Application
Example
setbuf (stdout, NULL);
setbuf (stderr, NULL);
#if USE_FILE
if ((fp = fopen(TESTDATA, "w")) == NULL) {
fprintf (stderr, "Could not create test data file.
exit (1);
}
fprintf (fp, "sys1:/usr/spool/notes\n");
fprintf (fp, "sys2:/dist/man\n");
fprintf (fp, "sys2:/dist/man\n");
fprintf (fp, "sys3:/users");
fprintf (fp, "sys3:/disc\n");
fprintf (fp, "sys4:/usr\n");
fprintf (fp, "sys5:/usr/man\n");
fprintf (fp, "sys5:/usr/spool/notes\n");
fprintf (fp, "sys5:/dist\n");
fclose (fp);
#endif
Exiting\n");
OVwInit();
OVwAddCallback
OVwAddCallback
OVwAddCallback
OVwAddCallback
Appendix B
437
An Example Application
Example
438
Appendix B
439
OVwEventIntro(5)
OVwRegIntro(5)
440
Appendix C
2. Determine where on your system the reference page files are kept.
Type
echo $MANPATH
You should see a list with one or more directories. Multiple directories
will be separated by colons (i.e., /usr/local/man:/usr/man). It is
recommended that you check the contents of each directory to make
sure it actually has reference page files in it.
3. Use the command syntax shown in Step 1 in one of two ways:
Specify the qualified path of the directory containing reference
page files as the %s value in the command.
Example: you know that the bggen(1) reference page is stored in
the
/usr/man/man1 directory on your system, but you are not
currently in that directory. To display this reference page online,
type the following command:
tbl -TX /usr/man/man1/bggen.1 |neqn|nroff -man|col|more
Appendix C
441
442
Appendix C
Help Routines
Callback Registration
OVwAddHelpCallback(3)
OVwAddActionCallback(3)
OVwShowHelp(3)
OVwAddAlertCallback(3)
OVwAddCallback(3)
OVwAddDropCallback(3)
OVwConfirmDeleteSymbolAlert(3)
Appendix C
443
Event Processing
Submap Routines
OVwAddInput(3)
OVwAckUserSubmapCreate(3)
OVwFileDescriptor(3)
OVwAddSubmapContext(3)
OVwMainLoop(3)
OVwCreateSubmap(3)
OVwPeekOVwEvent(3)
OVwCreateSubmaps(3)
OVwPending(3)
OVwDisplaySubmap(3)
OVwProcessEvent(3)
OVwGetSubmapInfo(3)
OVwXtAddInput(3)
OVwListSubmaps(3)
OVwXtMainLoop(3)
OVwLoadSubmap(3)
OVwLoadSubmaps(3)
Process Management
OVwUnloadSubmap(3)
OVwDbInit(3)
OVwUnloadSubmaps(3)
OVwDone(3)
OVwModifySubmaps(3)
OVwEndSessionCB(3)
OVwSetBackgroundGraphic(3)
OVwInit(3)
OVwSubmapChangeCB(3)
OVwSessionId(3)
OVwSetSubmapName(3)
OVwSubmapOpenCB(3)
OVwSubmapCloseCB(3)
OVwUserSubmapCreateCB(3)
Error Handling
OVwError(3)
OVwErrorMsg(3)
OVwIsIdNull(3)
444
Appendix C
Symbol Routines
OVwCreateSymbolAlert(3)
OVwDbAppendEnumConstants(3)
OVwCreateSymbols(3)
OVwDbCreateField(3)
OVwGetConnSymbol(3)
OVwDbCreateObject(3)
OVwGetSymbolInfo(3)
OVwDbDeleteObject(3)
OVwGetSymbolsByObject(3)
OVwDbFieldNameToFieldId(3)
OVwListSymbols(3)
OVwDbGetEnumConstants(3)
OVwListSymbolTypes(3)
OVwDbGetFieldInfo(3)
OVwModifySymbol(3)
OVwDbGetFieldValue(3)
OVwSetSymbolApp(3)
OVwDbGetFieldValues(3)
OVwSetSymbolBehavior(3)
OVwDbGetFieldValuesByObjects(3)
OVwSetSymbolLabel(3)
OVwDbGetUniqObjectName(3)
OVwSetSymbolPosition(3)
OVwDbHostnameToObjectId(3)
OVwSetSymbolStatusSource(3)
OVwDbInit(3)
OVwSetSymbolType(3)
OVwDbListFields(3)
OVwSymbolChangeCB(3)
OVwDbListObjectsByFieldValue(3)
OVwDbNameToObjectId(3)
OVwGetObjectInfo(3)
OVwDbSelectionNameToObjectId(3)
OVwGetSymbolsByObject(3)
OVwDbSetEnumConstants(3)
OVwHighlightObject(3)
OVwDbSetFieldValue(3)
OVwListObjectsOnMap(3)
OVwDbSetSelectionName(3)
OVwLocateBySelectionName(3)
OVwDbUnsetFieldValue(3)
OVwLocateByAttribute(3)
OVwLocateByComment(3)
OVwLocateBySymbolStatus(3)
OVwLocateBySymbolType(3)
OVwLocateBySymbolLabel(3)
Appendix C
445
OVwAlertMsg(3)
OVServerName(3)
OVwAPILevel(3)
OVwAckMapClose(3)
OVwCheckAction(3)
OVwBeginMapSync(3)
OVwCheckInternalFunction(3)
OVwGetMapInfo(3)
OVwFormat(3)
OVwMapCloseCB(3)
OVwGetSelections(3)
OVwMapOpenCB(3)
OVwPrintMapInfo(3)
OVwReturnLocateResults(3)
OVwSelectListChangeCB(3)
OVwSymbolLabelLocateCB(3)
OVwSymbolStatusLocateCB(3)
OVwSymbolTypeLocateCB(3)
OVwAttributeLocateCB(3)
446
Appendix C
OVwConfirmCapabilityChangeCB(3)
OVwActionRegistration(3)
OVwConfirmCreateObjectsCB(3)
OVwAddMenuItem(3)
OVwConfirmCreateSubmapCB(3)
OVwAddMenuItemFunction(3)
OVwConfirmCreateSymbolsCB(3)
OVwAddToolbarButton(3)
OVwConfirmDeleteObjectsCB(3)
OVwAddToolbarButtonFunction(3)
OVwConfirmDeleteSubmapsCB(3)
OVwAppRegistration(3)
OVwConfirmHideSymbolsCB(3)
OVwFindMenuItem(3)
OVwConfirmManageObjectsCB(3)
OVwGetFirstAction(3)
OVwConfirmMoveSymbolCB(3)
OVwGetFirstMenuItem(3)
OVwConfirmObjectStatusCB(3)
OVwGetFirstMenuItemFunction(3)
OVwVerifyAdd(3)
OVwGetFirstRegContext(3)
OVwVerifyAppConfigChange(3)
OVwGetFirstToolbarButton(3)
OVwVerifyConnect(3)
OVwGetFirstToolbarButtonFunction(3)
OVwVerifyDeleteSymbol(3)
OVwGetMenuItemPath(3)
OVwVerifyDescribeChange(3)
OVwGetMenuPathSeparator(3)
OVwVerifyDrop(3)
OVwGetRegContext(3)
OVwLockRegUpdates(3)
Application Information
OVwMenuRegistration(3)
OVwGetAppConfigValues(3)
OVwMenuItemRegistration(3)
OVwGetAppName(3)
OVwRenameRegContext(3)
OVwSaveRegUpdates(3)
OVwToolbarButtonRegistration(3)
Status
OVwSetStatusOnObject(3)
Appendix C
447
Reference Page
OVServerName
OVServerName(3)
OVisOnOVServer
OVServerName(3)
OVwAPILevel
OVwAPILevel(3)
OVwAckMapClose
OVwAckMapClose(3)
OVwAckUserSubmapCreate
OVwAckUserSubmapCreate(3)
OVwAddActionCallback
OVwAddActionCallback(3)
OVwAddAlertCallback
OVwAddAlertCallback(3)
OVwAddCallback
OVwAddCallback(3)
OVwAddDropCallback
OVwAddDropCallback(3)
OVwAddHelpCallback
OVwAddHelpCallback(3)
OVwAddInput
OVwAddInput(3)
OVwAddMenuItem
OVwAddMenuItem(3)
OVwAddMenuItemFunction
OVwAddMenuItemFunction(3)
OVwAddPopupMenuItemFunction
OVwAddMenuItemFunction(3)
OVwAddPulldownMenuItemFunction
OVwAddMenuItemFunction(3)
OVwAddSubmapContext
OVwAddSubmapContext(3)
OVwAddToolbarButton
OVwAddToolbarButton(3)
448
Appendix C
Reference Page
OVwAddToolbarButtonFunction
OVwAddToolbarButtonFunction(3)
OVwAlertCallbackProc
OVwAddAlertCallback(3)
OVwAlertMsg
OVwAlertMsg(3)
OVwAttributeLocateCB
OVwAttributeLocateCB(3)
OVwBeginMapSync
OVwBeginMapSync(3)
OVwCheckAction
OVwCheckAction(3)
OVwCheckInternalFunction
OVwCheckInternalFunction(3)
OVwClearBackgroundGraphic
OVwSetBackgroundGraphic(3)
OVwClearSymbolApp
OVwSetSymbolApp(3)
OVwCloseSubmap
OVwDisplaySubmap(3)
OVwConfirmAddSymbolCB
OVwVerifyAdd(3)
OVwConfirmAppConfigCB
OVwVerifyAppConfigChange(3)
OVwConfirmCapabilityChangeCB
OVwConfirmCapabilityChangeCB(3)
OVwConfirmCompoundStatusCB
OVwConfirmObjectStatusCB(3)
OVwConfirmConnectSymbolsCB
OVwVerifyConnect(3)
OVwConfirmCreateObjectsCB
OVwConfirmCreateObjectsCB(3)
OVwConfirmCreateSubmapsCB
OVwConfirmCreateSubmapsCB(3)
OVwConfirmCreateSymbolsCB
OVwConfirmCreateSymbolsCB(3)
OVwConfirmDeleteObjectsCB
OVwConfirmDeleteObjectsCB(3)
OVwConfirmDeleteSubmapsCB
OVwConfirmDeleteSubmapsCB(3)
OVwConfirmDeleteSymbolAlertCB
OVwConfirmDeleteSymbolAlertCB(3)
OVwConfirmDeleteSymbolsCB
OVwVerifyDeleteSymbol(3)
Appendix C
449
Reference Page
OVwConfirmDescribeCB
OVwVerifyDescribeChange(3)
OVwConfirmHideSymbolsCB
OVwConfirmHideSymbolsCB(3)
OVwConfirmManageObjectsCB
OVwConfirmManageObjectsCB(3)
OVwConfirmMoveSymbolCB
OVwConfirmMoveSymbolCB(3)
OVwConfirmObjectStatusCB
OVwConfirmObjectStatusCB(3)
OVwConfirmSymbolStatusCB
OVwConfirmObjectStatusCB(3)
OVwConfirmUnhideSymbolsCB
OVwConfirmHideSymbolsCB(3)
OVwConfirmUnmanageObjectsCB
OVwConfirmManageObjectsCB(3)
OVwCopyMapInfo
OVwGetMapInfo(3)
OVwCreateAction
OVwActionRegistration(3)
OVwCreateApp
OVwAppRegistration(3)
OVwCreateComponentSymbol
OVwCreateSymbol(3)
OVwCreateComponentSymbolByName
OVwCreateSymbol(3)
OVwCreateConnSymbol
OVwCreateSymbol(3)
OVwCreateConnSymbolByName
OVwCreateSymbol(3)
OVwCreateMenu
OVwMenuRegistration(3)
OVwCreateMenuItem
OVwMenuItemRegistration(3)
OVwCreateSubmap
OVwCreateSubmap(3)
OVwCreateSubmaps
OVwCreateSubmaps(3)
OVwCreateSymbol
OVwCreateSymbol(3)
OVwCreateSymbolAlert
OVwCreateSymbolAlert(3)
OVwCreateSymbolByHostname
OVwCreateSymbol(3)
450
Appendix C
Reference Page
OVwCreateSymbolByName
OVwCreateSymbol(3)
OVwCreateSymbolBySelectionName
OVwCreateSymbol(3)
OVwCreateSymbols
OVwCreateSymbol(3)
OVwCreateToolbarButton
OVwToolbarButtonRegistration(3)
OVwDbAppendEnumConstants
OVwDbAppendEnumConstants(3)
OVwDbCreateField
OVwDbCreateField(3)
OVwDbCreateObject
OVwDbCreateObject(3)
OVwDbCreateObjectByHostname
OVwDbCreateObject(3)
OVwDbCreateObjectBySelectionName
OVwDbCreateObject(3)
OVwDbDeleteField
OVwDbCreateField(3)
OVwDbDeleteObject
OVwDbDeleteObject(3)
OVwDbDone
OVwDbInit(3)
OVwDbFieldIdToFieldName
OVwDbFieldNameToFieldId(3)
OVwDbFieldNameToFieldId
OVwDbFieldNameToFieldId(3)
OVwDbFreeEnumConstants
OVwDbGetEnumConstants(3)
OVwDbFreeFieldBindList
OVwDbGetFieldValues(3)
OVwDbFreeFieldInfo
OVwDbGetFieldInfo(3)
OVwDbFreeFieldList
OVwDbListFields(3)
OVwDbFreeFieldValue
OVwDbGetFieldValue(3)
OVwDbFreeObjectFieldList
OVwDbGetFieldValuesByObjects(3)
OVwDbFreeObjectIdList
OVwDbListObjectsByFieldValue(3)
OVwDbGetCapabilityFieldValues
OVwDbGetFieldValues(3)
Appendix C
451
Reference Page
OVwDbGetEnumConstants
OVwDbGetEnumConstants(3)
OVwDbGetEnumName
OVwDbGetEnumConstants(3)
OVwDbGetEnumValue
OVwDbGetEnumConstants(3)
OVwDbGetFieldBooleanValue
OVwDbGetFieldValue(3)
OVwDbGetFieldEnumByName
OVwDbGetFieldValue(3)
OVwDbGetFieldEnumByValue
OVwDbGetFieldValue(3)
OVwDbGetFieldInfo
OVwDbGetFieldInfo(3)
OVwDbGetFieldIntegerValue
OVwDbGetFieldValue(3)
OVwDbGetFieldStringValue
OVwDbGetFieldValue(3)
OVwDbGetFieldValue
OVwDbGetFieldValue(3)
OVwDbGetFieldValues
OVwDbGetFieldValues(3)
OVwDbGetFieldValuesByObjects
OVwDbGetFieldValuesByObjects(3)
OVwDbGetNameFieldValues
OVwDbGetFieldValues(3)
OVwDbGetUniqObjectName
OVwDbGetUniqObjectName(3)
OVwDbHostnameToObjectId
OVwDbHostnameToObjectId(3)
OVwDbInit
OVwDbInit(3)
OVwDbListFields
OVwDbListFields(3)
OVwDbListObjectsByFieldValue
OVwDbListObjectsByFieldValue(3)
OVwDbListObjectsByFieldValues
OVwDbListObjectsByFieldValue(3)
OVwDbNameToObjectId
OVwDbNameToObjectId(3)
OVwDbObjectIdToHostname
OVwDbHostnameToObjectId(3)
OVwDbObjectIdToSelectionName
OVwDbSelectionNameToObjectId(3)
452
Appendix C
Reference Page
OVwDbSelectionNameToObjectId
OVwDbSelectionNameToObjectId(3)
OVwDbSetEnumConstants
OVwDbSetEnumConstants(3)
OVwDbSetFieldBooleanValue
OVwDbSetFieldValue(3)
OVwDbSetFieldEnumByName
OVwDbSetFieldValue(3)
OVwDbSetFieldEnumByValue
OVwDbSetFieldValue(3)
OVwDbSetFieldIntegerValue
OVwDbSetFieldValue(3)
OVwDbSetFieldStringValue
OVwDbSetFieldValue(3)
OVwDbSetFieldValue
OVwDbSetFieldValue(3)
OVwDbSetHostname
OVwDbSetSelectionName(3)
OVwDbSetSelectionName
OVwDbSetSelectionName(3)
OVwDbUnsetFieldValue
OVwDbUnsetFieldValue(3)
OVwDbUnsetFieldValues
OVwDbUnsetFieldValue(3)
OVwDeleteAction
OVwActionRegistration(3)
OVwDeleteApp
OVwAppRegistration(3)
OVwDeleteMenu
OVwMenuRegistration(3)
OVwDeleteMenuItem
OVwMenuItemRegistration(3)
OVwDeleteSubmap
OVwCreateSubmap(3)
OVwDeleteSymbol
OVwCreateSymbol(3)
OVwDeleteSymbolAlert
OVwCreateSymbolAlert(3)
OVwDeleteSymbols
OVwCreateSymbol(3)
OVwDeleteToolbarButton
OVwToolbarButtonRegistration(3)
OVwDisplaySubmap
OVwDisplaySubmap(3)
Appendix C
453
Reference Page
OVwDoAction
OVwCheckAction(3)
OVwDoInternalFunction
OVwCheckInternalFunction(3)
OVwDone
OVwDone(3)
OVwEndMapSync
OVwBeginMapSync(3)
OVwEndSessionCB
OVwEndSessionCB(3)
OVwError
OVwError(3)
OVwErrorMsg
OVwErrorMsg(3)
OVwFileDescriptor
OVwFileDescriptor(3)
OVwFindMenuItem
OVwFindMenuItem(3)
OVwFormatBehavior
OVwFormat(3)
OVwFormatBoolean
OVwFormat(3)
OVwFormatFieldDataType
OVwFormat(3)
OVwFormatFieldFlags
OVwFormat(3)
OVwFormatFieldId
OVwFormat(3)
OVwFormatLayoutStyle
OVwFormat(3)
OVwFormatMapPermissions
OVwFormat(3)
OVwFormatObjectId
OVwFormat(3)
OVwFormatOpScope
OVwFormat(3)
OVwFormatPlacementType
OVwFormat(3)
OVwFormatPlaneType
OVwFormat(3)
OVwFormatStatusSource
OVwFormat(3)
OVwFormatStatusType
OVwFormat(3)
454
Appendix C
Reference Page
OVwFormatSubmapId
OVwFormat(3)
OVwFormatSubmapPolicy
OVwFormat(3)
OVwFormatSymbolId
OVwFormat(3)
OVwFormatSymbolPosition
OVwFormat(3)
OVwFormatSymbolType
OVwFormat(3)
OVwFormatSymbolVariety
OVwFormat(3)
OVwFormatTime
OVwFormat(3)
OVwFreeActionRegInfo
OVwActionRegistration(3)
OVwFreeAppRegInfo
OVwAppRegistration(3)
OVwFreeMapInfo
OVwGetMapInfo(3)
OVwFreeMenuItemRegInfo
OVwMenuItemRegistration(3)
OVwFreeObjectInfo
OVwGetObjectInfo(3)
OVwFreeObjectList
OVwListObjectsOnMap(3)
OVwFreeLocateResultInfoList
OVwLocate(3)
OVwFreeSubmapInfo
OVwGetSubmapInfo(3)
OVwFreeSubmapList
OVwListSubmaps(3)
OVwFreeSubmapLoadAckList
OVwLoadSubmap(3)
OVwFreeSymbolInfo
OVwGetSymbolInfo(3)
OVwFreeSymbolList
OVwListSymbols(3)
OVwFreeToolbarButtonRegInfo
OVwToolbarButtonRegistration(3)
OVwGetAction
OVwActionRegistration(3)
OVwGetApp
OVwAppRegistration(3)
Appendix C
455
Reference Page
OVwGetAppConfigValues
OVwGetAppConfigValues(3)
OVwGetAppName
OVwGetAppName(3)
OVwGetConnSymbol
OVwGetConnSymbol(3)
OVwGetFirstAction
OVwGetFirstAction(3)
OVwGetFirstButtonFunction
OVwGetFirstButtonFunction(3)
OVwGetFirstMenuItem
OVwGetFirstMenuItem(3)
OVwGetFirstMenuItemFunction
OVwGetFirstMenuItemFunction(3)
OVwGetFirstPopupMenuItem
OVwGetFirstMenuItem(3)
OVwGetFirstPopupMenuItemFunction
OVwGetFirstMenuItemFunction(3)
OVwGetFirstPulldownMenuItem
OVwGetFirstMenuItem(3)
OVwGetFirstPulldownMenuItemFunction
OVwGetFirstMenuItemFunction(3)
OVwGetFirstRegContext
OVwGetFirstRegContext(3)
OVwGetFirstToolbarButton
OVwGetFirstToolbarButton(3)
OVwGetMapInfo
OVwGetMapInfo(3)
OVwGetMenuItem
OVwMenuItemRegistration(3)
OVwGetMenuItemMenu
OVwGetMenuItemPath(3)
OVwGetMenuItemPath
OVwGetMenuItemPath(3)
OVwGetMenuPathSeparator
OVwGetMenuPathSeparator(3)
OVwGetNextAction
OVwGetFirstAction(3)
OVwGetNextButtonFunction
OVwGetFirstButtonFunction(3)
OVwGetNextMenuItem
OVwGetFirstMenuItem(3)
OVwGetNextMenuItemFunction
OVwGetFirstMenuItemFunction(3)
456
Appendix C
Reference Page
OVwGetNextPopupMenuItem
OVwGetFirstMenuItem(3)
OVwGetNextPopupMenuItemFunction
OVwGetFirstMenuItemFunction(3)
OVwGetNextPulldownMenuItem
OVwGetFirstMenuItem(3)
OVwGetNextPulldownMenuItemFunction
OVwGetFirstMenuItemFunction(3)
OVwGetNextRegContext
OVwGetFirstRegContext(3)
OVwGetNextToolbarButton
OVwGetFirstToolbarButton(3)
OVwGetObjectInfo
OVwGetObjectInfo(3)
OVwGetRegContext
OVwGetRegContext(3)
OVwGetSelections
OVwGetSelections(3)
OVwGetSubmapInfo
OVwGetSubmapInfo(3)
OVwGetSymbolInfo
OVwGetSymbolInfo(3)
OVwGetSymbolsByObject
OVwGetSymbolsByObject(3)
OVwHelpCallbackProc
OVwAddHelpCallback(3)
OVwHighlightObject
OVwHighlightObject(3)
OVwHighlightObjects
OVwHighlightObject(3)
OVwInit
OVwInit(3)
OVwInitSession
OVwInit(3)
OVwIsIdEqual
OVwIsIdNull(3)
OVwIsIdNull
OVwIsIdNull(3)
OVwListObjectsOnMap
OVwListObjectsOnMap(3)
OVwListSubmaps
OVwListSubmaps(3)
OVwListSymbolTypeCaps
OVwListSymbolTypes(3)
Appendix C
457
Reference Page
OVwListSymbolTypes
OVwListSymbolTypes(3)
OVwListSymbols
OVwListSymbols(3)
OVwLoadSubmap
OVwLoadSubmap(3)
OVwLoadSubmaps
OVwLoadSubmap(3)
OVwLocateByAttribute
OVwLocate(3)
OVwLocateByComment
OVwLocate(3)
OVwLocateBySelectionName
OVwLocate(3)
OVwLocateBySymbolLabel
OVwLocate(3)
OVwLocateBySymbolStatus
OVwLocate(3)
OVwLocateBySymbolType
OVwLocate(3)
OVwLockRegUpdates
OVwLockRegUpdates(3)
OVwMainLoop
OVwMainLoop(3)
OVwManageObject
OVwManageObject(3)
OVwManageObjects
OVwManageObject(3)
OVwMapCloseCB
OVwMapCloseCB(3)
OVwMapOpenCB
OVwMapOpenCB(3)
OVwMenuItemRegistration
OVwMenuItemRegistration(3)
OVwMenuRegistration
OVwMenuRegistration(3)
OVwModifySubmap
OVwModifySubmaps(3)
OVwModifySubmaps
OVwModifySubmaps(3)
OVwModifySymbol
OVwModifySymbols(3)
OVwModifySymbols
OVwModifySymbols(3)
458
Appendix C
Reference Page
OVwPeekInputEvent
OVwPeekOVwEvent(3)
OVwPeekOVwEvent
OVwPeekOVwEvent(3)
OVwPending
OVwPending(3)
OVwPrintFieldInfo
OVwPrint(3)
OVwPrintFieldList
OVwPrint(3)
OVwPrintMapInfo
OVwPrint(3)
OVwPrintObjectInfo
OVwPrint(3)
OVwPrintObjectList
OVwPrint(3)
OVwPrintSubmapInfo
OVwPrint(3)
OVwPrintSubmapList
OVwPrint(3)
OVwPrintSymbolIdList
OVwPrint(3)
OVwPrintSymbolInfo
OVwPrint(3)
OVwPrintSymbolList
OVwPrint(3)
OVwPrintSymbolTypeList
OVwPrint(3)
OVwProcessEvent
OVwProcessEvent(3)
OVwQueryAddSymbolCB
OVwVerifyAdd(3)
OVwQueryAppConfigCB
OVwVerifyAppConfigChange(3)
OVwQueryConnectSymbolsCB
OVwVerifyConnect(3)
OVwQueryDeleteSymbolsCB
OVwVerifyDeleteSymbol(3)
OVwQueryDescribeCB
OVwVerifyDescribeChange(3)
OVwRemoveActionCallback
OVwAddActionCallback(3)
OVwRemoveAlertCallback
OVwAddAlertCallback(3)
Appendix C
459
Reference Page
OVwRemoveCallback
OVwAddCallback(3)
OVwRemoveDropCallback
OVwAddDropCallback(3)
OVwRemoveHelpCallback
OVwAddHelpCallback(3)
OVwRemoveInput
OVwAddInput(3)
OVwRemoveMenuItem
OVwAddMenuItem(3)
OVwRemoveMenuItemFunction
OVwAddMenuItemFunction(3)
OVwRemovePopupMenuItemFunction
OVwAddMenuItemFunction(3)
OVwRemovePulldownMenuItemFunction
OVwAddMenuItemFunction(3)
OVwRemoveSubmapContext
OVwAddSubmapContext(3)
OVwRemoveToolbarButton
OVwAddToolbarButton(3)
OVwRemoveToolbarButtonFunction
OVwAddToolbarButtonFunction(3)
OVwRenameRegContext
OVwRenameRegContext(3)
OVwReturnLocateResults
OVwReturnLocateResults(3)
OVwSaveRegUpdates
OVwSaveRegUpdates(3)
OVwSelectListChangeCB
OVwSelectListChangeCB(3)
OVwSelectObject
OVwSelectObject(3)
OVwSelectObjects
OVwSelectObject(3)
OVwSessionId
OVwSessionId(3)
OVwSetAction
OVwActionRegistration(3)
OVwSetApp
OVwAppRegistration(3)
OVwSetAppConfigValues
OVwGetAppConfigValues(3)
OVwSetBackgroundGraphic
OVwSetBackgroundGraphic(3)
460
Appendix C
Reference Page
OVwSetMenuItem
OVwMenuItemRegistration(3)
OVwSetMenuPathSeparator
OVwGetMenuPathSeparator(3)
OVwSetRegContext
OVwGetRegContext(3)
OVwSetStatusOnObject
OVwSetStatusOnObject(3)
OVwSetStatusOnObjects
OVwSetStatusOnObject(3)
OVwSetStatusOnSymbol
OVwSetStatusOnObject(3)
OVwSetStatusOnSymbols
OVwSetStatusOnObject(3)
OVwSetSubmapName
OVwSetSubmapName(3)
OVwSetSymbolAlertText
OVwCreateSymbolAlert(3)
OVwSetSymbolApp
OVwSetSymbolApp(3)
OVwSetSymbolBehavior
OVwSetSymbolBehavior(3)
OVwSetSymbolLabel
OVwSetSymbolLabel(3)
OVwSetSymbolPosition
OVwSetSymbolPosition(3)
OVwSetSymbolStatusSource
OVwSetSymbolStatusSource(3)
OVwSetSymbolType
OVwSetSymbolType(3)
OVwSetToolbarButton
OVwToolbarButtonRegistration(3)
OVwShowHelp
OVwShowHelp(3)
OVwSubmapChangeCB
OVwSubmapChangeCB(3)
OVwSubmapCloseCB
OVwSubmapCloseCB(3)
OVwSubmapOpenCB
OVwSubmapOpenCB(3)
OVwSymbolChangeCB
OVwSymbolChangeCB(3)
OVwSymbolLabelLocateCB
OVwSymbolLabelLocateCB(3)
Appendix C
461
Reference Page
OVwSymbolStatusLocateCB
OVwSymbolStatusLocateCB(3)
OVwSymbolTypeLocateCB
OVwSymbolTypeLocateCB(3)
OVwUndoRegUpdates
OVwSaveRegUpdates(3)
OVwUnloadSubmap
OVwLoadSubmap(3)
OVwUnloadSubmaps
OVwLoadSubmap(3)
OVwUnlockRegUpdates
OVwLockRegUpdates(3)
OVwUnmanageObject
OVwManageObject(3)
OVwUnmanageObjects
OVwManageObject(3)
OVwUserSubmapCreateCB
OVwUserSubmapCreateCB(3)
OVwVerifyAdd
OVwVerifyAdd(3)
OVwVerifyAppConfigChange
OVwVerifyAppConfigChange(3)
OVwVerifyConnect
OVwVerifyConnect(3)
OVwVerifyDeleteSymbol
OVwVerifyDeleteSymbol(3)
OVwVerifyDescribeChange
OVwVerifyDescribeChange(3)
OVwVerifyDrop
OVwVerifyDrop(3)
OVwXtAddInput
OVwXtAddInput(3)
OVwXtAppAddInput
OVwXtAddInput(3)
OVwXtAppMainLoop
OVwXtMainLoop(3)
OVwXtMainLoop
OVwXtMainLoop(3)
462
Appendix C
Index
Symbols
$LANG, 42
$OV_FIELDS/$LANG, 118
$OV_HELP/$LANG, 56
$OV_SYMBOLS/$LANG, 100
(*OVwConfirmDeleteSymbolsC
B)(), 307
(*OVwMapCloseCB)(), 228
(*OVwQueryDeleteSymbolsCB)(
), 307
A
acknowledgment timer
map close, 227
action events
callback routines, 149
description, 148
example, 149
adding
a symbol, 303
agents
daemon, 385, 393
non-well-behaved, 393
well-behaved, 384
alerts
See status
See symbol alert
AllContexts, 67
API version
controlling, 32
application
connecting to remote GUI, 331
application callbacks
associating with a DropAction,
321
removing association with
DropAction, 321
application configuration
changing the application
configuration, 303
map editing, 303
application development
Index
setting configuration
programmatically, 220
setting interest in a symbol,
279
starting after map open, 226
attributes
map-specific, 288
automatic layout
overriding, 250
B
background graphics, 229
clearing, 229
modifying for a submap, 214
setting, 229
background, sending your
process into, 388
base symbols, 243
behavior
changing for a symbol, 276
symbols, 238
Bus layout algorithm, 200
C
callback routines
example, 147
for map change events, 295
capabilities
merging default fields of
symbol type with fields of
object, 249
cg92_used, 33
changing
attributes of submaps, 214
object description, 304
status colors, 241
submap name, 215
text annotation dynamically
for symbol alert, 267
checking
event queue during map
synchronization, 226
463
Index
464
representing multiple
connections, 197
container symbols
meta-connections, 253
context, 65
context expressions, 66
convenience routines
OVwDb, 188
conventions
typographical, 21
coordinate position, 239
setting, 251
copying
flashing symbols, 272
symbol alerts, 243
copyright blocks, 52
creating
a symbol based on object name,
248
a symbol based on parent
object, 248
advantages/disadvantages
using
OVwCreateSymbols(), 259
combinations of icon and
connection symbols, 254
connection symbols, 252
example creating multiple
symbols with
OVwCreateSymbols(), 256
multiple symbols with a single
call, 254
object database fields, 170
objects, 176
submaps, deciding when to,
209
symbol alerts, 266
symbols, 246
text annotation dynamically
for symbol alert, 267
critical status, 240
CursorSize, 110
customization
Index
Index
submaps, 217
symbol alerts, 267
symbols, 259, 307
description blocks, 52
dialog box, adding help
, 88
disabled status, 240
disconnecting from ovw, 145
displaying
graphical map of managed
environment, 229
highlighted objects, 161
submaps, 208
displayTextAnnotationBackgrou
nd, 273
distribution, 325
drag and drop
drop action registration, 83
operations, 84
drag and drop operations, 316
323
application callback
invocation, 321
assigning a DropAction to a
drop target, 320
associating a DropAction with
an application callback,
321
behavior, 317
customization steps, 319
help for, 319
removing association between
DropAction and
application callback, 321
verifying success of drop
operation, 323
drag source
behavior, 317
dragging
transparent symbols, 270, 272
drop actions
help text, 84
modifying for a submap, 214
Index
operations, 84
registration, 83
selection rule, 84
drop operations
behavior, 319
drop targets
assigning DropAction to, 320
behavior, 317
drop_action, 320
drop_app_name, 320
DropAction
assigning to a drop target, 320
associating with an application
callback, 321
removing association with
application callback, 321
E
enableExecCueRemoval, 272
enableFlashing, 272
enroll block, 85
fields, 89
rules, 86
enumerated types
defiing, 172
enumeration types
retrieving information, 174
error handling
return code, 155
string associated with an error,
155
errors
cg92_used, 33
value definitions, 155
event handling
example, 299
event processing, 151
special needs, 153
event queue
checking during map
synchronization, 226
events, 146
465
Index
ovwSelectionListChange, 159
selection list changes, 295
status of symbol changed, 295
symbol moved within map, 295
example
modifying submap attributes,
215
example applications, 153
examples
action event registration, 149
callback routine, 147
changing symbol behavior, 278
checking for file descriptor
input, 152
creating a symbol, 247
creating an object containing a
name field, 180
creating multiple symbols with
OVwCreateSymbols(), 256
error handling, 155
event handling, 299
getting contents of selection
list, 158
listing connections of a metaconnection submap, 285
placing symbols by coordinate
position, 251
retrieving a list of submaps,
222
retrieving field value
information, 183
symbol alert callback
registration, 262
symbol pop-up menu
registration, 72
using OVwCreateSubmap(),
207
using OVwFieldBindList data
structure, 186
using OVwGetSelections(), 158
exclusive submaps, 197, 202
exec_vis_cue, 272
executable symbols, 238
466
appearance, 271
explodable symbols, 196, 238
expressions
context, 66
F
field data types
defining enumeration values,
172
field IDs
testing, 156
field information
managing, 168
field registration files, 118
capability flag, 119
combining flags, 123
examples, 121
field block, 118
field type, 119
general flag, 119
list flag, 119
locate flag, 119
name flag, 119
processing, 43
fields
convenience routines to
retrieve and set values,
184
converting field IDs to field
names, 171
converting field names to field
IDs, 171
creating, 170
data types, 168
defined, 168
enumeration, 172
getting values, 183
identifier, 171
name versus identifier, 171
passing values as arguments,
185
retrieving, 173
Index
Index
Index
changing application
configuration, 84, 300
changing the application
configuration, 303
choosing confirm event, 306
connecting symbols, 84, 300
connecting two symbols, 303
cut and paste operations, 314
events, 295
flashing symbols, 272
interactions, 300
modifying object attributes,
84, 300
query-verify-confirm sequence,
301
map edits
transparent symbols, 270
map synchronization
checking for important events,
226
maps
application configuration, 219
application participation in
map changes, 300, 308
callback routines for map
change events, 295
close request, 227
defined, 195
getting information, 218
map change events, 295299
map close acknowledgment
timer, 227
map editing events, 295
open, 195
processing a map close event,
227
processing map open request,
224
synchronization, 225
synchronization routines, 225
memory management
implementation of data
structures, 178
467
Index
memory use
Windows NT, 33
MenuBar blocks, 59
menus
mnemonic, 62
registration of symbol alert
menus, 73
registration of symbol alerts,
73
structure of pull-down, 58
meta-connection submaps
example listing connections,
285
meta-connections, 253
submap, 198
migrating
applications, 32
minor/marginal status, 240
modifying
attributes of submaps, 214
submap name, 215
submaps, 214
moving
flashing symbols, 272
transparent symbols, 270
multiple connections, 253
Multiple Connections layout
algorithm, 200
N
name field, 119
NameField statement, 57
nettl, 377
NNM
retrieving version information,
33
No Layout layout algorithm, 200
no position, 239
NoGeneric, 67
normal status, 240
notifications
map changes, 295299
468
O
object databases
convenience routines, 188
developer access, 168
field data types, 168
persistence, 168
object IDs
testing, 156
object information
managing, 168
objects
adding field, 184
as status sources, 241
capabilities, 86
changing description, 304
changing selection list via
APIs, 160
creating, 176, 179
creating by hostname, 182
creating by selection name,
182
defined, 169
definition, 236
deleting, 190
generating unique name, 181
generating unique selection
name, 181
getting the selection list, 158
global attributes vs. mapspecific attributes, 291
highlighting, 161
listing all on a map, 290
locating on transient submaps,
309
manage/unmanage object
events, 298
managing programmatically,
313
map-specific attributes, 289
OVwDbCreateObject(), 179
parent, 196
retrieving information, 288
291
Index
Index
overlay
graphics, 111
setting submap overlay, 215
submap windows, 204
OVNNMVersion, 33
OVsDone(), 387
OVServerName, 329
OVsInit(), 387
OVsInitComplete(), 387
ovspmd
diagram, 383
process management daemon,
383
OVsPMD API
functions in, 387
rules for use, 387
OVsReceive(), 387
ovstart, 383
ovstatus, 383
ovstop, 383
OVuLog(), 379
OVuTL API
functions of, 379
tracing and logging, 377
OVuTrace(), 379
OVVersion.h, 33
OVw APIs
groups, 30
ovw events, 146
ovw_errs.h, 155
ovw_obj.h, 169, 171
ovw_string.h, 184
OVwAckMapClose(), 228
OVwActionCallbackProc, 149
OVwAddActionCallback(), 148
OVwAddDropCallback(), 321
OVwAddInput(), 152
OVwAddSubmapContext(), 208
OVwAPILevel, 32
OVwAttributeLocateCB(), 310
OVwClearBackgroundGraphic,
229
OVwClearSymbolApp(), 279
Index
OVwCloseSubmap(), 210
OVwConfirmAddSymbolCB(),
303, 307
OVwConfirmAppConfigCB(),
303
ovwConfirmCapabilityChange,
295
OVwConfirmCapabilityChange
CB(), 295
ovwConfirmCompoundStatusCh
ange, 295
OVwConfirmCompoundStatusC
hangeCB(), 295
OVwConfirmConnectSymbolsC
B(), 303
ovwConfirmCreateObjects, 295
OVwConfirmCreateObjectsCB(),
295
ovwConfirmCreateSubmaps,
295
OVwConfirmCreateSubmapsCB
(), 295
OVwConfirmCreateSymbolCB(),
307
ovwConfirmCreateSymbols, 295
OVwConfirmCreateSymbolsCB(
), 295
ovwConfirmDeleteObjects, 295
OVwConfirmDeleteObjectsCB(),
295
ovwConfirmDeleteSubmaps, 295
OVwConfirmDeleteSubmapsCB(
), 295
OVwConfirmDeleteSymbolAlert
CB(), 267
ovwConfirmDeleteSymbols, 295
OVwConfirmDeleteSymbolsCB()
, 295
OVwConfirmDescribeCB, 304
ovwConfirmHideSymbols, 295,
297
OVwConfirmHideSymbolsCB(),
295
ovwConfirmManageObjects, 295
OVwConfirmManageObjectsCB(
), 295
ovwConfirmMoveSymbols, 295
OVwConfirmMoveSymbolsCB(),
295
ovwConfirmObjectStatusChang
e, 295
OVwConfirmObjectStatusChang
eCB(), 295
ovwConfirmSymbolStatusChang
e, 295
OVwConfirmSymbolStatusChan
geCB(), 295
ovwConfirmUnhideSymbols,
295, 298
OVwConfirmUnhideSymbolsCB
(), 295
ovwConfirmUnmanageEvent,
298
ovwConfirmUnmanageObjects,
295
OVwConfirmUnmanageObjects
CB(), 295
ovwCoordPosition, 249
OVwCreateComponentSymbol(),
248
OVwCreateConnSymbol(), 252
OVwCreateSubmap(), 206
OVwCreateSymbolAlert(), 266
OVwCreateSymbolByName(),
248
OVwCreateSymbols(), 246, 254
OVwDb
convenience routines, 188
OVwDbCreateField(), 171
OVwDbCreateObject(), 179
OVwDbCreateObjectByHostna
me(), 182
OVwDbCreateObjectBySelectio
nName(), 182
OVwDbFieldIdToFieldName(),
171
469
Index
OVwDbFieldNameToFieldId(),
171
OVwDbGetEnumConstants(),
175
OVwDbGetEnumName(), 175
OVwDbGetEnumValue(), 175
OVwDbGetFieldInfo(), 174
OVwDbGetFieldValue(), 183
OVwDbGetFieldValues(), 185
OVwDbSetEnumConstants(),
172
OVwDbSetFieldValue(), 184
OVwDeleteSubmap(), 217
OVwDeleteSymbol(), 259
OVwDeleteSymbolAlert(), 267
OVwDeleteSymbols(), 259
OVwDisplaySubmap(), 209
OVwDone, 145
ovwDoNotDisplayLabel, 249
OVwDropCallbackProc(), 322
ovwEndSession, 295
OVwEndSessionCB(), 295
OVwError(), 155
OVwErrorMsg(), 155
OVwFieldBinding data
structure, 179
OVwFieldInfo data structure,
173
OVwFieldValue data structure,
176
OVwFileDescriptor(), 153
OVwFreeObjectInfo(), 289
OVwFreeSubmapList(), 223
OVwFreeSymbolInfo(), 284
OVwFreeSymbolList(), 287
OVwGetAppConfigValues(), 219
OVwGetAppName(), 157
OVwGetConnSymbol(), 285
OVwGetMapInfo(), 218
OVwGetObjectInfo(), 289
OVwGetSymbolInfo(), 284
OVwGetSymbolsByObject(), 290
470
in on-demand map
applications, 312
OVwHighlightObject(), 161
OVwHighlightObjects(), 161
OVwInit, 145
OVwInitSession, 145
OVwInitSession(), 331
OVwIsIdEqual, 156
OVwIsIdNull, 156
OVwListFieldEntry, 176
OVwListFieldValue, 176
OVwListObjectsOnMap(), 290
in on-demand map
applications, 312
OVwListOpenSubmaps(), 223
OVwListSubmaps(), 221
in on-demand map
applications, 312
OVwListSymbols(), 286
OVwListSymbolTypeCaps(), 287
OVwListSymbolTypes(), 287
OVwLocateResultList data
structure, 309
OVwLocateResultObject, 309
OVwMainLoop(), 152
OVwManageObject(), 313
OVwManageObjects(), 313
ovwMapClose, 295
OVwMapCloseCB(), 295
OVwMapInfo data structure,
218
ovwMapOpen, 224, 295
OVwMapOpenCB(), 224, 295
ovwMergeDefaultCapabilities,
249
OVwModifySubmap, 214
OVwModifySubmap(), 214
OVwModifySubmaps, 214
OVwModifySubmaps(), 214
ovwNoLayout, 230
ovwNoPosition, 249
ovwNoSymbolFlags, 248
ovwNselectionName, 184
OVwObjectIdList data
structure, 158
OVwObjectInfo data structure,
288
OVwPeekOVwEvent(), 154
OVwPending(), 154
OVwProcessEvent(), 154
OVwQueryAddSymbolCB(), 303
OVwQueryConnectSymbolsCB()
, 303
OVwQueryDescribeCB(), 304
OVwRemoveDropCallback(),
321
OVwRemoveSubmapContext(),
208
OVwReturnLocateResults(), 309
ovwSelectionListChange, 295
ovwSelectionListChange event,
159
OVwSelectionListChangeCB(),
295
OVwSelectObject(), 160
OVwSelectObjects(), 160
ovwSequencePosition, 249
OVwSessionID, 331
OVwSetAppConfigValues(), 220
OVwSetBackgroundGraphic,
229
OVwSetStatusOnObject, 280
OVwSetStatusOnObjects(), 281
OVwSetStatusOnSymbol(), 280
OVwSetStatusOnSymbols(), 281
OVwSetSymbolAlertText(), 267
OVwSetSymbolApp(), 279
OVwSetSymbolBehavior(), 276
OVwSetSymbolPosition(), 276
OVwSetSymbolStatusSource(),
280
OVwSetSymbolType(), 276
ovwsetupclient, 330
and management consoles, 327
OVwShowHelp(), 162
ovwStarCenterPosition, 249
Index
Index
Index
OVwVerifyAppConfigChange(),
303
OVwVerifyConnect(), 303
OVwVerifyDeleteSymbol(), 307
OVwVerifyDescribeChange(),
304
OVwVerifyDrop(), 323
OVwXtMainLoop(), 153
P
page, 410
parent objects, 196
modifying for a submap, 214
parent submaps, 196
paste and cut operations, 314
percent_full, 275
persistent submaps, 201, 202
symbol alerts, 263
PixmapBaseName, 116
PixmapSize, 116
Point to Point layout algorithm,
200
pop-up menus
registration example, 72
porting
applications, 32
position
changing symbol position, 276
setting for symbol, 249
predefined fields, 175
process flags, 54
process management, 383
ovspmd, 383
OVsPMD API, 387
ovstart, 383
ovstatus, 383
ovstop, 383
processing
map close event, 227
map open requests, 224
programming tips
471
Index
R
receiving
map change notifications, 295
registering
map open events, 224
registration
drop action, 83
example pop-up menu, 72
overlay graphics, 111
symbol alert menus, 73
symbol alert types, 115
symbol pop-up menu, 70
registration files
application, 45
creating and using, 41
field, 118
processing, 43
symbol type, 100
types, 27
remote connection, 331
removing
submap context, 208
restricted status, 240
retrieving
application configuration
information, 219
global object attributes vs.
map-specific attributes,
291
information about a specific
submap, 220
information about open map,
218
list of open submaps, 223
list of registered symbol types,
287
list of submaps, 221
map-specific object
information, 289
object information, 288291
symbol information, 253, 282
??, 284, ??287
reusing
472
OVwCreateComponentSymbol
(), 248
OVwCreateConnSymbol(), 252
OVwCreateSubmap(), 206
OVwCreateSymbol(), 246
OVwCreateSymbolAlert(), 266
OVwCreateSymbolByName(),
248
OVwCreateSymbols(), 254
OVwDbCreateField(), 171
OVwDbCreateObject(), 179
OVwDbDeleteObject(), 190
OVwDbFieldIdToFieldName(),
172
OVwDbFieldNameToFieldId(),
172
OVwDbGetEnumConstants(),
175
OVwDbGetEnumName(), 175
OVwDbGetEnumValue(), 175
OVwDbGetFieldInfo(), 174
OVwDbGetFieldValue(), 183
OVwDbGetFieldValues(), 185
OVwDbInit(), 168
OVwDbSetEnumConstants(),
172
OVwDbSetFieldValue(), 184
OVwDbUniqObjectName(),
181
OVwDbUnsetFieldValue(), 190
OVwDeleteSubmap(), 217
OVwDeleteSymbol(), 259
OVwDeleteSymbolAlert(), 267
OVwDeleteSymbols(), 259
OVwDisplaySubmap(), 209
OVwDone(), 145
OVwEndMapSync(), 225
OVwError(), 155
OVwErrorMsg(), 155
OVwFileDescriptor(), 154
OVwFreeObjectInfo(), 289
OVwFreeSymbolInfo(), 284
OVwFreeSymbolList(), 287
Index
Index
OVwGetAppConfigValues(),
219
OVwGetAppName(), 157
OVwGetConnSymbol(), 285
OVwGetMapInfo(), 218
OVwGetObjectInfo(), 289
OVwGetSelections(), 158
OVwGetSubmapInfo(), 220
OVwGetSymbolInfo(), 284
OVwGetSymbolsByObject(),
289
OVwHighlightObject(), 161
OVwHighlightObjects(), 161
OVwInit(), 145
OVwIsIdEqual(), 156
OVwIsIdNull(), 156
OVwListFields(), 174
OVwListObjectsOnMap(), 290
OVwListOpenSubmaps(), 223
OVwListSubmaps(), 221
OVwListSymbols(), 286
OVwListSymbolTypeCaps(),
287
OVwListSymbolTypes(), 287
OVwMainLoop(), 152
OVwModifySubmap, 214
OVwModifySubmaps, 214
OVwPeekOVwEvent(), 154
OVwRemoveSubmapContext()
, 208
OVwSelectObject(), 160
OVwSelectObjects(), 160
OVwSetAppConfigValues(),
220
OVwSetBackgroundGraphic(),
229
OVwSetStatusOnObject(), 280
OVwSetStatusOnObjects(),
281
OVwSetStatusOnSymbol(),
280
OVwSetStatusOnSymbols(),
281
Index
OVwSetSubmapName(), 215
OVwSetSymbolAlertText(),
267
OVwSetSymbolApp(), 279
OVwSetSymbolBehavior(), 276
OVwSetSymbolLabel(), 278
OVwSetSymbolPosition(), 276
OVwSetSymbolStatusSource()
, 280
OVwSetSymbolType(), 276
OVwShowHelp(), 162
OVwVerifyAdd(), 302
OVwVerifyAppConfigChange()
, 302
OVwVerifyConnect(), 302
OVwVerifyDeleteSymbol(),
307
OVwVerifyDescribeChange(),
302
OVwXtMainLoop(), 153
XtAddInput(), 153
Row/Column layout algorithm,
200
S
scalability, 202
secondary_status, 275
select(), 387
select(2), 153
selecting
objects via API, 160
selection lists, 158
change notification, 159
changing contents, 160
getting contents, 158
selection rules, 159
selection names, 178
predefined name field, 175
specifying, 184
selection rules
using in OVW programs, 159
SelectionRule
drop actions, 84
sequence position, 239
constraints, 239
setting, 250
server
communication, 330
setting
application configuration
dynamically, 220
background graphics, 229
submap context, 208
severity levels
ISO 10164 standard, 241
shared submaps, 201
Solaris
compiling applications, 33
Star Center layout algorithm,
200
star center position, 239
constraints, 239
startup file (SUF), 383
status
changing colors, 241
changing the value, 280
colors, 239
compound, 198, 242
connection symbols, 275
control of status summation
algorithm, 242
eliminating status conflict
between applications, 242
managing status in on-demand
map applications, 312
representing in parent object,
198
sources, 241
status source by object, 241
summation of status for
multiple symbols, 242
symbol, 242
symbol status, 242
symbols, 239
status categories, 240
473
Index
status colors
changing, 241
See also symbol alerts
status conditions, 240
status meaning, 240
status source
changing for a symbol, 280
string constant definitions, 184
submap context
defined, 196
removing, 208
setting, 208
submap geometry
modifying for a submap, 214
setting, 216
transient submaps, 216
submap IDs
testing, 156
submap overlay
modifying for a submap, 214
ovwUpdateSubmapOverlay,
215
setting, 215
submap_overlay, 215
submap policies
modifying for a submap, 214
submap types
modifying for a submap, 214
submap_overlay, 215
submap_window_height, 216
submap_window_width, 216
submap_window_x, 216
submap_window_y, 216
submaps, 201
background graphic, 229
changing characteristics, 214
changing the name, 215
child, 196
choosing when to create, 209
closing, 210
context, 65
creating, 206
defined, 196
474
deleting, 217
displaying, 208
exclusive, 197, 202
geometry, 204
geometry definition, 203
getting information about
specific submap, 220
hierarchy, 210
home, 197
layout algorithm, 200
layout algorithm, defined, 238
list of symbols on, 286
listing open submaps, 223
meta-connection, 198
modifying, 214
modifying attributes of, 214
modifying name, 215
names, modifying for a
submap, 214
on-demand, 202
organizing hierarchy, 210
orphaned, 197
overlay, 204
overlay defined, 203
parent, 196
persistent, 202
planes, 201
presentation, 203
retrieving a list, 221
root, 197
scalability, 202
setting context, 208
setting geometry, 216
shared, 201
shared vs. exclusive, 201
size and location, 216
size and location of window,
203
targeting menu items for, 65
transient, 202
window reuse, 204
symbol alert types
registration, 115
Index
Index
Index
475
Index
universal pathnames
over NFS, 327
unknown status, 240
unmanage status, 240
unmanaging
objects programmatically, 313
updating
map synchronization, 225
/usr/OV/help/$LANG, 131
V
varieties, 108
symbol, 237
version information
retrieving programmatically,
33
version statements, 52
visual cues
See also connection symbols
See executable symbols
See flashing symbols
See status
See symbol alerts
See transparent symbols
W
warning status, 240
windows
presentation of submaps, 203
reusing, 215
submap arrangement on
display, 204
Windows NT
memory use, 33
referencing global variables,
33
using non-debug libraries, 33
X
X event processing, 153
xcg92, 33
U
unique object names
generating, 181
476
Index