62 return Name(commandPrefix)
80 bool isPresent = presentFields[i];
86 else if (isPresent && !m_optional[i]) {
Represents an absolute name.
bool empty() const noexcept
Checks if the name is empty, i.e., has no components.
Represents an error in ControlParameters.
FieldValidator & required(ControlParameterField field)
Declare a required field.
FieldValidator & optional(ControlParameterField field)
Declare an optional field.
void validate(const ControlParameters ¶meters) const
Verify that all required fields are present, and all present fields are either required or optional.
Base class of NFD ControlCommand.
ControlCommand(const std::string &module, const std::string &verb)
Name getRequestName(const Name &commandPrefix, const ControlParameters ¶meters) const
Construct the Name for a request Interest.
virtual void validateResponse(const ControlParameters ¶meters) const
Validate response parameters.
virtual void applyDefaultsToRequest(ControlParameters ¶meters) const
Apply default values to missing fields in request.
virtual void validateRequest(const ControlParameters ¶meters) const
Validate request parameters.
virtual void applyDefaultsToResponse(ControlParameters ¶meters) const
Apply default values to missing fields in response.
FieldValidator m_responseValidator
FieldValidator for response ControlParameters.
FieldValidator m_requestValidator
FieldValidator for request ControlParameters.
virtual ~ControlCommand()
Represents parameters in a ControlCommand request or response.
ControlParameters & setOrigin(RouteOrigin origin)
ControlParameters & setCost(uint64_t cost)
uint64_t getFaceId() const
const std::vector< bool > & getPresentFields() const
uint64_t getCapacity() const
ControlParameters & setFacePersistency(FacePersistency persistency)
bool hasFacePersistency() const
ControlParameters & setFlags(uint64_t flags)
uint64_t getCount() const
size_t wireEncode(EncodingImpl< TAG > &encoder) const
const Name & getName() const
ControlParameters & setFaceId(uint64_t faceId)
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
void validateRequest(const ControlParameters ¶meters) const override
Validate request parameters.
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
void applyDefaultsToRequest(ControlParameters ¶meters) const override
Apply default values to missing fields in request.
void validateRequest(const ControlParameters ¶meters) const override
Validate request parameters.
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
void applyDefaultsToRequest(ControlParameters ¶meters) const override
Apply default values to missing fields in request.
void validateResponse(const ControlParameters ¶meters) const override
void applyDefaultsToRequest(ControlParameters ¶meters) const override
Apply default values to missing fields in request.
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
void applyDefaultsToRequest(ControlParameters ¶meters) const override
Apply default values to missing fields in request.
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
FibRemoveNextHopCommand()
void applyDefaultsToRequest(ControlParameters ¶meters) const override
Apply default values to missing fields in request.
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
void applyDefaultsToRequest(ControlParameters ¶meters) const override
Apply default values to missing fields in request.
StrategyChoiceSetCommand()
void validateRequest(const ControlParameters ¶meters) const override
Validate request parameters.
StrategyChoiceUnsetCommand()
void validateResponse(const ControlParameters ¶meters) const override
Validate response parameters.
@ FACE_PERSISTENCY_PERSISTENT
face is persistent
@ ROUTE_FLAG_CHILD_INHERIT
@ CONTROL_PARAMETER_STRATEGY
@ CONTROL_PARAMETER_FACE_PERSISTENCY
@ CONTROL_PARAMETER_UBOUND
@ CONTROL_PARAMETER_DEFAULT_CONGESTION_THRESHOLD
@ CONTROL_PARAMETER_LOCAL_URI
@ CONTROL_PARAMETER_CAPACITY
@ CONTROL_PARAMETER_EXPIRATION_PERIOD
@ CONTROL_PARAMETER_FLAGS
@ CONTROL_PARAMETER_FACE_ID
@ CONTROL_PARAMETER_COUNT
@ CONTROL_PARAMETER_ORIGIN
@ CONTROL_PARAMETER_BASE_CONGESTION_MARKING_INTERVAL
Contains classes and functions related to the NFD Management protocol.
constexpr uint64_t INVALID_FACE_ID
constexpr std::string_view CONTROL_PARAMETER_FIELD[CONTROL_PARAMETER_UBOUND]