2

我正在尝试确定基础框架程序集中的哪些类型或方法被应用程序系统中的其他程序集使用。我似乎找不到一个直截了当的查询来做到这一点。

我要做的是首先确定哪些程序集直接使用框架程序集,然后在第二个查询中手动列出它们

SELECT TYPES FROM ASSEMBLIES "IBM.Data.DB2"
WHERE IsDirectlyUsedBy "ASSEMBLY:FirstDirectUsedByAssebmly"
OR IsDirectlyUsedBy "ASSEMBLY:SecondDirectUsedByAssebmly"
OR IsDirectlyUsedBy "ASSEMBLY:ThirdDirectUsedByAssebmly"
OR IsDirectlyUsedBy "ASSEMBLY:FourthDirectUsedByAssebmly"

有没有更好/更快的方法来查询这个?

此外,查询结果仅关注匹配的类型。导出的依赖关系图或矩阵仅显示这些的详细信息。我不知道如何呈现一个显示这些类型或方法的图表以及显示来自其他使用它们的程序集的依赖类型/方法?

更新

我不能使用类似的查询

SELECT METHODS/TYPES WHERE IsPublic AND !CouldBeInternal

因为结果返回在 IBM.Data.DB2 程序集中使用混淆类型的非常奇怪的结果。

SELECT TYPES
FROM ASSEMBLIES "IBM.Data.DB2"
WHERE IsPublic AND !CouldBeInternal


48 items 

--------------------------------------------------+--------------+
types                                             |# IL instructi|
                                                  |ons           |
--------------------------------------------------+--------------+
IBM.Data.DB2.ae+m                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+x                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+f                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+ac                                |0             |
                                                  |              |
IBM.Data.DB2.ae+aa                                |0             |
                                                  |              |
IBM.Data.DB2.ae+u                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+z                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+e                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+b                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+g                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+ab                                |0             |
                                                  |              |
IBM.Data.DB2.ae+h                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+r                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+p                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+ad                                |0             |
                                                  |              |
IBM.Data.DB2.ae+i                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+j                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+t                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+af                                |0             |
                                                  |              |
IBM.Data.DB2.ae+k                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+l                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+y                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+a                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+q                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+n                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+d                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+c                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+ae                                |0             |
                                                  |              |
IBM.Data.DB2.ae+o                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+w                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+s                                 |0             |
                                                  |              |
IBM.Data.DB2.ae+v                                 |0             |
                                                  |              |
IBM.Data.DB2.DB2Command                           |2 527         |
                                                  |              |
IBM.Data.DB2.DB2Connection                        |3 246         |
                                                  |              |
IBM.Data.DB2.DB2DataAdapter                       |520           |
                                                  |              |
IBM.Data.DB2.DB2DataReader                        |4 220         |
                                                  |              |
IBM.Data.DB2.DB2_UDF_PLATFORM                     |0             |
                                                  |              |
IBM.Data.DB2.DB2Enumerator+DB2EnumInstance        |19            |
                                                  |              |
IBM.Data.DB2.DB2Enumerator+DB2EnumDatabase        |15            |
                                                  |              |
IBM.Data.DB2.DB2Error                             |98            |
                                                  |              |
IBM.Data.DB2.DB2ErrorCollection                   |55            |
                                                  |              |
IBM.Data.DB2.DB2Exception                         |185           |
                                                  |              |
IBM.Data.DB2.DB2Parameter                         |1 853         |
                                                  |              |
IBM.Data.DB2.DB2ParameterCollection               |1 383         |
                                                  |              |
IBM.Data.DB2.DB2RowUpdatedEventHandler            |0             |
                                                  |              |
IBM.Data.DB2.DB2RowUpdatedEventArgs               |14            |
                                                  |              |
IBM.Data.DB2.DB2Type                              |0             |
                                                  |              |
IBM.Data.DB2.DB2XmlReader                         |500           |
                                                  |              |
--------------------------------------------------+--------------+
Sum:                                              |14 635        |
                                                  |              |
Average:                                          |304.9         |
                                                  |              |
Minimum:                                          |0             |
                                                  |              |
Maximum:                                          |4 220         |
                                                  |              |
Standard deviation:                               |868.22        |
                                                  |              |
Variance:                                         |753 808       |
                                                  |              |
--------------------------------------------------+--------------+

我们的代码不直接使用这些类型和枚举。

4

1 回答 1

0

此查询返回方法(分别是类型),它们是公共的,不能是内部的。因此,它返回确实在其声明程序集之外使用的方法/类型。

SELECT METHODS/TYPES WHERE IsPublic AND !CouldBeInternal
于 2010-04-05T19:55:45.523 回答