SelectedConstraint.h
Go to the documentation of this file.
1
/* Copyright 2020 CNRS-AIST JRL */
2
3
#pragma once
4
5
#include <
jrl-qp/enums.h
>
6
7
namespace
jrl::qp::internal
8
{
13
class
SelectedConstraint
14
{
15
public
:
17
SelectedConstraint
() : p_(-1), status_(
ActivationStatus
::
INACTIVE
) {}
23
SelectedConstraint
(
int
p,
ActivationStatus
status
) : p_(p), status_(
status
) {}
24
26
int
index
()
const
27
{
28
return
p_;
29
}
31
ActivationStatus
status
()
const
32
{
33
return
status_;
34
}
35
36
friend
std::ostream &
operator<<
(std::ostream & os,
const
SelectedConstraint
& sc)
37
{
38
os <<
"{"
<< sc.p_ <<
", "
<<
static_cast<
int
>
(sc.status_) <<
"}"
;
39
return
os;
40
}
41
42
private
:
43
int
p_;
44
ActivationStatus
status_;
45
};
46
}
// namespace jrl::qp::internal
jrl::qp::internal::SelectedConstraint
Definition:
SelectedConstraint.h:13
jrl::qp::internal::SelectedConstraint::operator<<
friend std::ostream & operator<<(std::ostream &os, const SelectedConstraint &sc)
Definition:
SelectedConstraint.h:36
jrl::qp::internal
Definition:
ActiveSet.h:11
jrl::qp::ActivationStatus
ActivationStatus
Definition:
enums.h:14
jrl::qp::internal::SelectedConstraint::status
ActivationStatus status() const
Definition:
SelectedConstraint.h:31
jrl::qp::internal::SelectedConstraint::SelectedConstraint
SelectedConstraint()
Definition:
SelectedConstraint.h:17
jrl::qp::ActivationStatus::INACTIVE
@ INACTIVE
jrl::qp::internal::SelectedConstraint::SelectedConstraint
SelectedConstraint(int p, ActivationStatus status)
Definition:
SelectedConstraint.h:23
jrl::qp::internal::SelectedConstraint::index
int index() const
Definition:
SelectedConstraint.h:26
enums.h
include
jrl-qp
internal
SelectedConstraint.h
Generated by
1.8.17