Class UniAll

Summary

The UniAll class holds the entire internal form of a Unicon documentation set.

Superclasses:
Object

Package:
UniDoc
File:
UniAll.icn
Methods:
addFile, addTag, classOnLinkPath, classify, classifyLines, cleanSets, dumpNames, dumpStatistics, fullyResolve, genAllSuperClasses, genDirs, genPackageFiles, getAllClasses, getAllFiles, getAllGlobals, getAllPackages, getAllProcedures, getAllRecords, getGlobal, getName, getParam, getTargetDir, hasSuffix, inherited, locatePack, locateSuperClass, makeNameTab, overrides, processBlank, processClass, processComment, processFile, processGlobal, processImport, processInitially, processKeyword, processLink, processMethod, processPackage, processProcedure, processRecord, setSaveSrc, setSourcePath, setTargetDir

Methods inherited from Object:
Type, className, clone, equals, fieldNames, genMethods, getField, get_class, get_class_name, get_id, hasField, hasMethod, hash_code, instanceOf, invoke, is_instance, setField, to_string

Fields:
badFiles, curClass, curComments, curFile, curPackage, fileHead, files, importSet, linkSet, packages, resolveFlag, saveSrcFlag, sourcePath, targetDir, uniFile

Source code.

Details
Constructor

UniAll()

Methods:

addFile(fName)

Remember fName as a file that has been processed.

This is intended for internal use only!


addTag(obj)

Insert a tag for an entity into the saved source code, if any.


classOnLinkPath(bClass, cName)

Given the name of a class, attempts to find an existing html page for that class, by searching the linkPath.

This method is currently broken!


classify(f)

Classify the type of an input line based on tokens produced during parsing of the file f.

This is intended for internal use only!


classifyLines(f)

Parse a file, building an internal representation.

This is intended for internal use only!


cleanSets()

Remove any files that have already been processed from the import and link sets.

This is intended for internal use only!


dumpNames(prefix, data)

Outputs a list of entity names.

This is intended for internal use only!


dumpStatistics(detail)

Output some simple statistics on the amount of processing that has been performed. Give more detail if detail is non-null.


fullyResolve(flag)

Set the level of entity resolution. If flag is &null, then references to entities not contained in files passed to processFile() are not expanded. If flag is non-null, then the current sourcePath is used to locate these entities.


genAllSuperClasses(aClass, scSet)

Generate (in order) all the superclasses of a class


genDirs(s)

Given a string of comma-separated directories, generates the individual directories from that string. Guarantees that each directory produced ends with "/".

This is intended for internal use only!


genPackageFiles(pName)

Given the name of a package, generates all the files associated with that package. (Uses parser package from Robert Parlett and requires that the package has been compiled and exists on IPATH.)


getAllClasses()

Produce a list of all classes.


getAllFiles()

Produce a list of all files that have been processed, whether by explicit reference processFile() or during entity resolution.


getAllGlobals()

Produce a list of all globals.


getAllPackages()

Produce a list of all packages.


getAllProcedures()

Produce a list of all procedures.


getAllRecords()

Produce a list of all records.


getGlobal(f, token, parent, comments)

Get a global.


getName(token)

There are places in a Unicon program where an entity may be represented by either a name or a string. This guarentees that it's represented by a name.

This is intended for internal use only!


getParam(f, token, category, parent)

Get a parameter.


getTargetDir()

Produce the target directory.


hasSuffix(s, suffix)

Parameters:
s
-- string to test
suffix
-- suffix to test against
Returns:
s if it ends in suffix

Returns its argument if that argument ends in the specified suffix.


inherited(aClass)

Produce a table of all methods that are inherited by a class. Keys are superclasses, entries are UniDoc::Set()s of methods.


locatePack(pName)


locateSuperClass(aClass, scName)

Given a class and the name of a superclass of that class, return that superclass.


makeNameTab(aTab)

Produce a sorted list (by name) of superclasses, given a table whose keys are superclasses.


overrides(aClass, mName)

Given a class and a method name from that class, does this method override any method from a superclass?

Returns the superclass of the overridden method, if any.


processBlank(f)

Process a blank line. Blank lines are only interesting in that they serve to distinguish comment blocks.

This is intended for internal use only!


processClass(f)

Process a class header. If there's an initially clause that will get tacked on later.

This is intended for internal use only!


processComment(f, s)

Process a comment.

This is intended for internal use only!


processFile(fName)

This is the main entry point to the UniAll class. When invoked, the file fName is parsed and added to an internal representation for the Unicon source code being handled by this class instance. May be called repeatedly to process multiple files.

If the argument is a directory, then all files suffixed with ".icn" within that directory are processed.


processGlobal(f)

Process a global statement.

This is intended for internal use only!


processImport(f)

Process an import statement.

This is intended for internal use only!


processInitially(f)

Process an initially clause, treating it as a class constructor.

This is intended for internal use only!


processKeyword(f, word)

Process a keyword. Not all keywords are interesting. Many are simply ignored.

This is intended for internal use only!


processLink(f)

Process a link statement.

This is intended for internal use only!


processMethod(f)

Process a method definition.

This is intended for internal use only!


processPackage(f)

Process a package header. Note that this implies that the current file isn't part of the default package.

This is intended for internal use only!


processProcedure(f)

Process a procedure definition.

This is intended for internal use only!


processRecord(f)

Process a record definition.

This is intended for internal use only!


setSaveSrc(flag)

Decide whether or not to save a copy of source code to link to.


setSourcePath(p)

Set the source path to be used when attempting to resolve unknown entities.


setTargetDir(tDir)

Remember the target directory (needed if we're output source code for later linking.)


Fields:
badFiles

curClass

curComments

curFile

curPackage

fileHead

files

importSet

linkSet

packages

resolveFlag

saveSrcFlag

sourcePath

targetDir

uniFile


This page produced by UniDoc on 2021/04/15 @ 23:59:54.