public bool TryGetValue(string name, out SerializedValueView value)
        {
            foreach (var m in this)
            {
                if (!m.Name().Equals(name))
                {
                    continue;
                }

                value = m.Value();
                return(true);
            }

            value = default;
            return(false);
        }
        /// <summary>
        /// Reads the next node as an array element.
        /// </summary>
        /// <param name="view">The view of the array element.</param>
        /// <returns>True if the element was successfully read, false otherwise.</returns>
        public bool ReadArrayElement(out SerializedValueView view)
        {
            if (!CheckArrayElement())
            {
                view = default;
                return(false);
            }

            view = ReadInternal(NodeType.Any, m_Parser.TokenParentIndex);

            if (m_Parser.NodeType != NodeType.Any)
            {
                return(true);
            }

            view = default;
            return(false);
        }
 public UInt64Property(SerializedStringView name, SerializedValueView value, IPropertyAttributeCollection attributes = null)
 {
     m_Name       = name;
     m_Value      = value;
     m_Attributes = attributes;
 }
 /// <summary>
 /// Reads the next node in the stream, respecting depth/scope.
 /// </summary>
 /// <param name="view">The view at the returned node type.</param>
 /// <param name="node">The node type to stop at.</param>
 /// <returns>The node type the parser stopped at.</returns>
 public NodeType Read(out SerializedValueView view, NodeType node = NodeType.Any)
 {
     view = ReadInternal(node, m_Parser.TokenParentIndex);
     return(m_Parser.NodeType);
 }
 /// <summary>
 /// Advances the reader to the given node type, ignoring depth/scope.
 /// </summary>
 /// <param name="view">The view at the returned node type.</param>
 /// <param name="node">The node type to stop at.</param>
 /// <returns>The node type the parser stopped at.</returns>
 public NodeType Step(out SerializedValueView view, NodeType node = NodeType.Any)
 {
     view = ReadInternal(node, NodeParser.k_IgnoreParent);
     return(m_Parser.NodeType);
 }