TPR3 changes to the Find Usages Query
7 March 2006
version 1.5 - revised 31 March 2006
Currently, in the TPR2
release, the Find Usages query is in the Analysis View. It
can also be invoked from the Schema View, a.k.a., Advanced or Column
View. For TPR3, the query will be moved from the Analysis
View to the vicinity of the Java refactoring Usages mode.
The query will only be invocable from the Schema View.
The
rest of this document describes the new or changed features
of
the Find Usages Query.
Description of new Find Usages results window:
The result window is a split pane; on the left side, an explorer, on the right, a graph.
The explorer is patterned after the Java refactoring Find Usages window. The containing Top Component is "XML Schema Usages". Each tab is "Find Schema Usages".
Logical view:
Physical view:
The graph is similar to the one in TPR2, with the exception of the two new features below (1 & 2), and the two new features that were implemented post TPR2 (3 & 4). The version of the graph that is in the daily build is the final TPR3 graph sans #1 and #2 below.
New features on the schema component nodes in the explorer and the graph:
The nodes now have an icon, representing the component
type, and the component name. The component type in text
format is in a tooltip, containing the following
information:
Description of the Find Usages Navigator
The navigator will be linked to any Schema Component node in the explorer or graph. It will show the path from the schema root to the target schema component. For explorer node #6 above, for example, the navigator might look like this:
These nodes are all named schema components. The only unnamed components in the navigator, graph, or explorer are Local Elements that reference a Global Element. All nodes will have the "Go to Source" and "Find in Schema View" actions. "Find in Schema View" is the default action. Simple selection does not result in any interaction with the other Top Components.
Note that the Java refactoring Find Usages window is not linked to the navigator.
Screenshots

Java Find Usages

[Click image for a larger view]
IDE after running Find Usages query.
The user has double-clicked the "Check" node in the graph, which highlights the "Check" schema component nodes (and ancestors) in the Schema View.
Description of new Find Usages results window:
The result window is a split pane; on the left side, an explorer, on the right, a graph.
The explorer is patterned after the Java refactoring Find Usages window. The containing Top Component is "XML Schema Usages". Each tab is "Find Schema Usages".
Logical view:
|
Physical view:
|
The graph is similar to the one in TPR2, with the exception of the two new features below (1 & 2), and the two new features that were implemented post TPR2 (3 & 4). The version of the graph that is in the daily build is the final TPR3 graph sans #1 and #2 below.
New features on the schema component nodes in the explorer and the graph:
- Show the property sheet for a selected node.
Selection is performed by single mouse click.
- Enable navigation to Schema View with "Find in Schema View" action.
Use the Schema View search
facility. Put text in the search textfield "Find ComponentX"
or "Find ComponentX ref". Enable the search dismiss button.
Highlight the search target nodes and parents. This text is used to
distinguish this type of search from one that the user invokes by
typing in a name. It
would be misleading to insert only the name of the component
into the textfield, because a search on component name could
result in different nodes being highlighted. When "Find in
Schema View" in invoked from the Find Usages window, the search
facility will find a specific schema component, not all components that
have the same name.
New features of the graph since TPR2 that are in the daily build. - The query now scans all the schema files in the project. For each file in which usages are found, a file node is shown in the graph. Initially, the file nodes are "collapsed", that is, the usages are not visible, unless there is only one file containing usages. If there is only one file containing usages, the file node is expanded by default, that is, the usage nodes are visible. The screenshot below shows that two files contain usages. The user has expanded both file nodes via a popup menuitem, "Expand" or "Collapse", depending on the current state of the file node.
The query node:
"Query Component"
component type, e.g. "Global Element"
The file nodes:
"Schema file containing usages of The-Name-of-the-Query-Component"
full path to file, e.g. on Windows, "C:\REMC\src\xml\REMCLibrary.xsd"
The usage nodes:
"Uses The-Name-of-the-Query-Component"
component type, e.g., "Local Element"
Other nodes in the path from the usage node to its penultimate-level ancestor, which is a global component under the schema root:
component type, e.g., "Global Complex Type"
"Query Component"
component type, e.g. "Global Element"
The file nodes:
"Schema file containing usages of The-Name-of-the-Query-Component"
full path to file, e.g. on Windows, "C:\REMC\src\xml\REMCLibrary.xsd"
The usage nodes:
"Uses The-Name-of-the-Query-Component"
component type, e.g., "Local Element"
Other nodes in the path from the usage node to its penultimate-level ancestor, which is a global component under the schema root:
component type, e.g., "Global Complex Type"
Description of the Find Usages Navigator
The navigator will be linked to any Schema Component node in the explorer or graph. It will show the path from the schema root to the target schema component. For explorer node #6 above, for example, the navigator might look like this:
|
These nodes are all named schema components. The only unnamed components in the navigator, graph, or explorer are Local Elements that reference a Global Element. All nodes will have the "Go to Source" and "Find in Schema View" actions. "Find in Schema View" is the default action. Simple selection does not result in any interaction with the other Top Components.
Note that the Java refactoring Find Usages window is not linked to the navigator.
Screenshots
Java Find Usages
[Click image for a larger view]
IDE after running Find Usages query.
The user has double-clicked the "Check" node in the graph, which highlights the "Check" schema component nodes (and ancestors) in the Schema View.