org.umlgraph.doclet
Class Options

Show UML class diagram
java.lang.Object
  extended by org.umlgraph.doclet.Options
All Implemented Interfaces:
Cloneable, OptionProvider

public class Options
extends Object
implements Cloneable, OptionProvider

Represent the program options


Field Summary
private static Pattern allPattern
           
(package private)  Map<Pattern,String> apiDocMap
           
(package private)  String apiDocRoot
           
(package private)  String bgColor
           
(package private)  boolean collapsibleDiagrams
           
private  Vector<Pattern> collPackages
           
(package private)  boolean compact
           
(package private)  RelationPattern contextRelationPattern
           
protected static String DEFAULT_EXTERNAL_APIDOC
           
private static String defaultFont
           
private static String defaultItalicFont
           
(package private)  String dotExecutable
           
(package private)  String edgeColor
           
(package private)  String edgeFontColor
           
(package private)  String edgeFontName
           
(package private)  double edgeFontSize
           
(package private)  boolean findViews
           
(package private)  String guilClose
          Guillemot right (close)
(package private)  String guilOpen
          Guillemot left (open)
(package private)  Vector<Pattern> hidePatterns
           
(package private)  boolean horizontal
           
(package private)  boolean inferDependencies
           
(package private)  Visibility inferDependencyVisibility
           
(package private)  boolean inferDepInPackage
           
(package private)  boolean inferRelationships
           
(package private)  RelationType inferRelationshipType
           
(package private)  String nodeFillColor
           
(package private)  String nodeFontAbstractName
           
(package private)  String nodeFontClassAbstractName
           
(package private)  String nodeFontClassName
           
(package private)  double nodeFontClassSize
           
(package private)  String nodeFontColor
           
(package private)  String nodeFontName
           
(package private)  String nodeFontPackageName
           
(package private)  double nodeFontPackageSize
           
(package private)  double nodeFontSize
           
(package private)  String nodeFontTagName
           
(package private)  double nodeFontTagSize
           
(package private)  double nodeSep
           
 String outputDirectory
           
(package private)  String outputEncoding
           
 String outputFileName
           
(package private)  boolean postfixPackage
           
(package private)  double rankSep
           
(package private)  boolean relativeLinksForSourcePackages
           
(package private)  Shape shape
           
(package private)  boolean showAttributes
           
(package private)  boolean showComment
           
(package private)  boolean showConstructors
           
(package private)  boolean showEnumConstants
           
(package private)  boolean showEnumerations
           
(package private)  boolean showOperations
           
(package private)  boolean showQualified
           
(package private)  boolean showType
           
(package private)  boolean showVisibility
           
(package private)  boolean strictMatching
           
(package private)  boolean useGuillemot
           
(package private)  boolean useImports
           
(package private)  String viewName
           
 
Constructor Summary
Options()
           
 
Method Summary
private  void addApiDocRoots(String packageListUrl)
          Adds api doc roots from a link.
private  void addApiDocRootsOffline(String docUrl, String packageListUrl)
          Adds api doc roots from an offline link.
 Object clone()
           
private  String fixApiDocRoot(String str)
          Trim and append a file separator to the string
 String getApiDocRoot(String className)
          Returns the appropriate URL "root" for an external class name.
 String getDisplayName()
          Returns user displayable name for this option provider.
 Options getGlobalOptions()
          Returns the global options (the class independent definition)
 Options getOptionsFor(ClassDoc cd)
          Returns the options for the specified class.
 Options getOptionsFor(String name)
          Returns the options for the specified class.
 boolean matchesCollPackageExpression(String s)
          Check if the supplied string matches an entity specified with the -hide parameter.
 boolean matchesHideExpression(String s)
          Check if the supplied string matches an entity specified with the -hide parameter.
static int optionLength(String option)
          Return the number of arguments associated with the specified option.
 void overrideForClass(Options opt, ClassDoc cd)
          Gets a base Options and applies the overrides for the specified class
 void overrideForClass(Options opt, String className)
          Gets a base Options and applies the overrides for the specified class
 void setAll()
          Most complete output
(package private)  void setApiDocMapFile(String apiDocMapFileName)
          Loads the property file referred by apiDocMapFileName and fills the apiDocMap accordingly
(package private)  void setOption(String[] opt)
          Set the options based on a single option and its arguments
 void setOptions(ClassDoc p)
          Set the options based on the tag elements of the ClassDoc parameter
 void setOptions(String[][] options)
          Set the options based on the command line parameters
 String toString()
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

defaultFont

private static String defaultFont

defaultItalicFont

private static String defaultItalicFont

allPattern

private static final Pattern allPattern

DEFAULT_EXTERNAL_APIDOC

protected static final String DEFAULT_EXTERNAL_APIDOC
See Also:
Constant Field Values

hidePatterns

Vector<Pattern> hidePatterns

showQualified

boolean showQualified

showAttributes

boolean showAttributes

showEnumerations

boolean showEnumerations

showEnumConstants

boolean showEnumConstants

showOperations

boolean showOperations

showConstructors

boolean showConstructors

showVisibility

boolean showVisibility

horizontal

boolean horizontal

showType

boolean showType

showComment

boolean showComment

edgeFontName

String edgeFontName

edgeFontColor

String edgeFontColor

edgeColor

String edgeColor

edgeFontSize

double edgeFontSize

nodeFontName

String nodeFontName

nodeFontAbstractName

String nodeFontAbstractName

nodeFontColor

String nodeFontColor

nodeFontSize

double nodeFontSize

nodeFillColor

String nodeFillColor

nodeFontClassSize

double nodeFontClassSize

nodeFontClassName

String nodeFontClassName

nodeFontClassAbstractName

String nodeFontClassAbstractName

nodeFontTagSize

double nodeFontTagSize

nodeFontTagName

String nodeFontTagName

nodeFontPackageSize

double nodeFontPackageSize

nodeFontPackageName

String nodeFontPackageName

shape

Shape shape

bgColor

String bgColor

outputFileName

public String outputFileName

outputEncoding

String outputEncoding

apiDocMap

Map<Pattern,String> apiDocMap

apiDocRoot

String apiDocRoot

postfixPackage

boolean postfixPackage

useGuillemot

boolean useGuillemot

findViews

boolean findViews

viewName

String viewName

nodeSep

double nodeSep

rankSep

double rankSep

outputDirectory

public String outputDirectory

guilOpen

String guilOpen
Guillemot left (open)


guilClose

String guilClose
Guillemot right (close)


inferRelationships

boolean inferRelationships

inferDependencies

boolean inferDependencies

collapsibleDiagrams

boolean collapsibleDiagrams

contextRelationPattern

RelationPattern contextRelationPattern

useImports

boolean useImports

inferDependencyVisibility

Visibility inferDependencyVisibility

inferDepInPackage

boolean inferDepInPackage

inferRelationshipType

RelationType inferRelationshipType

collPackages

private Vector<Pattern> collPackages

compact

boolean compact

relativeLinksForSourcePackages

boolean relativeLinksForSourcePackages

strictMatching

boolean strictMatching

dotExecutable

String dotExecutable
Constructor Detail

Options

Options()
Method Detail

clone

public Object clone()
Overrides:
clone in class Object

setAll

public void setAll()
Most complete output


optionLength

public static int optionLength(String option)
Return the number of arguments associated with the specified option. The return value includes the actual option. Will return 0 if the option is not supported.


setOption

void setOption(String[] opt)
Set the options based on a single option and its arguments


addApiDocRoots

private void addApiDocRoots(String packageListUrl)
Adds api doc roots from a link. The folder reffered by the link should contain a package-list file that will be parsed in order to add api doc roots to this configuration

Parameters:
packageListUrl -

addApiDocRootsOffline

private void addApiDocRootsOffline(String docUrl,
                                   String packageListUrl)
Adds api doc roots from an offline link. The folder specified by packageListUrl should contain the package-list associed with the docUrl folder.

Parameters:
docUrl - folder containing the javadoc
packageListUrl - folder containing the package-list

setApiDocMapFile

void setApiDocMapFile(String apiDocMapFileName)
Loads the property file referred by apiDocMapFileName and fills the apiDocMap accordingly

Parameters:
apiDocMapFileName -

getApiDocRoot

public String getApiDocRoot(String className)
Returns the appropriate URL "root" for an external class name. It will match the class name against the regular expressions specified in the apiDocMap; if a match is found, the associated URL will be returned. NOTE: The match order of the match attempts is the one specified by the constructor of the api doc root, so it depends on the order of "-link" and "-apiDocMap" parameters.


fixApiDocRoot

private String fixApiDocRoot(String str)
Trim and append a file separator to the string


setOptions

public void setOptions(String[][] options)
Set the options based on the command line parameters


setOptions

public void setOptions(ClassDoc p)
Set the options based on the tag elements of the ClassDoc parameter


matchesHideExpression

public boolean matchesHideExpression(String s)
Check if the supplied string matches an entity specified with the -hide parameter.

Returns:
true if the string matches.

matchesCollPackageExpression

public boolean matchesCollPackageExpression(String s)
Check if the supplied string matches an entity specified with the -hide parameter.

Returns:
true if the string matches.

getOptionsFor

public Options getOptionsFor(ClassDoc cd)
Description copied from interface: OptionProvider
Returns the options for the specified class.

Specified by:
getOptionsFor in interface OptionProvider

getOptionsFor

public Options getOptionsFor(String name)
Description copied from interface: OptionProvider
Returns the options for the specified class.

Specified by:
getOptionsFor in interface OptionProvider

getGlobalOptions

public Options getGlobalOptions()
Description copied from interface: OptionProvider
Returns the global options (the class independent definition)

Specified by:
getGlobalOptions in interface OptionProvider

overrideForClass

public void overrideForClass(Options opt,
                             ClassDoc cd)
Description copied from interface: OptionProvider
Gets a base Options and applies the overrides for the specified class

Specified by:
overrideForClass in interface OptionProvider

overrideForClass

public void overrideForClass(Options opt,
                             String className)
Description copied from interface: OptionProvider
Gets a base Options and applies the overrides for the specified class

Specified by:
overrideForClass in interface OptionProvider

getDisplayName

public String getDisplayName()
Description copied from interface: OptionProvider
Returns user displayable name for this option provider.

Will be used to provide progress feedback on the console

Specified by:
getDisplayName in interface OptionProvider

toString

public String toString()
Overrides:
toString in class Object