removing precompiled libprotobuf objects. fixes ticket 23
This commit is contained in:
parent
9be6c1c795
commit
26966f5cdb
@ -1,848 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
|
|
||||||
#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
|
|
||||||
#include "fileformat.pb.h"
|
|
||||||
#include <google/protobuf/stubs/once.h>
|
|
||||||
#include <google/protobuf/io/coded_stream.h>
|
|
||||||
#include <google/protobuf/wire_format_lite_inl.h>
|
|
||||||
#include <google/protobuf/descriptor.h>
|
|
||||||
#include <google/protobuf/reflection_ops.h>
|
|
||||||
#include <google/protobuf/wire_format.h>
|
|
||||||
// @@protoc_insertion_point(includes)
|
|
||||||
|
|
||||||
namespace OSMPBF {
|
|
||||||
|
|
||||||
namespace {
|
|
||||||
|
|
||||||
const ::google::protobuf::Descriptor* Blob_descriptor_ = NULL;
|
|
||||||
const ::google::protobuf::internal::GeneratedMessageReflection*
|
|
||||||
Blob_reflection_ = NULL;
|
|
||||||
const ::google::protobuf::Descriptor* BlobHeader_descriptor_ = NULL;
|
|
||||||
const ::google::protobuf::internal::GeneratedMessageReflection*
|
|
||||||
BlobHeader_reflection_ = NULL;
|
|
||||||
|
|
||||||
} // namespace
|
|
||||||
|
|
||||||
|
|
||||||
void protobuf_AssignDesc_fileformat_2eproto() {
|
|
||||||
protobuf_AddDesc_fileformat_2eproto();
|
|
||||||
const ::google::protobuf::FileDescriptor* file =
|
|
||||||
::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
|
|
||||||
"fileformat.proto");
|
|
||||||
GOOGLE_CHECK(file != NULL);
|
|
||||||
Blob_descriptor_ = file->message_type(0);
|
|
||||||
static const int Blob_offsets_[5] = {
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, raw_),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, raw_size_),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, zlib_data_),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, lzma_data_),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, obsolete_bzip2_data_),
|
|
||||||
};
|
|
||||||
Blob_reflection_ =
|
|
||||||
new ::google::protobuf::internal::GeneratedMessageReflection(
|
|
||||||
Blob_descriptor_,
|
|
||||||
Blob::default_instance_,
|
|
||||||
Blob_offsets_,
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, _has_bits_[0]),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Blob, _unknown_fields_),
|
|
||||||
-1,
|
|
||||||
::google::protobuf::DescriptorPool::generated_pool(),
|
|
||||||
::google::protobuf::MessageFactory::generated_factory(),
|
|
||||||
sizeof(Blob));
|
|
||||||
BlobHeader_descriptor_ = file->message_type(1);
|
|
||||||
static const int BlobHeader_offsets_[3] = {
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobHeader, type_),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobHeader, indexdata_),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobHeader, datasize_),
|
|
||||||
};
|
|
||||||
BlobHeader_reflection_ =
|
|
||||||
new ::google::protobuf::internal::GeneratedMessageReflection(
|
|
||||||
BlobHeader_descriptor_,
|
|
||||||
BlobHeader::default_instance_,
|
|
||||||
BlobHeader_offsets_,
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobHeader, _has_bits_[0]),
|
|
||||||
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobHeader, _unknown_fields_),
|
|
||||||
-1,
|
|
||||||
::google::protobuf::DescriptorPool::generated_pool(),
|
|
||||||
::google::protobuf::MessageFactory::generated_factory(),
|
|
||||||
sizeof(BlobHeader));
|
|
||||||
}
|
|
||||||
|
|
||||||
namespace {
|
|
||||||
|
|
||||||
GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
|
|
||||||
inline void protobuf_AssignDescriptorsOnce() {
|
|
||||||
::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
|
|
||||||
&protobuf_AssignDesc_fileformat_2eproto);
|
|
||||||
}
|
|
||||||
|
|
||||||
void protobuf_RegisterTypes(const ::std::string&) {
|
|
||||||
protobuf_AssignDescriptorsOnce();
|
|
||||||
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
|
|
||||||
Blob_descriptor_, &Blob::default_instance());
|
|
||||||
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
|
|
||||||
BlobHeader_descriptor_, &BlobHeader::default_instance());
|
|
||||||
}
|
|
||||||
|
|
||||||
} // namespace
|
|
||||||
|
|
||||||
void protobuf_ShutdownFile_fileformat_2eproto() {
|
|
||||||
delete Blob::default_instance_;
|
|
||||||
delete Blob_reflection_;
|
|
||||||
delete BlobHeader::default_instance_;
|
|
||||||
delete BlobHeader_reflection_;
|
|
||||||
}
|
|
||||||
|
|
||||||
void protobuf_AddDesc_fileformat_2eproto() {
|
|
||||||
static bool already_here = false;
|
|
||||||
if (already_here) return;
|
|
||||||
already_here = true;
|
|
||||||
GOOGLE_PROTOBUF_VERIFY_VERSION;
|
|
||||||
|
|
||||||
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
|
|
||||||
"\n\020fileformat.proto\022\006OSMPBF\"l\n\004Blob\022\013\n\003ra"
|
|
||||||
"w\030\001 \001(\014\022\020\n\010raw_size\030\002 \001(\005\022\021\n\tzlib_data\030\003"
|
|
||||||
" \001(\014\022\021\n\tlzma_data\030\004 \001(\014\022\037\n\023OBSOLETE_bzip"
|
|
||||||
"2_data\030\005 \001(\014B\002\030\001\"?\n\nBlobHeader\022\014\n\004type\030\001"
|
|
||||||
" \002(\t\022\021\n\tindexdata\030\002 \001(\014\022\020\n\010datasize\030\003 \002("
|
|
||||||
"\005B\017\n\rcrosby.binary", 218);
|
|
||||||
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
|
|
||||||
"fileformat.proto", &protobuf_RegisterTypes);
|
|
||||||
Blob::default_instance_ = new Blob();
|
|
||||||
BlobHeader::default_instance_ = new BlobHeader();
|
|
||||||
Blob::default_instance_->InitAsDefaultInstance();
|
|
||||||
BlobHeader::default_instance_->InitAsDefaultInstance();
|
|
||||||
::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_fileformat_2eproto);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Force AddDescriptors() to be called at static initialization time.
|
|
||||||
struct StaticDescriptorInitializer_fileformat_2eproto {
|
|
||||||
StaticDescriptorInitializer_fileformat_2eproto() {
|
|
||||||
protobuf_AddDesc_fileformat_2eproto();
|
|
||||||
}
|
|
||||||
} static_descriptor_initializer_fileformat_2eproto_;
|
|
||||||
|
|
||||||
|
|
||||||
// ===================================================================
|
|
||||||
|
|
||||||
const ::std::string Blob::_default_raw_;
|
|
||||||
const ::std::string Blob::_default_zlib_data_;
|
|
||||||
const ::std::string Blob::_default_lzma_data_;
|
|
||||||
const ::std::string Blob::_default_obsolete_bzip2_data_;
|
|
||||||
#ifndef _MSC_VER
|
|
||||||
const int Blob::kRawFieldNumber;
|
|
||||||
const int Blob::kRawSizeFieldNumber;
|
|
||||||
const int Blob::kZlibDataFieldNumber;
|
|
||||||
const int Blob::kLzmaDataFieldNumber;
|
|
||||||
const int Blob::kOBSOLETEBzip2DataFieldNumber;
|
|
||||||
#endif // !_MSC_VER
|
|
||||||
|
|
||||||
Blob::Blob()
|
|
||||||
: ::google::protobuf::Message() {
|
|
||||||
SharedCtor();
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::InitAsDefaultInstance() {
|
|
||||||
}
|
|
||||||
|
|
||||||
Blob::Blob(const Blob& from)
|
|
||||||
: ::google::protobuf::Message() {
|
|
||||||
SharedCtor();
|
|
||||||
MergeFrom(from);
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::SharedCtor() {
|
|
||||||
_cached_size_ = 0;
|
|
||||||
raw_ = const_cast< ::std::string*>(&_default_raw_);
|
|
||||||
raw_size_ = 0;
|
|
||||||
zlib_data_ = const_cast< ::std::string*>(&_default_zlib_data_);
|
|
||||||
lzma_data_ = const_cast< ::std::string*>(&_default_lzma_data_);
|
|
||||||
obsolete_bzip2_data_ = const_cast< ::std::string*>(&_default_obsolete_bzip2_data_);
|
|
||||||
::memset(_has_bits_, 0, sizeof(_has_bits_));
|
|
||||||
}
|
|
||||||
|
|
||||||
Blob::~Blob() {
|
|
||||||
SharedDtor();
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::SharedDtor() {
|
|
||||||
if (raw_ != &_default_raw_) {
|
|
||||||
delete raw_;
|
|
||||||
}
|
|
||||||
if (zlib_data_ != &_default_zlib_data_) {
|
|
||||||
delete zlib_data_;
|
|
||||||
}
|
|
||||||
if (lzma_data_ != &_default_lzma_data_) {
|
|
||||||
delete lzma_data_;
|
|
||||||
}
|
|
||||||
if (obsolete_bzip2_data_ != &_default_obsolete_bzip2_data_) {
|
|
||||||
delete obsolete_bzip2_data_;
|
|
||||||
}
|
|
||||||
if (this != default_instance_) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::SetCachedSize(int size) const {
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
|
|
||||||
_cached_size_ = size;
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_END();
|
|
||||||
}
|
|
||||||
const ::google::protobuf::Descriptor* Blob::descriptor() {
|
|
||||||
protobuf_AssignDescriptorsOnce();
|
|
||||||
return Blob_descriptor_;
|
|
||||||
}
|
|
||||||
|
|
||||||
const Blob& Blob::default_instance() {
|
|
||||||
if (default_instance_ == NULL) protobuf_AddDesc_fileformat_2eproto(); return *default_instance_;
|
|
||||||
}
|
|
||||||
|
|
||||||
Blob* Blob::default_instance_ = NULL;
|
|
||||||
|
|
||||||
Blob* Blob::New() const {
|
|
||||||
return new Blob;
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::Clear() {
|
|
||||||
if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
|
|
||||||
if (_has_bit(0)) {
|
|
||||||
if (raw_ != &_default_raw_) {
|
|
||||||
raw_->clear();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
raw_size_ = 0;
|
|
||||||
if (_has_bit(2)) {
|
|
||||||
if (zlib_data_ != &_default_zlib_data_) {
|
|
||||||
zlib_data_->clear();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (_has_bit(3)) {
|
|
||||||
if (lzma_data_ != &_default_lzma_data_) {
|
|
||||||
lzma_data_->clear();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (_has_bit(4)) {
|
|
||||||
if (obsolete_bzip2_data_ != &_default_obsolete_bzip2_data_) {
|
|
||||||
obsolete_bzip2_data_->clear();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
::memset(_has_bits_, 0, sizeof(_has_bits_));
|
|
||||||
mutable_unknown_fields()->Clear();
|
|
||||||
}
|
|
||||||
|
|
||||||
bool Blob::MergePartialFromCodedStream(
|
|
||||||
::google::protobuf::io::CodedInputStream* input) {
|
|
||||||
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
|
|
||||||
::google::protobuf::uint32 tag;
|
|
||||||
while ((tag = input->ReadTag()) != 0) {
|
|
||||||
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
|
|
||||||
// optional bytes raw = 1;
|
|
||||||
case 1: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
|
|
||||||
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
|
|
||||||
input, this->mutable_raw()));
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectTag(16)) goto parse_raw_size;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional int32 raw_size = 2;
|
|
||||||
case 2: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
|
|
||||||
parse_raw_size:
|
|
||||||
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
|
|
||||||
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
|
|
||||||
input, &raw_size_)));
|
|
||||||
_set_bit(1);
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectTag(26)) goto parse_zlib_data;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes zlib_data = 3;
|
|
||||||
case 3: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
|
|
||||||
parse_zlib_data:
|
|
||||||
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
|
|
||||||
input, this->mutable_zlib_data()));
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectTag(34)) goto parse_lzma_data;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes lzma_data = 4;
|
|
||||||
case 4: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
|
|
||||||
parse_lzma_data:
|
|
||||||
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
|
|
||||||
input, this->mutable_lzma_data()));
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectTag(42)) goto parse_OBSOLETE_bzip2_data;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes OBSOLETE_bzip2_data = 5 [deprecated = true];
|
|
||||||
case 5: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
|
|
||||||
parse_OBSOLETE_bzip2_data:
|
|
||||||
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
|
|
||||||
input, this->mutable_obsolete_bzip2_data()));
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectAtEnd()) return true;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
default: {
|
|
||||||
handle_uninterpreted:
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
DO_(::google::protobuf::internal::WireFormat::SkipField(
|
|
||||||
input, tag, mutable_unknown_fields()));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
#undef DO_
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::SerializeWithCachedSizes(
|
|
||||||
::google::protobuf::io::CodedOutputStream* output) const {
|
|
||||||
// optional bytes raw = 1;
|
|
||||||
if (_has_bit(0)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytes(
|
|
||||||
1, this->raw(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional int32 raw_size = 2;
|
|
||||||
if (_has_bit(1)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->raw_size(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes zlib_data = 3;
|
|
||||||
if (_has_bit(2)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytes(
|
|
||||||
3, this->zlib_data(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes lzma_data = 4;
|
|
||||||
if (_has_bit(3)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytes(
|
|
||||||
4, this->lzma_data(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes OBSOLETE_bzip2_data = 5 [deprecated = true];
|
|
||||||
if (_has_bit(4)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytes(
|
|
||||||
5, this->obsolete_bzip2_data(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!unknown_fields().empty()) {
|
|
||||||
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
|
|
||||||
unknown_fields(), output);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
::google::protobuf::uint8* Blob::SerializeWithCachedSizesToArray(
|
|
||||||
::google::protobuf::uint8* target) const {
|
|
||||||
// optional bytes raw = 1;
|
|
||||||
if (_has_bit(0)) {
|
|
||||||
target =
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
|
|
||||||
1, this->raw(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional int32 raw_size = 2;
|
|
||||||
if (_has_bit(1)) {
|
|
||||||
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->raw_size(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes zlib_data = 3;
|
|
||||||
if (_has_bit(2)) {
|
|
||||||
target =
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
|
|
||||||
3, this->zlib_data(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes lzma_data = 4;
|
|
||||||
if (_has_bit(3)) {
|
|
||||||
target =
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
|
|
||||||
4, this->lzma_data(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes OBSOLETE_bzip2_data = 5 [deprecated = true];
|
|
||||||
if (_has_bit(4)) {
|
|
||||||
target =
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
|
|
||||||
5, this->obsolete_bzip2_data(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!unknown_fields().empty()) {
|
|
||||||
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
|
|
||||||
unknown_fields(), target);
|
|
||||||
}
|
|
||||||
return target;
|
|
||||||
}
|
|
||||||
|
|
||||||
int Blob::ByteSize() const {
|
|
||||||
int total_size = 0;
|
|
||||||
|
|
||||||
if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
|
|
||||||
// optional bytes raw = 1;
|
|
||||||
if (has_raw()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::BytesSize(
|
|
||||||
this->raw());
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional int32 raw_size = 2;
|
|
||||||
if (has_raw_size()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::Int32Size(
|
|
||||||
this->raw_size());
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes zlib_data = 3;
|
|
||||||
if (has_zlib_data()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::BytesSize(
|
|
||||||
this->zlib_data());
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes lzma_data = 4;
|
|
||||||
if (has_lzma_data()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::BytesSize(
|
|
||||||
this->lzma_data());
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes OBSOLETE_bzip2_data = 5 [deprecated = true];
|
|
||||||
if (has_obsolete_bzip2_data()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::BytesSize(
|
|
||||||
this->obsolete_bzip2_data());
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
if (!unknown_fields().empty()) {
|
|
||||||
total_size +=
|
|
||||||
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
|
|
||||||
unknown_fields());
|
|
||||||
}
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
|
|
||||||
_cached_size_ = total_size;
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_END();
|
|
||||||
return total_size;
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::MergeFrom(const ::google::protobuf::Message& from) {
|
|
||||||
GOOGLE_CHECK_NE(&from, this);
|
|
||||||
const Blob* source =
|
|
||||||
::google::protobuf::internal::dynamic_cast_if_available<const Blob*>(
|
|
||||||
&from);
|
|
||||||
if (source == NULL) {
|
|
||||||
::google::protobuf::internal::ReflectionOps::Merge(from, this);
|
|
||||||
} else {
|
|
||||||
MergeFrom(*source);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::MergeFrom(const Blob& from) {
|
|
||||||
GOOGLE_CHECK_NE(&from, this);
|
|
||||||
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
|
|
||||||
if (from._has_bit(0)) {
|
|
||||||
set_raw(from.raw());
|
|
||||||
}
|
|
||||||
if (from._has_bit(1)) {
|
|
||||||
set_raw_size(from.raw_size());
|
|
||||||
}
|
|
||||||
if (from._has_bit(2)) {
|
|
||||||
set_zlib_data(from.zlib_data());
|
|
||||||
}
|
|
||||||
if (from._has_bit(3)) {
|
|
||||||
set_lzma_data(from.lzma_data());
|
|
||||||
}
|
|
||||||
if (from._has_bit(4)) {
|
|
||||||
set_obsolete_bzip2_data(from.obsolete_bzip2_data());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
mutable_unknown_fields()->MergeFrom(from.unknown_fields());
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::CopyFrom(const ::google::protobuf::Message& from) {
|
|
||||||
if (&from == this) return;
|
|
||||||
Clear();
|
|
||||||
MergeFrom(from);
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::CopyFrom(const Blob& from) {
|
|
||||||
if (&from == this) return;
|
|
||||||
Clear();
|
|
||||||
MergeFrom(from);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool Blob::IsInitialized() const {
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
void Blob::Swap(Blob* other) {
|
|
||||||
if (other != this) {
|
|
||||||
std::swap(raw_, other->raw_);
|
|
||||||
std::swap(raw_size_, other->raw_size_);
|
|
||||||
std::swap(zlib_data_, other->zlib_data_);
|
|
||||||
std::swap(lzma_data_, other->lzma_data_);
|
|
||||||
std::swap(obsolete_bzip2_data_, other->obsolete_bzip2_data_);
|
|
||||||
std::swap(_has_bits_[0], other->_has_bits_[0]);
|
|
||||||
_unknown_fields_.Swap(&other->_unknown_fields_);
|
|
||||||
std::swap(_cached_size_, other->_cached_size_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
::google::protobuf::Metadata Blob::GetMetadata() const {
|
|
||||||
protobuf_AssignDescriptorsOnce();
|
|
||||||
::google::protobuf::Metadata metadata;
|
|
||||||
metadata.descriptor = Blob_descriptor_;
|
|
||||||
metadata.reflection = Blob_reflection_;
|
|
||||||
return metadata;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// ===================================================================
|
|
||||||
|
|
||||||
const ::std::string BlobHeader::_default_type_;
|
|
||||||
const ::std::string BlobHeader::_default_indexdata_;
|
|
||||||
#ifndef _MSC_VER
|
|
||||||
const int BlobHeader::kTypeFieldNumber;
|
|
||||||
const int BlobHeader::kIndexdataFieldNumber;
|
|
||||||
const int BlobHeader::kDatasizeFieldNumber;
|
|
||||||
#endif // !_MSC_VER
|
|
||||||
|
|
||||||
BlobHeader::BlobHeader()
|
|
||||||
: ::google::protobuf::Message() {
|
|
||||||
SharedCtor();
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::InitAsDefaultInstance() {
|
|
||||||
}
|
|
||||||
|
|
||||||
BlobHeader::BlobHeader(const BlobHeader& from)
|
|
||||||
: ::google::protobuf::Message() {
|
|
||||||
SharedCtor();
|
|
||||||
MergeFrom(from);
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::SharedCtor() {
|
|
||||||
_cached_size_ = 0;
|
|
||||||
type_ = const_cast< ::std::string*>(&_default_type_);
|
|
||||||
indexdata_ = const_cast< ::std::string*>(&_default_indexdata_);
|
|
||||||
datasize_ = 0;
|
|
||||||
::memset(_has_bits_, 0, sizeof(_has_bits_));
|
|
||||||
}
|
|
||||||
|
|
||||||
BlobHeader::~BlobHeader() {
|
|
||||||
SharedDtor();
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::SharedDtor() {
|
|
||||||
if (type_ != &_default_type_) {
|
|
||||||
delete type_;
|
|
||||||
}
|
|
||||||
if (indexdata_ != &_default_indexdata_) {
|
|
||||||
delete indexdata_;
|
|
||||||
}
|
|
||||||
if (this != default_instance_) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::SetCachedSize(int size) const {
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
|
|
||||||
_cached_size_ = size;
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_END();
|
|
||||||
}
|
|
||||||
const ::google::protobuf::Descriptor* BlobHeader::descriptor() {
|
|
||||||
protobuf_AssignDescriptorsOnce();
|
|
||||||
return BlobHeader_descriptor_;
|
|
||||||
}
|
|
||||||
|
|
||||||
const BlobHeader& BlobHeader::default_instance() {
|
|
||||||
if (default_instance_ == NULL) protobuf_AddDesc_fileformat_2eproto(); return *default_instance_;
|
|
||||||
}
|
|
||||||
|
|
||||||
BlobHeader* BlobHeader::default_instance_ = NULL;
|
|
||||||
|
|
||||||
BlobHeader* BlobHeader::New() const {
|
|
||||||
return new BlobHeader;
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::Clear() {
|
|
||||||
if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
|
|
||||||
if (_has_bit(0)) {
|
|
||||||
if (type_ != &_default_type_) {
|
|
||||||
type_->clear();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (_has_bit(1)) {
|
|
||||||
if (indexdata_ != &_default_indexdata_) {
|
|
||||||
indexdata_->clear();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
datasize_ = 0;
|
|
||||||
}
|
|
||||||
::memset(_has_bits_, 0, sizeof(_has_bits_));
|
|
||||||
mutable_unknown_fields()->Clear();
|
|
||||||
}
|
|
||||||
|
|
||||||
bool BlobHeader::MergePartialFromCodedStream(
|
|
||||||
::google::protobuf::io::CodedInputStream* input) {
|
|
||||||
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
|
|
||||||
::google::protobuf::uint32 tag;
|
|
||||||
while ((tag = input->ReadTag()) != 0) {
|
|
||||||
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
|
|
||||||
// required string type = 1;
|
|
||||||
case 1: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
|
|
||||||
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
|
|
||||||
input, this->mutable_type()));
|
|
||||||
::google::protobuf::internal::WireFormat::VerifyUTF8String(
|
|
||||||
this->type().data(), this->type().length(),
|
|
||||||
::google::protobuf::internal::WireFormat::PARSE);
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectTag(18)) goto parse_indexdata;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes indexdata = 2;
|
|
||||||
case 2: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
|
|
||||||
parse_indexdata:
|
|
||||||
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
|
|
||||||
input, this->mutable_indexdata()));
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectTag(24)) goto parse_datasize;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// required int32 datasize = 3;
|
|
||||||
case 3: {
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
|
|
||||||
parse_datasize:
|
|
||||||
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
|
|
||||||
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
|
|
||||||
input, &datasize_)));
|
|
||||||
_set_bit(2);
|
|
||||||
} else {
|
|
||||||
goto handle_uninterpreted;
|
|
||||||
}
|
|
||||||
if (input->ExpectAtEnd()) return true;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
default: {
|
|
||||||
handle_uninterpreted:
|
|
||||||
if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
|
|
||||||
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
DO_(::google::protobuf::internal::WireFormat::SkipField(
|
|
||||||
input, tag, mutable_unknown_fields()));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
#undef DO_
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::SerializeWithCachedSizes(
|
|
||||||
::google::protobuf::io::CodedOutputStream* output) const {
|
|
||||||
// required string type = 1;
|
|
||||||
if (_has_bit(0)) {
|
|
||||||
::google::protobuf::internal::WireFormat::VerifyUTF8String(
|
|
||||||
this->type().data(), this->type().length(),
|
|
||||||
::google::protobuf::internal::WireFormat::SERIALIZE);
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteString(
|
|
||||||
1, this->type(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes indexdata = 2;
|
|
||||||
if (_has_bit(1)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytes(
|
|
||||||
2, this->indexdata(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
// required int32 datasize = 3;
|
|
||||||
if (_has_bit(2)) {
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->datasize(), output);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!unknown_fields().empty()) {
|
|
||||||
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
|
|
||||||
unknown_fields(), output);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
::google::protobuf::uint8* BlobHeader::SerializeWithCachedSizesToArray(
|
|
||||||
::google::protobuf::uint8* target) const {
|
|
||||||
// required string type = 1;
|
|
||||||
if (_has_bit(0)) {
|
|
||||||
::google::protobuf::internal::WireFormat::VerifyUTF8String(
|
|
||||||
this->type().data(), this->type().length(),
|
|
||||||
::google::protobuf::internal::WireFormat::SERIALIZE);
|
|
||||||
target =
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
|
|
||||||
1, this->type(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes indexdata = 2;
|
|
||||||
if (_has_bit(1)) {
|
|
||||||
target =
|
|
||||||
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
|
|
||||||
2, this->indexdata(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
// required int32 datasize = 3;
|
|
||||||
if (_has_bit(2)) {
|
|
||||||
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->datasize(), target);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!unknown_fields().empty()) {
|
|
||||||
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
|
|
||||||
unknown_fields(), target);
|
|
||||||
}
|
|
||||||
return target;
|
|
||||||
}
|
|
||||||
|
|
||||||
int BlobHeader::ByteSize() const {
|
|
||||||
int total_size = 0;
|
|
||||||
|
|
||||||
if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
|
|
||||||
// required string type = 1;
|
|
||||||
if (has_type()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::StringSize(
|
|
||||||
this->type());
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes indexdata = 2;
|
|
||||||
if (has_indexdata()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::BytesSize(
|
|
||||||
this->indexdata());
|
|
||||||
}
|
|
||||||
|
|
||||||
// required int32 datasize = 3;
|
|
||||||
if (has_datasize()) {
|
|
||||||
total_size += 1 +
|
|
||||||
::google::protobuf::internal::WireFormatLite::Int32Size(
|
|
||||||
this->datasize());
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
if (!unknown_fields().empty()) {
|
|
||||||
total_size +=
|
|
||||||
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
|
|
||||||
unknown_fields());
|
|
||||||
}
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
|
|
||||||
_cached_size_ = total_size;
|
|
||||||
GOOGLE_SAFE_CONCURRENT_WRITES_END();
|
|
||||||
return total_size;
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::MergeFrom(const ::google::protobuf::Message& from) {
|
|
||||||
GOOGLE_CHECK_NE(&from, this);
|
|
||||||
const BlobHeader* source =
|
|
||||||
::google::protobuf::internal::dynamic_cast_if_available<const BlobHeader*>(
|
|
||||||
&from);
|
|
||||||
if (source == NULL) {
|
|
||||||
::google::protobuf::internal::ReflectionOps::Merge(from, this);
|
|
||||||
} else {
|
|
||||||
MergeFrom(*source);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::MergeFrom(const BlobHeader& from) {
|
|
||||||
GOOGLE_CHECK_NE(&from, this);
|
|
||||||
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
|
|
||||||
if (from._has_bit(0)) {
|
|
||||||
set_type(from.type());
|
|
||||||
}
|
|
||||||
if (from._has_bit(1)) {
|
|
||||||
set_indexdata(from.indexdata());
|
|
||||||
}
|
|
||||||
if (from._has_bit(2)) {
|
|
||||||
set_datasize(from.datasize());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
mutable_unknown_fields()->MergeFrom(from.unknown_fields());
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::CopyFrom(const ::google::protobuf::Message& from) {
|
|
||||||
if (&from == this) return;
|
|
||||||
Clear();
|
|
||||||
MergeFrom(from);
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::CopyFrom(const BlobHeader& from) {
|
|
||||||
if (&from == this) return;
|
|
||||||
Clear();
|
|
||||||
MergeFrom(from);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool BlobHeader::IsInitialized() const {
|
|
||||||
if ((_has_bits_[0] & 0x00000005) != 0x00000005) return false;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
void BlobHeader::Swap(BlobHeader* other) {
|
|
||||||
if (other != this) {
|
|
||||||
std::swap(type_, other->type_);
|
|
||||||
std::swap(indexdata_, other->indexdata_);
|
|
||||||
std::swap(datasize_, other->datasize_);
|
|
||||||
std::swap(_has_bits_[0], other->_has_bits_[0]);
|
|
||||||
_unknown_fields_.Swap(&other->_unknown_fields_);
|
|
||||||
std::swap(_cached_size_, other->_cached_size_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
::google::protobuf::Metadata BlobHeader::GetMetadata() const {
|
|
||||||
protobuf_AssignDescriptorsOnce();
|
|
||||||
::google::protobuf::Metadata metadata;
|
|
||||||
metadata.descriptor = BlobHeader_descriptor_;
|
|
||||||
metadata.reflection = BlobHeader_reflection_;
|
|
||||||
return metadata;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(namespace_scope)
|
|
||||||
|
|
||||||
} // namespace OSMPBF
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(global_scope)
|
|
@ -1,599 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: fileformat.proto
|
|
||||||
|
|
||||||
#ifndef PROTOBUF_fileformat_2eproto__INCLUDED
|
|
||||||
#define PROTOBUF_fileformat_2eproto__INCLUDED
|
|
||||||
|
|
||||||
#include <string>
|
|
||||||
|
|
||||||
#include <google/protobuf/stubs/common.h>
|
|
||||||
|
|
||||||
#if GOOGLE_PROTOBUF_VERSION < 2003000
|
|
||||||
#error This file was generated by a newer version of protoc which is
|
|
||||||
#error incompatible with your Protocol Buffer headers. Please update
|
|
||||||
#error your headers.
|
|
||||||
#endif
|
|
||||||
#if 2003000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
|
|
||||||
#error This file was generated by an older version of protoc which is
|
|
||||||
#error incompatible with your Protocol Buffer headers. Please
|
|
||||||
#error regenerate this file with a newer version of protoc.
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <google/protobuf/generated_message_util.h>
|
|
||||||
#include <google/protobuf/repeated_field.h>
|
|
||||||
#include <google/protobuf/extension_set.h>
|
|
||||||
#include <google/protobuf/generated_message_reflection.h>
|
|
||||||
// @@protoc_insertion_point(includes)
|
|
||||||
|
|
||||||
namespace OSMPBF {
|
|
||||||
|
|
||||||
// Internal implementation detail -- do not call these.
|
|
||||||
void protobuf_AddDesc_fileformat_2eproto();
|
|
||||||
void protobuf_AssignDesc_fileformat_2eproto();
|
|
||||||
void protobuf_ShutdownFile_fileformat_2eproto();
|
|
||||||
|
|
||||||
class Blob;
|
|
||||||
class BlobHeader;
|
|
||||||
|
|
||||||
// ===================================================================
|
|
||||||
|
|
||||||
class Blob : public ::google::protobuf::Message {
|
|
||||||
public:
|
|
||||||
Blob();
|
|
||||||
virtual ~Blob();
|
|
||||||
|
|
||||||
Blob(const Blob& from);
|
|
||||||
|
|
||||||
inline Blob& operator=(const Blob& from) {
|
|
||||||
CopyFrom(from);
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const {
|
|
||||||
return _unknown_fields_;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() {
|
|
||||||
return &_unknown_fields_;
|
|
||||||
}
|
|
||||||
|
|
||||||
static const ::google::protobuf::Descriptor* descriptor();
|
|
||||||
static const Blob& default_instance();
|
|
||||||
|
|
||||||
void Swap(Blob* other);
|
|
||||||
|
|
||||||
// implements Message ----------------------------------------------
|
|
||||||
|
|
||||||
Blob* New() const;
|
|
||||||
void CopyFrom(const ::google::protobuf::Message& from);
|
|
||||||
void MergeFrom(const ::google::protobuf::Message& from);
|
|
||||||
void CopyFrom(const Blob& from);
|
|
||||||
void MergeFrom(const Blob& from);
|
|
||||||
void Clear();
|
|
||||||
bool IsInitialized() const;
|
|
||||||
|
|
||||||
int ByteSize() const;
|
|
||||||
bool MergePartialFromCodedStream(
|
|
||||||
::google::protobuf::io::CodedInputStream* input);
|
|
||||||
void SerializeWithCachedSizes(
|
|
||||||
::google::protobuf::io::CodedOutputStream* output) const;
|
|
||||||
::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf::uint8* output) const;
|
|
||||||
int GetCachedSize() const { return _cached_size_; }
|
|
||||||
private:
|
|
||||||
void SharedCtor();
|
|
||||||
void SharedDtor();
|
|
||||||
void SetCachedSize(int size) const;
|
|
||||||
public:
|
|
||||||
|
|
||||||
::google::protobuf::Metadata GetMetadata() const;
|
|
||||||
|
|
||||||
// nested types ----------------------------------------------------
|
|
||||||
|
|
||||||
// accessors -------------------------------------------------------
|
|
||||||
|
|
||||||
// optional bytes raw = 1;
|
|
||||||
inline bool has_raw() const;
|
|
||||||
inline void clear_raw();
|
|
||||||
static const int kRawFieldNumber = 1;
|
|
||||||
inline const ::std::string& raw() const;
|
|
||||||
inline void set_raw(const ::std::string& value);
|
|
||||||
inline void set_raw(const char* value);
|
|
||||||
inline void set_raw(const void* value, size_t size);
|
|
||||||
inline ::std::string* mutable_raw();
|
|
||||||
|
|
||||||
// optional int32 raw_size = 2;
|
|
||||||
inline bool has_raw_size() const;
|
|
||||||
inline void clear_raw_size();
|
|
||||||
static const int kRawSizeFieldNumber = 2;
|
|
||||||
inline ::google::protobuf::int32 raw_size() const;
|
|
||||||
inline void set_raw_size(::google::protobuf::int32 value);
|
|
||||||
|
|
||||||
// optional bytes zlib_data = 3;
|
|
||||||
inline bool has_zlib_data() const;
|
|
||||||
inline void clear_zlib_data();
|
|
||||||
static const int kZlibDataFieldNumber = 3;
|
|
||||||
inline const ::std::string& zlib_data() const;
|
|
||||||
inline void set_zlib_data(const ::std::string& value);
|
|
||||||
inline void set_zlib_data(const char* value);
|
|
||||||
inline void set_zlib_data(const void* value, size_t size);
|
|
||||||
inline ::std::string* mutable_zlib_data();
|
|
||||||
|
|
||||||
// optional bytes lzma_data = 4;
|
|
||||||
inline bool has_lzma_data() const;
|
|
||||||
inline void clear_lzma_data();
|
|
||||||
static const int kLzmaDataFieldNumber = 4;
|
|
||||||
inline const ::std::string& lzma_data() const;
|
|
||||||
inline void set_lzma_data(const ::std::string& value);
|
|
||||||
inline void set_lzma_data(const char* value);
|
|
||||||
inline void set_lzma_data(const void* value, size_t size);
|
|
||||||
inline ::std::string* mutable_lzma_data();
|
|
||||||
|
|
||||||
// optional bytes OBSOLETE_bzip2_data = 5 [deprecated = true];
|
|
||||||
inline bool has_obsolete_bzip2_data() const PROTOBUF_DEPRECATED;
|
|
||||||
inline void clear_obsolete_bzip2_data() PROTOBUF_DEPRECATED;
|
|
||||||
static const int kOBSOLETEBzip2DataFieldNumber = 5;
|
|
||||||
inline const ::std::string& obsolete_bzip2_data() const PROTOBUF_DEPRECATED;
|
|
||||||
inline void set_obsolete_bzip2_data(const ::std::string& value) PROTOBUF_DEPRECATED;
|
|
||||||
inline void set_obsolete_bzip2_data(const char* value) PROTOBUF_DEPRECATED;
|
|
||||||
inline void set_obsolete_bzip2_data(const void* value, size_t size) PROTOBUF_DEPRECATED;
|
|
||||||
inline ::std::string* mutable_obsolete_bzip2_data() PROTOBUF_DEPRECATED;
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:OSMPBF.Blob)
|
|
||||||
private:
|
|
||||||
::google::protobuf::UnknownFieldSet _unknown_fields_;
|
|
||||||
mutable int _cached_size_;
|
|
||||||
|
|
||||||
::std::string* raw_;
|
|
||||||
static const ::std::string _default_raw_;
|
|
||||||
::google::protobuf::int32 raw_size_;
|
|
||||||
::std::string* zlib_data_;
|
|
||||||
static const ::std::string _default_zlib_data_;
|
|
||||||
::std::string* lzma_data_;
|
|
||||||
static const ::std::string _default_lzma_data_;
|
|
||||||
::std::string* obsolete_bzip2_data_;
|
|
||||||
static const ::std::string _default_obsolete_bzip2_data_;
|
|
||||||
friend void protobuf_AddDesc_fileformat_2eproto();
|
|
||||||
friend void protobuf_AssignDesc_fileformat_2eproto();
|
|
||||||
friend void protobuf_ShutdownFile_fileformat_2eproto();
|
|
||||||
|
|
||||||
::google::protobuf::uint32 _has_bits_[(5 + 31) / 32];
|
|
||||||
|
|
||||||
// WHY DOES & HAVE LOWER PRECEDENCE THAN != !?
|
|
||||||
inline bool _has_bit(int index) const {
|
|
||||||
return (_has_bits_[index / 32] & (1u << (index % 32))) != 0;
|
|
||||||
}
|
|
||||||
inline void _set_bit(int index) {
|
|
||||||
_has_bits_[index / 32] |= (1u << (index % 32));
|
|
||||||
}
|
|
||||||
inline void _clear_bit(int index) {
|
|
||||||
_has_bits_[index / 32] &= ~(1u << (index % 32));
|
|
||||||
}
|
|
||||||
|
|
||||||
void InitAsDefaultInstance();
|
|
||||||
static Blob* default_instance_;
|
|
||||||
};
|
|
||||||
// -------------------------------------------------------------------
|
|
||||||
|
|
||||||
class BlobHeader : public ::google::protobuf::Message {
|
|
||||||
public:
|
|
||||||
BlobHeader();
|
|
||||||
virtual ~BlobHeader();
|
|
||||||
|
|
||||||
BlobHeader(const BlobHeader& from);
|
|
||||||
|
|
||||||
inline BlobHeader& operator=(const BlobHeader& from) {
|
|
||||||
CopyFrom(from);
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const {
|
|
||||||
return _unknown_fields_;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() {
|
|
||||||
return &_unknown_fields_;
|
|
||||||
}
|
|
||||||
|
|
||||||
static const ::google::protobuf::Descriptor* descriptor();
|
|
||||||
static const BlobHeader& default_instance();
|
|
||||||
|
|
||||||
void Swap(BlobHeader* other);
|
|
||||||
|
|
||||||
// implements Message ----------------------------------------------
|
|
||||||
|
|
||||||
BlobHeader* New() const;
|
|
||||||
void CopyFrom(const ::google::protobuf::Message& from);
|
|
||||||
void MergeFrom(const ::google::protobuf::Message& from);
|
|
||||||
void CopyFrom(const BlobHeader& from);
|
|
||||||
void MergeFrom(const BlobHeader& from);
|
|
||||||
void Clear();
|
|
||||||
bool IsInitialized() const;
|
|
||||||
|
|
||||||
int ByteSize() const;
|
|
||||||
bool MergePartialFromCodedStream(
|
|
||||||
::google::protobuf::io::CodedInputStream* input);
|
|
||||||
void SerializeWithCachedSizes(
|
|
||||||
::google::protobuf::io::CodedOutputStream* output) const;
|
|
||||||
::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf::uint8* output) const;
|
|
||||||
int GetCachedSize() const { return _cached_size_; }
|
|
||||||
private:
|
|
||||||
void SharedCtor();
|
|
||||||
void SharedDtor();
|
|
||||||
void SetCachedSize(int size) const;
|
|
||||||
public:
|
|
||||||
|
|
||||||
::google::protobuf::Metadata GetMetadata() const;
|
|
||||||
|
|
||||||
// nested types ----------------------------------------------------
|
|
||||||
|
|
||||||
// accessors -------------------------------------------------------
|
|
||||||
|
|
||||||
// required string type = 1;
|
|
||||||
inline bool has_type() const;
|
|
||||||
inline void clear_type();
|
|
||||||
static const int kTypeFieldNumber = 1;
|
|
||||||
inline const ::std::string& type() const;
|
|
||||||
inline void set_type(const ::std::string& value);
|
|
||||||
inline void set_type(const char* value);
|
|
||||||
inline void set_type(const char* value, size_t size);
|
|
||||||
inline ::std::string* mutable_type();
|
|
||||||
|
|
||||||
// optional bytes indexdata = 2;
|
|
||||||
inline bool has_indexdata() const;
|
|
||||||
inline void clear_indexdata();
|
|
||||||
static const int kIndexdataFieldNumber = 2;
|
|
||||||
inline const ::std::string& indexdata() const;
|
|
||||||
inline void set_indexdata(const ::std::string& value);
|
|
||||||
inline void set_indexdata(const char* value);
|
|
||||||
inline void set_indexdata(const void* value, size_t size);
|
|
||||||
inline ::std::string* mutable_indexdata();
|
|
||||||
|
|
||||||
// required int32 datasize = 3;
|
|
||||||
inline bool has_datasize() const;
|
|
||||||
inline void clear_datasize();
|
|
||||||
static const int kDatasizeFieldNumber = 3;
|
|
||||||
inline ::google::protobuf::int32 datasize() const;
|
|
||||||
inline void set_datasize(::google::protobuf::int32 value);
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:OSMPBF.BlobHeader)
|
|
||||||
private:
|
|
||||||
::google::protobuf::UnknownFieldSet _unknown_fields_;
|
|
||||||
mutable int _cached_size_;
|
|
||||||
|
|
||||||
::std::string* type_;
|
|
||||||
static const ::std::string _default_type_;
|
|
||||||
::std::string* indexdata_;
|
|
||||||
static const ::std::string _default_indexdata_;
|
|
||||||
::google::protobuf::int32 datasize_;
|
|
||||||
friend void protobuf_AddDesc_fileformat_2eproto();
|
|
||||||
friend void protobuf_AssignDesc_fileformat_2eproto();
|
|
||||||
friend void protobuf_ShutdownFile_fileformat_2eproto();
|
|
||||||
|
|
||||||
::google::protobuf::uint32 _has_bits_[(3 + 31) / 32];
|
|
||||||
|
|
||||||
// WHY DOES & HAVE LOWER PRECEDENCE THAN != !?
|
|
||||||
inline bool _has_bit(int index) const {
|
|
||||||
return (_has_bits_[index / 32] & (1u << (index % 32))) != 0;
|
|
||||||
}
|
|
||||||
inline void _set_bit(int index) {
|
|
||||||
_has_bits_[index / 32] |= (1u << (index % 32));
|
|
||||||
}
|
|
||||||
inline void _clear_bit(int index) {
|
|
||||||
_has_bits_[index / 32] &= ~(1u << (index % 32));
|
|
||||||
}
|
|
||||||
|
|
||||||
void InitAsDefaultInstance();
|
|
||||||
static BlobHeader* default_instance_;
|
|
||||||
};
|
|
||||||
// ===================================================================
|
|
||||||
|
|
||||||
|
|
||||||
// ===================================================================
|
|
||||||
|
|
||||||
// Blob
|
|
||||||
|
|
||||||
// optional bytes raw = 1;
|
|
||||||
inline bool Blob::has_raw() const {
|
|
||||||
return _has_bit(0);
|
|
||||||
}
|
|
||||||
inline void Blob::clear_raw() {
|
|
||||||
if (raw_ != &_default_raw_) {
|
|
||||||
raw_->clear();
|
|
||||||
}
|
|
||||||
_clear_bit(0);
|
|
||||||
}
|
|
||||||
inline const ::std::string& Blob::raw() const {
|
|
||||||
return *raw_;
|
|
||||||
}
|
|
||||||
inline void Blob::set_raw(const ::std::string& value) {
|
|
||||||
_set_bit(0);
|
|
||||||
if (raw_ == &_default_raw_) {
|
|
||||||
raw_ = new ::std::string;
|
|
||||||
}
|
|
||||||
raw_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_raw(const char* value) {
|
|
||||||
_set_bit(0);
|
|
||||||
if (raw_ == &_default_raw_) {
|
|
||||||
raw_ = new ::std::string;
|
|
||||||
}
|
|
||||||
raw_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_raw(const void* value, size_t size) {
|
|
||||||
_set_bit(0);
|
|
||||||
if (raw_ == &_default_raw_) {
|
|
||||||
raw_ = new ::std::string;
|
|
||||||
}
|
|
||||||
raw_->assign(reinterpret_cast<const char*>(value), size);
|
|
||||||
}
|
|
||||||
inline ::std::string* Blob::mutable_raw() {
|
|
||||||
_set_bit(0);
|
|
||||||
if (raw_ == &_default_raw_) {
|
|
||||||
raw_ = new ::std::string;
|
|
||||||
}
|
|
||||||
return raw_;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional int32 raw_size = 2;
|
|
||||||
inline bool Blob::has_raw_size() const {
|
|
||||||
return _has_bit(1);
|
|
||||||
}
|
|
||||||
inline void Blob::clear_raw_size() {
|
|
||||||
raw_size_ = 0;
|
|
||||||
_clear_bit(1);
|
|
||||||
}
|
|
||||||
inline ::google::protobuf::int32 Blob::raw_size() const {
|
|
||||||
return raw_size_;
|
|
||||||
}
|
|
||||||
inline void Blob::set_raw_size(::google::protobuf::int32 value) {
|
|
||||||
_set_bit(1);
|
|
||||||
raw_size_ = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes zlib_data = 3;
|
|
||||||
inline bool Blob::has_zlib_data() const {
|
|
||||||
return _has_bit(2);
|
|
||||||
}
|
|
||||||
inline void Blob::clear_zlib_data() {
|
|
||||||
if (zlib_data_ != &_default_zlib_data_) {
|
|
||||||
zlib_data_->clear();
|
|
||||||
}
|
|
||||||
_clear_bit(2);
|
|
||||||
}
|
|
||||||
inline const ::std::string& Blob::zlib_data() const {
|
|
||||||
return *zlib_data_;
|
|
||||||
}
|
|
||||||
inline void Blob::set_zlib_data(const ::std::string& value) {
|
|
||||||
_set_bit(2);
|
|
||||||
if (zlib_data_ == &_default_zlib_data_) {
|
|
||||||
zlib_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
zlib_data_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_zlib_data(const char* value) {
|
|
||||||
_set_bit(2);
|
|
||||||
if (zlib_data_ == &_default_zlib_data_) {
|
|
||||||
zlib_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
zlib_data_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_zlib_data(const void* value, size_t size) {
|
|
||||||
_set_bit(2);
|
|
||||||
if (zlib_data_ == &_default_zlib_data_) {
|
|
||||||
zlib_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
zlib_data_->assign(reinterpret_cast<const char*>(value), size);
|
|
||||||
}
|
|
||||||
inline ::std::string* Blob::mutable_zlib_data() {
|
|
||||||
_set_bit(2);
|
|
||||||
if (zlib_data_ == &_default_zlib_data_) {
|
|
||||||
zlib_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
return zlib_data_;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes lzma_data = 4;
|
|
||||||
inline bool Blob::has_lzma_data() const {
|
|
||||||
return _has_bit(3);
|
|
||||||
}
|
|
||||||
inline void Blob::clear_lzma_data() {
|
|
||||||
if (lzma_data_ != &_default_lzma_data_) {
|
|
||||||
lzma_data_->clear();
|
|
||||||
}
|
|
||||||
_clear_bit(3);
|
|
||||||
}
|
|
||||||
inline const ::std::string& Blob::lzma_data() const {
|
|
||||||
return *lzma_data_;
|
|
||||||
}
|
|
||||||
inline void Blob::set_lzma_data(const ::std::string& value) {
|
|
||||||
_set_bit(3);
|
|
||||||
if (lzma_data_ == &_default_lzma_data_) {
|
|
||||||
lzma_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
lzma_data_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_lzma_data(const char* value) {
|
|
||||||
_set_bit(3);
|
|
||||||
if (lzma_data_ == &_default_lzma_data_) {
|
|
||||||
lzma_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
lzma_data_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_lzma_data(const void* value, size_t size) {
|
|
||||||
_set_bit(3);
|
|
||||||
if (lzma_data_ == &_default_lzma_data_) {
|
|
||||||
lzma_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
lzma_data_->assign(reinterpret_cast<const char*>(value), size);
|
|
||||||
}
|
|
||||||
inline ::std::string* Blob::mutable_lzma_data() {
|
|
||||||
_set_bit(3);
|
|
||||||
if (lzma_data_ == &_default_lzma_data_) {
|
|
||||||
lzma_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
return lzma_data_;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes OBSOLETE_bzip2_data = 5 [deprecated = true];
|
|
||||||
inline bool Blob::has_obsolete_bzip2_data() const {
|
|
||||||
return _has_bit(4);
|
|
||||||
}
|
|
||||||
inline void Blob::clear_obsolete_bzip2_data() {
|
|
||||||
if (obsolete_bzip2_data_ != &_default_obsolete_bzip2_data_) {
|
|
||||||
obsolete_bzip2_data_->clear();
|
|
||||||
}
|
|
||||||
_clear_bit(4);
|
|
||||||
}
|
|
||||||
inline const ::std::string& Blob::obsolete_bzip2_data() const {
|
|
||||||
return *obsolete_bzip2_data_;
|
|
||||||
}
|
|
||||||
inline void Blob::set_obsolete_bzip2_data(const ::std::string& value) {
|
|
||||||
_set_bit(4);
|
|
||||||
if (obsolete_bzip2_data_ == &_default_obsolete_bzip2_data_) {
|
|
||||||
obsolete_bzip2_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
obsolete_bzip2_data_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_obsolete_bzip2_data(const char* value) {
|
|
||||||
_set_bit(4);
|
|
||||||
if (obsolete_bzip2_data_ == &_default_obsolete_bzip2_data_) {
|
|
||||||
obsolete_bzip2_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
obsolete_bzip2_data_->assign(value);
|
|
||||||
}
|
|
||||||
inline void Blob::set_obsolete_bzip2_data(const void* value, size_t size) {
|
|
||||||
_set_bit(4);
|
|
||||||
if (obsolete_bzip2_data_ == &_default_obsolete_bzip2_data_) {
|
|
||||||
obsolete_bzip2_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
obsolete_bzip2_data_->assign(reinterpret_cast<const char*>(value), size);
|
|
||||||
}
|
|
||||||
inline ::std::string* Blob::mutable_obsolete_bzip2_data() {
|
|
||||||
_set_bit(4);
|
|
||||||
if (obsolete_bzip2_data_ == &_default_obsolete_bzip2_data_) {
|
|
||||||
obsolete_bzip2_data_ = new ::std::string;
|
|
||||||
}
|
|
||||||
return obsolete_bzip2_data_;
|
|
||||||
}
|
|
||||||
|
|
||||||
// -------------------------------------------------------------------
|
|
||||||
|
|
||||||
// BlobHeader
|
|
||||||
|
|
||||||
// required string type = 1;
|
|
||||||
inline bool BlobHeader::has_type() const {
|
|
||||||
return _has_bit(0);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::clear_type() {
|
|
||||||
if (type_ != &_default_type_) {
|
|
||||||
type_->clear();
|
|
||||||
}
|
|
||||||
_clear_bit(0);
|
|
||||||
}
|
|
||||||
inline const ::std::string& BlobHeader::type() const {
|
|
||||||
return *type_;
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_type(const ::std::string& value) {
|
|
||||||
_set_bit(0);
|
|
||||||
if (type_ == &_default_type_) {
|
|
||||||
type_ = new ::std::string;
|
|
||||||
}
|
|
||||||
type_->assign(value);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_type(const char* value) {
|
|
||||||
_set_bit(0);
|
|
||||||
if (type_ == &_default_type_) {
|
|
||||||
type_ = new ::std::string;
|
|
||||||
}
|
|
||||||
type_->assign(value);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_type(const char* value, size_t size) {
|
|
||||||
_set_bit(0);
|
|
||||||
if (type_ == &_default_type_) {
|
|
||||||
type_ = new ::std::string;
|
|
||||||
}
|
|
||||||
type_->assign(reinterpret_cast<const char*>(value), size);
|
|
||||||
}
|
|
||||||
inline ::std::string* BlobHeader::mutable_type() {
|
|
||||||
_set_bit(0);
|
|
||||||
if (type_ == &_default_type_) {
|
|
||||||
type_ = new ::std::string;
|
|
||||||
}
|
|
||||||
return type_;
|
|
||||||
}
|
|
||||||
|
|
||||||
// optional bytes indexdata = 2;
|
|
||||||
inline bool BlobHeader::has_indexdata() const {
|
|
||||||
return _has_bit(1);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::clear_indexdata() {
|
|
||||||
if (indexdata_ != &_default_indexdata_) {
|
|
||||||
indexdata_->clear();
|
|
||||||
}
|
|
||||||
_clear_bit(1);
|
|
||||||
}
|
|
||||||
inline const ::std::string& BlobHeader::indexdata() const {
|
|
||||||
return *indexdata_;
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_indexdata(const ::std::string& value) {
|
|
||||||
_set_bit(1);
|
|
||||||
if (indexdata_ == &_default_indexdata_) {
|
|
||||||
indexdata_ = new ::std::string;
|
|
||||||
}
|
|
||||||
indexdata_->assign(value);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_indexdata(const char* value) {
|
|
||||||
_set_bit(1);
|
|
||||||
if (indexdata_ == &_default_indexdata_) {
|
|
||||||
indexdata_ = new ::std::string;
|
|
||||||
}
|
|
||||||
indexdata_->assign(value);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_indexdata(const void* value, size_t size) {
|
|
||||||
_set_bit(1);
|
|
||||||
if (indexdata_ == &_default_indexdata_) {
|
|
||||||
indexdata_ = new ::std::string;
|
|
||||||
}
|
|
||||||
indexdata_->assign(reinterpret_cast<const char*>(value), size);
|
|
||||||
}
|
|
||||||
inline ::std::string* BlobHeader::mutable_indexdata() {
|
|
||||||
_set_bit(1);
|
|
||||||
if (indexdata_ == &_default_indexdata_) {
|
|
||||||
indexdata_ = new ::std::string;
|
|
||||||
}
|
|
||||||
return indexdata_;
|
|
||||||
}
|
|
||||||
|
|
||||||
// required int32 datasize = 3;
|
|
||||||
inline bool BlobHeader::has_datasize() const {
|
|
||||||
return _has_bit(2);
|
|
||||||
}
|
|
||||||
inline void BlobHeader::clear_datasize() {
|
|
||||||
datasize_ = 0;
|
|
||||||
_clear_bit(2);
|
|
||||||
}
|
|
||||||
inline ::google::protobuf::int32 BlobHeader::datasize() const {
|
|
||||||
return datasize_;
|
|
||||||
}
|
|
||||||
inline void BlobHeader::set_datasize(::google::protobuf::int32 value) {
|
|
||||||
_set_bit(2);
|
|
||||||
datasize_ = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(namespace_scope)
|
|
||||||
|
|
||||||
} // namespace OSMPBF
|
|
||||||
|
|
||||||
#ifndef SWIG
|
|
||||||
namespace google {
|
|
||||||
namespace protobuf {
|
|
||||||
|
|
||||||
|
|
||||||
} // namespace google
|
|
||||||
} // namespace protobuf
|
|
||||||
#endif // SWIG
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(global_scope)
|
|
||||||
|
|
||||||
#endif // PROTOBUF_fileformat_2eproto__INCLUDED
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
61
SConstruct
61
SConstruct
@ -3,6 +3,51 @@
|
|||||||
import os
|
import os
|
||||||
import os.path
|
import os.path
|
||||||
import sys
|
import sys
|
||||||
|
from subprocess import call
|
||||||
|
|
||||||
|
def CheckBoost(context, version):
|
||||||
|
# Boost versions are in format major.minor.subminor
|
||||||
|
v_arr = version.split(".")
|
||||||
|
version_n = 0
|
||||||
|
if len(v_arr) > 0:
|
||||||
|
version_n += int(v_arr[0])*100000
|
||||||
|
if len(v_arr) > 1:
|
||||||
|
version_n += int(v_arr[1])*100
|
||||||
|
if len(v_arr) > 2:
|
||||||
|
version_n += int(v_arr[2])
|
||||||
|
|
||||||
|
context.Message('Checking for Boost version >= %s... ' % (version))
|
||||||
|
ret = context.TryRun("""
|
||||||
|
#include <boost/version.hpp>
|
||||||
|
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
return BOOST_VERSION >= %d ? 0 : 1;
|
||||||
|
}
|
||||||
|
""" % version_n, '.cpp')[0]
|
||||||
|
context.Result(ret)
|
||||||
|
return ret
|
||||||
|
|
||||||
|
def CheckProtobuf(context, version):
|
||||||
|
# Protobuf versions are in format major.minor.subminor
|
||||||
|
v_arr = version.split(".")
|
||||||
|
version_n = 0
|
||||||
|
if len(v_arr) > 0:
|
||||||
|
version_n += int(v_arr[0])*1000000
|
||||||
|
if len(v_arr) > 1:
|
||||||
|
version_n += int(v_arr[1])*1000
|
||||||
|
if len(v_arr) > 2:
|
||||||
|
version_n += int(v_arr[2])
|
||||||
|
|
||||||
|
context.Message('Checking for Protobuffer version >= %s... ' % (version))
|
||||||
|
ret = context.TryRun("""
|
||||||
|
#include <google/protobuf/stubs/common.h>
|
||||||
|
int main() {
|
||||||
|
return (GOOGLE_PROTOBUF_VERSION >= %d) ? 0 : 1;
|
||||||
|
}
|
||||||
|
""" % version_n, '.cpp')[0]
|
||||||
|
context.Result(ret)
|
||||||
|
return ret
|
||||||
|
|
||||||
AddOption('--cxx', dest='cxx', type='string', nargs=1, action='store', metavar='STRING', help='C++ Compiler')
|
AddOption('--cxx', dest='cxx', type='string', nargs=1, action='store', metavar='STRING', help='C++ Compiler')
|
||||||
AddOption('--stxxlroot', dest='stxxlroot', type='string', nargs=1, action='store', metavar='STRING', help='root directory of STXXL')
|
AddOption('--stxxlroot', dest='stxxlroot', type='string', nargs=1, action='store', metavar='STRING', help='root directory of STXXL')
|
||||||
@ -35,7 +80,7 @@ if GetOption('buildconfiguration') == 'debug':
|
|||||||
else:
|
else:
|
||||||
env.Append(CCFLAGS = ' -O3 -DNDEBUG -march=native')
|
env.Append(CCFLAGS = ' -O3 -DNDEBUG -march=native')
|
||||||
#print "Compiling with: ", env['CXX']
|
#print "Compiling with: ", env['CXX']
|
||||||
conf = Configure(env)
|
conf = Configure(env, custom_tests = { 'CheckBoost' : CheckBoost, 'CheckProtobuf' : CheckProtobuf })
|
||||||
if not conf.CheckHeader('omp.h'):
|
if not conf.CheckHeader('omp.h'):
|
||||||
print "Compiler does not support OpenMP. Exiting"
|
print "Compiler does not support OpenMP. Exiting"
|
||||||
Exit(-1)
|
Exit(-1)
|
||||||
@ -88,9 +133,23 @@ if not conf.CheckLibWithHeader('protobuf', 'google/protobuf/descriptor.h', 'CXX'
|
|||||||
Exit(-1)
|
Exit(-1)
|
||||||
#if os.sysconf('SC_NPROCESSORS_ONLN') > 1:
|
#if os.sysconf('SC_NPROCESSORS_ONLN') > 1:
|
||||||
# env.Append(CCFLAGS = ' -D_GLIBCXX_PARALLEL');
|
# env.Append(CCFLAGS = ' -D_GLIBCXX_PARALLEL');
|
||||||
|
if not (conf.CheckBoost('1.37')):
|
||||||
|
print 'Boost version >= 1.37 needed'
|
||||||
|
Exit(-1);
|
||||||
|
#check for protobuf 2.3.0, else rebuild proto files
|
||||||
|
if not (conf.CheckProtobuf('2.3.0')):
|
||||||
|
if not (env.Detect('protoc')):
|
||||||
|
print 'protobuffer compiler not found'
|
||||||
|
Exit(-1);
|
||||||
|
|
||||||
|
protobld = Builder(action = 'protoc -I=DataStructures/pbf-proto --cpp_out=DataStructures/pbf-proto $SOURCE')
|
||||||
|
env.Append(BUILDERS = {'Protobuf' : protobld})
|
||||||
|
env.Protobuf('DataStructures/pbf-proto/fileformat.proto')
|
||||||
|
env.Protobuf('DataStructures/pbf-proto/osmformat.proto')
|
||||||
env.Append(CCFLAGS = ' -fopenmp')
|
env.Append(CCFLAGS = ' -fopenmp')
|
||||||
env.Append(LINKFLAGS = ' -fopenmp')
|
env.Append(LINKFLAGS = ' -fopenmp')
|
||||||
|
|
||||||
|
|
||||||
env.StaticObject("DataStructures/pbf-proto/fileformat.pb.cc")
|
env.StaticObject("DataStructures/pbf-proto/fileformat.pb.cc")
|
||||||
env.StaticObject("DataStructures/pbf-proto/osmformat.pb.cc")
|
env.StaticObject("DataStructures/pbf-proto/osmformat.pb.cc")
|
||||||
env.Program("extractor.cpp")
|
env.Program("extractor.cpp")
|
||||||
|
Loading…
Reference in New Issue
Block a user