ndn::nfd::CommandOptions Class Reference

contains options for ControlCommand execution More...

#include <command-options.hpp>

+ Collaboration diagram for ndn::nfd::CommandOptions:

Public Member Functions

 CommandOptions ()
 constructs CommandOptions More...
 
const NamegetPrefix () const
 
const security::SigningInfogetSigningInfo () const
 
const time::milliseconds & getTimeout () const
 
CommandOptionssetPrefix (const Name &prefix)
 sets command prefix More...
 
CommandOptionssetSigningInfo (const security::SigningInfo &signingInfo)
 sets signing parameters More...
 
CommandOptionssetTimeout (const time::milliseconds &timeout)
 sets command timeout More...
 

Static Public Attributes

static const Name DEFAULT_PREFIX
 gives the default command prefix: ndn:/localhost/nfd More...
 
static const time::milliseconds DEFAULT_TIMEOUT
 gives the default command timeout: 10000ms More...
 

Detailed Description

contains options for ControlCommand execution

Note
This type is intentionally copyable

Definition at line 34 of file command-options.hpp.

Constructor & Destructor Documentation

ndn::nfd::CommandOptions::CommandOptions ( )

constructs CommandOptions

Postcondition
getTimeout() == DEFAULT_TIMEOUT
getPrefix() == DEFAULT_PREFIX
getSigningInfo().getSignerType() == SIGNER_TYPE_NULL

Definition at line 30 of file command-options.cpp.

Member Function Documentation

const Name& ndn::nfd::CommandOptions::getPrefix ( ) const
inline
Returns
command prefix

Definition at line 63 of file command-options.hpp.

const security::SigningInfo& ndn::nfd::CommandOptions::getSigningInfo ( ) const
inline
Returns
signing parameters

Definition at line 77 of file command-options.hpp.

const time::milliseconds& ndn::nfd::CommandOptions::getTimeout ( ) const
inline
Returns
command timeout

Definition at line 47 of file command-options.hpp.

CommandOptions & ndn::nfd::CommandOptions::setPrefix ( const Name prefix)

sets command prefix

Returns
self

Definition at line 48 of file command-options.cpp.

CommandOptions & ndn::nfd::CommandOptions::setSigningInfo ( const security::SigningInfo signingInfo)

sets signing parameters

Returns
self

Definition at line 55 of file command-options.cpp.

CommandOptions & ndn::nfd::CommandOptions::setTimeout ( const time::milliseconds &  timeout)

sets command timeout

Parameters
timeoutthe new command timeout, must be positive
Exceptions
std::out_of_rangeif timeout is non-positive
Returns
self

Definition at line 37 of file command-options.cpp.

Member Data Documentation

const Name ndn::nfd::CommandOptions::DEFAULT_PREFIX
static

gives the default command prefix: ndn:/localhost/nfd

Definition at line 95 of file command-options.hpp.

const time::milliseconds ndn::nfd::CommandOptions::DEFAULT_TIMEOUT
static

gives the default command timeout: 10000ms

Definition at line 91 of file command-options.hpp.