Browse Source

2021 1103 楚天车位管理 增加手动查询车位消息

wk 3 years ago
parent
commit
5d2952553d

+ 16 - 16
CMakeLists.txt

@@ -13,7 +13,6 @@ FIND_PACKAGE(PCL REQUIRED)
 
 include_directories(
         /usr/local/include
-        ${PCL_INCLUDE_DIRS}
         ${OpenCV_INCLUDE_DIRS}
         ${PROTOBUF_INCLUDE_DIRS}
         communication
@@ -50,22 +49,23 @@ target_link_libraries(parkspace_test
         /usr/local/lib/libglog.a
         /usr/local/lib/libgflags.a
         libmysqlcppconn.so
+        -lpthread
         )
-add_executable(parkspace_client
-        ./test/parkspace_client.cpp
-        ${error_src}
-        ${message_src}
-        ${TOOL_SRC}
-        ${COMMUNICATION_SRC}
-        )
-target_link_libraries(parkspace_client
-        nnxx
-        nanomsg
-        ${PROTOBUF_LIBRARIES}
-        ${PCL_LIBRARIES}
-        /usr/local/lib/libglog.a
-        /usr/local/lib/libgflags.a
-        )
+#add_executable(parkspace_client
+#        ./test/parkspace_client.cpp
+#        ${error_src}
+#        ${message_src}
+#       ${TOOL_SRC}
+#       ${COMMUNICATION_SRC}
+#       )
+#target_link_libraries(parkspace_client
+#       nnxx
+#       nanomsg
+#       ${PROTOBUF_LIBRARIES}
+#       ${PCL_LIBRARIES}
+#       /usr/local/lib/libglog.a
+#      /usr/local/lib/libgflags.a
+#      )
 
 ## db test
 #add_executable(db_test

+ 77 - 50
communication/communication.pb.cc

@@ -7,6 +7,7 @@
 
 #include <google/protobuf/stubs/common.h>
 #include <google/protobuf/stubs/port.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>
@@ -18,10 +19,6 @@
 #include "third_party/protobuf/version.h"
 #endif
 // @@protoc_insertion_point(includes)
-
-namespace protobuf_communication_2eproto {
-extern PROTOBUF_INTERNAL_EXPORT_protobuf_communication_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Communication_parameter;
-}  // namespace protobuf_communication_2eproto
 namespace Communication_proto {
 class Communication_parameterDefaultTypeInternal {
  public:
@@ -35,9 +32,14 @@ class Communication_parameter_allDefaultTypeInternal {
 } _Communication_parameter_all_default_instance_;
 }  // namespace Communication_proto
 namespace protobuf_communication_2eproto {
-static void InitDefaultsCommunication_parameter() {
+void InitDefaultsCommunication_parameterImpl() {
   GOOGLE_PROTOBUF_VERIFY_VERSION;
 
+#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
+  ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
+#else
+  ::google::protobuf::internal::InitProtobufDefaults();
+#endif  // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
   {
     void* ptr = &::Communication_proto::_Communication_parameter_default_instance_;
     new (ptr) ::Communication_proto::Communication_parameter();
@@ -46,12 +48,20 @@ static void InitDefaultsCommunication_parameter() {
   ::Communication_proto::Communication_parameter::InitAsDefaultInstance();
 }
 
-::google::protobuf::internal::SCCInfo<0> scc_info_Communication_parameter =
-    {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsCommunication_parameter}, {}};
+void InitDefaultsCommunication_parameter() {
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsCommunication_parameterImpl);
+}
 
-static void InitDefaultsCommunication_parameter_all() {
+void InitDefaultsCommunication_parameter_allImpl() {
   GOOGLE_PROTOBUF_VERIFY_VERSION;
 
+#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
+  ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
+#else
+  ::google::protobuf::internal::InitProtobufDefaults();
+#endif  // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
+  protobuf_communication_2eproto::InitDefaultsCommunication_parameter();
   {
     void* ptr = &::Communication_proto::_Communication_parameter_all_default_instance_;
     new (ptr) ::Communication_proto::Communication_parameter_all();
@@ -60,13 +70,9 @@ static void InitDefaultsCommunication_parameter_all() {
   ::Communication_proto::Communication_parameter_all::InitAsDefaultInstance();
 }
 
-::google::protobuf::internal::SCCInfo<1> scc_info_Communication_parameter_all =
-    {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsCommunication_parameter_all}, {
-      &protobuf_communication_2eproto::scc_info_Communication_parameter.base,}};
-
-void InitDefaults() {
-  ::google::protobuf::internal::InitSCC(&scc_info_Communication_parameter.base);
-  ::google::protobuf::internal::InitSCC(&scc_info_Communication_parameter_all.base);
+void InitDefaultsCommunication_parameter_all() {
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsCommunication_parameter_allImpl);
 }
 
 ::google::protobuf::Metadata file_level_metadata[2];
@@ -101,14 +107,15 @@ static ::google::protobuf::Message const * const file_default_instances[] = {
 
 void protobuf_AssignDescriptors() {
   AddDescriptors();
+  ::google::protobuf::MessageFactory* factory = NULL;
   AssignDescriptors(
-      "communication.proto", schemas, file_default_instances, TableStruct::offsets,
+      "communication.proto", schemas, file_default_instances, TableStruct::offsets, factory,
       file_level_metadata, NULL, NULL);
 }
 
 void protobuf_AssignDescriptorsOnce() {
-  static ::google::protobuf::internal::once_flag once;
-  ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors);
 }
 
 void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
@@ -134,8 +141,8 @@ void AddDescriptorsImpl() {
 }
 
 void AddDescriptors() {
-  static ::google::protobuf::internal::once_flag once;
-  ::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
 }
 // Force AddDescriptors() to be called at dynamic initialization time.
 struct StaticDescriptorInitializer {
@@ -157,8 +164,9 @@ const int Communication_parameter::kConnectStringVectorFieldNumber;
 
 Communication_parameter::Communication_parameter()
   : ::google::protobuf::Message(), _internal_metadata_(NULL) {
-  ::google::protobuf::internal::InitSCC(
-      &protobuf_communication_2eproto::scc_info_Communication_parameter.base);
+  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
+    ::protobuf_communication_2eproto::InitDefaultsCommunication_parameter();
+  }
   SharedCtor();
   // @@protoc_insertion_point(constructor:Communication_proto.Communication_parameter)
 }
@@ -166,6 +174,7 @@ Communication_parameter::Communication_parameter(const Communication_parameter&
   : ::google::protobuf::Message(),
       _internal_metadata_(NULL),
       _has_bits_(from._has_bits_),
+      _cached_size_(0),
       connect_string_vector_(from.connect_string_vector_) {
   _internal_metadata_.MergeFrom(from._internal_metadata_);
   bind_string_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
@@ -176,6 +185,7 @@ Communication_parameter::Communication_parameter(const Communication_parameter&
 }
 
 void Communication_parameter::SharedCtor() {
+  _cached_size_ = 0;
   bind_string_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 
@@ -189,7 +199,9 @@ void Communication_parameter::SharedDtor() {
 }
 
 void Communication_parameter::SetCachedSize(int size) const {
-  _cached_size_.Set(size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
 }
 const ::google::protobuf::Descriptor* Communication_parameter::descriptor() {
   ::protobuf_communication_2eproto::protobuf_AssignDescriptorsOnce();
@@ -197,10 +209,17 @@ const ::google::protobuf::Descriptor* Communication_parameter::descriptor() {
 }
 
 const Communication_parameter& Communication_parameter::default_instance() {
-  ::google::protobuf::internal::InitSCC(&protobuf_communication_2eproto::scc_info_Communication_parameter.base);
+  ::protobuf_communication_2eproto::InitDefaultsCommunication_parameter();
   return *internal_default_instance();
 }
 
+Communication_parameter* Communication_parameter::New(::google::protobuf::Arena* arena) const {
+  Communication_parameter* n = new Communication_parameter;
+  if (arena != NULL) {
+    arena->Own(n);
+  }
+  return n;
+}
 
 void Communication_parameter::Clear() {
 // @@protoc_insertion_point(message_clear_start:Communication_proto.Communication_parameter)
@@ -211,7 +230,8 @@ void Communication_parameter::Clear() {
   connect_string_vector_.Clear();
   cached_has_bits = _has_bits_[0];
   if (cached_has_bits & 0x00000001u) {
-    bind_string_.ClearNonDefaultToEmptyNoArena();
+    GOOGLE_DCHECK(!bind_string_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
+    (*bind_string_.UnsafeRawStringPointer())->clear();
   }
   _has_bits_.Clear();
   _internal_metadata_.Clear();
@@ -223,7 +243,7 @@ bool Communication_parameter::MergePartialFromCodedStream(
   ::google::protobuf::uint32 tag;
   // @@protoc_insertion_point(parse_start:Communication_proto.Communication_parameter)
   for (;;) {
-    ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
     tag = p.first;
     if (!p.second) goto handle_unusual;
     switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -376,7 +396,9 @@ size_t Communication_parameter::ByteSizeLong() const {
   }
 
   int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
-  SetCachedSize(cached_size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = cached_size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
   return total_size;
 }
 
@@ -433,11 +455,11 @@ void Communication_parameter::Swap(Communication_parameter* other) {
 }
 void Communication_parameter::InternalSwap(Communication_parameter* other) {
   using std::swap;
-  connect_string_vector_.InternalSwap(CastToBase(&other->connect_string_vector_));
-  bind_string_.Swap(&other->bind_string_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
-    GetArenaNoVirtual());
+  connect_string_vector_.InternalSwap(&other->connect_string_vector_);
+  bind_string_.Swap(&other->bind_string_);
   swap(_has_bits_[0], other->_has_bits_[0]);
   _internal_metadata_.Swap(&other->_internal_metadata_);
+  swap(_cached_size_, other->_cached_size_);
 }
 
 ::google::protobuf::Metadata Communication_parameter::GetMetadata() const {
@@ -458,15 +480,17 @@ const int Communication_parameter_all::kCommunicationParametersFieldNumber;
 
 Communication_parameter_all::Communication_parameter_all()
   : ::google::protobuf::Message(), _internal_metadata_(NULL) {
-  ::google::protobuf::internal::InitSCC(
-      &protobuf_communication_2eproto::scc_info_Communication_parameter_all.base);
+  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
+    ::protobuf_communication_2eproto::InitDefaultsCommunication_parameter_all();
+  }
   SharedCtor();
   // @@protoc_insertion_point(constructor:Communication_proto.Communication_parameter_all)
 }
 Communication_parameter_all::Communication_parameter_all(const Communication_parameter_all& from)
   : ::google::protobuf::Message(),
       _internal_metadata_(NULL),
-      _has_bits_(from._has_bits_) {
+      _has_bits_(from._has_bits_),
+      _cached_size_(0) {
   _internal_metadata_.MergeFrom(from._internal_metadata_);
   if (from.has_communication_parameters()) {
     communication_parameters_ = new ::Communication_proto::Communication_parameter(*from.communication_parameters_);
@@ -477,6 +501,7 @@ Communication_parameter_all::Communication_parameter_all(const Communication_par
 }
 
 void Communication_parameter_all::SharedCtor() {
+  _cached_size_ = 0;
   communication_parameters_ = NULL;
 }
 
@@ -490,7 +515,9 @@ void Communication_parameter_all::SharedDtor() {
 }
 
 void Communication_parameter_all::SetCachedSize(int size) const {
-  _cached_size_.Set(size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
 }
 const ::google::protobuf::Descriptor* Communication_parameter_all::descriptor() {
   ::protobuf_communication_2eproto::protobuf_AssignDescriptorsOnce();
@@ -498,10 +525,17 @@ const ::google::protobuf::Descriptor* Communication_parameter_all::descriptor()
 }
 
 const Communication_parameter_all& Communication_parameter_all::default_instance() {
-  ::google::protobuf::internal::InitSCC(&protobuf_communication_2eproto::scc_info_Communication_parameter_all.base);
+  ::protobuf_communication_2eproto::InitDefaultsCommunication_parameter_all();
   return *internal_default_instance();
 }
 
+Communication_parameter_all* Communication_parameter_all::New(::google::protobuf::Arena* arena) const {
+  Communication_parameter_all* n = new Communication_parameter_all;
+  if (arena != NULL) {
+    arena->Own(n);
+  }
+  return n;
+}
 
 void Communication_parameter_all::Clear() {
 // @@protoc_insertion_point(message_clear_start:Communication_proto.Communication_parameter_all)
@@ -524,7 +558,7 @@ bool Communication_parameter_all::MergePartialFromCodedStream(
   ::google::protobuf::uint32 tag;
   // @@protoc_insertion_point(parse_start:Communication_proto.Communication_parameter_all)
   for (;;) {
-    ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
     tag = p.first;
     if (!p.second) goto handle_unusual;
     switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -570,7 +604,7 @@ void Communication_parameter_all::SerializeWithCachedSizes(
   // optional .Communication_proto.Communication_parameter communication_parameters = 1;
   if (cached_has_bits & 0x00000001u) {
     ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
-      1, this->_internal_communication_parameters(), output);
+      1, *this->communication_parameters_, output);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -592,7 +626,7 @@ void Communication_parameter_all::SerializeWithCachedSizes(
   if (cached_has_bits & 0x00000001u) {
     target = ::google::protobuf::internal::WireFormatLite::
       InternalWriteMessageToArray(
-        1, this->_internal_communication_parameters(), deterministic, target);
+        1, *this->communication_parameters_, deterministic, target);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -616,11 +650,13 @@ size_t Communication_parameter_all::ByteSizeLong() const {
   if (has_communication_parameters()) {
     total_size += 1 +
       ::google::protobuf::internal::WireFormatLite::MessageSize(
-        *communication_parameters_);
+        *this->communication_parameters_);
   }
 
   int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
-  SetCachedSize(cached_size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = cached_size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
   return total_size;
 }
 
@@ -678,6 +714,7 @@ void Communication_parameter_all::InternalSwap(Communication_parameter_all* othe
   swap(communication_parameters_, other->communication_parameters_);
   swap(_has_bits_[0], other->_has_bits_[0]);
   _internal_metadata_.Swap(&other->_internal_metadata_);
+  swap(_cached_size_, other->_cached_size_);
 }
 
 ::google::protobuf::Metadata Communication_parameter_all::GetMetadata() const {
@@ -688,15 +725,5 @@ void Communication_parameter_all::InternalSwap(Communication_parameter_all* othe
 
 // @@protoc_insertion_point(namespace_scope)
 }  // namespace Communication_proto
-namespace google {
-namespace protobuf {
-template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::Communication_proto::Communication_parameter* Arena::CreateMaybeMessage< ::Communication_proto::Communication_parameter >(Arena* arena) {
-  return Arena::CreateInternal< ::Communication_proto::Communication_parameter >(arena);
-}
-template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::Communication_proto::Communication_parameter_all* Arena::CreateMaybeMessage< ::Communication_proto::Communication_parameter_all >(Arena* arena) {
-  return Arena::CreateInternal< ::Communication_proto::Communication_parameter_all >(arena);
-}
-}  // namespace protobuf
-}  // namespace google
 
 // @@protoc_insertion_point(global_scope)

+ 47 - 65
communication/communication.pb.h

@@ -1,19 +1,19 @@
 // Generated by the protocol buffer compiler.  DO NOT EDIT!
 // source: communication.proto
 
-#ifndef PROTOBUF_INCLUDED_communication_2eproto
-#define PROTOBUF_INCLUDED_communication_2eproto
+#ifndef PROTOBUF_communication_2eproto__INCLUDED
+#define PROTOBUF_communication_2eproto__INCLUDED
 
 #include <string>
 
 #include <google/protobuf/stubs/common.h>
 
-#if GOOGLE_PROTOBUF_VERSION < 3006001
+#if GOOGLE_PROTOBUF_VERSION < 3005000
 #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 3006001 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
+#if 3005000 < 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.
@@ -24,14 +24,12 @@
 #include <google/protobuf/arenastring.h>
 #include <google/protobuf/generated_message_table_driven.h>
 #include <google/protobuf/generated_message_util.h>
-#include <google/protobuf/inlined_string_field.h>
 #include <google/protobuf/metadata.h>
 #include <google/protobuf/message.h>
 #include <google/protobuf/repeated_field.h>  // IWYU pragma: export
 #include <google/protobuf/extension_set.h>  // IWYU pragma: export
 #include <google/protobuf/unknown_field_set.h>
 // @@protoc_insertion_point(includes)
-#define PROTOBUF_INTERNAL_EXPORT_protobuf_communication_2eproto 
 
 namespace protobuf_communication_2eproto {
 // Internal implementation detail -- do not use these members.
@@ -44,6 +42,14 @@ struct TableStruct {
   static const ::google::protobuf::uint32 offsets[];
 };
 void AddDescriptors();
+void InitDefaultsCommunication_parameterImpl();
+void InitDefaultsCommunication_parameter();
+void InitDefaultsCommunication_parameter_allImpl();
+void InitDefaultsCommunication_parameter_all();
+inline void InitDefaults() {
+  InitDefaultsCommunication_parameter();
+  InitDefaultsCommunication_parameter_all();
+}
 }  // namespace protobuf_communication_2eproto
 namespace Communication_proto {
 class Communication_parameter;
@@ -53,12 +59,6 @@ class Communication_parameter_all;
 class Communication_parameter_allDefaultTypeInternal;
 extern Communication_parameter_allDefaultTypeInternal _Communication_parameter_all_default_instance_;
 }  // namespace Communication_proto
-namespace google {
-namespace protobuf {
-template<> ::Communication_proto::Communication_parameter* Arena::CreateMaybeMessage<::Communication_proto::Communication_parameter>(Arena*);
-template<> ::Communication_proto::Communication_parameter_all* Arena::CreateMaybeMessage<::Communication_proto::Communication_parameter_all>(Arena*);
-}  // namespace protobuf
-}  // namespace google
 namespace Communication_proto {
 
 // ===================================================================
@@ -104,7 +104,7 @@ class Communication_parameter : public ::google::protobuf::Message /* @@protoc_i
     return reinterpret_cast<const Communication_parameter*>(
                &_Communication_parameter_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     0;
 
   void Swap(Communication_parameter* other);
@@ -114,33 +114,28 @@ class Communication_parameter : public ::google::protobuf::Message /* @@protoc_i
 
   // implements Message ----------------------------------------------
 
-  inline Communication_parameter* New() const final {
-    return CreateMaybeMessage<Communication_parameter>(NULL);
-  }
+  inline Communication_parameter* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Communication_parameter* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Communication_parameter>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Communication_parameter* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Communication_parameter& from);
   void MergeFrom(const Communication_parameter& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Communication_parameter* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -151,7 +146,7 @@ class Communication_parameter : public ::google::protobuf::Message /* @@protoc_i
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -201,10 +196,11 @@ class Communication_parameter : public ::google::protobuf::Message /* @@protoc_i
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::google::protobuf::RepeatedPtrField< ::std::string> connect_string_vector_;
   ::google::protobuf::internal::ArenaStringPtr bind_string_;
   friend struct ::protobuf_communication_2eproto::TableStruct;
+  friend void ::protobuf_communication_2eproto::InitDefaultsCommunication_parameterImpl();
 };
 // -------------------------------------------------------------------
 
@@ -249,7 +245,7 @@ class Communication_parameter_all : public ::google::protobuf::Message /* @@prot
     return reinterpret_cast<const Communication_parameter_all*>(
                &_Communication_parameter_all_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     1;
 
   void Swap(Communication_parameter_all* other);
@@ -259,33 +255,28 @@ class Communication_parameter_all : public ::google::protobuf::Message /* @@prot
 
   // implements Message ----------------------------------------------
 
-  inline Communication_parameter_all* New() const final {
-    return CreateMaybeMessage<Communication_parameter_all>(NULL);
-  }
+  inline Communication_parameter_all* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Communication_parameter_all* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Communication_parameter_all>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Communication_parameter_all* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Communication_parameter_all& from);
   void MergeFrom(const Communication_parameter_all& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Communication_parameter_all* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -296,7 +287,7 @@ class Communication_parameter_all : public ::google::protobuf::Message /* @@prot
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -306,9 +297,6 @@ class Communication_parameter_all : public ::google::protobuf::Message /* @@prot
   bool has_communication_parameters() const;
   void clear_communication_parameters();
   static const int kCommunicationParametersFieldNumber = 1;
-  private:
-  const ::Communication_proto::Communication_parameter& _internal_communication_parameters() const;
-  public:
   const ::Communication_proto::Communication_parameter& communication_parameters() const;
   ::Communication_proto::Communication_parameter* release_communication_parameters();
   ::Communication_proto::Communication_parameter* mutable_communication_parameters();
@@ -321,9 +309,10 @@ class Communication_parameter_all : public ::google::protobuf::Message /* @@prot
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::Communication_proto::Communication_parameter* communication_parameters_;
   friend struct ::protobuf_communication_2eproto::TableStruct;
+  friend void ::protobuf_communication_2eproto::InitDefaultsCommunication_parameter_allImpl();
 };
 // ===================================================================
 
@@ -386,11 +375,8 @@ inline ::std::string* Communication_parameter::mutable_bind_string() {
 }
 inline ::std::string* Communication_parameter::release_bind_string() {
   // @@protoc_insertion_point(field_release:Communication_proto.Communication_parameter.bind_string)
-  if (!has_bind_string()) {
-    return NULL;
-  }
   clear_has_bind_string();
-  return bind_string_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return bind_string_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Communication_parameter::set_allocated_bind_string(::std::string* bind_string) {
   if (bind_string != NULL) {
@@ -489,9 +475,6 @@ inline void Communication_parameter_all::clear_communication_parameters() {
   if (communication_parameters_ != NULL) communication_parameters_->Clear();
   clear_has_communication_parameters();
 }
-inline const ::Communication_proto::Communication_parameter& Communication_parameter_all::_internal_communication_parameters() const {
-  return *communication_parameters_;
-}
 inline const ::Communication_proto::Communication_parameter& Communication_parameter_all::communication_parameters() const {
   const ::Communication_proto::Communication_parameter* p = communication_parameters_;
   // @@protoc_insertion_point(field_get:Communication_proto.Communication_parameter_all.communication_parameters)
@@ -508,8 +491,7 @@ inline ::Communication_proto::Communication_parameter* Communication_parameter_a
 inline ::Communication_proto::Communication_parameter* Communication_parameter_all::mutable_communication_parameters() {
   set_has_communication_parameters();
   if (communication_parameters_ == NULL) {
-    auto* p = CreateMaybeMessage<::Communication_proto::Communication_parameter>(GetArenaNoVirtual());
-    communication_parameters_ = p;
+    communication_parameters_ = new ::Communication_proto::Communication_parameter;
   }
   // @@protoc_insertion_point(field_mutable:Communication_proto.Communication_parameter_all.communication_parameters)
   return communication_parameters_;
@@ -545,4 +527,4 @@ inline void Communication_parameter_all::set_allocated_communication_parameters(
 
 // @@protoc_insertion_point(global_scope)
 
-#endif  // PROTOBUF_INCLUDED_communication_2eproto
+#endif  // PROTOBUF_communication_2eproto__INCLUDED

+ 2 - 0
communication/communication_message.h

@@ -50,6 +50,8 @@ public:
 		eParkspace_confirm_alloc_response_msg = 0x3B,//确认分配车位反馈消息
         eParkspace_refresh_request_msg=0x3C,        //请求更新车位数据
         eParkspace_allocation_data_response_msg=0x3D,
+		eParkspace_manual_search_request_msg = 0x3E,	//手动查询车位请求消息
+		eParkspace_manual_search_response_msg = 0x3F,	//手动查询车位反馈消息
 
 		eStore_command_request_msg=0x41,        //终端停车请求消息
 		eStore_command_response_msg=0x42,       //停车请求反馈消息

File diff suppressed because it is too large
+ 415 - 248
message/message_base.pb.cc


+ 243 - 202
message/message_base.pb.h

@@ -1,19 +1,19 @@
 // Generated by the protocol buffer compiler.  DO NOT EDIT!
 // source: message_base.proto
 
-#ifndef PROTOBUF_INCLUDED_message_5fbase_2eproto
-#define PROTOBUF_INCLUDED_message_5fbase_2eproto
+#ifndef PROTOBUF_message_5fbase_2eproto__INCLUDED
+#define PROTOBUF_message_5fbase_2eproto__INCLUDED
 
 #include <string>
 
 #include <google/protobuf/stubs/common.h>
 
-#if GOOGLE_PROTOBUF_VERSION < 3006001
+#if GOOGLE_PROTOBUF_VERSION < 3005000
 #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 3006001 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
+#if 3005000 < 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.
@@ -24,7 +24,6 @@
 #include <google/protobuf/arenastring.h>
 #include <google/protobuf/generated_message_table_driven.h>
 #include <google/protobuf/generated_message_util.h>
-#include <google/protobuf/inlined_string_field.h>
 #include <google/protobuf/metadata.h>
 #include <google/protobuf/message.h>
 #include <google/protobuf/repeated_field.h>  // IWYU pragma: export
@@ -32,7 +31,6 @@
 #include <google/protobuf/generated_enum_reflection.h>
 #include <google/protobuf/unknown_field_set.h>
 // @@protoc_insertion_point(includes)
-#define PROTOBUF_INTERNAL_EXPORT_protobuf_message_5fbase_2eproto 
 
 namespace protobuf_message_5fbase_2eproto {
 // Internal implementation detail -- do not use these members.
@@ -45,6 +43,26 @@ struct TableStruct {
   static const ::google::protobuf::uint32 offsets[];
 };
 void AddDescriptors();
+void InitDefaultsBase_infoImpl();
+void InitDefaultsBase_info();
+void InitDefaultsBase_msgImpl();
+void InitDefaultsBase_msg();
+void InitDefaultsError_managerImpl();
+void InitDefaultsError_manager();
+void InitDefaultsLocate_informationImpl();
+void InitDefaultsLocate_information();
+void InitDefaultsCar_infoImpl();
+void InitDefaultsCar_info();
+void InitDefaultsParkspace_infoImpl();
+void InitDefaultsParkspace_info();
+inline void InitDefaults() {
+  InitDefaultsBase_info();
+  InitDefaultsBase_msg();
+  InitDefaultsError_manager();
+  InitDefaultsLocate_information();
+  InitDefaultsCar_info();
+  InitDefaultsParkspace_info();
+}
 }  // namespace protobuf_message_5fbase_2eproto
 namespace message {
 class Base_info;
@@ -66,16 +84,6 @@ class Parkspace_info;
 class Parkspace_infoDefaultTypeInternal;
 extern Parkspace_infoDefaultTypeInternal _Parkspace_info_default_instance_;
 }  // namespace message
-namespace google {
-namespace protobuf {
-template<> ::message::Base_info* Arena::CreateMaybeMessage<::message::Base_info>(Arena*);
-template<> ::message::Base_msg* Arena::CreateMaybeMessage<::message::Base_msg>(Arena*);
-template<> ::message::Car_info* Arena::CreateMaybeMessage<::message::Car_info>(Arena*);
-template<> ::message::Error_manager* Arena::CreateMaybeMessage<::message::Error_manager>(Arena*);
-template<> ::message::Locate_information* Arena::CreateMaybeMessage<::message::Locate_information>(Arena*);
-template<> ::message::Parkspace_info* Arena::CreateMaybeMessage<::message::Parkspace_info>(Arena*);
-}  // namespace protobuf
-}  // namespace google
 namespace message {
 
 enum Message_type {
@@ -102,6 +110,8 @@ enum Message_type {
   eParkspace_confirm_alloc_response_msg = 59,
   eParkspace_allocation_data_msg = 60,
   eParkspace_allocation_data_response_msg = 61,
+  eParkspace_manual_search_request_msg = 62,
+  eParkspace_manual_search_response_msg = 63,
   eStore_command_request_msg = 65,
   eStore_command_response_msg = 66,
   ePickup_command_request_msg = 67,
@@ -438,7 +448,7 @@ class Base_info : public ::google::protobuf::Message /* @@protoc_insertion_point
     return reinterpret_cast<const Base_info*>(
                &_Base_info_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     0;
 
   void Swap(Base_info* other);
@@ -448,33 +458,28 @@ class Base_info : public ::google::protobuf::Message /* @@protoc_insertion_point
 
   // implements Message ----------------------------------------------
 
-  inline Base_info* New() const final {
-    return CreateMaybeMessage<Base_info>(NULL);
-  }
+  inline Base_info* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Base_info* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Base_info>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Base_info* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Base_info& from);
   void MergeFrom(const Base_info& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Base_info* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -485,7 +490,7 @@ class Base_info : public ::google::protobuf::Message /* @@protoc_insertion_point
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -535,12 +540,13 @@ class Base_info : public ::google::protobuf::Message /* @@protoc_insertion_point
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   int msg_type_;
   ::google::protobuf::int32 timeout_ms_;
   int sender_;
   int receiver_;
   friend struct ::protobuf_message_5fbase_2eproto::TableStruct;
+  friend void ::protobuf_message_5fbase_2eproto::InitDefaultsBase_infoImpl();
 };
 // -------------------------------------------------------------------
 
@@ -585,7 +591,7 @@ class Base_msg : public ::google::protobuf::Message /* @@protoc_insertion_point(
     return reinterpret_cast<const Base_msg*>(
                &_Base_msg_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     1;
 
   void Swap(Base_msg* other);
@@ -595,33 +601,28 @@ class Base_msg : public ::google::protobuf::Message /* @@protoc_insertion_point(
 
   // implements Message ----------------------------------------------
 
-  inline Base_msg* New() const final {
-    return CreateMaybeMessage<Base_msg>(NULL);
-  }
+  inline Base_msg* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Base_msg* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Base_msg>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Base_msg* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Base_msg& from);
   void MergeFrom(const Base_msg& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Base_msg* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -632,7 +633,7 @@ class Base_msg : public ::google::protobuf::Message /* @@protoc_insertion_point(
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -642,9 +643,6 @@ class Base_msg : public ::google::protobuf::Message /* @@protoc_insertion_point(
   bool has_base_info() const;
   void clear_base_info();
   static const int kBaseInfoFieldNumber = 1;
-  private:
-  const ::message::Base_info& _internal_base_info() const;
-  public:
   const ::message::Base_info& base_info() const;
   ::message::Base_info* release_base_info();
   ::message::Base_info* mutable_base_info();
@@ -657,9 +655,10 @@ class Base_msg : public ::google::protobuf::Message /* @@protoc_insertion_point(
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::message::Base_info* base_info_;
   friend struct ::protobuf_message_5fbase_2eproto::TableStruct;
+  friend void ::protobuf_message_5fbase_2eproto::InitDefaultsBase_msgImpl();
 };
 // -------------------------------------------------------------------
 
@@ -704,7 +703,7 @@ class Error_manager : public ::google::protobuf::Message /* @@protoc_insertion_p
     return reinterpret_cast<const Error_manager*>(
                &_Error_manager_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     2;
 
   void Swap(Error_manager* other);
@@ -714,33 +713,28 @@ class Error_manager : public ::google::protobuf::Message /* @@protoc_insertion_p
 
   // implements Message ----------------------------------------------
 
-  inline Error_manager* New() const final {
-    return CreateMaybeMessage<Error_manager>(NULL);
-  }
+  inline Error_manager* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Error_manager* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Error_manager>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Error_manager* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Error_manager& from);
   void MergeFrom(const Error_manager& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Error_manager* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -751,7 +745,7 @@ class Error_manager : public ::google::protobuf::Message /* @@protoc_insertion_p
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -797,11 +791,12 @@ class Error_manager : public ::google::protobuf::Message /* @@protoc_insertion_p
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::google::protobuf::internal::ArenaStringPtr error_description_;
   ::google::protobuf::int32 error_code_;
   int error_level_;
   friend struct ::protobuf_message_5fbase_2eproto::TableStruct;
+  friend void ::protobuf_message_5fbase_2eproto::InitDefaultsError_managerImpl();
 };
 // -------------------------------------------------------------------
 
@@ -846,7 +841,7 @@ class Locate_information : public ::google::protobuf::Message /* @@protoc_insert
     return reinterpret_cast<const Locate_information*>(
                &_Locate_information_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     3;
 
   void Swap(Locate_information* other);
@@ -856,33 +851,28 @@ class Locate_information : public ::google::protobuf::Message /* @@protoc_insert
 
   // implements Message ----------------------------------------------
 
-  inline Locate_information* New() const final {
-    return CreateMaybeMessage<Locate_information>(NULL);
-  }
+  inline Locate_information* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Locate_information* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Locate_information>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Locate_information* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Locate_information& from);
   void MergeFrom(const Locate_information& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Locate_information* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -893,7 +883,7 @@ class Locate_information : public ::google::protobuf::Message /* @@protoc_insert
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -994,7 +984,7 @@ class Locate_information : public ::google::protobuf::Message /* @@protoc_insert
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   float locate_x_;
   float locate_y_;
   float locate_angle_;
@@ -1006,6 +996,7 @@ class Locate_information : public ::google::protobuf::Message /* @@protoc_insert
   bool locate_correct_;
   float locate_front_theta_;
   friend struct ::protobuf_message_5fbase_2eproto::TableStruct;
+  friend void ::protobuf_message_5fbase_2eproto::InitDefaultsLocate_informationImpl();
 };
 // -------------------------------------------------------------------
 
@@ -1050,7 +1041,7 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
     return reinterpret_cast<const Car_info*>(
                &_Car_info_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     4;
 
   void Swap(Car_info* other);
@@ -1060,33 +1051,28 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
 
   // implements Message ----------------------------------------------
 
-  inline Car_info* New() const final {
-    return CreateMaybeMessage<Car_info>(NULL);
-  }
+  inline Car_info* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Car_info* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Car_info>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Car_info* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Car_info& from);
   void MergeFrom(const Car_info& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Car_info* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -1097,7 +1083,7 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -1118,6 +1104,21 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
   ::std::string* release_license();
   void set_allocated_license(::std::string* license);
 
+  // optional string car_numberPlate = 5 [default = ""];
+  bool has_car_numberplate() const;
+  void clear_car_numberplate();
+  static const int kCarNumberPlateFieldNumber = 5;
+  const ::std::string& car_numberplate() const;
+  void set_car_numberplate(const ::std::string& value);
+  #if LANG_CXX11
+  void set_car_numberplate(::std::string&& value);
+  #endif
+  void set_car_numberplate(const char* value);
+  void set_car_numberplate(const char* value, size_t size);
+  ::std::string* mutable_car_numberplate();
+  ::std::string* release_car_numberplate();
+  void set_allocated_car_numberplate(::std::string* car_numberplate);
+
   // optional float car_length = 1 [default = 0];
   bool has_car_length() const;
   void clear_car_length();
@@ -1139,17 +1140,17 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
   float car_height() const;
   void set_car_height(float value);
 
-  // optional float car_wheel_base = 5 [default = 0];
+  // optional float car_wheel_base = 6 [default = 0];
   bool has_car_wheel_base() const;
   void clear_car_wheel_base();
-  static const int kCarWheelBaseFieldNumber = 5;
+  static const int kCarWheelBaseFieldNumber = 6;
   float car_wheel_base() const;
   void set_car_wheel_base(float value);
 
-  // optional float car_wheel_width = 6 [default = 0];
+  // optional float car_wheel_width = 7 [default = 0];
   bool has_car_wheel_width() const;
   void clear_car_wheel_width();
-  static const int kCarWheelWidthFieldNumber = 6;
+  static const int kCarWheelWidthFieldNumber = 7;
   float car_wheel_width() const;
   void set_car_wheel_width(float value);
 
@@ -1163,6 +1164,8 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
   void clear_has_car_height();
   void set_has_license();
   void clear_has_license();
+  void set_has_car_numberplate();
+  void clear_has_car_numberplate();
   void set_has_car_wheel_base();
   void clear_has_car_wheel_base();
   void set_has_car_wheel_width();
@@ -1170,14 +1173,16 @@ class Car_info : public ::google::protobuf::Message /* @@protoc_insertion_point(
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::google::protobuf::internal::ArenaStringPtr license_;
+  ::google::protobuf::internal::ArenaStringPtr car_numberplate_;
   float car_length_;
   float car_width_;
   float car_height_;
   float car_wheel_base_;
   float car_wheel_width_;
   friend struct ::protobuf_message_5fbase_2eproto::TableStruct;
+  friend void ::protobuf_message_5fbase_2eproto::InitDefaultsCar_infoImpl();
 };
 // -------------------------------------------------------------------
 
@@ -1222,7 +1227,7 @@ class Parkspace_info : public ::google::protobuf::Message /* @@protoc_insertion_
     return reinterpret_cast<const Parkspace_info*>(
                &_Parkspace_info_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     5;
 
   void Swap(Parkspace_info* other);
@@ -1232,33 +1237,28 @@ class Parkspace_info : public ::google::protobuf::Message /* @@protoc_insertion_
 
   // implements Message ----------------------------------------------
 
-  inline Parkspace_info* New() const final {
-    return CreateMaybeMessage<Parkspace_info>(NULL);
-  }
+  inline Parkspace_info* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Parkspace_info* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Parkspace_info>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Parkspace_info* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Parkspace_info& from);
   void MergeFrom(const Parkspace_info& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Parkspace_info* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -1269,7 +1269,7 @@ class Parkspace_info : public ::google::protobuf::Message /* @@protoc_insertion_
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -1309,9 +1309,6 @@ class Parkspace_info : public ::google::protobuf::Message /* @@protoc_insertion_
   bool has_car_info() const;
   void clear_car_info();
   static const int kCarInfoFieldNumber = 11;
-  private:
-  const ::message::Car_info& _internal_car_info() const;
-  public:
   const ::message::Car_info& car_info() const;
   ::message::Car_info* release_car_info();
   ::message::Car_info* mutable_car_info();
@@ -1454,7 +1451,7 @@ class Parkspace_info : public ::google::protobuf::Message /* @@protoc_insertion_
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::google::protobuf::internal::ArenaStringPtr entry_time_;
   ::google::protobuf::internal::ArenaStringPtr leave_time_;
   ::message::Car_info* car_info_;
@@ -1473,6 +1470,7 @@ class Parkspace_info : public ::google::protobuf::Message /* @@protoc_insertion_
   int parkspace_status_target_;
   int car_type_;
   friend struct ::protobuf_message_5fbase_2eproto::TableStruct;
+  friend void ::protobuf_message_5fbase_2eproto::InitDefaultsParkspace_infoImpl();
 };
 // ===================================================================
 
@@ -1602,9 +1600,6 @@ inline void Base_msg::clear_base_info() {
   if (base_info_ != NULL) base_info_->Clear();
   clear_has_base_info();
 }
-inline const ::message::Base_info& Base_msg::_internal_base_info() const {
-  return *base_info_;
-}
 inline const ::message::Base_info& Base_msg::base_info() const {
   const ::message::Base_info* p = base_info_;
   // @@protoc_insertion_point(field_get:message.Base_msg.base_info)
@@ -1621,8 +1616,7 @@ inline ::message::Base_info* Base_msg::release_base_info() {
 inline ::message::Base_info* Base_msg::mutable_base_info() {
   set_has_base_info();
   if (base_info_ == NULL) {
-    auto* p = CreateMaybeMessage<::message::Base_info>(GetArenaNoVirtual());
-    base_info_ = p;
+    base_info_ = new ::message::Base_info;
   }
   // @@protoc_insertion_point(field_mutable:message.Base_msg.base_info)
   return base_info_;
@@ -1749,11 +1743,8 @@ inline ::std::string* Error_manager::mutable_error_description() {
 }
 inline ::std::string* Error_manager::release_error_description() {
   // @@protoc_insertion_point(field_release:message.Error_manager.error_description)
-  if (!has_error_description()) {
-    return NULL;
-  }
   clear_has_error_description();
-  return error_description_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return error_description_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Error_manager::set_allocated_error_description(::std::string* error_description) {
   if (error_description != NULL) {
@@ -2015,13 +2006,13 @@ inline void Locate_information::set_locate_front_theta(float value) {
 
 // optional float car_length = 1 [default = 0];
 inline bool Car_info::has_car_length() const {
-  return (_has_bits_[0] & 0x00000002u) != 0;
+  return (_has_bits_[0] & 0x00000004u) != 0;
 }
 inline void Car_info::set_has_car_length() {
-  _has_bits_[0] |= 0x00000002u;
+  _has_bits_[0] |= 0x00000004u;
 }
 inline void Car_info::clear_has_car_length() {
-  _has_bits_[0] &= ~0x00000002u;
+  _has_bits_[0] &= ~0x00000004u;
 }
 inline void Car_info::clear_car_length() {
   car_length_ = 0;
@@ -2039,13 +2030,13 @@ inline void Car_info::set_car_length(float value) {
 
 // optional float car_width = 2 [default = 0];
 inline bool Car_info::has_car_width() const {
-  return (_has_bits_[0] & 0x00000004u) != 0;
+  return (_has_bits_[0] & 0x00000008u) != 0;
 }
 inline void Car_info::set_has_car_width() {
-  _has_bits_[0] |= 0x00000004u;
+  _has_bits_[0] |= 0x00000008u;
 }
 inline void Car_info::clear_has_car_width() {
-  _has_bits_[0] &= ~0x00000004u;
+  _has_bits_[0] &= ~0x00000008u;
 }
 inline void Car_info::clear_car_width() {
   car_width_ = 0;
@@ -2063,13 +2054,13 @@ inline void Car_info::set_car_width(float value) {
 
 // optional float car_height = 3 [default = 0];
 inline bool Car_info::has_car_height() const {
-  return (_has_bits_[0] & 0x00000008u) != 0;
+  return (_has_bits_[0] & 0x00000010u) != 0;
 }
 inline void Car_info::set_has_car_height() {
-  _has_bits_[0] |= 0x00000008u;
+  _has_bits_[0] |= 0x00000010u;
 }
 inline void Car_info::clear_has_car_height() {
-  _has_bits_[0] &= ~0x00000008u;
+  _has_bits_[0] &= ~0x00000010u;
 }
 inline void Car_info::clear_car_height() {
   car_height_ = 0;
@@ -2135,11 +2126,8 @@ inline ::std::string* Car_info::mutable_license() {
 }
 inline ::std::string* Car_info::release_license() {
   // @@protoc_insertion_point(field_release:message.Car_info.license)
-  if (!has_license()) {
-    return NULL;
-  }
   clear_has_license();
-  return license_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return license_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Car_info::set_allocated_license(::std::string* license) {
   if (license != NULL) {
@@ -2151,15 +2139,78 @@ inline void Car_info::set_allocated_license(::std::string* license) {
   // @@protoc_insertion_point(field_set_allocated:message.Car_info.license)
 }
 
-// optional float car_wheel_base = 5 [default = 0];
+// optional string car_numberPlate = 5 [default = ""];
+inline bool Car_info::has_car_numberplate() const {
+  return (_has_bits_[0] & 0x00000002u) != 0;
+}
+inline void Car_info::set_has_car_numberplate() {
+  _has_bits_[0] |= 0x00000002u;
+}
+inline void Car_info::clear_has_car_numberplate() {
+  _has_bits_[0] &= ~0x00000002u;
+}
+inline void Car_info::clear_car_numberplate() {
+  car_numberplate_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  clear_has_car_numberplate();
+}
+inline const ::std::string& Car_info::car_numberplate() const {
+  // @@protoc_insertion_point(field_get:message.Car_info.car_numberPlate)
+  return car_numberplate_.GetNoArena();
+}
+inline void Car_info::set_car_numberplate(const ::std::string& value) {
+  set_has_car_numberplate();
+  car_numberplate_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
+  // @@protoc_insertion_point(field_set:message.Car_info.car_numberPlate)
+}
+#if LANG_CXX11
+inline void Car_info::set_car_numberplate(::std::string&& value) {
+  set_has_car_numberplate();
+  car_numberplate_.SetNoArena(
+    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+  // @@protoc_insertion_point(field_set_rvalue:message.Car_info.car_numberPlate)
+}
+#endif
+inline void Car_info::set_car_numberplate(const char* value) {
+  GOOGLE_DCHECK(value != NULL);
+  set_has_car_numberplate();
+  car_numberplate_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+  // @@protoc_insertion_point(field_set_char:message.Car_info.car_numberPlate)
+}
+inline void Car_info::set_car_numberplate(const char* value, size_t size) {
+  set_has_car_numberplate();
+  car_numberplate_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+      ::std::string(reinterpret_cast<const char*>(value), size));
+  // @@protoc_insertion_point(field_set_pointer:message.Car_info.car_numberPlate)
+}
+inline ::std::string* Car_info::mutable_car_numberplate() {
+  set_has_car_numberplate();
+  // @@protoc_insertion_point(field_mutable:message.Car_info.car_numberPlate)
+  return car_numberplate_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline ::std::string* Car_info::release_car_numberplate() {
+  // @@protoc_insertion_point(field_release:message.Car_info.car_numberPlate)
+  clear_has_car_numberplate();
+  return car_numberplate_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+}
+inline void Car_info::set_allocated_car_numberplate(::std::string* car_numberplate) {
+  if (car_numberplate != NULL) {
+    set_has_car_numberplate();
+  } else {
+    clear_has_car_numberplate();
+  }
+  car_numberplate_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), car_numberplate);
+  // @@protoc_insertion_point(field_set_allocated:message.Car_info.car_numberPlate)
+}
+
+// optional float car_wheel_base = 6 [default = 0];
 inline bool Car_info::has_car_wheel_base() const {
-  return (_has_bits_[0] & 0x00000010u) != 0;
+  return (_has_bits_[0] & 0x00000020u) != 0;
 }
 inline void Car_info::set_has_car_wheel_base() {
-  _has_bits_[0] |= 0x00000010u;
+  _has_bits_[0] |= 0x00000020u;
 }
 inline void Car_info::clear_has_car_wheel_base() {
-  _has_bits_[0] &= ~0x00000010u;
+  _has_bits_[0] &= ~0x00000020u;
 }
 inline void Car_info::clear_car_wheel_base() {
   car_wheel_base_ = 0;
@@ -2175,15 +2226,15 @@ inline void Car_info::set_car_wheel_base(float value) {
   // @@protoc_insertion_point(field_set:message.Car_info.car_wheel_base)
 }
 
-// optional float car_wheel_width = 6 [default = 0];
+// optional float car_wheel_width = 7 [default = 0];
 inline bool Car_info::has_car_wheel_width() const {
-  return (_has_bits_[0] & 0x00000020u) != 0;
+  return (_has_bits_[0] & 0x00000040u) != 0;
 }
 inline void Car_info::set_has_car_wheel_width() {
-  _has_bits_[0] |= 0x00000020u;
+  _has_bits_[0] |= 0x00000040u;
 }
 inline void Car_info::clear_has_car_wheel_width() {
-  _has_bits_[0] &= ~0x00000020u;
+  _has_bits_[0] &= ~0x00000040u;
 }
 inline void Car_info::clear_car_wheel_width() {
   car_wheel_width_ = 0;
@@ -2460,9 +2511,6 @@ inline void Parkspace_info::clear_car_info() {
   if (car_info_ != NULL) car_info_->Clear();
   clear_has_car_info();
 }
-inline const ::message::Car_info& Parkspace_info::_internal_car_info() const {
-  return *car_info_;
-}
 inline const ::message::Car_info& Parkspace_info::car_info() const {
   const ::message::Car_info* p = car_info_;
   // @@protoc_insertion_point(field_get:message.Parkspace_info.car_info)
@@ -2479,8 +2527,7 @@ inline ::message::Car_info* Parkspace_info::release_car_info() {
 inline ::message::Car_info* Parkspace_info::mutable_car_info() {
   set_has_car_info();
   if (car_info_ == NULL) {
-    auto* p = CreateMaybeMessage<::message::Car_info>(GetArenaNoVirtual());
-    car_info_ = p;
+    car_info_ = new ::message::Car_info;
   }
   // @@protoc_insertion_point(field_mutable:message.Parkspace_info.car_info)
   return car_info_;
@@ -2554,11 +2601,8 @@ inline ::std::string* Parkspace_info::mutable_entry_time() {
 }
 inline ::std::string* Parkspace_info::release_entry_time() {
   // @@protoc_insertion_point(field_release:message.Parkspace_info.entry_time)
-  if (!has_entry_time()) {
-    return NULL;
-  }
   clear_has_entry_time();
-  return entry_time_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return entry_time_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Parkspace_info::set_allocated_entry_time(::std::string* entry_time) {
   if (entry_time != NULL) {
@@ -2620,11 +2664,8 @@ inline ::std::string* Parkspace_info::mutable_leave_time() {
 }
 inline ::std::string* Parkspace_info::release_leave_time() {
   // @@protoc_insertion_point(field_release:message.Parkspace_info.leave_time)
-  if (!has_leave_time()) {
-    return NULL;
-  }
   clear_has_leave_time();
-  return leave_time_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return leave_time_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Parkspace_info::set_allocated_leave_time(::std::string* leave_time) {
   if (leave_time != NULL) {
@@ -2756,62 +2797,62 @@ inline void Parkspace_info::set_car_type(::message::Car_type value) {
 namespace google {
 namespace protobuf {
 
-template <> struct is_proto_enum< ::message::Message_type> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Message_type> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Message_type>() {
   return ::message::Message_type_descriptor();
 }
-template <> struct is_proto_enum< ::message::Communicator> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Communicator> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Communicator>() {
   return ::message::Communicator_descriptor();
 }
-template <> struct is_proto_enum< ::message::Process_type> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Process_type> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Process_type>() {
   return ::message::Process_type_descriptor();
 }
-template <> struct is_proto_enum< ::message::Error_level> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Error_level> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Error_level>() {
   return ::message::Error_level_descriptor();
 }
-template <> struct is_proto_enum< ::message::Parkspace_status> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Parkspace_status> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Parkspace_status>() {
   return ::message::Parkspace_status_descriptor();
 }
-template <> struct is_proto_enum< ::message::Direction> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Direction> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Direction>() {
   return ::message::Direction_descriptor();
 }
-template <> struct is_proto_enum< ::message::Parkspace_path> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Parkspace_path> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Parkspace_path>() {
   return ::message::Parkspace_path_descriptor();
 }
-template <> struct is_proto_enum< ::message::Parkspace_type> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Parkspace_type> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Parkspace_type>() {
   return ::message::Parkspace_type_descriptor();
 }
-template <> struct is_proto_enum< ::message::Car_type> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Car_type> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Car_type>() {
   return ::message::Car_type_descriptor();
 }
-template <> struct is_proto_enum< ::message::Step_type> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Step_type> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Step_type>() {
   return ::message::Step_type_descriptor();
 }
-template <> struct is_proto_enum< ::message::Step_statu> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Step_statu> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Step_statu>() {
   return ::message::Step_statu_descriptor();
 }
-template <> struct is_proto_enum< ::message::Dispatch_device_type> : ::std::true_type {};
+template <> struct is_proto_enum< ::message::Dispatch_device_type> : ::google::protobuf::internal::true_type {};
 template <>
 inline const EnumDescriptor* GetEnumDescriptor< ::message::Dispatch_device_type>() {
   return ::message::Dispatch_device_type_descriptor();
@@ -2822,4 +2863,4 @@ inline const EnumDescriptor* GetEnumDescriptor< ::message::Dispatch_device_type>
 
 // @@protoc_insertion_point(global_scope)
 
-#endif  // PROTOBUF_INCLUDED_message_5fbase_2eproto
+#endif  // PROTOBUF_message_5fbase_2eproto__INCLUDED

+ 6 - 3
message/message_base.proto

@@ -32,6 +32,8 @@ enum Message_type
     eParkspace_confirm_alloc_response_msg = 0x3B;//确认分配车位反馈消息
     eParkspace_allocation_data_msg = 0x3C;     //车位分配模块车位数据消息
     eParkspace_allocation_data_response_msg =0x3D;//车位数据反馈消息
+    eParkspace_manual_search_request_msg = 0x3E;	//手动查询车位请求消息
+    eParkspace_manual_search_response_msg = 0x3F;	//手动查询车位反馈消息
 
     eStore_command_request_msg=0x41;        //终端停车请求消息
     eStore_command_response_msg=0x42;       //停车请求反馈消息
@@ -153,9 +155,10 @@ message Car_info
     optional float                      car_length=1[default = 0];           //车长
     optional float                      car_width=2[default = 0];            //车宽
     optional float                      car_height=3[default = 0];           //车高
-    optional string                     license=4[default = ""];              //车辆凭证号
-    optional float                      car_wheel_base = 5[default = 0];	    //整车的轮距; 前后轮的距离; 用于机器人或agv的抓车
-    optional float                      car_wheel_width = 6[default = 0];	//整车的轮距; 左右轮的距离; 用于机器人或agv的抓车
+    optional string                     license=4[default = ""];             //车辆凭证号(车牌号+唯一码)
+    optional string                     car_numberPlate = 5[default = ""];   //车牌号
+    optional float                      car_wheel_base = 6[default = 0];	 //整车的轮距; 前后轮的距离; 用于机器人或agv的抓车
+    optional float                      car_wheel_width = 7[default = 0];	 //整车的轮距; 左右轮的距离; 用于机器人或agv的抓车
 }
 
 //车位状态枚举

File diff suppressed because it is too large
+ 1781 - 628
message/parkspace_allocation_message.pb.cc


File diff suppressed because it is too large
+ 1637 - 1171
message/parkspace_allocation_message.pb.h


+ 17 - 1
message/parkspace_allocation_message.proto

@@ -55,7 +55,7 @@ message Parkspace_allocation_response_msg
     optional Car_type                   car_type = 5;//汽车类型
 }
 
-//2.查询车辆位置请求
+//2.查询车辆位置请求(根据车辆唯一标识码查询)
 message Parkspace_search_request_msg
 {
     required Base_info                  base_info=1;            //消息类型
@@ -71,6 +71,22 @@ message Parkspace_search_response_msg
     required Error_manager              error_manager=3;        //分配成功与否标志
     repeated Parkspace_info             query_parkspace_info_ex=4;         //待查询车辆存放位置
 }
+//手动查询车辆位置请求(根据车牌号查询)
+message Parkspace_manual_search_request_msg
+{
+    required Base_info                  base_info=1;            //消息类型
+    required string                     command_key=2;           //指令唯一标识符id
+    required Car_info                   car_info=3;              //车辆凭证或号牌
+}
+
+//手动查询车辆位置反馈
+message Parkspace_manual_search_response_msg
+{
+    required Base_info                  base_info=1;            //消息类型
+    required string                     command_key=2;           //指令唯一标识符id
+    required Error_manager              error_manager=3;        //分配成功与否标志
+    repeated Parkspace_info             query_parkspace_info_ex=4;         //待查询车辆存放位置
+}
 
 //3.释放车位请求
 message Parkspace_release_request_msg

+ 86 - 59
parkspace_allocation/database_communication_configuration.pb.cc

@@ -7,6 +7,7 @@
 
 #include <google/protobuf/stubs/common.h>
 #include <google/protobuf/stubs/port.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>
@@ -18,10 +19,6 @@
 #include "third_party/protobuf/version.h"
 #endif
 // @@protoc_insertion_point(includes)
-
-namespace protobuf_database_5fcommunication_5fconfiguration_2eproto {
-extern PROTOBUF_INTERNAL_EXPORT_protobuf_database_5fcommunication_5fconfiguration_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Database_communication_configuration;
-}  // namespace protobuf_database_5fcommunication_5fconfiguration_2eproto
 namespace parkspace_proto {
 class Database_communication_configurationDefaultTypeInternal {
  public:
@@ -35,9 +32,14 @@ class Database_communication_configuration_allDefaultTypeInternal {
 } _Database_communication_configuration_all_default_instance_;
 }  // namespace parkspace_proto
 namespace protobuf_database_5fcommunication_5fconfiguration_2eproto {
-static void InitDefaultsDatabase_communication_configuration() {
+void InitDefaultsDatabase_communication_configurationImpl() {
   GOOGLE_PROTOBUF_VERIFY_VERSION;
 
+#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
+  ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
+#else
+  ::google::protobuf::internal::InitProtobufDefaults();
+#endif  // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
   {
     void* ptr = &::parkspace_proto::_Database_communication_configuration_default_instance_;
     new (ptr) ::parkspace_proto::Database_communication_configuration();
@@ -46,12 +48,20 @@ static void InitDefaultsDatabase_communication_configuration() {
   ::parkspace_proto::Database_communication_configuration::InitAsDefaultInstance();
 }
 
-::google::protobuf::internal::SCCInfo<0> scc_info_Database_communication_configuration =
-    {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsDatabase_communication_configuration}, {}};
+void InitDefaultsDatabase_communication_configuration() {
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDatabase_communication_configurationImpl);
+}
 
-static void InitDefaultsDatabase_communication_configuration_all() {
+void InitDefaultsDatabase_communication_configuration_allImpl() {
   GOOGLE_PROTOBUF_VERIFY_VERSION;
 
+#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
+  ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
+#else
+  ::google::protobuf::internal::InitProtobufDefaults();
+#endif  // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
+  protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configuration();
   {
     void* ptr = &::parkspace_proto::_Database_communication_configuration_all_default_instance_;
     new (ptr) ::parkspace_proto::Database_communication_configuration_all();
@@ -60,13 +70,9 @@ static void InitDefaultsDatabase_communication_configuration_all() {
   ::parkspace_proto::Database_communication_configuration_all::InitAsDefaultInstance();
 }
 
-::google::protobuf::internal::SCCInfo<1> scc_info_Database_communication_configuration_all =
-    {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsDatabase_communication_configuration_all}, {
-      &protobuf_database_5fcommunication_5fconfiguration_2eproto::scc_info_Database_communication_configuration.base,}};
-
-void InitDefaults() {
-  ::google::protobuf::internal::InitSCC(&scc_info_Database_communication_configuration.base);
-  ::google::protobuf::internal::InitSCC(&scc_info_Database_communication_configuration_all.base);
+void InitDefaultsDatabase_communication_configuration_all() {
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDatabase_communication_configuration_allImpl);
 }
 
 ::google::protobuf::Metadata file_level_metadata[2];
@@ -109,14 +115,15 @@ static ::google::protobuf::Message const * const file_default_instances[] = {
 
 void protobuf_AssignDescriptors() {
   AddDescriptors();
+  ::google::protobuf::MessageFactory* factory = NULL;
   AssignDescriptors(
-      "database_communication_configuration.proto", schemas, file_default_instances, TableStruct::offsets,
+      "database_communication_configuration.proto", schemas, file_default_instances, TableStruct::offsets, factory,
       file_level_metadata, NULL, NULL);
 }
 
 void protobuf_AssignDescriptorsOnce() {
-  static ::google::protobuf::internal::once_flag once;
-  ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors);
 }
 
 void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
@@ -146,8 +153,8 @@ void AddDescriptorsImpl() {
 }
 
 void AddDescriptors() {
-  static ::google::protobuf::internal::once_flag once;
-  ::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
+  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
+  ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
 }
 // Force AddDescriptors() to be called at dynamic initialization time.
 struct StaticDescriptorInitializer {
@@ -173,15 +180,17 @@ const int Database_communication_configuration::kDbConnPoolSizeFieldNumber;
 
 Database_communication_configuration::Database_communication_configuration()
   : ::google::protobuf::Message(), _internal_metadata_(NULL) {
-  ::google::protobuf::internal::InitSCC(
-      &protobuf_database_5fcommunication_5fconfiguration_2eproto::scc_info_Database_communication_configuration.base);
+  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
+    ::protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configuration();
+  }
   SharedCtor();
   // @@protoc_insertion_point(constructor:parkspace_proto.Database_communication_configuration)
 }
 Database_communication_configuration::Database_communication_configuration(const Database_communication_configuration& from)
   : ::google::protobuf::Message(),
       _internal_metadata_(NULL),
-      _has_bits_(from._has_bits_) {
+      _has_bits_(from._has_bits_),
+      _cached_size_(0) {
   _internal_metadata_.MergeFrom(from._internal_metadata_);
   db_ip_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   if (from.has_db_ip()) {
@@ -206,6 +215,7 @@ Database_communication_configuration::Database_communication_configuration(const
 }
 
 void Database_communication_configuration::SharedCtor() {
+  _cached_size_ = 0;
   db_ip_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   db_username_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   db_passwd_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
@@ -228,7 +238,9 @@ void Database_communication_configuration::SharedDtor() {
 }
 
 void Database_communication_configuration::SetCachedSize(int size) const {
-  _cached_size_.Set(size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
 }
 const ::google::protobuf::Descriptor* Database_communication_configuration::descriptor() {
   ::protobuf_database_5fcommunication_5fconfiguration_2eproto::protobuf_AssignDescriptorsOnce();
@@ -236,10 +248,17 @@ const ::google::protobuf::Descriptor* Database_communication_configuration::desc
 }
 
 const Database_communication_configuration& Database_communication_configuration::default_instance() {
-  ::google::protobuf::internal::InitSCC(&protobuf_database_5fcommunication_5fconfiguration_2eproto::scc_info_Database_communication_configuration.base);
+  ::protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configuration();
   return *internal_default_instance();
 }
 
+Database_communication_configuration* Database_communication_configuration::New(::google::protobuf::Arena* arena) const {
+  Database_communication_configuration* n = new Database_communication_configuration;
+  if (arena != NULL) {
+    arena->Own(n);
+  }
+  return n;
+}
 
 void Database_communication_configuration::Clear() {
 // @@protoc_insertion_point(message_clear_start:parkspace_proto.Database_communication_configuration)
@@ -250,16 +269,20 @@ void Database_communication_configuration::Clear() {
   cached_has_bits = _has_bits_[0];
   if (cached_has_bits & 15u) {
     if (cached_has_bits & 0x00000001u) {
-      db_ip_.ClearNonDefaultToEmptyNoArena();
+      GOOGLE_DCHECK(!db_ip_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
+      (*db_ip_.UnsafeRawStringPointer())->clear();
     }
     if (cached_has_bits & 0x00000002u) {
-      db_username_.ClearNonDefaultToEmptyNoArena();
+      GOOGLE_DCHECK(!db_username_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
+      (*db_username_.UnsafeRawStringPointer())->clear();
     }
     if (cached_has_bits & 0x00000004u) {
-      db_passwd_.ClearNonDefaultToEmptyNoArena();
+      GOOGLE_DCHECK(!db_passwd_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
+      (*db_passwd_.UnsafeRawStringPointer())->clear();
     }
     if (cached_has_bits & 0x00000008u) {
-      db_name_.ClearNonDefaultToEmptyNoArena();
+      GOOGLE_DCHECK(!db_name_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
+      (*db_name_.UnsafeRawStringPointer())->clear();
     }
   }
   if (cached_has_bits & 48u) {
@@ -277,7 +300,7 @@ bool Database_communication_configuration::MergePartialFromCodedStream(
   ::google::protobuf::uint32 tag;
   // @@protoc_insertion_point(parse_start:parkspace_proto.Database_communication_configuration)
   for (;;) {
-    ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
     tag = p.first;
     if (!p.second) goto handle_unusual;
     switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -609,7 +632,9 @@ size_t Database_communication_configuration::ByteSizeLong() const {
   }
 
   int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
-  SetCachedSize(cached_size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = cached_size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
   return total_size;
 }
 
@@ -688,18 +713,15 @@ void Database_communication_configuration::Swap(Database_communication_configura
 }
 void Database_communication_configuration::InternalSwap(Database_communication_configuration* other) {
   using std::swap;
-  db_ip_.Swap(&other->db_ip_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
-    GetArenaNoVirtual());
-  db_username_.Swap(&other->db_username_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
-    GetArenaNoVirtual());
-  db_passwd_.Swap(&other->db_passwd_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
-    GetArenaNoVirtual());
-  db_name_.Swap(&other->db_name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
-    GetArenaNoVirtual());
+  db_ip_.Swap(&other->db_ip_);
+  db_username_.Swap(&other->db_username_);
+  db_passwd_.Swap(&other->db_passwd_);
+  db_name_.Swap(&other->db_name_);
   swap(db_port_, other->db_port_);
   swap(db_conn_pool_size_, other->db_conn_pool_size_);
   swap(_has_bits_[0], other->_has_bits_[0]);
   _internal_metadata_.Swap(&other->_internal_metadata_);
+  swap(_cached_size_, other->_cached_size_);
 }
 
 ::google::protobuf::Metadata Database_communication_configuration::GetMetadata() const {
@@ -720,15 +742,17 @@ const int Database_communication_configuration_all::kDatabaseCommunicationConfig
 
 Database_communication_configuration_all::Database_communication_configuration_all()
   : ::google::protobuf::Message(), _internal_metadata_(NULL) {
-  ::google::protobuf::internal::InitSCC(
-      &protobuf_database_5fcommunication_5fconfiguration_2eproto::scc_info_Database_communication_configuration_all.base);
+  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
+    ::protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configuration_all();
+  }
   SharedCtor();
   // @@protoc_insertion_point(constructor:parkspace_proto.Database_communication_configuration_all)
 }
 Database_communication_configuration_all::Database_communication_configuration_all(const Database_communication_configuration_all& from)
   : ::google::protobuf::Message(),
       _internal_metadata_(NULL),
-      _has_bits_(from._has_bits_) {
+      _has_bits_(from._has_bits_),
+      _cached_size_(0) {
   _internal_metadata_.MergeFrom(from._internal_metadata_);
   if (from.has_database_communication_configurations()) {
     database_communication_configurations_ = new ::parkspace_proto::Database_communication_configuration(*from.database_communication_configurations_);
@@ -739,6 +763,7 @@ Database_communication_configuration_all::Database_communication_configuration_a
 }
 
 void Database_communication_configuration_all::SharedCtor() {
+  _cached_size_ = 0;
   database_communication_configurations_ = NULL;
 }
 
@@ -752,7 +777,9 @@ void Database_communication_configuration_all::SharedDtor() {
 }
 
 void Database_communication_configuration_all::SetCachedSize(int size) const {
-  _cached_size_.Set(size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
 }
 const ::google::protobuf::Descriptor* Database_communication_configuration_all::descriptor() {
   ::protobuf_database_5fcommunication_5fconfiguration_2eproto::protobuf_AssignDescriptorsOnce();
@@ -760,10 +787,17 @@ const ::google::protobuf::Descriptor* Database_communication_configuration_all::
 }
 
 const Database_communication_configuration_all& Database_communication_configuration_all::default_instance() {
-  ::google::protobuf::internal::InitSCC(&protobuf_database_5fcommunication_5fconfiguration_2eproto::scc_info_Database_communication_configuration_all.base);
+  ::protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configuration_all();
   return *internal_default_instance();
 }
 
+Database_communication_configuration_all* Database_communication_configuration_all::New(::google::protobuf::Arena* arena) const {
+  Database_communication_configuration_all* n = new Database_communication_configuration_all;
+  if (arena != NULL) {
+    arena->Own(n);
+  }
+  return n;
+}
 
 void Database_communication_configuration_all::Clear() {
 // @@protoc_insertion_point(message_clear_start:parkspace_proto.Database_communication_configuration_all)
@@ -786,7 +820,7 @@ bool Database_communication_configuration_all::MergePartialFromCodedStream(
   ::google::protobuf::uint32 tag;
   // @@protoc_insertion_point(parse_start:parkspace_proto.Database_communication_configuration_all)
   for (;;) {
-    ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
     tag = p.first;
     if (!p.second) goto handle_unusual;
     switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -832,7 +866,7 @@ void Database_communication_configuration_all::SerializeWithCachedSizes(
   // optional .parkspace_proto.Database_communication_configuration database_communication_configurations = 1;
   if (cached_has_bits & 0x00000001u) {
     ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
-      1, this->_internal_database_communication_configurations(), output);
+      1, *this->database_communication_configurations_, output);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -854,7 +888,7 @@ void Database_communication_configuration_all::SerializeWithCachedSizes(
   if (cached_has_bits & 0x00000001u) {
     target = ::google::protobuf::internal::WireFormatLite::
       InternalWriteMessageToArray(
-        1, this->_internal_database_communication_configurations(), deterministic, target);
+        1, *this->database_communication_configurations_, deterministic, target);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -878,11 +912,13 @@ size_t Database_communication_configuration_all::ByteSizeLong() const {
   if (has_database_communication_configurations()) {
     total_size += 1 +
       ::google::protobuf::internal::WireFormatLite::MessageSize(
-        *database_communication_configurations_);
+        *this->database_communication_configurations_);
   }
 
   int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
-  SetCachedSize(cached_size);
+  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
+  _cached_size_ = cached_size;
+  GOOGLE_SAFE_CONCURRENT_WRITES_END();
   return total_size;
 }
 
@@ -943,6 +979,7 @@ void Database_communication_configuration_all::InternalSwap(Database_communicati
   swap(database_communication_configurations_, other->database_communication_configurations_);
   swap(_has_bits_[0], other->_has_bits_[0]);
   _internal_metadata_.Swap(&other->_internal_metadata_);
+  swap(_cached_size_, other->_cached_size_);
 }
 
 ::google::protobuf::Metadata Database_communication_configuration_all::GetMetadata() const {
@@ -953,15 +990,5 @@ void Database_communication_configuration_all::InternalSwap(Database_communicati
 
 // @@protoc_insertion_point(namespace_scope)
 }  // namespace parkspace_proto
-namespace google {
-namespace protobuf {
-template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::parkspace_proto::Database_communication_configuration* Arena::CreateMaybeMessage< ::parkspace_proto::Database_communication_configuration >(Arena* arena) {
-  return Arena::CreateInternal< ::parkspace_proto::Database_communication_configuration >(arena);
-}
-template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::parkspace_proto::Database_communication_configuration_all* Arena::CreateMaybeMessage< ::parkspace_proto::Database_communication_configuration_all >(Arena* arena) {
-  return Arena::CreateInternal< ::parkspace_proto::Database_communication_configuration_all >(arena);
-}
-}  // namespace protobuf
-}  // namespace google
 
 // @@protoc_insertion_point(global_scope)

+ 50 - 77
parkspace_allocation/database_communication_configuration.pb.h

@@ -1,19 +1,19 @@
 // Generated by the protocol buffer compiler.  DO NOT EDIT!
 // source: database_communication_configuration.proto
 
-#ifndef PROTOBUF_INCLUDED_database_5fcommunication_5fconfiguration_2eproto
-#define PROTOBUF_INCLUDED_database_5fcommunication_5fconfiguration_2eproto
+#ifndef PROTOBUF_database_5fcommunication_5fconfiguration_2eproto__INCLUDED
+#define PROTOBUF_database_5fcommunication_5fconfiguration_2eproto__INCLUDED
 
 #include <string>
 
 #include <google/protobuf/stubs/common.h>
 
-#if GOOGLE_PROTOBUF_VERSION < 3006001
+#if GOOGLE_PROTOBUF_VERSION < 3005000
 #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 3006001 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
+#if 3005000 < 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.
@@ -24,14 +24,12 @@
 #include <google/protobuf/arenastring.h>
 #include <google/protobuf/generated_message_table_driven.h>
 #include <google/protobuf/generated_message_util.h>
-#include <google/protobuf/inlined_string_field.h>
 #include <google/protobuf/metadata.h>
 #include <google/protobuf/message.h>
 #include <google/protobuf/repeated_field.h>  // IWYU pragma: export
 #include <google/protobuf/extension_set.h>  // IWYU pragma: export
 #include <google/protobuf/unknown_field_set.h>
 // @@protoc_insertion_point(includes)
-#define PROTOBUF_INTERNAL_EXPORT_protobuf_database_5fcommunication_5fconfiguration_2eproto 
 
 namespace protobuf_database_5fcommunication_5fconfiguration_2eproto {
 // Internal implementation detail -- do not use these members.
@@ -44,6 +42,14 @@ struct TableStruct {
   static const ::google::protobuf::uint32 offsets[];
 };
 void AddDescriptors();
+void InitDefaultsDatabase_communication_configurationImpl();
+void InitDefaultsDatabase_communication_configuration();
+void InitDefaultsDatabase_communication_configuration_allImpl();
+void InitDefaultsDatabase_communication_configuration_all();
+inline void InitDefaults() {
+  InitDefaultsDatabase_communication_configuration();
+  InitDefaultsDatabase_communication_configuration_all();
+}
 }  // namespace protobuf_database_5fcommunication_5fconfiguration_2eproto
 namespace parkspace_proto {
 class Database_communication_configuration;
@@ -53,12 +59,6 @@ class Database_communication_configuration_all;
 class Database_communication_configuration_allDefaultTypeInternal;
 extern Database_communication_configuration_allDefaultTypeInternal _Database_communication_configuration_all_default_instance_;
 }  // namespace parkspace_proto
-namespace google {
-namespace protobuf {
-template<> ::parkspace_proto::Database_communication_configuration* Arena::CreateMaybeMessage<::parkspace_proto::Database_communication_configuration>(Arena*);
-template<> ::parkspace_proto::Database_communication_configuration_all* Arena::CreateMaybeMessage<::parkspace_proto::Database_communication_configuration_all>(Arena*);
-}  // namespace protobuf
-}  // namespace google
 namespace parkspace_proto {
 
 // ===================================================================
@@ -104,7 +104,7 @@ class Database_communication_configuration : public ::google::protobuf::Message
     return reinterpret_cast<const Database_communication_configuration*>(
                &_Database_communication_configuration_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     0;
 
   void Swap(Database_communication_configuration* other);
@@ -114,33 +114,28 @@ class Database_communication_configuration : public ::google::protobuf::Message
 
   // implements Message ----------------------------------------------
 
-  inline Database_communication_configuration* New() const final {
-    return CreateMaybeMessage<Database_communication_configuration>(NULL);
-  }
+  inline Database_communication_configuration* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Database_communication_configuration* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Database_communication_configuration>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Database_communication_configuration* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Database_communication_configuration& from);
   void MergeFrom(const Database_communication_configuration& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Database_communication_configuration* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -151,7 +146,7 @@ class Database_communication_configuration : public ::google::protobuf::Message
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -251,7 +246,7 @@ class Database_communication_configuration : public ::google::protobuf::Message
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::google::protobuf::internal::ArenaStringPtr db_ip_;
   ::google::protobuf::internal::ArenaStringPtr db_username_;
   ::google::protobuf::internal::ArenaStringPtr db_passwd_;
@@ -259,6 +254,7 @@ class Database_communication_configuration : public ::google::protobuf::Message
   ::google::protobuf::int64 db_port_;
   ::google::protobuf::int64 db_conn_pool_size_;
   friend struct ::protobuf_database_5fcommunication_5fconfiguration_2eproto::TableStruct;
+  friend void ::protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configurationImpl();
 };
 // -------------------------------------------------------------------
 
@@ -303,7 +299,7 @@ class Database_communication_configuration_all : public ::google::protobuf::Mess
     return reinterpret_cast<const Database_communication_configuration_all*>(
                &_Database_communication_configuration_all_default_instance_);
   }
-  static constexpr int kIndexInFileMessages =
+  static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
     1;
 
   void Swap(Database_communication_configuration_all* other);
@@ -313,33 +309,28 @@ class Database_communication_configuration_all : public ::google::protobuf::Mess
 
   // implements Message ----------------------------------------------
 
-  inline Database_communication_configuration_all* New() const final {
-    return CreateMaybeMessage<Database_communication_configuration_all>(NULL);
-  }
+  inline Database_communication_configuration_all* New() const PROTOBUF_FINAL { return New(NULL); }
 
-  Database_communication_configuration_all* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<Database_communication_configuration_all>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
+  Database_communication_configuration_all* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
+  void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
+  void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
   void CopyFrom(const Database_communication_configuration_all& from);
   void MergeFrom(const Database_communication_configuration_all& from);
-  void Clear() final;
-  bool IsInitialized() const final;
+  void Clear() PROTOBUF_FINAL;
+  bool IsInitialized() const PROTOBUF_FINAL;
 
-  size_t ByteSizeLong() const final;
+  size_t ByteSizeLong() const PROTOBUF_FINAL;
   bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
+      ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
   void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
+      ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
   ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
+      bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
+  int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
   private:
   void SharedCtor();
   void SharedDtor();
-  void SetCachedSize(int size) const final;
+  void SetCachedSize(int size) const PROTOBUF_FINAL;
   void InternalSwap(Database_communication_configuration_all* other);
   private:
   inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
@@ -350,7 +341,7 @@ class Database_communication_configuration_all : public ::google::protobuf::Mess
   }
   public:
 
-  ::google::protobuf::Metadata GetMetadata() const final;
+  ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
 
   // nested types ----------------------------------------------------
 
@@ -360,9 +351,6 @@ class Database_communication_configuration_all : public ::google::protobuf::Mess
   bool has_database_communication_configurations() const;
   void clear_database_communication_configurations();
   static const int kDatabaseCommunicationConfigurationsFieldNumber = 1;
-  private:
-  const ::parkspace_proto::Database_communication_configuration& _internal_database_communication_configurations() const;
-  public:
   const ::parkspace_proto::Database_communication_configuration& database_communication_configurations() const;
   ::parkspace_proto::Database_communication_configuration* release_database_communication_configurations();
   ::parkspace_proto::Database_communication_configuration* mutable_database_communication_configurations();
@@ -375,9 +363,10 @@ class Database_communication_configuration_all : public ::google::protobuf::Mess
 
   ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
   ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
+  mutable int _cached_size_;
   ::parkspace_proto::Database_communication_configuration* database_communication_configurations_;
   friend struct ::protobuf_database_5fcommunication_5fconfiguration_2eproto::TableStruct;
+  friend void ::protobuf_database_5fcommunication_5fconfiguration_2eproto::InitDefaultsDatabase_communication_configuration_allImpl();
 };
 // ===================================================================
 
@@ -440,11 +429,8 @@ inline ::std::string* Database_communication_configuration::mutable_db_ip() {
 }
 inline ::std::string* Database_communication_configuration::release_db_ip() {
   // @@protoc_insertion_point(field_release:parkspace_proto.Database_communication_configuration.db_ip)
-  if (!has_db_ip()) {
-    return NULL;
-  }
   clear_has_db_ip();
-  return db_ip_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return db_ip_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Database_communication_configuration::set_allocated_db_ip(::std::string* db_ip) {
   if (db_ip != NULL) {
@@ -530,11 +516,8 @@ inline ::std::string* Database_communication_configuration::mutable_db_username(
 }
 inline ::std::string* Database_communication_configuration::release_db_username() {
   // @@protoc_insertion_point(field_release:parkspace_proto.Database_communication_configuration.db_username)
-  if (!has_db_username()) {
-    return NULL;
-  }
   clear_has_db_username();
-  return db_username_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return db_username_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Database_communication_configuration::set_allocated_db_username(::std::string* db_username) {
   if (db_username != NULL) {
@@ -596,11 +579,8 @@ inline ::std::string* Database_communication_configuration::mutable_db_passwd()
 }
 inline ::std::string* Database_communication_configuration::release_db_passwd() {
   // @@protoc_insertion_point(field_release:parkspace_proto.Database_communication_configuration.db_passwd)
-  if (!has_db_passwd()) {
-    return NULL;
-  }
   clear_has_db_passwd();
-  return db_passwd_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return db_passwd_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Database_communication_configuration::set_allocated_db_passwd(::std::string* db_passwd) {
   if (db_passwd != NULL) {
@@ -662,11 +642,8 @@ inline ::std::string* Database_communication_configuration::mutable_db_name() {
 }
 inline ::std::string* Database_communication_configuration::release_db_name() {
   // @@protoc_insertion_point(field_release:parkspace_proto.Database_communication_configuration.db_name)
-  if (!has_db_name()) {
-    return NULL;
-  }
   clear_has_db_name();
-  return db_name_.ReleaseNonDefaultNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
+  return db_name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
 }
 inline void Database_communication_configuration::set_allocated_db_name(::std::string* db_name) {
   if (db_name != NULL) {
@@ -720,9 +697,6 @@ inline void Database_communication_configuration_all::clear_database_communicati
   if (database_communication_configurations_ != NULL) database_communication_configurations_->Clear();
   clear_has_database_communication_configurations();
 }
-inline const ::parkspace_proto::Database_communication_configuration& Database_communication_configuration_all::_internal_database_communication_configurations() const {
-  return *database_communication_configurations_;
-}
 inline const ::parkspace_proto::Database_communication_configuration& Database_communication_configuration_all::database_communication_configurations() const {
   const ::parkspace_proto::Database_communication_configuration* p = database_communication_configurations_;
   // @@protoc_insertion_point(field_get:parkspace_proto.Database_communication_configuration_all.database_communication_configurations)
@@ -739,8 +713,7 @@ inline ::parkspace_proto::Database_communication_configuration* Database_communi
 inline ::parkspace_proto::Database_communication_configuration* Database_communication_configuration_all::mutable_database_communication_configurations() {
   set_has_database_communication_configurations();
   if (database_communication_configurations_ == NULL) {
-    auto* p = CreateMaybeMessage<::parkspace_proto::Database_communication_configuration>(GetArenaNoVirtual());
-    database_communication_configurations_ = p;
+    database_communication_configurations_ = new ::parkspace_proto::Database_communication_configuration;
   }
   // @@protoc_insertion_point(field_mutable:parkspace_proto.Database_communication_configuration_all.database_communication_configurations)
   return database_communication_configurations_;
@@ -776,4 +749,4 @@ inline void Database_communication_configuration_all::set_allocated_database_com
 
 // @@protoc_insertion_point(global_scope)
 
-#endif  // PROTOBUF_INCLUDED_database_5fcommunication_5fconfiguration_2eproto
+#endif  // PROTOBUF_database_5fcommunication_5fconfiguration_2eproto__INCLUDED

+ 60 - 1
parkspace_allocation/parkspace_manager.cpp

@@ -124,6 +124,23 @@ Error_manager Parkspace_manager::execute_msg(Communication_message* p_msg)
 
 			m_thread_pool.enqueue(&Parkspace_manager::execute_for_force_update, this, request, request.command_key());
 			return SUCCESS;
+		}
+		//手动查询请求
+		case Communication_message::eParkspace_manual_search_request_msg:
+		{
+			message::Parkspace_manual_search_request_msg request;
+			bool result = request.ParseFromString(p_msg->get_message_buf());
+			LOG(INFO)<<"manual search request, parkspace  ";
+			if(!result)
+			{
+				return Error_manager(Error_code::PARKSPACE_ALLOCATOR_MSG_PARSE_ERROR, Error_level::MINOR_ERROR,
+									 " message::Parkspace_manual_search_request_msg  ParseFromString error ");
+			}
+			//往线程池添加执行任务, 之后会唤醒一个线程去执行他.
+//			std::cout<<"手动:"<<request.DebugString()<<std::endl;
+
+			m_thread_pool.enqueue(&Parkspace_manager::execute_for_manual_search, this, request.car_info(), request.command_key());
+			return SUCCESS;
 		}
 			// 车位确认占用请求消息
 		case Communication_message::eParkspace_confirm_alloc_request_msg:
@@ -145,6 +162,8 @@ Error_manager Parkspace_manager::execute_msg(Communication_message* p_msg)
 			//车位数据刷新请求
 		case Communication_message::eParkspace_refresh_request_msg:
 		{
+			LOG(INFO)<<"refresh request ";
+
 			return send_parkspace_data();
 		}
 	}
@@ -479,7 +498,7 @@ void Parkspace_manager::execute_for_search(message::Car_info car_info,std::strin
 {
     std::lock_guard<std::mutex> lck(m_parkspace_lock);
 
-    LOG(INFO) << "查询车位     "<<"牌号:"<<car_info.license()<<"     command_key="<<command_key;
+    LOG(INFO) << "查询车位     "<<"唯一标识车牌号:"<<car_info.license()<<"		车牌号:"<<car_info.car_numberplate()<<"     command_key="<<command_key;
 	//根据车辆凭证信息查询车辆位置
 	message::Parkspace_search_response_msg response_msg;
 	message::Base_info t_response_header;
@@ -513,6 +532,46 @@ void Parkspace_manager::execute_for_search(message::Car_info car_info,std::strin
 	Parkspace_communicator::get_instance_references().send_response(&response);
 	std::cout<<std::endl;
 }
+//查询车位线程函数
+void Parkspace_manager::execute_for_manual_search(message::Car_info car_info,std::string command_key)
+{
+	std::lock_guard<std::mutex> lck(m_parkspace_lock);
+
+	LOG(INFO) << "手动查询车位     "<<"唯一标识车牌号:"<<car_info.license()<<"		车牌号:"<<car_info.car_numberplate()<<"     command_key="<<command_key;
+	//根据车辆凭证信息查询车辆位置
+	message::Parkspace_manual_search_response_msg response_msg;
+	message::Base_info t_response_header;
+	message::Error_manager t_error;
+	t_response_header.set_msg_type(message::Message_type::eParkspace_manual_search_request_msg);
+	t_response_header.set_timeout_ms(1000);
+	t_response_header.set_sender(message::Communicator::eParkspace);
+	t_response_header.set_receiver(message::Communicator::eMain);
+	//查询车辆位置
+	message::Parkspace_info parkspace_info;
+	Error_manager error=m_parkspace_operating_function.query_one_parkspace_with_numberPlate(car_info.car_numberplate(),parkspace_info);
+	if ( error != SUCCESS )
+	{
+		t_error.set_error_code(error.get_error_code());
+		t_error.set_error_level((message::Error_level)error.get_error_level());
+		t_error.set_error_description(error.get_error_description());
+		LOG(ERROR) << "查询车位失败     "<<error.to_string();
+	}
+	else
+	{
+		t_error.set_error_code(SUCCESS);
+		t_error.set_error_level(message::Error_level::NORMAL);
+		LOG(INFO) << " 查询成功! 车位ID:"<<parkspace_info.parkingspace_index_id()<<"	单元号:"<<parkspace_info.parkingspace_unit_id()<<"	单元内部ID:"<<parkspace_info.parkingspace_label_id()<<"	号牌:"<<parkspace_info.car_info().license()<<"	车位当前状态:"<<parkspace_info.parkingspace_status();
+	}
+	response_msg.mutable_base_info()->CopyFrom(t_response_header);
+	response_msg.set_command_key(command_key);
+	response_msg.mutable_error_manager()->CopyFrom(t_error);
+	response_msg.mutable_query_parkspace_info_ex()->Add()->CopyFrom(parkspace_info);
+	Communication_message response=Communication_message();
+	response.reset(t_response_header, response_msg.SerializeAsString());
+
+	Parkspace_communicator::get_instance_references().send_response(&response);
+	std::cout<<std::endl;
+}
 
 //释放车位线程函数
 void Parkspace_manager::execute_for_release(message::Parkspace_release_request_msg release_msg, std::string command_key)

+ 2 - 0
parkspace_allocation/parkspace_manager.h

@@ -98,6 +98,8 @@ public://execute_msg创建各线程进行处理
 	void execute_for_confirm_alloc(message::Parkspace_confirm_alloc_request_msg space_info);
     //查询车位线程函数
     void execute_for_search(message::Car_info car_info,std::string command_key);
+	//手动查询车位线程函数
+	void execute_for_manual_search(message::Car_info car_info,std::string command_key);
     //释放车位线程函数
     void execute_for_release(message::Parkspace_release_request_msg release_msg, std::string command_key);
     //强制更新车位信息线程函数

+ 95 - 3
parkspace_allocation/parkspace_operating_function.cpp

@@ -48,6 +48,8 @@ Error_manager Parkspace_operating_function::get_all_parkspace_info(message::Park
 				t_parkspace->set_parkingspace_status((message::Parkspace_status)tp_result->getInt("parkingspace_status"));
 				t_parkspace->set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				t_parkspace->set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
+
+				t_parkspace->mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				t_parkspace->mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				t_parkspace->mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				t_parkspace->mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
@@ -119,6 +121,8 @@ Error_manager Parkspace_operating_function::get_specify_the_type_parkspace_info(
 
 				t_parkspace->set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				t_parkspace->set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
+
+				t_parkspace->mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				t_parkspace->mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				t_parkspace->mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				t_parkspace->mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
@@ -199,8 +203,9 @@ Error_manager Parkspace_operating_function::update_parkspace_data(message::Parks
 //	}
 	if(parkspace_info.has_car_info() && status!=message::Parkspace_status::eParkspace_empty)
 	{
-		sprintf(update_space_sql, "update parkingspace set parkingspace_status = %d,parkSpaceCarLicense = '%s',parkSpaceCarLength = %.3f,parkSpaceCarWidth = %.3f,parkSpaceCarHeight = %.3f,parkSpaceCarType = %d,parkSpaceCarWheelBase = %.3f,parkSpaceCarWheelWidth = %.3f,entryTime = '%s',leaveTime = '%s' where parkingSpaceID = %d",
+		sprintf(update_space_sql, "update parkingspace set parkingspace_status = %d,parkSpaceCarNumberPlate = '%s',parkSpaceCarLicense = '%s',parkSpaceCarLength = %.3f,parkSpaceCarWidth = %.3f,parkSpaceCarHeight = %.3f,parkSpaceCarType = %d,parkSpaceCarWheelBase = %.3f,parkSpaceCarWheelWidth = %.3f,entryTime = '%s',leaveTime = '%s' where parkingSpaceID = %d",
 				status,
+				parkspace_info.car_info().car_numberplate().c_str(),
 				parkspace_info.car_info().license().c_str(),
 				parkspace_info.car_info().has_car_length()?parkspace_info.car_info().car_length():0.0f,
 				parkspace_info.car_info().car_width(),
@@ -213,7 +218,7 @@ Error_manager Parkspace_operating_function::update_parkspace_data(message::Parks
 				parkspace_info.parkingspace_index_id());
 	}else
 	{
-		sprintf(update_space_sql, "update parkingspace set parkingspace_status = %d,parkSpaceCarLicense = NULL,parkSpaceCarLength = 0,parkSpaceCarWidth = 0,parkSpaceCarHeight = 0,parkSpaceCarType = 0,parkSpaceCarWheelBase = 0,parkSpaceCarWheelWidth = 0,entryTime = NULL,leaveTime = NULL where parkingSpaceID = %d", status, parkspace_info.parkingspace_index_id());
+		sprintf(update_space_sql, "update parkingspace set parkingspace_status = %d,parkSpaceCarNumberPlate = NULL,parkSpaceCarLicense = NULL,parkSpaceCarLength = 0,parkSpaceCarWidth = 0,parkSpaceCarHeight = 0,parkSpaceCarType = 0,parkSpaceCarWheelBase = 0,parkSpaceCarWheelWidth = 0,entryTime = NULL,leaveTime = NULL where parkingSpaceID = %d", status, parkspace_info.parkingspace_index_id());
 	}
 	//boost::shared_ptr<sql::ResultSet>  tp_result = nullptr;
 	Error_manager ec = Database_controller::get_instance_pointer()->sql_update(update_space_sql);
@@ -455,6 +460,7 @@ Error_manager Parkspace_operating_function::query_one_parkspace_with_parkspace_i
 				parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
 
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
@@ -532,6 +538,7 @@ Error_manager Parkspace_operating_function::query_one_occupied_parkspace_with_li
 				parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
 
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
@@ -608,7 +615,8 @@ Error_manager Parkspace_operating_function::query_one_parkspace_with_license(std
                 parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
                 parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
 
-                parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
+				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
                 parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
                 parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
                 parkspace_info.mutable_car_info()->set_car_height(tp_result->getDouble("parkSpaceCarHeight"));
@@ -648,6 +656,84 @@ Error_manager Parkspace_operating_function::query_one_parkspace_with_license(std
         return ec;
     }
 
+}
+
+// 根据车牌号查询车位
+Error_manager Parkspace_operating_function::query_one_parkspace_with_numberPlate(std::string numberPlate, message::Parkspace_info &parkspace_info)
+{
+	//执行sql操作
+	//std::string query_parkspace_sql = std::string("select * from parkingspace where parkingspace_status == 2 and parkSpaceCarLicense='").append(license).append("'");
+	char query_parkspace_sql[1024];
+	memset(query_parkspace_sql, 0, 1024);
+	sprintf(query_parkspace_sql,"select * from parkingspace where parkingspace_status != %d and parkSpaceCarNumberPlate='%s' ",message::Parkspace_status::eParkspace_empty,numberPlate.c_str());
+	boost::shared_ptr<sql::ResultSet>  tp_result = nullptr;
+	Error_manager ec = Database_controller::get_instance_pointer()->sql_query(query_parkspace_sql, tp_result);
+	if(ec == SUCCESS)
+	{
+		if(tp_result == nullptr)
+		{
+			return Error_manager(Error_code::DB_RESULT_SET_EMPTY, Error_level::MINOR_ERROR,
+								 "数据库外层查询返回结果空指针 Parkspace_operating_function::query_one_parkspace_with_license error ");
+		}
+		if (tp_result->next())
+		{
+			char buf[1024];
+			memset(buf, 0, 1024);
+			try
+			{
+
+				parkspace_info.set_parkingspace_status((message::Parkspace_status)tp_result->getInt("parkingspace_status"));
+
+				parkspace_info.set_parkingspace_index_id(tp_result->getInt("parkingSpaceID"));
+				parkspace_info.set_parkingspace_unit_id(tp_result->getInt("parkingspace_unit_id"));
+				parkspace_info.set_parkingspace_label_id(tp_result->getInt("parkingspace_label_id"));
+				parkspace_info.set_parkingspace_room_id(tp_result->getInt("parkingspace_room_id"));
+				parkspace_info.set_parkingspace_direction(tp_result->getInt("parkingspace_direction") > 0 ? message::Direction::eForward : message::Direction::eBackward);
+				parkspace_info.set_parkingspace_floor_id(tp_result->getInt("parkingspace_floor_id"));
+				parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
+				parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
+
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
+				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
+				parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
+				parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
+				parkspace_info.mutable_car_info()->set_car_height(tp_result->getDouble("parkSpaceCarHeight"));
+				parkspace_info.set_car_type((message::Car_type)tp_result->getInt("parkSpaceCarType"));
+				parkspace_info.mutable_car_info()->set_car_wheel_base(tp_result->getDouble("parkSpaceCarWheelBase"));
+				parkspace_info.mutable_car_info()->set_car_wheel_width(tp_result->getDouble("parkSpaceCarWheelWidth"));
+				parkspace_info.set_entry_time(tp_result->getString("entryTime"));
+				parkspace_info.set_leave_time(tp_result->getString("leaveTime"));
+			}
+			catch (sql::SQLException &e)
+			{
+				/* Use what() (derived from std::runtime_error) to fetch the error message */
+				sprintf(buf, "# ERR: %s\n (MySQL error code: %d, SQLState: %s", e.what(), e.getErrorCode(), e.getSQLState().c_str());
+				return Error_manager(DB_RESULT_SET_PARSE_ERROR, NEGLIGIBLE_ERROR, buf);
+			}
+			catch (std::runtime_error &e)
+			{
+				sprintf(buf, "# ERR: %s\n ERR: runtime_error in  %s ", e.what(), __FILE__);
+				return Error_manager(DB_RESULT_SET_PARSE_ERROR, NEGLIGIBLE_ERROR, buf);
+			}
+			if (tp_result->next())
+			{
+				return Error_manager(Error_code::DB_QUERY_DATA_REPEAT, Error_level::MAJOR_ERROR,
+									 "数据库查询数据重复 Parkspace_operating_function::query_one_parkspace_with_license error ");
+			}
+		}
+		else
+		{
+			return Error_manager(Error_code::DB_QUERY_NOT_DATA, Error_level::MINOR_ERROR,
+								 "数据库未查询到数据 Parkspace_operating_function::query_one_parkspace_with_license error ");
+		}
+
+		return SUCCESS;
+	}
+	else
+	{
+		return ec;
+	}
+
 }
 // 找到一个空车位
 Error_manager Parkspace_operating_function::query_one_empty_parkspace(message::Parkspace_info &parkspace_info)
@@ -682,6 +768,8 @@ Error_manager Parkspace_operating_function::query_one_empty_parkspace(message::P
 				parkspace_info.set_parkingspace_floor_id(tp_result->getInt("parkingspace_floor_id"));
 				parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
+
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
@@ -754,6 +842,8 @@ Error_manager Parkspace_operating_function::query_one_specified_unit_empty_parks
 				parkspace_info.set_parkingspace_floor_id(tp_result->getInt("parkingspace_floor_id"));
 				parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
+
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));
@@ -826,6 +916,8 @@ Error_manager Parkspace_operating_function::query_one_specified_unit_and_type_em
 				parkspace_info.set_parkingspace_floor_id(tp_result->getInt("parkingspace_floor_id"));
 				parkspace_info.set_parkingspace_width(tp_result->getDouble("parkingspace_width"));
 				parkspace_info.set_parkingspace_height(tp_result->getDouble("parkingspace_height"));
+
+				parkspace_info.mutable_car_info()->set_car_numberplate(tp_result->getString("parkSpaceCarNumberPlate"));
 				parkspace_info.mutable_car_info()->set_license(tp_result->getString("parkSpaceCarLicense"));
 				parkspace_info.mutable_car_info()->set_car_length(tp_result->getDouble("parkSpaceCarLength"));
 				parkspace_info.mutable_car_info()->set_car_width(tp_result->getDouble("parkSpaceCarWidth"));

+ 5 - 3
parkspace_allocation/parkspace_operating_function.h

@@ -35,7 +35,7 @@ public:
     Error_manager update_parkspace_data(message::Parkspace_info parkspace_info);
     // 更新数据库车辆状态,车位信息中包含车辆信息用于匹配更新
     Error_manager update_vehicle_with_parkspace(message::Parkspace_info parkspace_info, message::Vehicle_status &vehicle_status);
-    // 根据车牌号更新车辆的停车记录ID
+    // 根据车辆唯一标识更新车辆的停车记录ID
 	Error_manager update_record_id(std::string license,int record_id);
     // 插入车辆
     Error_manager insert_vehicle_with_parkspace(message::Parkspace_info parkspace_info, message::Vehicle_status &vehicle_status);
@@ -45,9 +45,11 @@ public:
     Error_manager update_parking_record(message::Parkspace_info parkspace_info, int record_id);
     // 根据车位编号查询车位
     Error_manager query_one_parkspace_with_parkspace_id(int parkspace_id, message::Parkspace_info &parkspace_info);
-	// 根据车牌号查询车位
+	// 根据车辆唯一标识查询车位
 	Error_manager query_one_parkspace_with_license(std::string license, message::Parkspace_info &parkspace_info);
-    // 根据车牌号查询状态为占用的车位
+	// 根据车牌号查询车位
+	Error_manager query_one_parkspace_with_numberPlate(std::string numberPlate, message::Parkspace_info &parkspace_info);
+    // 根据车辆唯一标识查询状态为占用的车位
     Error_manager query_one_occupied_parkspace_with_license(std::string license, message::Parkspace_info &parkspace_info);
 	// 找到一个空车位
 	Error_manager query_one_empty_parkspace(message::Parkspace_info &parkspace_info);

+ 11 - 11
setting/database_communication.prototxt

@@ -1,20 +1,20 @@
 
-#database_communication_configurations
-#{
-#    db_ip:"127.0.0.1",
-#    db_port:3306,
-#    db_username:"wk",
-#    db_passwd:"123456",
-#    db_name:"test",
-#    db_conn_pool_size:5
-#}
 database_communication_configurations
 {
     db_ip:"127.0.0.1",
     db_port:3306,
-    db_username:"zx",
-    db_passwd:"zx123456",
+    db_username:"wk",
+    db_passwd:"123456",
     db_name:"chutian_parkspace",
     db_conn_pool_size:5
 }
+#database_communication_configurations
+#{
+ #   db_ip:"127.0.0.1",
+ #   db_port:3306,
+ #   db_username:"zx",
+ #   db_passwd:"zx123456",
+  #  db_name:"chutian_parkspace",
+  #  db_conn_pool_size:5
+#}