Class MachinesLibraryHelper
Inheritance
MachinesLibraryHelper
Assembly: CAMIPC.DotnetHelper.dll
Syntax
public static class MachinesLibraryHelper
Methods
AddScanFolder(ComWrapper<ICamIpcMachinesLibrary>, string)
Add a user folder to scan for machine schemas (scanned immediately, persists across restarts)
Declaration
public static void AddScanFolder(this ComWrapper<ICamIpcMachinesLibrary> libCom, string path)
Parameters
CurrentMachine(ComWrapper<ICamIpcMachinesLibrary>)
Current project machine (read-only)
Declaration
public static ComWrapper<ICamIpcMachineInfo> CurrentMachine(this ComWrapper<ICamIpcMachinesLibrary> libCom)
Parameters
Returns
EnumerateMachines(ComWrapper<ICamIpcMachinesLibrary>)
Enumerate all machines currently known to the library (indexed scan folders,
registered files and machines of recently opened projects)
Declaration
public static IEnumerable<ComWrapper<ICamIpcMachineInfo>> EnumerateMachines(this ComWrapper<ICamIpcMachinesLibrary> libCom)
Parameters
Returns
FindMachine(ComWrapper<ICamIpcMachinesLibrary>, Guid, string, string)
Try to find best matching machine by guid, optional filePath and typeName
Declaration
public static ComWrapper<ICamIpcMachineInfo> FindMachine(this ComWrapper<ICamIpcMachinesLibrary> libCom, Guid guid, string filePath, string typeName)
Parameters
Returns
LoadMachineFromFile(ComWrapper<ICamIpcMachinesLibrary>, string, string)
Load machine info directly from a schema file, bypassing the machines search tree.
The file is read even when it is not registered in any scan folder and even when it
has no MachineRegistrator block (MachineMaker/DMC export). typeName selects the root
machine type; "" picks the first machine type in the file.
Declaration
public static ComWrapper<ICamIpcMachineInfo> LoadMachineFromFile(this ComWrapper<ICamIpcMachinesLibrary> libCom, string schemaFilePath, string typeName)
Parameters
Returns
RemoveScanFolder(ComWrapper<ICamIpcMachinesLibrary>, string)
Remove a previously added user scan folder
Declaration
public static void RemoveScanFolder(this ComWrapper<ICamIpcMachinesLibrary> libCom, string path)
Parameters
Rescan(ComWrapper<ICamIpcMachinesLibrary>)
Re-index all scan folders from the file system without restarting ENCY
Declaration
public static void Rescan(this ComWrapper<ICamIpcMachinesLibrary> libCom)
Parameters
ScanFolders(ComWrapper<ICamIpcMachinesLibrary>)
Declaration
public static ComWrapper<IListString> ScanFolders(this ComWrapper<ICamIpcMachinesLibrary> libCom)
Parameters
Returns