diff options
author | pixel <pixel> | 2004-11-27 21:44:44 +0000 |
---|---|---|
committer | pixel <pixel> | 2004-11-27 21:44:44 +0000 |
commit | d38e80ee04afe582e70150d3884e56c05f3fd7a8 (patch) | |
tree | f2627c50fa22aea89447e8406ac418eb68650d3d /includes/cdreader.h | |
parent | 50f0dd331f8168fb5b2cd60c70178fad627b7fb6 (diff) |
Large dos2unix commit...
Diffstat (limited to 'includes/cdreader.h')
-rw-r--r-- | includes/cdreader.h | 132 |
1 files changed, 66 insertions, 66 deletions
diff --git a/includes/cdreader.h b/includes/cdreader.h index 6b01efc..7d0d15e 100644 --- a/includes/cdreader.h +++ b/includes/cdreader.h @@ -1,66 +1,66 @@ -/*
- * PSX-Tools Bundle Pack
- * Copyright (C) 2002-2003 Nicolas "Pixel" Noble
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-/* $Id: cdreader.h,v 1.11 2004-11-27 21:44:46 pixel Exp $ */
-
-#ifndef __CDREADER_H__
-#define __CDREADER_H__
-
-#include <sys/types.h>
-#include <time.h>
-#include <BString.h>
-#include <Handle.h>
-#include "cdabstract.h"
-
-class cdreader : public Handle {
- public:
- cdreader(const String &) throw (GeneralException);
- cdreader(const cdreader &);
- virtual ~cdreader();
- virtual bool CanWrite() const;
- virtual bool CanRead() const;
- virtual bool CanSeek() const;
-#if defined (_MSC_VER) || defined (__MINGW32__)
- virtual void close() throw (GeneralException);
-#endif
- virtual ssize_t read(void *buf, size_t count) throw (GeneralException);
- virtual off_t seek(off_t, int = SEEK_SET) throw (GeneralException);
- virtual String GetName() const;
- virtual ssize_t GetSize() const;
- void fetchsector(void *, int = -1);
- void getsector(void *, int = -1, int = 1) throw (GeneralException);
- void sectorseek(int);
-
- private:
- struct cachedsector {
- Byte sector[2352];
- cachedsector * next, * prev;
- int n;
- };
- String n;
- int sector;
- cachedsector * head, * tail, * sectors[400000];
- int nsectors;
-
- void removetail();
- void actualize(cachedsector * s);
- void introduce(Byte * datas, int n);
-};
-
-#endif
+/* + * PSX-Tools Bundle Pack + * Copyright (C) 2002-2003 Nicolas "Pixel" Noble + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +/* $Id: cdreader.h,v 1.12 2004-11-27 21:47:53 pixel Exp $ */ + +#ifndef __CDREADER_H__ +#define __CDREADER_H__ + +#include <sys/types.h> +#include <time.h> +#include <BString.h> +#include <Handle.h> +#include "cdabstract.h" + +class cdreader : public Handle { + public: + cdreader(const String &) throw (GeneralException); + cdreader(const cdreader &); + virtual ~cdreader(); + virtual bool CanWrite() const; + virtual bool CanRead() const; + virtual bool CanSeek() const; +#if defined (_MSC_VER) || defined (__MINGW32__) + virtual void close() throw (GeneralException); +#endif + virtual ssize_t read(void *buf, size_t count) throw (GeneralException); + virtual off_t seek(off_t, int = SEEK_SET) throw (GeneralException); + virtual String GetName() const; + virtual ssize_t GetSize() const; + void fetchsector(void *, int = -1); + void getsector(void *, int = -1, int = 1) throw (GeneralException); + void sectorseek(int); + + private: + struct cachedsector { + Byte sector[2352]; + cachedsector * next, * prev; + int n; + }; + String n; + int sector; + cachedsector * head, * tail, * sectors[400000]; + int nsectors; + + void removetail(); + void actualize(cachedsector * s); + void introduce(Byte * datas, int n); +}; + +#endif |