33 references to EntryType
System.Formats.Tar (33)
System\Formats\Tar\GnuTarEntry.cs (1)
119internal 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)
60TarEntryType compatibleEntryType = TarHelpers.GetCorrectTypeFlagForFormat(format, other.EntryType); 113/// When the <see cref="EntryType"/> indicates an entry that can contain data, this property returns the length in bytes of such data. 119/// 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. 203if (EntryType is TarEntryType.SymbolicLink or TarEntryType.HardLink or TarEntryType.GlobalExtendedAttributes) 205throw new InvalidOperationException(SR.Format(SR.TarEntryTypeNotSupportedForExtracting, EntryType)); 237if (EntryType is TarEntryType.SymbolicLink or TarEntryType.HardLink or TarEntryType.GlobalExtendedAttributes) 239return Task.FromException(new InvalidOperationException(SR.Format(SR.TarEntryTypeNotSupportedForExtracting, EntryType))); 245/// The data section of this entry. If the <see cref="EntryType"/> does not support containing data, then returns <see langword="null"/>. 248/// <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> 250/// <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> 260throw new InvalidOperationException(SR.Format(SR.TarEntryDoesNotSupportDataStream, Name, EntryType)); 307if (EntryType == TarEntryType.Directory) 330if (EntryType == TarEntryType.Directory) 360if (EntryType is TarEntryType.SymbolicLink) 375else if (EntryType is TarEntryType.HardLink) 410if (EntryType is TarEntryType.RegularFile or TarEntryType.V7RegularFile or TarEntryType.ContiguousFile) 429if (EntryType is TarEntryType.RegularFile or TarEntryType.V7RegularFile or TarEntryType.ContiguousFile) 442Debug.Assert(EntryType is not (TarEntryType.RegularFile or TarEntryType.V7RegularFile or TarEntryType.ContiguousFile)); 444switch (EntryType) 490Debug.Fail($"Metadata entry type should not be visible: '{EntryType}'"); 498throw 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;