X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FExchangePlugin%2FExchangePlugin_Validators.h;h=6f345f9bbec0476e003a06285c9f73167b33ea75;hb=f51f8ab55887ac6eff49fb9937a460abe1956517;hp=ffaa7664dab47eb3c07bb61758bea0509d473dd9;hpb=7074394f8f08413d885f63be01df6bd5007b868c;p=modules%2Fshaper.git diff --git a/src/ExchangePlugin/ExchangePlugin_Validators.h b/src/ExchangePlugin/ExchangePlugin_Validators.h index ffaa7664d..6f345f9bb 100644 --- a/src/ExchangePlugin/ExchangePlugin_Validators.h +++ b/src/ExchangePlugin/ExchangePlugin_Validators.h @@ -1,4 +1,4 @@ -// Copyright (C) 2014-2017 CEA/DEN, EDF R&D +// Copyright (C) 2014-2020 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -12,10 +12,9 @@ // // You should have received a copy of the GNU Lesser General Public // License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // -// See http://www.salome-platform.org/ or -// email : webmaster.salome@opencascade.com +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // #ifndef EXCHANGEPLUGIN_VALIDATORS_H @@ -72,4 +71,20 @@ class ExchangePlugin_ExportFormatValidator : public ExchangePlugin_FormatValidat }; +/** + * Check the selected result is in history (avoid Origin and coordinate axes and planes). + */ +class ExchangePlugin_InHistoryValidator : public ModelAPI_AttributeValidator +{ +public: + /// \return True if the attribute is valid. + /// It checks whether the selected object is in history. + /// \param[in] theAttribute an attribute to check + /// \param[in] theArguments a filter parameters + /// \param[out] theError error message. + virtual bool isValid(const AttributePtr& theAttribute, + const std::list& theArguments, + Events_InfoMessage& theError) const; +}; + #endif