| 
    KiCad PCB EDA Suite
    
   | 
 
A holder for a rule check item, DRC in Pcbnew or ERC in Eeschema. More...
#include <rc_item.h>
  
Public Types | |
| typedef std::vector< KIID > | KIIDS | 
Public Member Functions | |
| RC_ITEM () | |
| RC_ITEM (const std::shared_ptr< RC_ITEM > &aItem) | |
| virtual | ~RC_ITEM () | 
| void | SetErrorMessage (const wxString &aMessage) | 
| void | SetItems (const KIIDS &aIds) | 
| void | AddItem (EDA_ITEM *aItem) | 
| void | SetItems (const EDA_ITEM *aItem, const EDA_ITEM *bItem=nullptr, const EDA_ITEM *cItem=nullptr, const EDA_ITEM *dItem=nullptr) | 
| void | SetItems (const KIID &aItem, const KIID &bItem=niluuid, const KIID &cItem=niluuid, const KIID &dItem=niluuid) | 
| virtual KIID | GetMainItemID () const | 
| virtual KIID | GetAuxItemID () const | 
| virtual KIID | GetAuxItem2ID () const | 
| virtual KIID | GetAuxItem3ID () const | 
| std::vector< KIID > | GetIDs () const | 
| void | SetParent (MARKER_BASE *aMarker) | 
| MARKER_BASE * | GetParent () const | 
| virtual wxString | ShowReport (UNITS_PROVIDER *aUnitsProvider, SEVERITY aSeverity, const std::map< KIID, EDA_ITEM * > &aItemMap) const | 
| Translate this object into a text string suitable for saving to disk in a report.   | |
| virtual void | GetJsonViolation (RC_JSON::VIOLATION &aViolation, UNITS_PROVIDER *aUnitsProvider, SEVERITY aSeverity, const std::map< KIID, EDA_ITEM * > &aItemMap) const | 
| Translate this object into an RC_JSON::VIOLATION object.   | |
| int | GetErrorCode () const | 
| void | SetErrorCode (int aCode) | 
| virtual wxString | GetErrorMessage () const | 
| wxString | GetErrorText () const | 
| wxString | GetSettingsKey () const | 
| virtual wxString | GetViolatingRuleDesc () const | 
Static Protected Member Functions | |
| static wxString | getSeverityString (SEVERITY aSeverity) | 
Protected Attributes | |
| int | m_errorCode | 
| The error code's numeric value.   | |
| wxString | m_errorMessage | 
| A message describing the details of this specific error.   | |
| wxString | m_errorTitle | 
| The string describing the type of error.   | |
| wxString | m_settingsKey | 
| The key used to describe this type of error in settings.   | |
| MARKER_BASE * | m_parent | 
| The marker this item belongs to, if any.   | |
| KIIDS | m_ids | 
A holder for a rule check item, DRC in Pcbnew or ERC in Eeschema.
RC_ITEMs can have zero, one, or two related EDA_ITEMs.
| typedef std::vector<KIID> RC_ITEM::KIIDS | 
      
  | 
  inline | 
Definition at line 83 of file rc_item.h.
References m_errorCode, and m_parent.
Referenced by DRC_ITEM::Create(), ERC_ITEM::Create(), DRC_ITEM::GetItemsWithSeverities(), and ERC_ITEM::GetItemsWithSeverities().
      
  | 
  inline | 
Definition at line 89 of file rc_item.h.
References m_errorCode, m_errorMessage, m_errorTitle, m_ids, m_parent, and m_settingsKey.
| void RC_ITEM::AddItem | ( | EDA_ITEM * | aItem | ) | 
Definition at line 56 of file rc_item.cpp.
References m_ids, and EDA_ITEM::m_Uuid.
      
  | 
  inlinevirtual | 
      
  | 
  inlinevirtual | 
      
  | 
  inlinevirtual | 
Definition at line 122 of file rc_item.h.
References m_ids, and niluuid.
Referenced by GetJsonViolation(), and ShowReport().
      
  | 
  inline | 
Definition at line 154 of file rc_item.h.
References m_errorCode.
Referenced by BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), SHEETLIST_ERC_ITEMS_PROVIDER::GetCount(), PCB_MARKER::GetSeverity(), SCH_MARKER::GetSeverity(), KI_TEST::IsDrcMarkerOfType(), DIALOG_ERC::OnERCItemRClick(), and SHEETLIST_ERC_ITEMS_PROVIDER::SetSeverities().
      
  | 
  virtual | 
Definition at line 39 of file rc_item.cpp.
References GetErrorText(), and m_errorMessage.
Referenced by BOOST_FIXTURE_TEST_CASE(), GetJsonViolation(), and ShowReport().
      
  | 
  inline | 
Definition at line 167 of file rc_item.h.
References m_errorTitle.
Referenced by CLEANUP_ITEM::CLEANUP_ITEM(), and GetErrorMessage().
      
  | 
  inline | 
Definition at line 126 of file rc_item.h.
References m_ids.
Referenced by BOARD::ResolveDRCExclusions().
      
  | 
  virtual | 
Translate this object into an RC_JSON::VIOLATION object.
| aViolation | is the violation to be populated by info from this item | 
| aUnitsProvider | is the units provider that will be used to output coordinates | 
| aSeverity | is the severity of this item | 
| aItemMap | is a map allowing the lookup of items from KIIDs | 
Definition at line 166 of file rc_item.cpp.
References KIID::AsString(), RC_JSON::AFFECTED_ITEM::description, RC_JSON::VIOLATION::description, RC_JSON::VIOLATION::excluded, GetAuxItemID(), GetErrorMessage(), EDA_ITEM::GetItemDescription(), UNITS_PROVIDER::GetIuScale(), GetMainItemID(), EDA_ITEM::GetPosition(), GetSettingsKey(), getSeverityString(), UNITS_PROVIDER::GetUserUnits(), RC_JSON::VIOLATION::items, m_parent, EDA_ITEM::m_Uuid, RC_JSON::AFFECTED_ITEM::pos, RC_JSON::VIOLATION::severity, EDA_UNIT_UTILS::UI::ToUserUnit(), RC_JSON::VIOLATION::type, RC_JSON::AFFECTED_ITEM::uuid, RC_JSON::COORDINATE::x, VECTOR2< T >::x, RC_JSON::COORDINATE::y, and VECTOR2< T >::y.
      
  | 
  inlinevirtual | 
Definition at line 121 of file rc_item.h.
References m_ids, and niluuid.
Referenced by GetJsonViolation(), and ShowReport().
      
  | 
  inline | 
Definition at line 129 of file rc_item.h.
References m_parent.
Referenced by DIALOG_DRC::ExcludeMarker(), DIALOG_ERC::ExcludeMarker(), RC_TREE_MODEL::GetAttr(), and DIALOG_DRC::OnDRCItemSelected().
      
  | 
  inline | 
Definition at line 172 of file rc_item.h.
References m_settingsKey.
Referenced by GetJsonViolation(), SCHEMATIC::ResolveERCExclusions(), and ShowReport().
      
  | 
  staticprotected | 
Definition at line 81 of file rc_item.cpp.
References RPT_SEVERITY_ACTION, RPT_SEVERITY_DEBUG, RPT_SEVERITY_ERROR, RPT_SEVERITY_EXCLUSION, RPT_SEVERITY_INFO, and RPT_SEVERITY_WARNING.
Referenced by GetJsonViolation(), and ShowReport().
      
  | 
  inlinevirtual | 
      
  | 
  inline | 
Definition at line 155 of file rc_item.h.
References m_errorCode.
      
  | 
  inline | 
Definition at line 101 of file rc_item.h.
References m_errorMessage.
| void RC_ITEM::SetItems | ( | const EDA_ITEM * | aItem, | 
| const EDA_ITEM * | bItem = nullptr, | ||
| const EDA_ITEM * | cItem = nullptr, | ||
| const EDA_ITEM * | dItem = nullptr ) | 
Definition at line 62 of file rc_item.cpp.
References m_ids, and EDA_ITEM::m_Uuid.
      
  | 
  inline | 
      
  | 
  inline | 
      
  | 
  virtual | 
Translate this object into a text string suitable for saving to disk in a report.
Definition at line 100 of file rc_item.cpp.
References GetAuxItemID(), GetErrorMessage(), EDA_ITEM::GetItemDescription(), GetMainItemID(), EDA_ITEM::GetPosition(), GetSettingsKey(), getSeverityString(), GetViolatingRuleDesc(), m_parent, and showCoord().
Referenced by BOOST_DATA_TEST_CASE_F().
      
  | 
  protected | 
The error code's numeric value.
Definition at line 185 of file rc_item.h.
Referenced by CLEANUP_ITEM::CLEANUP_ITEM(), DRC_ITEM::DRC_ITEM(), ERC_ITEM::ERC_ITEM(), DRC_ITEM::GetAuxItem2ID(), DRC_ITEM::GetAuxItem3ID(), GetErrorCode(), CLEANUP_ITEM::GetErrorText(), RC_ITEM(), RC_ITEM(), and SetErrorCode().
      
  | 
  protected | 
A message describing the details of this specific error.
Definition at line 186 of file rc_item.h.
Referenced by GetErrorMessage(), RC_ITEM(), and SetErrorMessage().
      
  | 
  protected | 
The string describing the type of error.
Definition at line 187 of file rc_item.h.
Referenced by CLEANUP_ITEM::CLEANUP_ITEM(), DRC_ITEM::DRC_ITEM(), ERC_ITEM::ERC_ITEM(), GetErrorText(), and RC_ITEM().
      
  | 
  protected | 
Definition at line 191 of file rc_item.h.
Referenced by AddItem(), DRC_ITEM::GetAuxItem2ID(), GetAuxItem2ID(), DRC_ITEM::GetAuxItem3ID(), GetAuxItem3ID(), GetAuxItemID(), GetIDs(), GetMainItemID(), RC_ITEM(), SetItems(), SetItems(), and SetItems().
      
  | 
  protected | 
The marker this item belongs to, if any.
Definition at line 189 of file rc_item.h.
Referenced by DRC_ITEM::DRC_ITEM(), GetJsonViolation(), GetParent(), RC_ITEM(), RC_ITEM(), SetParent(), and ShowReport().
      
  | 
  protected | 
The key used to describe this type of error in settings.
Definition at line 188 of file rc_item.h.
Referenced by DRC_ITEM::DRC_ITEM(), ERC_ITEM::ERC_ITEM(), GetSettingsKey(), and RC_ITEM().