Class Group
For example, if user has used -group option as -group "Core Packages" "java.*" -group "CORBA Packages" "org.omg.*", then the packages specified on the command line will be grouped according to their names starting with either "java." or "org.omg.". All the other packages which do not fall in the user given groups, are grouped in default group, named as either "Other Packages" or "Packages" depending upon if "-group" option used or not at all used respectively.
Also the packages are grouped according to the longest possible match of their names with the grouping information provided. For example, if there are two groups, like -group "Lang" "java.lang" and -group "Core" "java.*", will put the package java.lang in the group "Lang" and not in group "Core".
This is NOT part of any supported API. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class
Deprecated.Since we need to sort the keys in the reverse order(longest key first), the compare method in the implementing class is doing the reverse comparison. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Configuration
Deprecated.The global configuration information for this run.Deprecated.List of group names in the same order as given on the command line.Deprecated.Map of non-regular expressions(possible package names) with the corresponding group name.Deprecated.Map of regular expressions with the corresponding group name.Deprecated.List of regular expressions sorted according to the length. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
checkPackageGroups
(String groupname, String pkgNameFormList) Deprecated.Depending upon the format of the package name provided in the "-group" option, generate two separate maps.(package private) boolean
foundGroupFormat
(Map<String, ?> map, String pkgFormat) Deprecated.Search if the given map has given the package format.Deprecated.Return the list of groups, in the same order as specified on the command line.(package private) List<PackageDoc>
getPkgList
(Map<String, List<PackageDoc>> map, String groupname) Deprecated.For the given group name, return the package list, on which it is mapped.groupPackages
(Set<PackageDoc> packages) Deprecated.Group the packages according the grouping information provided on the command line.(package private) String
regExpGroupName
(String pkgName) Deprecated.Search for package name in the sorted regular expression list, if found return the group name.
-
Field Details
-
regExpGroupMap
Deprecated.Map of regular expressions with the corresponding group name. -
sortedRegExpList
Deprecated.List of regular expressions sorted according to the length. Regular expression with longest length will be first in the sorted order. -
groupList
Deprecated.List of group names in the same order as given on the command line. -
pkgNameGroupMap
Deprecated.Map of non-regular expressions(possible package names) with the corresponding group name. -
configuration
Deprecated.The global configuration information for this run.
-
-
Constructor Details
-
Group
Deprecated.
-
-
Method Details
-
checkPackageGroups
Deprecated.Depending upon the format of the package name provided in the "-group" option, generate two separate maps. There will be a map for mapping regular expression(only meta character allowed is '*' and that is at the end of the regular expression) on to the group name. And another map for mapping (possible) package names(if the name format doesen't contain meta character '*', then it is assumed to be a package name) on to the group name. This will also sort all the regular expressions found in the reverse order of their lengths, i.e. longest regular expression will be first in the sorted list.- Parameters:
groupname
- The name of the group from -group option.pkgNameFormList
- List of the package name formats.
-
foundGroupFormat
Deprecated.Search if the given map has given the package format.- Parameters:
map
- Map to be searched.pkgFormat
- The pacakge format to search.- Returns:
- true if package name format found in the map, else false.
-
groupPackages
Deprecated.Group the packages according the grouping information provided on the command line. Given a list of packages, search each package name in regular expression map as well as package name map to get the corresponding group name. Create another map with mapping of group name to the package list, which will fall under the specified group. If any package doesen't belong to any specified group on the comamnd line, then a new group named "Other Packages" will be created for it. If there are no groups found, in other words if "-group" option is not at all used, then all the packages will be grouped under group "Packages".- Parameters:
packages
- Packages specified on the command line.
-
regExpGroupName
Deprecated.Search for package name in the sorted regular expression list, if found return the group name. If not, return null.- Parameters:
pkgName
- Name of package to be found in the regular expression list.
-
getPkgList
Deprecated.For the given group name, return the package list, on which it is mapped. Create a new list, if not found.- Parameters:
map
- Map to be searched for gorup name.groupname
- Group name to search.
-
getGroupList
Deprecated.Return the list of groups, in the same order as specified on the command line.
-