blob: b709093dd21af9ad6a5f1154b0d4813e9e223b93 [file] [log] [blame]
/* --COPYRIGHT--,EPL
* Copyright (c) 2008 Texas Instruments and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Texas Instruments - initial implementation
*
* --/COPYRIGHT--*/
/*
* ======== ViewInfo ========
*/
package xdc.rov
/*!
* ======== ViewInfo ========
* Describes the ROV views supported by a particular module.
*/
@Facet metaonly module ViewInfo {
/*!
* ======== ViewType ========
* ROV view type
*
* @p(dlist)
* - INSTANCE
* basic instance information (one row per instance). The view
* init function is passed two arguments: (1) an instance of the
* view structure, and (2) the instance state structure of the
* instance to view.
*
* - INSTANCE_DATA
* instance-specific data tables (many rows per instance). The
* view init function is passed two arguments:(1) an instance of
* the {@link xdc.rov.Program#InstDataView Program.InstDataView}
* structure, and (2) an instance state structure for the
* instance to view.
*
* - MODULE
* basic module information (one row per module). The view
* init function is passed two arguments: (1) an instance of the
* view structure, and (2) the module state structure of the
* module to view.
*
* - MODULE_DATA
* module-specific data tables (many rows per module). The
* view init function is passed one argument: a
* {@link xdc.rov.Program#ModDataView Program.ModDataView}
* structure.
*
* - RAW
* This is a reserved view type used by ROV to display raw data.
*
* - TREE_TABLE
* The view init function is passed no arguments and is expected
* to return a new initialized
* {@link xdc.rov.Program#TreeNode xdc.rov.Program.TreeNode}
* array or `null` in the event that there is nothing to
* display.
*
* This view type is used to describe the `Diags` masks
* for all modules, for example; see
* {@link xdc.runtime.Diags#rovViewInfo Diags.rovViewInfo}'
*
* - TREE
* The view init function is passed no arguments and is expected
* to return a new initialized JavaScript hash table of hash
* tables or `null` in the event that there is nothing to display.
*
* This view type provides a simple two-level tree of name-value
* pairs.
* @p
*/
metaonly enum ViewType {
INSTANCE,
MODULE,
INSTANCE_DATA,
MODULE_DATA,
RAW,
TREE_TABLE,
TREE
}
/*!
* ======== View ========
* ROV View descriptor
*
* @field(type) the view type which control the type of arguments
* passed to the `viewInitFxn`
* @field(viewInitFxn) the name of a function that converts raw target
* data into a human readable "view structure".
* This name is the name of a metaonly function
* defined in the module's `.xs` file.
* @field(structName) the name of the view structure populated by
* the `viewInitFxn`. This name is a name defined
* the module's `.xdc` file.
*/
metaonly struct View {
ViewType type;
String viewInitFxn;
String structName;
}
instance:
/*!
* ======== viewMap ========
* Specifies all of the ROV views for the module
*
* Maps module-specific view names to an appropriate View descriptor.
*/
metaonly config View viewMap[string];
/*!
* ======== showRawTab ========
* Control whether or not the "raw view" is available
*/
metaonly config Bool showRawTab = true;
}