Struct opencv::core::FileNode

source ·
pub struct FileNode { /* private fields */ }
Expand description

File Storage Node class.

The node is used to store each and every element of the file storage opened for reading. When XML/YAML file is read, it is first parsed and stored in the memory as a hierarchical collection of nodes. Each node can be a “leaf” that is contain a single number or a string, or be a collection of other nodes. There can be named collections (mappings) where each element has a name and it is accessed by a name, and ordered collections (sequences) where elements do not have names but rather accessed by index. Type of the file node can be determined using FileNode::type method.

Note that file nodes are only used for navigating file storages opened for reading. When a file storage is opened for writing, no data is stored in memory after it is written.

Implementations§

The constructors.

These constructors are used to create a default file node, construct it from obsolete structures or from the another file node.

The constructors.

These constructors are used to create a default file node, construct it from obsolete structures or from the another file node.

Overloaded parameters
Parameters
  • fs: Pointer to the file storage structure.

  • blockIdx: Index of the memory block where the file node is stored

  • ofs: Offset in bytes from the beginning of the serialized storage

    @deprecated

The constructors.

These constructors are used to create a default file node, construct it from obsolete structures or from the another file node.

Overloaded parameters
Parameters
  • node: File node to be used as initialization for the created file node.

Trait Implementations§

Wrap the specified raw pointer Read more
Return an the underlying raw pointer while consuming this wrapper. Read more
Return the underlying raw pointer. Read more
Return the underlying mutable raw pointer Read more
Executes the destructor for this type. Read more
Internal method used when reading FileStorage. Sets the type (int, real or string) and value of the previously created node. Read more
Returns element of a mapping node or a sequence node. Read more
Returns element of a mapping node or a sequence node. Read more
Returns element of a mapping node or a sequence node. Read more
Returns keys of a mapping node. Read more
Returns type of the node. Read more
returns true if the node is empty
returns true if the node is a “none” object
returns true if the node is a sequence
returns true if the node is a mapping
returns true if the node is an integer
returns true if the node is a floating-point number
returns true if the node is a text string
returns true if the node has a name
returns the node name or an empty string if the node is nameless
returns the number of elements in the node, if it is a sequence or mapping, or 1 otherwise.
returns raw size of the FileNode in bytes
returns the node content as an integer. If the node stores floating-point number, it is rounded.
returns the node content as float
returns the node content as double
returns the node content as text string
returns iterator pointing to the first node element
returns iterator pointing to the element following the last node element
Reads node elements to the buffer with the specified format. Read more
Simplified reading API to use with bindings.
Simplified reading API to use with bindings.
Simplified reading API to use with bindings.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.