|
|
|
@ -128,7 +128,7 @@ static inline constexpr const char *BUNDLE_PROPERTY_COUNT = "_propertyCount";
|
|
|
|
|
|
|
|
|
|
template<size_t N>
|
|
|
|
|
static inline bool startsWith(const std::string &s, const char (&comp)[N]) {
|
|
|
|
|
return !strncmp(s.c_str(), comp, N-1);
|
|
|
|
|
return !strncmp(s.c_str(), comp, N - 1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -798,14 +798,14 @@ public:
|
|
|
|
|
Item& operator=(Item&& other) = default;
|
|
|
|
|
|
|
|
|
|
bool operator==(const Item& other) const {
|
|
|
|
|
if (mPid != other.mPid
|
|
|
|
|
|| mUid != other.mUid
|
|
|
|
|
|| mPkgName != other.mPkgName
|
|
|
|
|
|| mPkgVersionCode != other.mPkgVersionCode
|
|
|
|
|
|| mKey != other.mKey
|
|
|
|
|
|| mTimestamp != other.mTimestamp
|
|
|
|
|
|| mProps != other.mProps) return false;
|
|
|
|
|
return true;
|
|
|
|
|
return mPid == other.mPid
|
|
|
|
|
&& mUid == other.mUid
|
|
|
|
|
&& mPkgName == other.mPkgName
|
|
|
|
|
&& mPkgVersionCode == other.mPkgVersionCode
|
|
|
|
|
&& mKey == other.mKey
|
|
|
|
|
&& mTimestamp == other.mTimestamp
|
|
|
|
|
&& mProps == other.mProps
|
|
|
|
|
;
|
|
|
|
|
}
|
|
|
|
|
bool operator!=(const Item& other) const {
|
|
|
|
|
return !(*this == other);
|
|
|
|
@ -935,6 +935,11 @@ public:
|
|
|
|
|
return get(key, value);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const Prop::Elem* get(const char *key) const {
|
|
|
|
|
const Prop *prop = findProp(key);
|
|
|
|
|
return prop == nullptr ? nullptr : &prop->get();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Deliver the item to MediaMetrics
|
|
|
|
|
bool selfrecord();
|
|
|
|
|
|
|
|
|
|