#ifndef OPTICALAPERTURESETTINGS_TYPE_HPP_INCLUDED
#define OPTICALAPERTURESETTINGS_TYPE_HPP_INCLUDED

#include <iostream>
#include <memory>
#include <optional>
#include <set>
#include <string>
#include <vector>
#include <NBO/NBO/OpticalApertureID_Type.h>
#include <NBO/NBO/ReflectanceProfileFile.h>
#include <NBO/NBO/ReflectionWavelengthRangeSettings.h>
#include <NBO/NBO/Settings_Type.h>
#include <NBO/NBO/TransmissionWavelengthRangeSettings.h>
#include <NBO/NBO/TransmittanceProfileFile.h>
#include <NBO/NBO/ENBOType.h>
#include <NBO/NBOGlobal.h>
#include <NBO/Shared/Base/NBOBaseClass.h>


namespace Inscoper::NBO {

/*!
* \brief Represents the XML complex type OpticalApertureSettings.
*
* This element refers to the Optical Aperture device used to acquire this image and it holds the settings that were applied to it during this Acquisition.
*/
class NBO_EXPORT OpticalApertureSettings_Type : public Settings_Type {

public:
	
	OpticalApertureSettings_Type();
	~OpticalApertureSettings_Type();

	/*!
	* \brief Cast a NBOBaseClass to a OpticalApertureSettings_Type.
	*
	* \param base The base class to cast
	* \return The casted element, or nullptr if the cast fails
	*/
	static std::shared_ptr<OpticalApertureSettings_Type> fromBase(NBOBaseClassPtr base);

	/*!
	* \brief Returns the class type name.
	*
	* \return The class type name
	*/
	virtual std::string getTypeName() const override;

	/*!
	* \brief Returns the XML element name corresponding to this class.
	*
	* \return The XML element name
	*/
	std::string getXMLName() const override;

	/*!
	* \brief Returns the NBO Type corresponding to this class.
	*
	* \return The NBO Type value
	*/
	ENBOType getNBOType() const override;

	/*!
	* \brief Returns a list of all classes derived from this class.
	*
	* \return The list of derived classes
	*/
	std::vector<NBOBaseClassPtr> getChildren() const override;

	/*!
	* \brief Returns a list of all child elements contained in this class.
	*
	* \return The list of child classes
	*/
	std::vector<NBOBaseClassPtr> getSubElements() const override;

	/*!
	* \brief Populates this object from a JSON file.
	*
	* \param path The path to the JSON file
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void fromJsonFile(const std::string& path, bool validate = true);

	/*!
	* \brief Populates this object from a JSON string.
	*
	* \param json_string The JSON content as a string
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void fromJsonString(const std::string& json_string, bool validate = true);

	/*!
	* \brief Populates this object from a XML file.
	*
	* \param path The path to the XML file
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void fromXmlFile(const std::string& path, bool validate = true);

	/*!
	* \brief Populates this object from a XML string.
	*
	* \param xml_string The XML content as a string
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void fromXmlString(const std::string& xml_string, bool validate = true);

	/*!
	* \brief Serializes this object to an XML file.
	*
	* \param filename The path to the output XML file
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void toXmlFile(const std::string& filename, bool validate = true) const;

	/*!
	* \brief Serializes this object to an XML string.
	*
	* \param validate If true, validates constraints on value. Default is true.
	* \return A string containing the XML representation of this object
	*/
	std::string toXmlString(bool validate = true) const;

	/*!
	* \brief Sets the value of the ID attribute.
	*
	* This is the Unique Identifier of the device used in this case.
	*
	* \param value The value to set
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void setID(const Inscoper::NBO::OpticalApertureID_TypePtr& value, bool validate = true);

	/*!
	* \brief Returns the value of the ID attribute.
	*
	* This is the Unique Identifier of the device used in this case.
	*
	* \return The value of the attribute
	*/
	OpticalApertureID_TypePtr getID() const;

	/*!
	* \brief Resets the ID attribute to an unset state.
	*
	* This is the Unique Identifier of the device used in this case.
	*/
	void resetID();

	/*!
	* \brief Checks whether the optional ID attribute is present.
	*
	* This is the Unique Identifier of the device used in this case.
	*
	* \return true if the optional attribute has been set, false otherwise
	*/
	bool hasID() const;

	/*!
	* \brief Sets the list of TransmittanceProfileFile elements.
	*
	* No description available in the XSD standard.
	*
	* \param value The new list of TransmittanceProfileFile elements
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void setTransmittanceProfileFile_List(const std::vector<Inscoper::NBO::TransmittanceProfileFilePtr>& value, bool validate = true);

	/*!
	* \brief Returns the list of TransmittanceProfileFile elements.
	*
	* No description available in the XSD standard.
	*
	* \return The list of TransmittanceProfileFile elements
	*/
	std::vector<Inscoper::NBO::TransmittanceProfileFilePtr> getTransmittanceProfileFile_List() const;

	/*!
	* \brief Adds a new TransmittanceProfileFile element to this object.
	*
	* No description available in the XSD standard.
	*
	* \param value The element to add
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void addToTransmittanceProfileFile_List(const Inscoper::NBO::TransmittanceProfileFilePtr& value, bool validate = true);

	/*!
	* \brief Clear the list of TransmittanceProfileFile.
	*
	* No description available in the XSD standard.
	*/
	void clearTransmittanceProfileFile_List();

	/*!
	* \brief Sets the list of ReflectanceProfileFile elements.
	*
	* No description available in the XSD standard.
	*
	* \param value The new list of ReflectanceProfileFile elements
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void setReflectanceProfileFile_List(const std::vector<Inscoper::NBO::ReflectanceProfileFilePtr>& value, bool validate = true);

	/*!
	* \brief Returns the list of ReflectanceProfileFile elements.
	*
	* No description available in the XSD standard.
	*
	* \return The list of ReflectanceProfileFile elements
	*/
	std::vector<Inscoper::NBO::ReflectanceProfileFilePtr> getReflectanceProfileFile_List() const;

	/*!
	* \brief Adds a new ReflectanceProfileFile element to this object.
	*
	* No description available in the XSD standard.
	*
	* \param value The element to add
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void addToReflectanceProfileFile_List(const Inscoper::NBO::ReflectanceProfileFilePtr& value, bool validate = true);

	/*!
	* \brief Clear the list of ReflectanceProfileFile.
	*
	* No description available in the XSD standard.
	*/
	void clearReflectanceProfileFile_List();

	/*!
	* \brief Sets the list of TransmissionWavelengthRangeSettings elements.
	*
	* No description available in the XSD standard.
	*
	* \param value The new list of TransmissionWavelengthRangeSettings elements
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void setTransmissionWavelengthRangeSettings_List(const std::vector<Inscoper::NBO::TransmissionWavelengthRangeSettingsPtr>& value, bool validate = true);

	/*!
	* \brief Returns the list of TransmissionWavelengthRangeSettings elements.
	*
	* No description available in the XSD standard.
	*
	* \return The list of TransmissionWavelengthRangeSettings elements
	*/
	std::vector<Inscoper::NBO::TransmissionWavelengthRangeSettingsPtr> getTransmissionWavelengthRangeSettings_List() const;

	/*!
	* \brief Adds a new TransmissionWavelengthRangeSettings element to this object.
	*
	* No description available in the XSD standard.
	*
	* \param value The element to add
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void addToTransmissionWavelengthRangeSettings_List(const Inscoper::NBO::TransmissionWavelengthRangeSettingsPtr& value, bool validate = true);

	/*!
	* \brief Clear the list of TransmissionWavelengthRangeSettings.
	*
	* No description available in the XSD standard.
	*/
	void clearTransmissionWavelengthRangeSettings_List();

	/*!
	* \brief Sets the list of ReflectionWavelengthRangeSettings elements.
	*
	* No description available in the XSD standard.
	*
	* \param value The new list of ReflectionWavelengthRangeSettings elements
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void setReflectionWavelengthRangeSettings_List(const std::vector<Inscoper::NBO::ReflectionWavelengthRangeSettingsPtr>& value, bool validate = true);

	/*!
	* \brief Returns the list of ReflectionWavelengthRangeSettings elements.
	*
	* No description available in the XSD standard.
	*
	* \return The list of ReflectionWavelengthRangeSettings elements
	*/
	std::vector<Inscoper::NBO::ReflectionWavelengthRangeSettingsPtr> getReflectionWavelengthRangeSettings_List() const;

	/*!
	* \brief Adds a new ReflectionWavelengthRangeSettings element to this object.
	*
	* No description available in the XSD standard.
	*
	* \param value The element to add
	* \param validate If true, validates constraints on value. Default is true.
	*/
	void addToReflectionWavelengthRangeSettings_List(const Inscoper::NBO::ReflectionWavelengthRangeSettingsPtr& value, bool validate = true);

	/*!
	* \brief Clear the list of ReflectionWavelengthRangeSettings.
	*
	* No description available in the XSD standard.
	*/
	void clearReflectionWavelengthRangeSettings_List();


private:
	class Impl;
	std::unique_ptr<Impl> pImpl;

	OpticalApertureID_TypePtr ID = nullptr; // Optional attribute
    std::vector<Inscoper::NBO::TransmittanceProfileFilePtr> TransmittanceProfileFile_List;
    std::vector<Inscoper::NBO::ReflectanceProfileFilePtr> ReflectanceProfileFile_List;
    std::vector<Inscoper::NBO::TransmissionWavelengthRangeSettingsPtr> TransmissionWavelengthRangeSettings_List;
    std::vector<Inscoper::NBO::ReflectionWavelengthRangeSettingsPtr> ReflectionWavelengthRangeSettings_List;
};

/*! Shared pointer for OpticalApertureSettings_Type*/
typedef std::shared_ptr<OpticalApertureSettings_Type> OpticalApertureSettings_TypePtr;

} // namespace Inscoper::NBO

#endif // OPTICALAPERTURESETTINGS_TYPE_HPP_INCLUDED