Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
ICaseOptionList.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2026 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
4// See the top-level COPYRIGHT file for details.
5// SPDX-License-Identifier: Apache-2.0
6//-----------------------------------------------------------------------------
7/*---------------------------------------------------------------------------*/
8/* ICaseOptionList.h (C) 2000-2025 */
9/* */
10/* Data set options. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_CORE_ICASEOPTIONLIST_H
13#define ARCANE_CORE_ICASEOPTIONLIST_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
19
20/*---------------------------------------------------------------------------*/
21/*---------------------------------------------------------------------------*/
22
23namespace Arcane
24{
25
26class XmlNode;
27class ICaseMng;
28class XmlNodeList;
30
31/*---------------------------------------------------------------------------*/
32/*---------------------------------------------------------------------------*/
33
38class ARCANE_CORE_EXPORT ICaseOptionList
39{
41
42 protected:
43
44 virtual ~ICaseOptionList() = default;
45
46 public:
47
54 virtual XmlNode rootElement() const = 0;
56 virtual XmlNode parentElement() const = 0;
58 virtual void addChild(ICaseOptions* co) = 0;
60 virtual void removeChild(ICaseOptions* co) = 0;
62 virtual ICaseMng* caseMng() const = 0;
63
65 virtual void readChildren(bool is_phase1) = 0;
67 virtual void printChildren(const String& lang, int indent) = 0;
69 virtual String rootTagName() const = 0;
73 virtual bool isPresent() const = 0;
75 virtual bool isOptional() const = 0;
77 virtual Integer minOccurs() const = 0;
79 virtual Integer maxOccurs() const = 0;
81 virtual void visit(ICaseDocumentVisitor* visitor) = 0;
83 virtual String xpathFullName() const = 0;
85 virtual MeshHandle meshHandle() const = 0;
86
89
96 virtual void disable() = 0;
97
98 public:
99
101 ARCANE_DEPRECATED_REASON("Y2023: This method is internal to Arcane")
102 virtual void addConfig(CaseOptionBase* o, XmlNode parent) = 0;
103
105 ARCANE_DEPRECATED_REASON("Y2023: This method is internal to Arcane")
106 virtual void setRootElementWithParent(XmlNode parent_element) = 0;
107
109 ARCANE_DEPRECATED_REASON("Y2023: This method is internal to Arcane")
110 virtual void setRootElement(XmlNode root_element) = 0;
111
113 ARCANE_DEPRECATED_REASON("Y2023: This method is internal to Arcane")
114 virtual void addInvalidChildren(XmlNodeList& nlist) = 0;
115
116 public:
117
120};
121
122/*---------------------------------------------------------------------------*/
123/*---------------------------------------------------------------------------*/
124
125} // End namespace Arcane
126
127/*---------------------------------------------------------------------------*/
128/*---------------------------------------------------------------------------*/
129
130#endif
Declarations of Arcane's general types.
Declarations of types related to dataset options.
#define ARCCORE_DECLARE_REFERENCE_COUNTED_INCLASS_METHODS()
Macro to declare the virtual methods managing reference counters.
Base class for 1D data vectors.
Base class for a data set option.
Interface of a part of a dataset.
Visitor interface for a dataset option.
Case manager interface.
Definition ICaseMng.h:57
Internal API of the data set options list interface.
Interface for a data set options list.
virtual Integer minOccurs() const =0
Minimum number of occurrences.
virtual void visit(ICaseDocumentVisitor *visitor)=0
Applies the visitor visitor.
virtual XmlNode rootElement() const =0
Returns the element associated with this options list.
virtual String xpathFullName() const =0
Full name in XPath format corresponding to rootElement().
virtual void addInvalidChildren(XmlNodeList &nlist)=0
Adds child elements that do not correspond to options in nlist.
virtual void setRootElement(XmlNode root_element)=0
Positions the root element of the list. If already positioned, throws an exception.
virtual void setRootElementWithParent(XmlNode parent_element)=0
Positions the root element of the list, with parent_element as parent. If already positioned,...
virtual String rootTagName() const =0
Returns the name of the element of this list.
virtual ICaseDocumentFragment * caseDocumentFragment() const =0
Associated document.
virtual void disable()=0
Disables the option as if it were absent.
virtual bool isOptional() const =0
Indicates if the option is optional.
virtual void deepGetChildren(Array< CaseOptionBase * > &col)=0
Adds all child options to the list col.
virtual void readChildren(bool is_phase1)=0
Reads the option values from the DOM elements.
virtual void addChild(ICaseOptions *co)=0
Adds the list co to the list of children.
virtual XmlNode parentElement() const =0
Returns the parent element.
virtual Integer maxOccurs() const =0
Maximum number of occurrences.
virtual bool isPresent() const =0
Indicates if the option is present in the data set.
virtual void printChildren(const String &lang, int indent)=0
Displays the list of child options in language lang and their value.
virtual ICaseMng * caseMng() const =0
Returns the case manager.
virtual MeshHandle meshHandle() const =0
Handle of the associated mesh.
virtual ICaseOptionListInternal * _internalApi()=0
Internal Arcane API.
virtual void removeChild(ICaseOptions *co)=0
Removes co from the list of children.
virtual void addConfig(CaseOptionBase *o, XmlNode parent)=0
Adds option o with parent parent.
Interface for a list of data set options.
Handle on a mesh.
Definition MeshHandle.h:48
List of nodes of a DOM tree.
Definition XmlNodeList.h:36
Node of a DOM tree.
Definition XmlNode.h:51
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
Int32 Integer
Type representing an integer.