258void QPlace::insertContent(QPlaceContent::Type type,
const QPlaceContent::Collection &content)
260 for (
auto iter = content.cbegin(), end = content.cend(); iter != end; ++iter)
261 d_ptr->m_contentCollections[type].insert(iter.key(), iter.value());
448void QPlace::setExtendedAttribute(
const QString &attributeType,
449 const QPlaceAttribute &attribute)
451 if (attribute == QPlaceAttribute())
452 d_ptr->extendedAttributes().remove(attributeType);
454 d_ptr->extendedAttributes().insert(attributeType, attribute);
495void QPlace::setContactDetails(
const QString &contactType, QList<QPlaceContactDetail> details)
497 if (details.isEmpty())
498 d_ptr->contacts().remove(contactType);
500 d_ptr->contacts().insert(contactType, details);
508void QPlace::appendContactDetail(
const QString &contactType,
const QPlaceContactDetail &detail)
510 QList<QPlaceContactDetail> details = d_ptr->contacts().value(contactType);
511 details.append(detail);
512 d_ptr->contacts().insert(contactType, details);
570bool QPlacePrivate::operator== (
const QPlacePrivate &other)
const
572 return (categories() == other.categories()
573 && location() == other.location()
574 && ratings() == other.ratings()
575 && supplier() == other.supplier()
576 && m_contentCollections == other.m_contentCollections
577 && m_contentCounts == other.m_contentCounts
578 && name() == other.name()
579 && placeId() == other.placeId()
580 && attribution() == other.attribution()
581 && contacts() == other.contacts()
582 && extendedAttributes() == other.extendedAttributes()
583 && visibility() == other.visibility()
584 && icon() == other.icon()
589bool QPlacePrivate::isEmpty()
const
591 return (categories().isEmpty()
592 && location().isEmpty()
593 && ratings().isEmpty()
594 && supplier().isEmpty()
595 && m_contentCollections.isEmpty()
596 && m_contentCounts.isEmpty()
598 && placeId().isEmpty()
599 && attribution().isEmpty()
600 && contacts().isEmpty()
601 && extendedAttributes().isEmpty()
602 && QLocation::UnspecifiedVisibility == visibility()
623QPlacePrivateDefault::QPlacePrivateDefault(
const QPlacePrivateDefault &other)
624 : QPlacePrivate(other),
625 m_categories(other.m_categories),
626 m_location(other.m_location),
627 m_ratings(other.m_ratings),
628 m_supplier(other.m_supplier),
629 m_name(other.m_name),
630 m_placeId(other.m_placeId),
631 m_attribution(other.m_attribution),
632 m_extendedAttributes(other.m_extendedAttributes),
633 m_contacts(other.m_contacts),
634 m_visibility(other.m_visibility),
635 m_icon(other.m_icon),
636 m_detailsFetched(other.m_detailsFetched)