From 1e8dd54c54a04d5f5ee249db22f84001fa16101e Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Thu, 31 Aug 2017 16:31:47 -0400 Subject: Rename fxcrt_ and ifxcrt_ files to better names The CFXCRT and IFXCRT prefix was only used on 3 files. This CL renames them to the more common CFX and IFX. The files were renamed as needed. Change-Id: Iccdaa55c5822adb93af7c58aedfb121413a30223 Reviewed-on: https://pdfium-review.googlesource.com/12675 Reviewed-by: Tom Sepez Commit-Queue: dsinclair --- core/fxcrt/ifx_fileaccess.h | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 core/fxcrt/ifx_fileaccess.h (limited to 'core/fxcrt/ifx_fileaccess.h') diff --git a/core/fxcrt/ifx_fileaccess.h b/core/fxcrt/ifx_fileaccess.h new file mode 100644 index 0000000000..e818303d85 --- /dev/null +++ b/core/fxcrt/ifx_fileaccess.h @@ -0,0 +1,38 @@ +// Copyright 2014 PDFium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com + +#ifndef CORE_FXCRT_IFX_FILEACCESS_H_ +#define CORE_FXCRT_IFX_FILEACCESS_H_ + +#include +#include + +#include "core/fxcrt/fx_safe_types.h" +#include "core/fxcrt/fx_stream.h" +#include "core/fxcrt/fx_string.h" + +class IFX_FileAccess { + public: + static std::unique_ptr Create(); + virtual ~IFX_FileAccess() {} + + virtual bool Open(const CFX_ByteStringC& fileName, uint32_t dwMode) = 0; + virtual bool Open(const CFX_WideStringC& fileName, uint32_t dwMode) = 0; + virtual void Close() = 0; + virtual FX_FILESIZE GetSize() const = 0; + virtual FX_FILESIZE GetPosition() const = 0; + virtual FX_FILESIZE SetPosition(FX_FILESIZE pos) = 0; + virtual size_t Read(void* pBuffer, size_t szBuffer) = 0; + virtual size_t Write(const void* pBuffer, size_t szBuffer) = 0; + virtual size_t ReadPos(void* pBuffer, size_t szBuffer, FX_FILESIZE pos) = 0; + virtual size_t WritePos(const void* pBuffer, + size_t szBuffer, + FX_FILESIZE pos) = 0; + virtual bool Flush() = 0; + virtual bool Truncate(FX_FILESIZE szFile) = 0; +}; + +#endif // CORE_FXCRT_IFX_FILEACCESS_H_ -- cgit v1.2.3