mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-25 23:28:09 +00:00
Add getAddressWithoutGruu to Identity address and create participant without gruu
This commit is contained in:
parent
47cf1d436c
commit
d835f50943
4 changed files with 9 additions and 7 deletions
|
|
@ -130,6 +130,12 @@ bool IdentityAddress::setGruu (const string &gruu) {
|
|||
return true;
|
||||
}
|
||||
|
||||
IdentityAddress IdentityAddress::getAddressWithoutGruu () const {
|
||||
IdentityAddress address(*this);
|
||||
address.setGruu("");
|
||||
return address;
|
||||
}
|
||||
|
||||
string IdentityAddress::asString () const {
|
||||
Address tmpAddress(*this);
|
||||
return tmpAddress.asStringUriOnly();
|
||||
|
|
|
|||
|
|
@ -57,6 +57,8 @@ public:
|
|||
const std::string &getGruu () const;
|
||||
bool setGruu (const std::string &gruu);
|
||||
|
||||
IdentityAddress getAddressWithoutGruu () const;
|
||||
|
||||
virtual std::string asString () const;
|
||||
|
||||
private:
|
||||
|
|
|
|||
|
|
@ -88,12 +88,7 @@ void ParticipantPrivate::removeDevice (const IdentityAddress &gruu) {
|
|||
|
||||
Participant::Participant (const IdentityAddress &address) : Object(*new ParticipantPrivate) {
|
||||
L_D();
|
||||
d->addr = address;
|
||||
}
|
||||
|
||||
Participant::Participant (IdentityAddress &&address) : Object(*new ParticipantPrivate) {
|
||||
L_D();
|
||||
d->addr = address;
|
||||
d->addr = address.getAddressWithoutGruu();
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -57,7 +57,6 @@ public:
|
|||
L_OVERRIDE_SHARED_FROM_THIS(Participant);
|
||||
|
||||
explicit Participant (const IdentityAddress &address);
|
||||
explicit Participant (IdentityAddress &&address);
|
||||
|
||||
const IdentityAddress &getAddress () const;
|
||||
bool isAdmin () const;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue