|
WSF
|
Contains the 'categories' to which an object belongs. More...
#include <WsfCategoryList.hpp>
Public Types | |
| typedef std::vector< WsfStringId > | CategoryList |
Public Member Functions | |
| WsfCategoryList () | |
| void | Clear () |
| Clears the category list. | |
| void | JoinCategory (WsfStringId aCategoryId) |
| bool | ProcessInput (UtInput &aInput) |
| bool | IsCategoryMember (WsfStringId aCategoryId) const |
| bool | Intersects (const WsfCategoryList &aOtherList) const |
| bool | IsASubsetOf (const WsfCategoryList &aOtherList) const |
| const CategoryList & | GetCategoryList () const |
| Return a the actual list. | |
Contains the 'categories' to which an object belongs.
An object (platform, sensor, etc.) may be a member of zero or more 'categories'. Categories are generally used to associate groups of objects for the purposes of decision making. For instance, a particular category of objects may represent high value targets.
This class simply provides the mechanism maintain the category list and to determine if an object is a member of a particular category.
| typedef std::vector<WsfStringId> WsfCategoryList::CategoryList |
| WsfCategoryList::WsfCategoryList | ( | ) |
Referenced by Intersects(), and IsASubsetOf().
|
inline |
Clears the category list.
|
inline |
Return a the actual list.
Referenced by WsfHEL_Lethality::FindMappedEntry(), WsfBMUtils::GetSensorType(), WsfPlatformAvailability::PlatformIsAvailable(), and WsfSensorMode::UpdateTrack().
| bool WsfCategoryList::Intersects | ( | const WsfCategoryList & | aOtherList | ) | const |
Does another category list intersect with this category list?
| aOtherList | The other category list. |
References WsfCategoryList().
Referenced by WsfWeaponEffects::IsVulnerable().
| bool WsfCategoryList::IsASubsetOf | ( | const WsfCategoryList & | aOtherList | ) | const |
Is this category list completely contained within another category list?
| aOtherList | The other category list. |
References WsfCategoryList().
| bool WsfCategoryList::IsCategoryMember | ( | WsfStringId | aCategoryId | ) | const |
Determine if the associated object is a member of the indicated category.
| aCategoryId | String ID number of the category to be checked. |
Referenced by WsfMilExtInterface::GetWarheadEnum(), and JoinCategory().
| void WsfCategoryList::JoinCategory | ( | WsfStringId | aCategoryId | ) |
Indicate the associated object is a member of the indicated category.
| aCategoryId | String ID number of the category of which the object is a member. |
References IsCategoryMember().
Referenced by ProcessInput().
| bool WsfCategoryList::ProcessInput | ( | UtInput & | aInput | ) |
Process input from a generic source.
Examine the current input command. If it is NOT one of the commands recognized by this class then it simply returns 'false'. If it is one of the commands recognized by this class then it processes the command and returns 'true'.
| aInput | a reference to a UtInput object. |
| UtInput::ExceptionBase | (or an object derived from it) if the command was recognized but contains some sort of error. |
References JoinCategory().