63 name.append(m_module).append(m_verb);
80 bool isPresent = presentFields[i];
87 else if (isPresent && !m_optional[i]) {
110 BOOST_THROW_EXCEPTION(
ArgumentError(
"FaceId must not be zero"));
128 BOOST_THROW_EXCEPTION(
ArgumentError(
"FaceId must not be zero"));
156 BOOST_THROW_EXCEPTION(
ArgumentError(
"LocalControlFeature is invalid"));
206 BOOST_THROW_EXCEPTION(
ArgumentError(
"FaceId must not be zero"));
235 BOOST_THROW_EXCEPTION(
ArgumentError(
"FaceId must not be zero"));
262 BOOST_THROW_EXCEPTION(
ArgumentError(
"Name must not be ndn:/"));
314 BOOST_THROW_EXCEPTION(
ArgumentError(
"FaceId must not be zero"));
348 BOOST_THROW_EXCEPTION(
ArgumentError(
"FaceId must not be zero"));
void validate(const ControlParameters ¶meters) const
verify that all required fields are present, and all present fields are either required or optional ...
ControlParameters & setFaceId(uint64_t faceId)
virtual void applyDefaultsToResponse(ControlParameters ¶meters) const
apply default values to missing fields in response
Copyright (c) 2011-2015 Regents of the University of California.
virtual void applyDefaultsToRequest(ControlParameters ¶meters) const
apply default values to missing fields in request
virtual void applyDefaultsToRequest(ControlParameters ¶meters) const
apply default values to missing fields in request
represents parameters in a ControlCommand request or response
virtual void validateRequest(const ControlParameters ¶meters) const
validate request parameters
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
size_t wireEncode(EncodingImpl< TAG > &encoder) const
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
FieldValidator m_requestValidator
FieldValidator for request ControlParameters.
base class of NFD ControlCommand
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
ControlParameters & setFlags(uint64_t flags)
StrategyChoiceUnsetCommand()
FieldValidator m_responseValidator
FieldValidator for response ControlParameters.
virtual void validateRequest(const ControlParameters ¶meters) const
validate request parameters
virtual void applyDefaultsToRequest(ControlParameters ¶meters) const
apply default values to missing fields in request
ControlCommand(const std::string &module, const std::string &verb)
StrategyChoiceSetCommand()
virtual void validateRequest(const ControlParameters ¶meters) const
validate request parameters
const Name & getName() const
FaceLocalControlCommand(const std::string &verb)
FaceDisableLocalControlCommand()
Name getRequestName(const Name &commandPrefix, const ControlParameters ¶meters) const
construct the Name for a request Interest
FaceEnableLocalControlCommand()
Copyright (c) 2011-2015 Regents of the University of California.
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
FieldValidator & required(ControlParameterField field)
declare a required field
Name abstraction to represent an absolute name.
const std::string CONTROL_PARAMETER_FIELD[CONTROL_PARAMETER_UBOUND]
const std::vector< bool > & getPresentFields() const
uint64_t getFaceId() const
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
size_t size() const
Get the number of components.
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
virtual void applyDefaultsToRequest(ControlParameters ¶meters) const
apply default values to missing fields in request
ControlParameters & setCost(uint64_t cost)
virtual void validateResponse(const ControlParameters ¶meters) const
validate response parameters
Base class for faces/[*]-local-control commands.
ControlParameters & setOrigin(uint64_t origin)
FibRemoveNextHopCommand()
represents an error in ControlParameters
LocalControlFeature getLocalControlFeature() const
virtual void applyDefaultsToRequest(ControlParameters ¶meters) const
apply default values to missing fields in request
virtual void validateRequest(const ControlParameters ¶meters) const
validate request parameters
FieldValidator & optional(ControlParameterField field)
declare an optional field