예제 #1
0
		/// <summary>
		///    Constructs and initializes a new instance of <see
		///    cref="File" /> for a specified path in the local file
		///    system and specified read style.
		/// </summary>
		/// <param name="path">
		///    A <see cref="string" /> object containing the path of the
		///    file to use in the new instance.
		/// </param>
		/// <param name="propertiesStyle">
		///    A <see cref="ReadStyle" /> value specifying at what level
		///    of accuracy to read the media properties, or <see
		///    cref="ReadStyle.None" /> to ignore the properties.
		/// </param>
		/// <exception cref="ArgumentNullException">
		///    <paramref name="path" /> is <see langword="null" />.
		/// </exception>
		public File (string path, ReadStyle propertiesStyle, CUETools.Processor.CUEToolsTagger _tagger)
			: base (path, propertiesStyle)
		{
			tagger = _tagger;
			// Make sure we have a tag.
			switch (tagger)
			{
				case CUETools.Processor.CUEToolsTagger.APEv2:
					GetTag(TagTypes.Ape, true);
					break;
				case CUETools.Processor.CUEToolsTagger.ID3v2:
					GetTag(TagTypes.Id3v2, true);
					break;
			}
		}
예제 #2
0
		/// <summary>
		///    Constructs and initializes a new instance of <see
		///    cref="File" /> for a specified file abstraction with an
		///    average read style.
		/// </summary>
		/// <param name="abstraction">
		///    A <see cref="IFileAbstraction" /> object to use when
		///    reading from and writing to the file.
		/// </param>
		/// <exception cref="ArgumentNullException">
		///    <paramref name="abstraction" /> is <see langword="null"
		///    />.
		/// </exception>
		public File(File.IFileAbstraction abstraction, CUETools.Processor.CUEToolsTagger _tagger)
			: base (abstraction)
		{
			tagger = _tagger;
			// Make sure we have a tag.
			switch (tagger)
			{
				case CUETools.Processor.CUEToolsTagger.APEv2:
					GetTag(TagTypes.Ape, true);
					break;
				case CUETools.Processor.CUEToolsTagger.ID3v2:
					GetTag(TagTypes.Id3v2, true);
					break;
			}
		}