#include <SelectionsResult.h>
Inherits enable_shared_from_this< SelectionsResult >.
The SelectionsResult class holds the result of a selection process.
Embeds a map of keyple::core::selection::AbstractMatchingSe. At most one of these matching SE is active.
Provides a set of methods to retrieve the active selection (getActiveMatchingSe) or a particular matching SE specified by its index.
◆ SelectionsResult()
keyple::core::selection::SelectionsResult::SelectionsResult |
( |
| ) |
|
◆ addMatchingSe()
void keyple::core::selection::SelectionsResult::addMatchingSe |
( |
int |
selectionIndex, |
|
|
const std::shared_ptr< AbstractMatchingSe > |
matchingSe, |
|
|
bool |
isSelected |
|
) |
| |
Append a keyple::core::selection::AbstractMatchingSe to the internal list
- Parameters
-
selectionIndex | the index of the selection that resulted in the matching SE |
matchingSe | the matching SE to add |
isSelected | true if the currently added matching SE is selected (its logical channel is open) |
◆ getActiveMatchingSe()
const std::shared_ptr< AbstractMatchingSe > keyple::core::selection::SelectionsResult::getActiveMatchingSe |
( |
| ) |
|
Get the active matching SE. I.e. the SE that has been selected.
The hasActiveSelection method should be called before.
- Returns
- the currently active matching SE
- Exceptions
-
IllegalStateException | if no active matching SE is found |
◆ getActiveSelectionIndex()
int keyple::core::selection::SelectionsResult::getActiveSelectionIndex |
( |
| ) |
const |
- Returns
- the index of the active selection
◆ getMatchingSe()
const std::shared_ptr< AbstractMatchingSe > keyple::core::selection::SelectionsResult::getMatchingSe |
( |
int |
selectionIndex | ) |
|
◆ getMatchingSelections()
const std::map< int, std::shared_ptr< AbstractMatchingSe > > & keyple::core::selection::SelectionsResult::getMatchingSelections |
( |
| ) |
const |
◆ hasActiveSelection()
bool keyple::core::selection::SelectionsResult::hasActiveSelection |
( |
| ) |
const |
- Returns
- true if an active selection is present
◆ hasSelectionMatched()
bool keyple::core::selection::SelectionsResult::hasSelectionMatched |
( |
int |
selectionIndex | ) |
const |
Get the matching status of a selection for which the index is provided.
Checks for the presence of an entry in the MatchingSe Map for the given index
- Parameters
-
selectionIndex | the selection index |
- Returns
- true if the selection has matched
◆ operator<< [1/3]
◆ operator<< [2/3]
◆ operator<< [3/3]
The documentation for this class was generated from the following files: