InsertableItem.hpp 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /*##############################################################################
  2. HPCC SYSTEMS software Copyright (C) 2018 HPCC Systems®.
  3. Licensed under the Apache License, Version 2.0 (the "License");
  4. you may not use this file except in compliance with the License.
  5. You may obtain a copy of the License at
  6. http://www.apache.org/licenses/LICENSE-2.0
  7. Unless required by applicable law or agreed to in writing, software
  8. distributed under the License is distributed on an "AS IS" BASIS,
  9. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. See the License for the specific language governing permissions and
  11. limitations under the License.
  12. ############################################################################## */
  13. #ifndef _CONFIG2_CONFIGINSERTABLE_ITEMS_HPP_
  14. #define _CONFIG2_CONFIGINSERTABLE_ITEMS_HPP_
  15. #include "SchemaItem.hpp"
  16. #include <vector>
  17. class EnvironmentNode;
  18. struct InsertItemLimitChoice
  19. {
  20. InsertItemLimitChoice(const std::string &item, const std::string &attrName, const std::string &attrVal) :
  21. itemName(item), attributeName(attrName), attributeValue(attrVal) { }
  22. std::string itemName;
  23. std::string attributeName;
  24. std::string attributeValue;
  25. };
  26. struct InsertableItem
  27. {
  28. InsertableItem(std::shared_ptr<const EnvironmentNode> pParentEnvNode, const std::shared_ptr<SchemaItem> &pSchemaItem);
  29. std::shared_ptr<const EnvironmentNode> m_pParentEnvNode;
  30. std::shared_ptr<SchemaItem> m_pSchemaItem;
  31. std::vector<InsertItemLimitChoice> m_itemLimits;
  32. bool m_limitChoices;
  33. };
  34. #endif