summaryrefslogtreecommitdiffstats
path: root/library/cpp/tvmauth/src/user_ticket.cpp
blob: 0df1d5157af17764b2d14cda0f0d085806372097 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#include "user_impl.h" 
 
#include <library/cpp/tvmauth/checked_user_ticket.h> 
 
namespace NTvmAuth { 
    static const char* EX_MSG = "Ticket already moved out"; 
 
    TCheckedUserTicket::TCheckedUserTicket(THolder<TCheckedUserTicket::TImpl> impl) 
        : Impl_(std::move(impl)) 
    { 
    } 
 
    TCheckedUserTicket::TCheckedUserTicket(TCheckedUserTicket&& o) = default; 
    TCheckedUserTicket::~TCheckedUserTicket() = default; 
    TCheckedUserTicket& TCheckedUserTicket::operator=(TCheckedUserTicket&& o) = default; 
 
    TCheckedUserTicket::operator bool() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->operator bool(); 
    } 
 
    const TUids& TCheckedUserTicket::GetUids() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->GetUids(); 
    } 
 
    TUid TCheckedUserTicket::GetDefaultUid() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->GetDefaultUid(); 
    } 
 
    const TScopes& TCheckedUserTicket::GetScopes() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->GetScopes(); 
    } 
 
    bool TCheckedUserTicket::HasScope(TStringBuf scopeName) const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->HasScope(scopeName); 
    } 
 
    ETicketStatus TCheckedUserTicket::GetStatus() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->GetStatus(); 
    } 
 
    TString TCheckedUserTicket::DebugInfo() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->DebugInfo(); 
    } 
 
    EBlackboxEnv TCheckedUserTicket::GetEnv() const { 
        Y_ENSURE(Impl_, EX_MSG); 
        return Impl_->GetEnv(); 
    } 
}