org.acm.seguin.summary
Class PackageSummary

java.lang.Object
  extended by org.acm.seguin.summary.Summary
      extended by org.acm.seguin.summary.PackageSummary
All Implemented Interfaces:
java.io.Serializable, net.sourceforge.jrefactory.ast.ModifierHolder

public class PackageSummary
extends Summary

Creates a summary of a package

Since:
2.6.31
Author:
Chris Seguin
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.acm.seguin.summary.Summary
modifiers
 
Fields inherited from interface net.sourceforge.jrefactory.ast.ModifierHolder
ABSTRACT, EXPLICIT, FINAL, INTERFACE, names, NATIVE, PRIVATE, PROTECTED, PUBLIC, STATIC, STRICTFP, SYNCHRONIZED, TRANSIENT, VOLATILE
 
Constructor Summary
protected PackageSummary(java.lang.String packageName)
          Constructor for the package summary
 
Method Summary
 java.lang.Object accept(SummaryVisitor visitor, java.lang.Object data)
          Provide method to visit a node
protected  void addFileSummary(FileSummary fileSummary)
          Add a file summary
 void deleteFileSummary(FileSummary fileSummary)
          Delete a file summary
static java.util.Iterator getAllPackages()
          Get a package summary object
 java.io.File getDirectory()
          Get the directory associated with this package
 java.util.Iterator getFileSummaries()
          Return an iterator of the files
 FileSummary getFileSummary(java.lang.String name)
          Get a file summary by file name
 java.lang.String getName()
          Get the name of the package
static PackageSummary getPackageSummary(java.lang.String name)
          Get a package summary object
 boolean isTopLevel()
          Determines if it is the top level package
static void loadAll(java.io.ObjectInputStream in)
          Loads all the packages from the object input stream
static void removeAll()
          Removes all the packages to allow them to be reloaded
static void saveAll(java.io.ObjectOutputStream out)
          Saves all the packages to an object output stream
 java.lang.String toString()
          Converts this object to a string
 
Methods inherited from class org.acm.seguin.summary.Summary
addModifier, copyModifiers, getDeclarationLine, getEndLine, getModifiers, getModifiersString, getParent, getStartLine, isAbstract, isExplicit, isFinal, isInterface, isNative, isPackage, isPrivate, isProtected, isPublic, isStatic, isStrictFP, isSynchronized, isTransient, isVolatile, setAbstract, setAbstract, setCode, setEndLine, setFinal, setModifiers, setPrivate, setPrivate, setProtected, setProtected, setPublic, setPublic, setStartLine, setStatic, setStatic, setStrict, setSynchronized, setSynchronized, toStandardOrderString, toStringAlphabetical
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PackageSummary

protected PackageSummary(java.lang.String packageName)
Constructor for the package summary

Parameters:
packageName - the name of the package
Since:
2.6.31
Method Detail

getAllPackages

public static java.util.Iterator getAllPackages()
Get a package summary object

Returns:
all package summaries
Since:
2.6.31

getDirectory

public java.io.File getDirectory()
Get the directory associated with this package

Returns:
a file or null if none
Since:
2.6.31

getFileSummaries

public java.util.Iterator getFileSummaries()
Return an iterator of the files

Returns:
the iterator
Since:
2.6.31

getFileSummary

public FileSummary getFileSummary(java.lang.String name)
Get a file summary by file name

Parameters:
name - the name of the file summary
Returns:
the file summary if it is found and null otherwise
Since:
2.6.31

getName

public java.lang.String getName()
Get the name of the package

Specified by:
getName in class Summary
Returns:
the package name
Since:
2.6.31

getPackageSummary

public static PackageSummary getPackageSummary(java.lang.String name)
Get a package summary object

Parameters:
name - the name of the package that we are creating
Returns:
The PackageSummary value
Since:
2.6.31

isTopLevel

public boolean isTopLevel()
Determines if it is the top level package

Returns:
true if it is the top level
Since:
2.6.31

accept

public java.lang.Object accept(SummaryVisitor visitor,
                               java.lang.Object data)
Provide method to visit a node

Overrides:
accept in class Summary
Parameters:
visitor - the visitor
data - the data for the visit
Returns:
some new data
Since:
2.6.31

addFileSummary

protected void addFileSummary(FileSummary fileSummary)
Add a file summary

Parameters:
fileSummary - the file summary that we are adding
Since:
2.6.31

deleteFileSummary

public void deleteFileSummary(FileSummary fileSummary)
Delete a file summary

Parameters:
fileSummary - the file summary object that we are removing
Since:
2.6.31

loadAll

public static void loadAll(java.io.ObjectInputStream in)
                    throws java.io.IOException
Loads all the packages from the object input stream

Parameters:
in - Description of Parameter
Throws:
java.io.IOException - Description of Exception
Since:
2.6.31

removeAll

public static void removeAll()
Removes all the packages to allow them to be reloaded

Since:
2.6.31

saveAll

public static void saveAll(java.io.ObjectOutputStream out)
                    throws java.io.IOException
Saves all the packages to an object output stream

Parameters:
out - Description of Parameter
Throws:
java.io.IOException - Description of Exception
Since:
2.6.31

toString

public java.lang.String toString()
Converts this object to a string

Overrides:
toString in class java.lang.Object
Returns:
the string
Since:
2.6.31