33 references to EntryType
System.Formats.Tar (33)
System\Formats\Tar\GnuTarEntry.cs (1)
121internal override bool IsDataStreamSetterSupported() => EntryType is TarEntryType.RegularFile;
System\Formats\Tar\PaxTarEntry.cs (1)
154internal override bool IsDataStreamSetterSupported() => EntryType == TarEntryType.RegularFile;
System\Formats\Tar\TarEntry.cs (21)
57TarEntryType compatibleEntryType = TarHelpers.GetCorrectTypeFlagForFormat(format, other.EntryType); 107/// When the <see cref="EntryType"/> indicates an entry that can contain data, this property returns the length in bytes of such data. 113/// When the <see cref="EntryType"/> indicates a <see cref="TarEntryType.SymbolicLink"/> or a <see cref="TarEntryType.HardLink"/>, this property returns the link target path of such link. 197if (EntryType is TarEntryType.SymbolicLink or TarEntryType.HardLink or TarEntryType.GlobalExtendedAttributes) 199throw new InvalidOperationException(SR.Format(SR.TarEntryTypeNotSupportedForExtracting, EntryType)); 231if (EntryType is TarEntryType.SymbolicLink or TarEntryType.HardLink or TarEntryType.GlobalExtendedAttributes) 233return Task.FromException(new InvalidOperationException(SR.Format(SR.TarEntryTypeNotSupportedForExtracting, EntryType))); 239/// The data section of this entry. If the <see cref="EntryType"/> does not support containing data, then returns <see langword="null"/>. 242/// <para>Sets a new stream that represents the data section, if it makes sense for the <see cref="EntryType"/> to contain data; if a stream already existed, the old stream gets disposed before substituting it with the new stream. Setting a <see langword="null"/> stream is allowed.</para></value> 244/// <exception cref="InvalidOperationException">Setting a data section is not supported because the <see cref="EntryType"/> is not <see cref="TarEntryType.RegularFile"/> (or <see cref="TarEntryType.V7RegularFile"/> for an archive of <see cref="TarEntryFormat.V7"/> format).</exception> 254throw new InvalidOperationException(SR.Format(SR.TarEntryDoesNotSupportDataStream, Name, EntryType)); 292if (EntryType == TarEntryType.Directory) 315if (EntryType == TarEntryType.Directory) 345if (EntryType is TarEntryType.SymbolicLink) 360else if (EntryType is TarEntryType.HardLink) 395if (EntryType is TarEntryType.RegularFile or TarEntryType.V7RegularFile or TarEntryType.ContiguousFile) 414if (EntryType is TarEntryType.RegularFile or TarEntryType.V7RegularFile or TarEntryType.ContiguousFile) 427Debug.Assert(EntryType is not TarEntryType.RegularFile or TarEntryType.V7RegularFile or TarEntryType.ContiguousFile); 429switch (EntryType) 475Debug.Assert(false, $"Metadata entry type should not be visible: '{EntryType}'"); 483throw new InvalidOperationException(SR.Format(SR.TarEntryTypeNotSupportedForExtracting, EntryType));
System\Formats\Tar\TarEntry.Unix.cs (4)
16Debug.Assert(EntryType is TarEntryType.BlockDevice); 23Debug.Assert(EntryType is TarEntryType.CharacterDevice); 30Debug.Assert(EntryType is TarEntryType.Fifo); 37Debug.Assert(EntryType is TarEntryType.HardLink);
System\Formats\Tar\TarFile.cs (2)
465if (entry.EntryType is not TarEntryType.GlobalExtendedAttributes) 510if (entry.EntryType is not TarEntryType.GlobalExtendedAttributes)
System\Formats\Tar\TarWriter.Unix.cs (2)
92if (entry.EntryType == TarEntryType.SymbolicLink) 97if (entry.EntryType is TarEntryType.RegularFile or TarEntryType.V7RegularFile)
System\Formats\Tar\UstarTarEntry.cs (1)
58internal override bool IsDataStreamSetterSupported() => EntryType == TarEntryType.RegularFile;
System\Formats\Tar\V7TarEntry.cs (1)
44internal override bool IsDataStreamSetterSupported() => EntryType == TarEntryType.V7RegularFile;