2ca1376080
No functional code altered. https://dev.haiku-os.org/ticket/17197 Change-Id: I75cc74f6be0ad968fd77c31fbe5b0f650a6fe9e0 Reviewed-on: https://review.haiku-os.org/c/haiku/+/4364 Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org> Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
45 lines
884 B
C++
45 lines
884 B
C++
//----------------------------------------------------------------------
|
|
// This software is part of the Haiku distribution and is covered
|
|
// by the MIT License.
|
|
//---------------------------------------------------------------------
|
|
/*!
|
|
\file sniffer/Range.h
|
|
MIME sniffer range declarations
|
|
*/
|
|
#ifndef _SNIFFER_RANGE_H
|
|
#define _SNIFFER_RANGE_H
|
|
|
|
#include <SupportDefs.h>
|
|
|
|
namespace BPrivate {
|
|
namespace Storage {
|
|
namespace Sniffer {
|
|
|
|
class Err;
|
|
|
|
//! A range of byte offsets from which to check a pattern against a data stream.
|
|
class Range {
|
|
public:
|
|
Range(int32 start, int32 end);
|
|
|
|
status_t InitCheck() const;
|
|
Err* GetErr() const;
|
|
|
|
int32 Start() const;
|
|
int32 End() const;
|
|
|
|
void SetTo(int32 start, int32 end);
|
|
private:
|
|
int32 fStart;
|
|
int32 fEnd;
|
|
status_t fCStatus;
|
|
};
|
|
|
|
}; // namespace Sniffer
|
|
}; // namespace Storage
|
|
}; // namespace BPrivate
|
|
|
|
#endif // _SNIFFER_RANGE_H
|
|
|
|
|