Commit 9b9a8027 authored by Franz Pöschel's avatar Franz Pöschel Committed by Atkins, Charles Vernon
Browse files

Add binding: Attribute::IsValue

parent 182ab77c
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -64,6 +64,14 @@ namespace adios2
    }                                                                          \
                                                                               \
    template <>                                                                \
    bool Attribute<T>::IsValue() const                                         \
    {                                                                          \
        helper::CheckForNullptr(m_Attribute,                                   \
                                "in call to Attribute<T>::IsValue()");         \
        return m_Attribute->m_IsSingleValue;                                   \
    }                                                                          \
                                                                               \
    template <>                                                                \
    std::string ToString(const Attribute<T> &attribute)                        \
    {                                                                          \
        return std::string("Attribute<") + attribute.Type() + ">(Name: \"" +   \
+6 −0
Original line number Diff line number Diff line
@@ -67,6 +67,12 @@ public:
     */
    std::vector<T> Data() const;

    /**
     * Distinguish single-value attributes from vector attributes
     * @return true if single-value, false otherwise
     */
    bool IsValue() const;

private:
    Attribute<T>(core::Attribute<IOType> *attribute);
    core::Attribute<IOType> *m_Attribute = nullptr;