Changeset 4

Show
Ignore:
Timestamp:
11/08/08 16:01:16 (12 days ago)
Author:
Jeremy
Message:

Added tag model

Location:
trunk/TagModel
Files:
2 added
3 modified
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/TagModel/CompositeTagFormat.cs

    r3 r4  
    5050            string fileExtension = Path.GetExtension(fileName).ToUpperInvariant(); 
    5151 
     52            // Try the formats with a matching extension first. 
    5253            foreach (ITagFormat format in manager.AddIns) 
    5354                if (format.Extensions.Contains(fileExtension)) 
     
    6061                } 
    6162 
    62             return null; 
     63            // If the tag is still not read, return a "null" one. 
     64            return new NullTag(); 
    6365        } 
    6466 
  • trunk/TagModel/ITagFormat.cs

    r3 r4  
    1919 
    2020using System.Collections.ObjectModel; 
    21 using OmniEncoder.AddInModel; 
    2221 
    2322namespace OmniEncoder.TagModel 
  • trunk/TagModel/TagInvalidException.cs

    r3 r4  
    2121using System.Runtime.Serialization; 
    2222 
    23 namespace OmniEncoder.AudioModel 
     23namespace OmniEncoder.TagModel 
    2424{ 
    2525    [Serializable] 
    26     public class AudioInvalidException : Exception 
     26    public class TagInvalidException : Exception 
    2727    { 
    28         public AudioInvalidException() 
     28        public TagInvalidException() 
    2929            : base() 
    3030        { 
    3131        } 
    3232 
    33         public AudioInvalidException(string message) 
     33        public TagInvalidException(string message) 
    3434            : base(message) 
    3535        { 
    3636        } 
    3737 
    38         public AudioInvalidException(string message, Exception innerException) 
     38        public TagInvalidException(string message, Exception innerException) 
    3939            : base(message, innerException) 
    4040        { 
    4141        } 
    4242 
    43         protected AudioInvalidException(SerializationInfo info, StreamingContext context) 
     43        protected TagInvalidException(SerializationInfo info, StreamingContext context) 
    4444            : base(info, context) 
    4545        { 
  • trunk/TagModel/TagModel.csproj

    r3 r4  
    2525    <ErrorReport>prompt</ErrorReport> 
    2626    <WarningLevel>4</WarningLevel> 
     27    <RunCodeAnalysis>true</RunCodeAnalysis> 
    2728  </PropertyGroup> 
    2829  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> 
     
    5152  </ItemGroup> 
    5253  <ItemGroup> 
     54    <Compile Include="NullTag.cs" /> 
     55    <Compile Include="TagInvalidException.cs" /> 
     56    <Compile Include="TagUnsupportedException.cs" /> 
    5357    <Compile Include="CompositeTagFormat.cs" /> 
    5458    <Compile Include="ITag.cs" />