Explorar o código

Remove const to some member functions

Daniele Bartolini %!s(int64=12) %!d(string=hai) anos
pai
achega
4107290fe6

+ 4 - 4
engine/core/filesystem/DiskFile.cpp

@@ -143,13 +143,13 @@ bool DiskFile::copy_to(File& file, size_t size)
 }
 
 //-----------------------------------------------------------------------------
-bool DiskFile::end_of_file() const
+bool DiskFile::end_of_file()
 {
 	return position() == size();
 }
 
 //-----------------------------------------------------------------------------
-bool DiskFile::is_valid() const
+bool DiskFile::is_valid()
 {
 	return m_file.is_open();
 }
@@ -163,7 +163,7 @@ void DiskFile::flush()
 }
 
 //-----------------------------------------------------------------------------
-size_t DiskFile::position() const
+size_t DiskFile::position()
 {
 	check_valid();
 
@@ -171,7 +171,7 @@ size_t DiskFile::position() const
 }
 
 //-----------------------------------------------------------------------------
-size_t DiskFile::size() const
+size_t DiskFile::size()
 {
 	check_valid();
 	

+ 4 - 4
engine/core/filesystem/DiskFile.h

@@ -64,16 +64,16 @@ public:
 	void			flush();
 
 	/// @copydoc File::end_of_file() 
-	bool			end_of_file() const;
+	bool			end_of_file();
 
 	/// @copydoc File::is_valid() 
-	bool			is_valid() const;
+	bool			is_valid();
 
 	/// @copydoc File::size() 
-	size_t			size() const;
+	size_t			size();
 
 	/// @copydoc File::position() 
-	size_t			position() const;
+	size_t			position();
 
 	/// @copydoc File::can_read() 
 	bool			can_read() const;

+ 4 - 4
engine/core/filesystem/File.h

@@ -90,18 +90,18 @@ public:
 	/// A file is valid when the buffer where it operates
 	/// exists. (i.e. a file descriptor is attached to the file, 
 	/// a memory area is attached to the file etc.)
-	virtual bool		is_valid() const = 0;
+	virtual bool		is_valid() = 0;
 
 	/// Returns whether the position is at end of file.
-	virtual bool		end_of_file() const = 0;
+	virtual bool		end_of_file() = 0;
 
 	/// Returns the size of file in bytes.
-	virtual size_t		size() const = 0;
+	virtual size_t		size() = 0;
 
 	/// Returns the current position in file.
 	/// Generally, for binary data, it means the number of bytes
 	/// from the beginning of the file.
-	virtual size_t		position() const = 0;
+	virtual size_t		position() = 0;
 
 	/// Returns whether the file can be read.
 	virtual bool		can_read() const = 0;