コード例 #1
0
void ServerAllocation::print(std::ostream& os) const
{
    os << "ServerAllocation["
       << "\r\tTuple=" << _tuple << "\r\tUsername="******"\n\tBandwidth Limit=" << bandwidthLimit()
       << "\n\tBandwidth Used=" << bandwidthUsed()
       << "\n\tBandwidth Remaining=" << bandwidthRemaining()
       << "\n\tBase Time Remaining=" << IAllocation::timeRemaining()
       << "\n\tTime Remaining=" << timeRemaining()
       << "\n\tMax Time Remaining=" << maxTimeRemaining()
       << "\n\tDeletable=" << IAllocation::deleted()
       << "\n\tExpired=" << expired() << "]" << endl;
}
コード例 #2
0
ファイル: iallocation.cpp プロジェクト: runt18/libsourcey
bool IAllocation::expired() const
{
    return timeRemaining() == 0
        || bandwidthRemaining() == 0;
}