Home > Class Reference > ENSLIB namespace > %iKnow.Source.File.Lister
Private  

%iKnow.Source.File.Lister

class %iKnow.Source.File.Lister extends %iKnow.Source.Lister

Lister implementation for scanning a filesystem.

Lister Parameters to be supplied to AddListToBatch and ProcessList calls:

  1. path As %String - the directory where to look for files
  2. extensions As %List - the extensions (without leading dot) to load
  3. recursive As %Boolean - whether or not to recurse into subdirectories
  4. filter As %String - a code fragment that can be called through $xecute to evaluate a filename and directory. For example:
    "(fn,dir) quit '$find(fn,""draft"")"

External ID structure: [GroupName][LocalRef]

Lister alias: "FILE"

Default Processor: %iKnow.Source.File.Processor

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
4

Summary

Properties
Configuration
Methods
%AddToSaveSet %ClassIsLatestVersion %ClassName %ConstructClone
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Extends
%GetParameter %IsA %IsModified %New
%NormalizeObject %ObjectModified %OriginalNamespace %PackageName
%RemoveFromSaveSet %SerializeObject %SetModified %ValidateObject
AddListToBatch BuildExtId BuildExtIdFromName DefaultProcessor
ExpandList FormatParams GetAlias GetExtidPrefix
GetGroupId GetGroupName Init ProcessList
ProcessVirtualList RegisterFixedMetadata SetConfig SetConverter
SetProcessor SplitExtId TestParams

Methods

method ExpandList(listparams As %List) as %Status

Scans through the directory as dictated by the Lister Parameters. No metadata is gathered along the way.

See also ExpandList in %iKnow.Source.Lister.

classmethod FormatParams(listerParams As %List) as %String

Utility method to format the parameter string passed in AddList for display by the %iKnow.Source.Loader.GetCurrentLists() method. Defaults to $lts() but should be overridden to nicen up complex datatypes in the parameter list.

classmethod GetAlias() as %String

Lister alias: "FILE"

method TestParams(listerParams...) as %Status

Tests performed by this Lister:

  1. path: checks whether this is a valid string (no check on whether this is a valid path!)
  2. extensions: no checks
  3. recursive: no checks
  4. filter: if nonempty, checks whether this is a valid expression for $xecute() with two parameters