newPackage ( PackageName, ... )
The dictionaries for the symbols in the packages loaded by the user are moved out of the way to avoid conflicts, so just the standard pre-loaded packages are visible to the source code of the package. In addition, the package SimpleDoc is made available. If functions from additional packages are needed by the code in the new package, then needsPackage can be used (after the use of newPackage) to provide them. If functions from additional packages are needed by the user who will load the new package, then needsPackage can be used (before the use of newPackage) to provide them.
|
|
The options can be recovered with options as follows.
|
|
Here is a template for a typical newPackage entry in a package.
|
The object newPackage is a method function with a single argument.
The source of this document is in Macaulay2Doc/functions/package-doc.m2:688:0.