mirror of
https://github.com/TomHarte/CLK.git
synced 2026-04-26 19:17:52 +00:00
Simplify namespace syntax.
This commit is contained in:
@@ -12,9 +12,7 @@
|
||||
#include <cstdint>
|
||||
#include "../../../Disk/Track/PCMSegment.hpp"
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace AppleGCR {
|
||||
namespace Storage::Encodings::AppleGCR {
|
||||
|
||||
/// Describes the standard three-byte prologue that begins a header on both the Macintosh and the Apple II from DOS 3.3.
|
||||
constexpr uint8_t header_prologue[3] = {0xd5, 0xaa, 0x96};
|
||||
@@ -93,8 +91,6 @@ Storage::Disk::PCMSegment five_and_three_data(const uint8_t *source);
|
||||
*/
|
||||
Storage::Disk::PCMSegment five_and_three_sync(int length);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* AppleGCR_hpp */
|
||||
|
||||
@@ -12,9 +12,7 @@
|
||||
#include <cstdint>
|
||||
#include <vector>
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace AppleGCR {
|
||||
namespace Storage::Encodings::AppleGCR {
|
||||
|
||||
struct Sector {
|
||||
/*!
|
||||
@@ -76,8 +74,6 @@ struct Sector {
|
||||
encoding(rhs.encoding) {}
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* Sector_h */
|
||||
|
||||
@@ -13,9 +13,7 @@
|
||||
#include "../../Track/PCMSegment.hpp"
|
||||
#include <map>
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace AppleGCR {
|
||||
namespace Storage::Encodings::AppleGCR {
|
||||
|
||||
/*!
|
||||
Scans @c segment for all included sectors, returning a set that maps from location within
|
||||
@@ -23,8 +21,6 @@ namespace AppleGCR {
|
||||
*/
|
||||
std::map<std::size_t, Sector> sectors_from_segment(const Disk::PCMSegment &segment);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* TrackParser_hpp */
|
||||
|
||||
@@ -12,8 +12,7 @@
|
||||
#include "../../Storage.hpp"
|
||||
#include <cstdint>
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace Storage::Encodings {
|
||||
|
||||
namespace CommodoreGCR {
|
||||
/*!
|
||||
@@ -48,7 +47,6 @@ namespace CommodoreGCR {
|
||||
unsigned int decoding_from_dectet(unsigned int dectet);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* CommodoreGCR_hpp */
|
||||
|
||||
@@ -11,9 +11,7 @@
|
||||
|
||||
#include "../../../Storage.hpp"
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace MFM {
|
||||
namespace Storage::Encodings::MFM {
|
||||
|
||||
const uint8_t IndexAddressByte = 0xfc;
|
||||
const uint8_t IDAddressByte = 0xfe;
|
||||
@@ -35,8 +33,6 @@ const uint8_t MFMSyncByteValue = 0xa1;
|
||||
const Time MFMBitLength = Time(1, 100000);
|
||||
const Time FMBitLength = Time(1, 50000);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* Constants_h */
|
||||
|
||||
@@ -17,9 +17,7 @@
|
||||
#include "../../Track/Track.hpp"
|
||||
#include "../../../../Numeric/CRC.hpp"
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace MFM {
|
||||
namespace Storage::Encodings::MFM {
|
||||
|
||||
extern const std::size_t DefaultSectorGapLength;
|
||||
/*!
|
||||
@@ -80,8 +78,6 @@ class Encoder {
|
||||
std::unique_ptr<Encoder> GetMFMEncoder(std::vector<bool> &target, std::vector<bool> *fuzzy_target = nullptr);
|
||||
std::unique_ptr<Encoder> GetFMEncoder(std::vector<bool> &target, std::vector<bool> *fuzzy_target = nullptr);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* MFM_hpp */
|
||||
|
||||
@@ -13,9 +13,7 @@
|
||||
#include "../../Track/Track.hpp"
|
||||
#include "../../Drive.hpp"
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace MFM {
|
||||
namespace Storage::Encodings::MFM {
|
||||
|
||||
/*!
|
||||
Provides a mechanism for collecting sectors from a disk.
|
||||
@@ -40,8 +38,6 @@ class Parser {
|
||||
std::map<Storage::Disk::Track::Address, std::map<int, Storage::Encodings::MFM::Sector>> sectors_by_address_by_track_;
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* Parser_hpp */
|
||||
|
||||
@@ -12,9 +12,7 @@
|
||||
#include <cstdint>
|
||||
#include <vector>
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace MFM {
|
||||
namespace Storage::Encodings::MFM {
|
||||
|
||||
/*!
|
||||
Represents a single [M]FM sector, identified by its track, side and sector records, a blob of data
|
||||
@@ -54,8 +52,6 @@ struct Sector {
|
||||
is_deleted(rhs.is_deleted ){}
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* Sector_h */
|
||||
|
||||
@@ -13,9 +13,7 @@
|
||||
#include "../../Track/PCMSegment.hpp"
|
||||
#include <map>
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace MFM {
|
||||
namespace Storage::Encodings::MFM {
|
||||
|
||||
/*!
|
||||
Scans @c segment for all included sectors, returning a set that maps from location within
|
||||
@@ -24,8 +22,6 @@ namespace MFM {
|
||||
*/
|
||||
std::map<std::size_t, Sector> sectors_from_segment(const Disk::PCMSegment &&segment, bool is_double_density);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* SegmentParser_hpp */
|
||||
|
||||
@@ -13,9 +13,7 @@
|
||||
#include <memory>
|
||||
#include "../../../../Numeric/CRC.hpp"
|
||||
|
||||
namespace Storage {
|
||||
namespace Encodings {
|
||||
namespace MFM {
|
||||
namespace Storage::Encodings::MFM {
|
||||
|
||||
/*!
|
||||
The MFM shifter parses a stream of bits as input in order to produce
|
||||
@@ -80,8 +78,6 @@ class Shifter {
|
||||
CRC::CCITT *crc_generator_;
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* Shifter_hpp */
|
||||
|
||||
Reference in New Issue
Block a user