public File(Context context, CatalogNodeId nodeId, CommonCatalogFileInfo catalogInfo) { Context = context; NodeId = nodeId; _catalogInfo = catalogInfo; //_hasCompressionAttribute = // Context.Attributes.Find(new AttributeKey(NodeId, CompressionAttributeName)) != null; _hasCompressionAttribute = false; }
private static CommonCatalogFileInfo ParseDirEntryData(byte[] dirEntryData) { CatalogRecordType type = (CatalogRecordType)EndianUtilities.ToInt16BigEndian(dirEntryData, 0); CommonCatalogFileInfo result = null; switch (type) { case CatalogRecordType.FolderRecord: result = new CatalogDirInfo(); break; case CatalogRecordType.FileRecord: result = new CatalogFileInfo(); break; default: throw new NotImplementedException("Unknown catalog record type: " + type); } result.ReadFrom(dirEntryData, 0); return(result); }
public Directory(Context context, CatalogNodeId nodeId, CommonCatalogFileInfo fileInfo) : base(context, nodeId, fileInfo) { }
public Symlink(Context context, CatalogNodeId nodeId, CommonCatalogFileInfo catalogInfo) : base(context, nodeId, catalogInfo) { }