From OpenSCADAWiki
Jump to: navigation, search
(Importing a new version from external source)
 
(Importing a new version from external source)
 
Line 27: Line 27:
 
* ''XMLNode* childGet( const string &attr, const string &vl, bool noex = false ) const;'' — Getting the included ''numb'' indexed tag by its value ''vl'' of the attribute ''attr''. ''noex'' indicates the prohibition of the generation of exception in the case of absence of the tag.
 
* ''XMLNode* childGet( const string &attr, const string &vl, bool noex = false ) const;'' — Getting the included ''numb'' indexed tag by its value ''vl'' of the attribute ''attr''. ''noex'' indicates the prohibition of the generation of exception in the case of absence of the tag.
 
* ''XMLNode* getElementBy( const string &attr, const string &val );'' — Included node search by the value ''val'' of the attribute ''attr''.
 
* ''XMLNode* getElementBy( const string &attr, const string &val );'' — Included node search by the value ''val'' of the attribute ''attr''.
* ''void getElementsBy( const string &tag, const string &attr, const string &val, TArrayObj *rez );'' — get elements array ''rez'' from the tree by ''tag'' (empty for all) and attribute ''attr'' value ''val'' (empty for pass).
+
* ''void getElementsBy( const string &tag, const string &attr, const string &val, TArrayObj *rez, unsigned limit = 0, unsigned *from = NULL );'' — get elements array ''rez'' from the tree by ''tag'' (empty for all) and attribute ''attr'' value ''val'' (empty for pass), also starting the tag number ''from'' and limiting them number in ''limit'' (zero for no limit).
 
* ''XMLNode* parent( );'' — Parent tag of the tag.
 
* ''XMLNode* parent( );'' — Parent tag of the tag.
 
* ''XMLNode* root( );'' — Root tag of the tag.
 
* ''XMLNode* root( );'' — Root tag of the tag.

Latest revision as of 09:27, 2 June 2024

Information about message (contribute)
This message has no documentation. If you know where or how this message is used, you can help other translators by adding documentation to this message.
Message definition (Documents/API)
'''Public methods:'''
* ''XMLNode( const string &name = "" );'' — Initialization of the tag with the ''name''.
* ''XMLNode( const XMLNode &nd );'' — Copy constructor.
* ''XMLNode &operator=( const XMLNode &prm );'' — Copying a branch of the XML-tree from ''prm''.
* ''string name( ) const;'' — Tag's name.
* ''XMLNode* setName( const string &s );'' — Setting the tag's name to ''s''.
* ''string text( bool childs = false, bool recursive = false ) const;'' — Tag's text. ''childs'' — for text getting from special text nodes.
* ''XMLNode* setText( const string &s, bool childs = false );'' — Setting the tag's text to ''s''. ''childs'' — for set text to special text node.
* ''void attrList( vector<string> & list ) const;'' — ''List'' of attributes in the tag.
* ''XMLNode* attrDel( const string &name );'' — Deleting of the attribute ''name''.
* ''void attrClear( );'' — Clean up the tag's attributes.
* ''string attr( const string &name, bool caseSens = true, bool *presence = NULL ) const;'' — Getting the attribute ''name'' for the case-sensitivity ''caseSens'' and with the ''presence'' sign.
* ''XMLNode* setAttr( const string &name, const string &val );'' — Setting/creation of the attribute ''name'' with the value ''val''.
* ''void load( const string &vl, unsigned flg = 0, const string &cp = "UTF-8" );'' — Load/parsing of the XML-file, with source encoding ''cp'' and flags ''flg''.
* ''string save( unsigned flg = 0, const string &cp = "UTF-8" ) const;'' — Saving/creation of the XML-file with the formatting parameter ''flg'' and encoding to ''cp''.
* ''XMLNode* clear( );'' — Clear the tag (recursively, including all childs).
* ''bool childEmpty( ) const;'' — Check for empty included tags.
* ''unsigned childSize( ) const;'' — Number of included tags.
* ''void childAdd( XMLNode *nd ); XMLNode* childAdd( const string &name = "" );'' — Adding the included tag.
* ''int childIns( int id, XMLNode *nd );'' — Insert of the included tag ''nd'' to the position ''id''. Negative ''id'' counts from end.
* ''XMLNode* childIns( int id, const string &name = "" );'' — Insert of the included tag with the name ''name'' to the position ''id''. Negative ''id'' counts from end.
* ''void childDel( const int id );'' — Deleting of the included tag ''id''. Negative ''id'' counts from end.
* ''void childDel( XMLNode *nd );'' — Deleting of the included tag using its address ''nd''.
* ''void childClear( const string &name = "" );'' — Clean up of the included tag ''name''.
* ''XMLNode* childGet( const int, bool noex = false ) const;'' — Getting the included tag by its index number.
* ''XMLNode* childGet( const string &name, const int numb = 0, bool noex = false ) const;'' — Getting of the included ''numb'' indexed tag by the tag's name ''name''. ''noex'' indicates the prohibition of the generation of exception in the case of absence of the tag.
* ''XMLNode* childGet( const string &attr, const string &vl, bool noex = false ) const;'' — Getting the included ''numb'' indexed tag by its value ''vl'' of the attribute ''attr''. ''noex'' indicates the prohibition of the generation of exception in the case of absence of the tag.
* ''XMLNode* getElementBy( const string &attr, const string &val );'' — Included node search by the value ''val'' of the attribute ''attr''.
* ''void getElementsBy( const string &tag, const string &attr, const string &val, TArrayObj *rez, unsigned limit = 0, unsigned *from = NULL );'' — get elements array ''rez'' from the tree by ''tag'' (empty for all) and attribute ''attr'' value ''val'' (empty for pass), also starting the tag number ''from'' and limiting them number in ''limit'' (zero for no limit).
* ''XMLNode* parent( );'' — Parent tag of the tag.
* ''XMLNode* root( );'' — Root tag of the tag.
Translation'''Public methods:'''
* ''XMLNode( const string &name = "" );'' — Initialization of the tag with the ''name''.
* ''XMLNode( const XMLNode &nd );'' — Copy constructor.
* ''XMLNode &operator=( const XMLNode &prm );'' — Copying a branch of the XML-tree from ''prm''.
* ''string name( ) const;'' — Tag's name.
* ''XMLNode* setName( const string &s );'' — Setting the tag's name to ''s''.
* ''string text( bool childs = false, bool recursive = false ) const;'' — Tag's text. ''childs'' — for text getting from special text nodes.
* ''XMLNode* setText( const string &s, bool childs = false );'' — Setting the tag's text to ''s''. ''childs'' — for set text to special text node.
* ''void attrList( vector<string> & list ) const;'' — ''List'' of attributes in the tag.
* ''XMLNode* attrDel( const string &name );'' — Deleting of the attribute ''name''.
* ''void attrClear( );'' — Clean up the tag's attributes.
* ''string attr( const string &name, bool caseSens = true, bool *presence = NULL ) const;'' — Getting the attribute ''name'' for the case-sensitivity ''caseSens'' and with the ''presence'' sign.
* ''XMLNode* setAttr( const string &name, const string &val );'' — Setting/creation of the attribute ''name'' with the value ''val''.
* ''void load( const string &vl, unsigned flg = 0, const string &cp = "UTF-8" );'' — Load/parsing of the XML-file, with source encoding ''cp'' and flags ''flg''.
* ''string save( unsigned flg = 0, const string &cp = "UTF-8" ) const;'' — Saving/creation of the XML-file with the formatting parameter ''flg'' and encoding to ''cp''.
* ''XMLNode* clear( );'' — Clear the tag (recursively, including all childs).
* ''bool childEmpty( ) const;'' — Check for empty included tags.
* ''unsigned childSize( ) const;'' — Number of included tags.
* ''void childAdd( XMLNode *nd ); XMLNode* childAdd( const string &name = "" );'' — Adding the included tag.
* ''int childIns( int id, XMLNode *nd );'' — Insert of the included tag ''nd'' to the position ''id''. Negative ''id'' counts from end.
* ''XMLNode* childIns( int id, const string &name = "" );'' — Insert of the included tag with the name ''name'' to the position ''id''. Negative ''id'' counts from end.
* ''void childDel( const int id );'' — Deleting of the included tag ''id''. Negative ''id'' counts from end.
* ''void childDel( XMLNode *nd );'' — Deleting of the included tag using its address ''nd''.
* ''void childClear( const string &name = "" );'' — Clean up of the included tag ''name''.
* ''XMLNode* childGet( const int, bool noex = false ) const;'' — Getting the included tag by its index number.
* ''XMLNode* childGet( const string &name, const int numb = 0, bool noex = false ) const;'' — Getting of the included ''numb'' indexed tag by the tag's name ''name''. ''noex'' indicates the prohibition of the generation of exception in the case of absence of the tag.
* ''XMLNode* childGet( const string &attr, const string &vl, bool noex = false ) const;'' — Getting the included ''numb'' indexed tag by its value ''vl'' of the attribute ''attr''. ''noex'' indicates the prohibition of the generation of exception in the case of absence of the tag.
* ''XMLNode* getElementBy( const string &attr, const string &val );'' — Included node search by the value ''val'' of the attribute ''attr''.
* ''void getElementsBy( const string &tag, const string &attr, const string &val, TArrayObj *rez, unsigned limit = 0, unsigned *from = NULL );'' — get elements array ''rez'' from the tree by ''tag'' (empty for all) and attribute ''attr'' value ''val'' (empty for pass), also starting the tag number ''from'' and limiting them number in ''limit'' (zero for no limit).
* ''XMLNode* parent( );'' — Parent tag of the tag.
* ''XMLNode* root( );'' — Root tag of the tag.

Public methods:

  • XMLNode( const string &name = "" ); — Initialization of the tag with the name.
  • XMLNode( const XMLNode &nd ); — Copy constructor.
  • XMLNode &operator=( const XMLNode &prm ); — Copying a branch of the XML-tree from prm.
  • string name( ) const; — Tag's name.
  • XMLNode* setName( const string &s ); — Setting the tag's name to s.
  • string text( bool childs = false, bool recursive = false ) const; — Tag's text. childs — for text getting from special text nodes.
  • XMLNode* setText( const string &s, bool childs = false ); — Setting the tag's text to s. childs — for set text to special text node.
  • void attrList( vector<string> & list ) const;List of attributes in the tag.
  • XMLNode* attrDel( const string &name ); — Deleting of the attribute name.
  • void attrClear( ); — Clean up the tag's attributes.
  • string attr( const string &name, bool caseSens = true, bool *presence = NULL ) const; — Getting the attribute name for the case-sensitivity caseSens and with the presence sign.
  • XMLNode* setAttr( const string &name, const string &val ); — Setting/creation of the attribute name with the value val.
  • void load( const string &vl, unsigned flg = 0, const string &cp = "UTF-8" ); — Load/parsing of the XML-file, with source encoding cp and flags flg.
  • string save( unsigned flg = 0, const string &cp = "UTF-8" ) const; — Saving/creation of the XML-file with the formatting parameter flg and encoding to cp.
  • XMLNode* clear( ); — Clear the tag (recursively, including all childs).
  • bool childEmpty( ) const; — Check for empty included tags.
  • unsigned childSize( ) const; — Number of included tags.
  • void childAdd( XMLNode *nd ); XMLNode* childAdd( const string &name = "" ); — Adding the included tag.
  • int childIns( int id, XMLNode *nd ); — Insert of the included tag nd to the position id. Negative id counts from end.
  • XMLNode* childIns( int id, const string &name = "" ); — Insert of the included tag with the name name to the position id. Negative id counts from end.
  • void childDel( const int id ); — Deleting of the included tag id. Negative id counts from end.
  • void childDel( XMLNode *nd ); — Deleting of the included tag using its address nd.
  • void childClear( const string &name = "" ); — Clean up of the included tag name.
  • XMLNode* childGet( const int, bool noex = false ) const; — Getting the included tag by its index number.
  • XMLNode* childGet( const string &name, const int numb = 0, bool noex = false ) const; — Getting of the included numb indexed tag by the tag's name name. noex indicates the prohibition of the generation of exception in the case of absence of the tag.
  • XMLNode* childGet( const string &attr, const string &vl, bool noex = false ) const; — Getting the included numb indexed tag by its value vl of the attribute attr. noex indicates the prohibition of the generation of exception in the case of absence of the tag.
  • XMLNode* getElementBy( const string &attr, const string &val ); — Included node search by the value val of the attribute attr.
  • void getElementsBy( const string &tag, const string &attr, const string &val, TArrayObj *rez, unsigned limit = 0, unsigned *from = NULL ); — get elements array rez from the tree by tag (empty for all) and attribute attr value val (empty for pass), also starting the tag number from and limiting them number in limit (zero for no limit).
  • XMLNode* parent( ); — Parent tag of the tag.
  • XMLNode* root( ); — Root tag of the tag.