Drake
|
Extends OutputPort3 for cases where the OutputPort3 is known to be vector-valued, with scalar elements of template type T
.
More...
#include <drake/systems/framework/system3_output.h>
Public Member Functions | |
VectorOutputPort3 (std::unique_ptr< VectorInterface< T >> model_value) | |
Takes over ownership of the supplied concrete VectorInterface object to serve as the model value for this VectorOutputPort3. More... | |
VectorOutputPort3 (int length) | |
If you supply just a length this port will use a BasicVector of that length as its model value. More... | |
const VectorInterface< T > & | get_model_vector () const |
Returns the model value of this port as a const reference to VectorInterface<T> . More... | |
VectorInterface< T > * | get_mutable_model_vector () |
Returns the model value of this port as a mutable pointer to VectorInterface<T> . More... | |
Public Member Functions inherited from OutputPort3 | |
virtual | ~OutputPort3 ()=default |
OutputPort3 () | |
Create an OutputPort3 that has no model value. More... | |
OutputPort3 (std::unique_ptr< AbstractValue > model_value) | |
Create an OutputPort3 with the indicated model value, taking over ownership of the model value. More... | |
void | set_model_value (std::unique_ptr< AbstractValue > model_value) |
Set the model value for this OutputPort3. More... | |
const AbstractValue & | get_model_value () const |
Returns a const reference to a value of the type that this OutputPort3 will present at run time. More... | |
AbstractValue * | get_mutable_model_value () |
Returns a mutable pointer to a value of the type that this OutputPort3 will present at run time. More... | |
std::pair< const AbstractSystem3 *, int > | get_owner_system () const |
If this OutputPort3 is owned by a system, return that system and the output port number by which that system knows this port. More... | |
Extends OutputPort3 for cases where the OutputPort3 is known to be vector-valued, with scalar elements of template type T
.
The model value is a VectorInterface<T>
.
The model value is actually stored in an AbstractValue so that it can be retrieved as the model value of the base class OutputPort3. That allows all output ports can be treated identically when appropriate. Note: the concrete type is actually Value<VectorObject<T>>
; the VectorObject wraps the VectorInterface value.
T | The type of the output port. Must be a valid Eigen scalar. |
|
inlineexplicit |
Takes over ownership of the supplied concrete VectorInterface object to serve as the model value for this VectorOutputPort3.
|
inlineexplicit |
If you supply just a length this port will use a BasicVector of that length as its model value.
|
inline |
Returns the model value of this port as a const reference to VectorInterface<T>
.
|
inline |
Returns the model value of this port as a mutable pointer to VectorInterface<T>
.