mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-20 11:05:54 +00:00
50 lines
1.1 KiB
C++
50 lines
1.1 KiB
C++
//------------------------------------------------------------------------------
|
|
/*
|
|
Copyright (c) 2011-2013, OpenCoin, Inc.
|
|
*/
|
|
//==============================================================================
|
|
|
|
|
|
#ifndef RIPPLE_NICKNAMESTATE_H
|
|
#define RIPPLE_NICKNAMESTATE_H
|
|
|
|
//
|
|
// State of a nickname node.
|
|
// - Isolate ledger entry format.
|
|
//
|
|
|
|
class NicknameState
|
|
{
|
|
public:
|
|
typedef boost::shared_ptr <NicknameState> pointer;
|
|
|
|
public:
|
|
explicit NicknameState (SerializedLedgerEntry::pointer ledgerEntry); // For accounts in a ledger
|
|
|
|
bool haveMinimumOffer () const;
|
|
STAmount getMinimumOffer () const;
|
|
RippleAddress getAccountID () const;
|
|
|
|
SerializedLedgerEntry::pointer getSLE ()
|
|
{
|
|
return mLedgerEntry;
|
|
}
|
|
const SerializedLedgerEntry& peekSLE () const
|
|
{
|
|
return *mLedgerEntry;
|
|
}
|
|
SerializedLedgerEntry& peekSLE ()
|
|
{
|
|
return *mLedgerEntry;
|
|
}
|
|
|
|
Blob getRaw () const;
|
|
void addJson (Json::Value& value);
|
|
|
|
private:
|
|
SerializedLedgerEntry::pointer mLedgerEntry;
|
|
};
|
|
|
|
#endif
|
|
// vim:ts=4
|