Adjusted namespaces

This commit is contained in:
Adam Hathcock
2013-04-28 12:23:41 +01:00
parent f3b7e91579
commit 5e6501704b
10 changed files with 16 additions and 17 deletions

View File

@@ -5,7 +5,7 @@ using System.Linq;
using SharpCompress.Compressor.LZMA;
using SharpCompress.Compressor.LZMA.Utilites;
using SharpCompress.IO;
using CRC = ManagedLzma.LZMA.Master.SevenZip.CRC;
using CRC = SharpCompress.Compressor.LZMA.CRC;
namespace SharpCompress.Common.SevenZip
{

View File

@@ -1,6 +1,5 @@
using System;
using System.Collections.Generic;
using ManagedLzma.LZMA.Master.SevenZip;
using SharpCompress.Compressor.LZMA;
namespace SharpCompress.Common.SevenZip

View File

@@ -1,7 +1,7 @@
using System;
using System.IO;
namespace ManagedLzma.LZMA.Master.SevenZip
namespace SharpCompress.Compressor.LZMA
{
internal static class CRC
{

View File

@@ -1,4 +1,4 @@
namespace SharpCompress.Compressor.LZMA
namespace SharpCompress.Compressor.LZMA.LZ
{
internal class CRC
{

View File

@@ -13,7 +13,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
public CrcBuilderStream(Stream target)
{
mTarget = target;
mCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.kInitCRC;
mCRC = CRC.kInitCRC;
}
public long Processed
@@ -26,7 +26,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
if(!mFinished)
{
mFinished = true;
mCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.Finish(mCRC);
mCRC = CRC.Finish(mCRC);
}
return mCRC;
@@ -83,7 +83,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
throw new InvalidOperationException("CRC calculation has been finished.");
mProcessed += count;
mCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.Update(mCRC, buffer, offset, count);
mCRC = CRC.Update(mCRC, buffer, offset, count);
mTarget.Write(buffer, offset, count);
}
}
@@ -98,7 +98,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
public ReadingCrcBuilderStream(Stream source)
{
mSource = source;
mCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.kInitCRC;
mCRC = CRC.kInitCRC;
}
protected override void Dispose(bool disposing)
@@ -124,7 +124,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
if(!mFinished)
{
mFinished = true;
mCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.Finish(mCRC);
mCRC = CRC.Finish(mCRC);
}
return mCRC;
@@ -169,7 +169,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
if(read > 0)
{
mProcessed += read;
mCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.Update(mCRC, buffer, offset, read);
mCRC = CRC.Update(mCRC, buffer, offset, read);
return read;
}

View File

@@ -15,7 +15,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
public CrcCheckStream(uint crc)
{
mExpectedCRC = crc;
mCurrentCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.kInitCRC;
mCurrentCRC = CRC.kInitCRC;
}
protected override void Dispose(bool disposing)
@@ -27,7 +27,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
if(disposing && !mClosed)
{
mClosed = true;
mCurrentCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.Finish(mCurrentCRC);
mCurrentCRC = CRC.Finish(mCurrentCRC);
#if DEBUG
if(mCurrentCRC == mExpectedCRC)
System.Diagnostics.Debug.WriteLine("CRC ok: " + mExpectedCRC.ToString("x8"));
@@ -108,7 +108,7 @@ namespace SharpCompress.Compressor.LZMA.Utilites
for(int i = 0; i < count; i++)
mBytes[buffer[offset + i]]++;
mCurrentCRC = ManagedLzma.LZMA.Master.SevenZip.CRC.Update(mCurrentCRC, buffer, offset, count);
mCurrentCRC = CRC.Update(mCurrentCRC, buffer, offset, count);
}
}
}

View File

@@ -196,12 +196,12 @@
<Compile Include="Compressor\LZMA\Bcj2DecoderStream.cs" />
<Compile Include="Compressor\LZMA\BitVector.cs" />
<Compile Include="Compressor\LZMA\CRC.cs" />
<Compile Include="Compressor\LZMA\CRC2.cs" />
<Compile Include="Compressor\LZMA\DecoderStream.cs" />
<Compile Include="Compressor\LZMA\ICoder.cs" />
<Compile Include="Compressor\LZMA\Log.cs" />
<Compile Include="Compressor\LZMA\LzmaEncoderProperties.cs" />
<Compile Include="Compressor\LZMA\LzmaStream.cs" />
<Compile Include="Compressor\LZMA\LZ\CRC.cs" />
<Compile Include="Compressor\LZMA\LZ\LzBinTree.cs" />
<Compile Include="Compressor\LZMA\LZ\LzInWindow.cs" />
<Compile Include="Compressor\LZMA\LzmaBase.cs" />

View File

@@ -210,12 +210,12 @@
<Compile Include="Compressor\LZMA\Bcj2DecoderStream.cs" />
<Compile Include="Compressor\LZMA\BitVector.cs" />
<Compile Include="Compressor\LZMA\CRC.cs" />
<Compile Include="Compressor\LZMA\CRC2.cs" />
<Compile Include="Compressor\LZMA\DecoderStream.cs" />
<Compile Include="Compressor\LZMA\ICoder.cs" />
<Compile Include="Compressor\LZMA\Log.cs" />
<Compile Include="Compressor\LZMA\LzmaEncoderProperties.cs" />
<Compile Include="Compressor\LZMA\LzmaStream.cs" />
<Compile Include="Compressor\LZMA\LZ\CRC.cs" />
<Compile Include="Compressor\LZMA\LZ\LzBinTree.cs" />
<Compile Include="Compressor\LZMA\LZ\LzInWindow.cs" />
<Compile Include="Compressor\LZMA\LzmaBase.cs" />

View File

@@ -179,12 +179,12 @@
<Compile Include="Compressor\LZMA\Bcj2DecoderStream.cs" />
<Compile Include="Compressor\LZMA\BitVector.cs" />
<Compile Include="Compressor\LZMA\CRC.cs" />
<Compile Include="Compressor\LZMA\CRC2.cs" />
<Compile Include="Compressor\LZMA\DecoderStream.cs" />
<Compile Include="Compressor\LZMA\ICoder.cs" />
<Compile Include="Compressor\LZMA\Log.cs" />
<Compile Include="Compressor\LZMA\LzmaEncoderProperties.cs" />
<Compile Include="Compressor\LZMA\LzmaStream.cs" />
<Compile Include="Compressor\LZMA\LZ\CRC.cs" />
<Compile Include="Compressor\LZMA\LZ\LzBinTree.cs" />
<Compile Include="Compressor\LZMA\LZ\LzInWindow.cs" />
<Compile Include="Compressor\LZMA\LzmaBase.cs" />

View File

@@ -172,7 +172,7 @@
<Compile Include="Compressor\LZMA\BitVector.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="Compressor\LZMA\CRC2.cs" />
<Compile Include="Compressor\LZMA\LZ\CRC.cs" />
<Compile Include="Compressor\LZMA\CRC.cs" />
<Compile Include="Common\SevenZip\ArchiveDatabase.cs" />
<Compile Include="Common\SevenZip\ArchiveReader.cs" />