import { Diagnostic , DiagnosticWithinFile } from '../common/diagnostic' ; export enum SymbolCategory { Indeterminate , Module , Class , Variable , Constant , Function , Method , TypeVar , TypeAlias } export const enum TypeKnownStatus { Known , PartiallyUnknown , Unknown } export interface SymbolInfo { category : SymbolCategory ; name : string ; fullName : string ; filePath : string ; isExported : boolean ; typeKnownStatus : TypeKnownStatus ; referenceCount : number ; diagnostics : DiagnosticWithinFile [ ] ; } export interface ModuleInfo { name : string ; path : string ; isExported : boolean ; } export type AlternateSymbolNameMap = Map < string , string [ ] > ; export interface PackageTypeReport { packageName : string ; ignoreExternal : boolean ; rootDirectory : string | undefined ; pyTypedPath : string | undefined ; missingFunctionDocStringCount : number ; missingClassDocStringCount : number ; missingDefaultParamCount : number ; alternateSymbolNames : AlternateSymbolNameMap ; modules : Map < string , ModuleInfo > ; generalDiagnostics : Diagnostic [ ] ; symbols : Map < string , SymbolInfo > ; } export function getEmptyReport ( packageName , rootDirectory , ignoreExternal ) { const report = { packageName , ignoreExternal , rootDirectory , pyTypedPath : undefined , missingFunctionDocStringCount : 0 , missingClassDocStringCount : 0 , missingDefaultParamCount : 0 , alternateSymbolNames : new Map < string , string [ ] > ( ) , modules : new Map < string , ModuleInfo > ( ) , generalDiagnostics : [ ] , symbols : new Map < string , SymbolInfo > ( ) , } ; return report ; }