DWFEncryptingInputStream.h

Go to the documentation of this file.
00001 //
00002 //  Copyright (c) 2006 by Autodesk, Inc.
00003 //
00004 //  By using this code, you are agreeing to the terms and conditions of
00005 //  the License Agreement included in the documentation for this code.
00006 //
00007 //  AUTODESK MAKES NO WARRANTIES, EXPRESS OR IMPLIED,
00008 //  AS TO THE CORRECTNESS OF THIS CODE OR ANY DERIVATIVE
00009 //  WORKS WHICH INCORPORATE IT.
00010 //
00011 //  AUTODESK PROVIDES THE CODE ON AN "AS-IS" BASIS
00012 //  AND EXPLICITLY DISCLAIMS ANY LIABILITY, INCLUDING
00013 //  CONSEQUENTIAL AND INCIDENTAL DAMAGES FOR ERRORS,
00014 //  OMISSIONS, AND OTHER PROBLEMS IN THE CODE.
00015 //
00016 //  Use, duplication, or disclosure by the U.S. Government is subject to
00017 //  restrictions set forth in FAR 52.227-19 (Commercial Computer Software
00018 //  Restricted Rights) and DFAR 252.227-7013(c)(1)(ii) (Rights in Technical
00019 //  Data and Computer Software), as applicable.
00020 //
00021 
00022 
00023 #ifndef _DWFCORE_ENCRYPTING_INPUT_STREAM_H
00024 #define _DWFCORE_ENCRYPTING_INPUT_STREAM_H
00025 
00026 
00031 
00032 #include "dwfcore/InputStream.h"
00033 #include "dwfcore/String.h"
00034 
00035 namespace DWFCore
00036 {
00037 
00044 class DWFEncryptingInputStream : public DWFInputStream
00045 {
00046 
00047 public:
00048 
00061     _DWFCORE_API
00062     DWFEncryptingInputStream( DWFInputStream* pInputStream,
00063                               const DWFString& rPassword )
00064         throw();
00065 
00069     _DWFCORE_API
00070     virtual ~DWFEncryptingInputStream()
00071         throw();
00072 
00081     _DWFCORE_API
00082     virtual size_t available() const
00083         throw( DWFException );
00084 
00098     _DWFCORE_API
00099     virtual size_t read( void*  pBuffer,
00100                          size_t nBytesToRead )
00101         throw( DWFException );
00102 
00117     _DWFCORE_API
00118     virtual off_t seek( int     eOrigin,
00119                         off_t   nOffset )
00120         throw( DWFException );
00121 
00122 private:
00123 
00124     DWFInputStream* _pInputStream;
00125         unsigned long   _aKeys[3];    
00126 
00127 private:
00128 
00129     //
00130     // Unimplemented methods
00131     //
00132 
00133     DWFEncryptingInputStream( const DWFEncryptingInputStream& );
00134     DWFEncryptingInputStream& operator=( const DWFEncryptingInputStream& );
00135 };
00136 
00137 }
00138 
00139 
00140 
00141 #endif
00142 
00143 

Generated on Tue Jan 6 22:39:28 2009 for Autodesk DWF Core Library by  doxygen 1.4.5