示例#1
0
void Message::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (has_to()) {
      if (to_ != &::google::protobuf::internal::kEmptyString) {
        to_->clear();
      }
    }
    id_ = GOOGLE_LONGLONG(0);
    time_ = GOOGLE_LONGLONG(0);
    if (has_from()) {
      if (from_ != &::google::protobuf::internal::kEmptyString) {
        from_->clear();
      }
    }
    type_ = 0;
    if (has_sn()) {
      if (sn_ != &::google::protobuf::internal::kEmptyString) {
        sn_->clear();
      }
    }
    if (has_data()) {
      if (data_ != &::google::protobuf::internal::kEmptyString) {
        data_->clear();
      }
    }
    expire_ = GOOGLE_LONGLONG(0);
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}
示例#2
0
void Message::SharedCtor() {
  _cached_size_ = 0;
  to_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  id_ = GOOGLE_LONGLONG(0);
  time_ = GOOGLE_LONGLONG(0);
  from_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  type_ = 0;
  sn_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  data_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  expire_ = GOOGLE_LONGLONG(0);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}
void MsgNeighbor::SharedCtor() {
  _cached_size_ = 0;
  platform_ = const_cast< ::std::string*>(&_default_platform_);
  accountid_ = GOOGLE_LONGLONG(0);
  score_ = 0;
  xp_ = 0;
  extid_ = const_cast< ::std::string*>(&_default_extid_);
  url_ = const_cast< ::std::string*>(&_default_url_);
  name_ = const_cast< ::std::string*>(&_default_name_);
  isneighbor_ = 0;
  levelbasedonscore_ = 0;
  wishlist_ = const_cast< ::std::string*>(&_default_wishlist_);
  damageprotectiontimeleft_ = GOOGLE_LONGLONG(0);
  tutorialcompleted_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}
示例#4
0
void Sess::SharedCtor() {
  _cached_size_ = 0;
  id_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  type_ = 0;
  lasttime_ = GOOGLE_LONGLONG(0);
  sessid_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  consvid_ = 0;
  version_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}
void MsgNeighbor::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (_has_bit(0)) {
      if (platform_ != &_default_platform_) {
        platform_->clear();
      }
    }
    accountid_ = GOOGLE_LONGLONG(0);
    score_ = 0;
    xp_ = 0;
    if (_has_bit(4)) {
      if (extid_ != &_default_extid_) {
        extid_->clear();
      }
    }
    if (_has_bit(5)) {
      if (url_ != &_default_url_) {
        url_->clear();
      }
    }
    if (_has_bit(6)) {
      if (name_ != &_default_name_) {
        name_->clear();
      }
    }
    isneighbor_ = 0;
  }
  if (_has_bits_[8 / 32] & (0xffu << (8 % 32))) {
    levelbasedonscore_ = 0;
    if (_has_bit(9)) {
      if (wishlist_ != &_default_wishlist_) {
        wishlist_->clear();
      }
    }
    damageprotectiontimeleft_ = GOOGLE_LONGLONG(0);
    tutorialcompleted_ = 0;
  }
  neighbor_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}
示例#6
0
void Sess::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (has_id()) {
      if (id_ != &::google::protobuf::internal::kEmptyString) {
        id_->clear();
      }
    }
    type_ = 0;
    lasttime_ = GOOGLE_LONGLONG(0);
    if (has_sessid()) {
      if (sessid_ != &::google::protobuf::internal::kEmptyString) {
        sessid_->clear();
      }
    }
    consvid_ = 0;
    if (has_version()) {
      if (version_ != &::google::protobuf::internal::kEmptyString) {
        version_->clear();
      }
    }
  }
  kvs_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}