/// <summary> /// Returns a folder object for the specified node. /// </summary> public ArchiveFolderState GetFolderState(ISystemContext context, string rootId) { var path = new StringBuilder(); path.Append(_configuration.ArchiveRoot); path.Append('/'); path.Append(rootId); var folder = new ArchiveFolder(rootId, new DirectoryInfo(path.ToString())); return(new ArchiveFolderState(context, folder, _namespaceIndex)); }
#pragma warning disable RECS0154 // Parameter is never used /// <summary> /// Creates a new instance of a folder. /// </summary> public ArchiveFolderState(ISystemContext context, ArchiveFolder folder, ushort namespaceIndex) #pragma warning restore RECS0154 // Parameter is never used : base(null) { ArchiveFolder = folder; TypeDefinitionId = ObjectTypeIds.FolderType; SymbolicName = folder.Name; NodeId = ConstructId(folder.UniquePath, namespaceIndex); BrowseName = new QualifiedName(folder.Name, namespaceIndex); DisplayName = new LocalizedText(BrowseName.Name); Description = null; WriteMask = 0; UserWriteMask = 0; EventNotifier = EventNotifiers.None; }