⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 abstractdomparser.hpp

📁 经典开源游戏glest的源代码
💻 HPP
📖 第 1 页 / 共 5 页
字号:
      *      * @param noNamespaceSchemaLocation the XML Schema Location with no target namespace      *      * @see #setExternalNoNamespaceSchemaLocation(const XMLCh* const)      */    void setExternalNoNamespaceSchemaLocation(const char* const noNamespaceSchemaLocation);    /**      * This allows an application to set a SecurityManager on      * the parser; this object stores information that various      * components use to limit their consumption of system      * resources while processing documents.      *      * If this method is called more than once, only the last one takes effect.      * It may not be reset during a parse.      *      *      * @param securityManager  the SecurityManager instance to      * be used by this parser      *      * @see #getSecurityManager      */    void setSecurityManager(SecurityManager* const securityManager);    /** Set the 'Loading External DTD' flag      *      * This method allows users to enable or disable the loading of external DTD.      * When set to false, the parser will ignore any external DTD completely      * if the validationScheme is set to Val_Never.      *      * The parser's default state is: true.      *      * This flag is ignored if the validationScheme is set to Val_Always or Val_Auto.      *      * @param newState The value specifying whether external DTD should      *                 be loaded or not.      *      * @see #getLoadExternalDTD      * @see #setValidationScheme      */    void setLoadExternalDTD(const bool newState);     /** Set the 'create comment nodes' flag      *      * This method allows the user to specify whether the parser should      * create comment nodes in the DOM tree being produced.      * <p>The default value is 'true'.      *      * @param create The new state of the create comment nodes      *               flag.      * @see #getCreateCommentNodes      */    void setCreateCommentNodes(const bool create);    /** Enable/disable src offset calculation      *      * This method allows users to enable/disable src offset calculation.      * Disabling the calculation will improve performance.      *      * The parser's default state is: false.      *      * @param newState The value specifying whether we should enable or      *                 disable src offset calculation      *      * @see #getCalculateSrcOfs      */    void setCalculateSrcOfs(const bool newState);    /** Force standard uri      *      * This method allows users to tell the parser to force standard uri conformance.      *      * The parser's default state is: false.      *      * @param newState The value specifying whether the parser should reject malformed URI.      *      * @see #getStandardUriConformant      */    void setStandardUriConformant(const bool newState);    /** Set the scanner to use when scanning the XML document      *      * This method allows users to set the  scanner to use      * when scanning a given XML document.      *      * @param scannerName The name of the desired scanner      */    void useScanner(const XMLCh* const scannerName);    /** Set the implementation to use when creating the  document      *      * This method allows users to set the implementation to use      * to create the document when parseing.      *      * @param implementationFeatures The names of the desired features the implementation should have.      */    void useImplementation(const XMLCh* const implementationFeatures);    /**      * This method installs the user specified PSVI handler on      * the parser.      *      * @param handler A pointer to the PSVI handler to be called      *                when the parser comes across 'PSVI' events      *                as per the schema specification.      */    virtual void setPSVIHandler(PSVIHandler* const handler);    /** Set the 'associate schema info' flag      *      * This method allows users to specify whether       * the parser should store schema informations in the element       * and attribute nodes in the DOM tree being produced.      *      * @return  The state of the associate schema info flag.      * @see #getCreateSchemaInfo      */    void  setCreateSchemaInfo(const bool newState);    /** Set the 'ignore annotation' flag      *      * This method gives users the option to not generate XSAnnotations      * when "traversing" a schema.      *      * The parser's default state is false      *      * @param newValue The state to set      */    void setIgnoreAnnotations(const bool newValue);    /** Set the 'disable default entity resolution' flag      *      * This method gives users the option to not perform default entity      * resolution.  If the user's resolveEntity method returns NULL the      * parser will try to resolve the entity on its own.  When this option      * is set to true, the parser will not attempt to resolve the entity      * when the resolveEntity method returns NULL.      *          * The parser's default state is false      *      * @param newValue The state to set      *      * @see #entityResolver      */    void setDisableDefaultEntityResolution(const bool newValue);    /** Set the 'skip DTD validation' flag      *      * This method gives users the option to skip DTD validation only when       * schema validation is on (i.e. when performing validation,  we will      * ignore the DTD, except for entities, when schema validation is enabled).      *      * NOTE: This option is ignored if schema validation is disabled.      *      * The parser's default state is false      *      * @param newValue The state to set      */    void setSkipDTDValidation(const bool newValue);    //@}    // -----------------------------------------------------------------------    //  Parsing methods    // -----------------------------------------------------------------------    /** @name Parsing methods */    //@{    /** Parse via an input source object      *      * This method invokes the parsing process on the XML file specified      * by the InputSource parameter. This API is borrowed from the      * SAX Parser interface.      *      * @param source A const reference to the InputSource object which      *               points to the XML file to be parsed.      * @exception SAXException Any SAX exception, possibly      *            wrapping another exception.      * @exception XMLException An exception from the parser or client      *            handler code.      * @exception DOMException A DOM exception as per DOM spec.      * @see InputSource#InputSource      */    void parse(const InputSource& source);    /** Parse via a file path or URL      *      * This method invokes the parsing process on the XML file specified by      * the Unicode string parameter 'systemId'. This method is borrowed      * from the SAX Parser interface.      *      * @param systemId A const XMLCh pointer to the Unicode string which      *                 contains the path to the XML file to be parsed.      *      * @exception SAXException Any SAX exception, possibly      *            wrapping another exception.      * @exception XMLException An exception from the parser or client      *            handler code.      * @exception DOMException A DOM exception as per DOM spec.      * @see #parse(InputSource,...)      */    void parse(const XMLCh* const systemId);    /** Parse via a file path or URL (in the local code page)      *      * This method invokes the parsing process on the XML file specified by      * the native char* string parameter 'systemId'.      *      * @param systemId A const char pointer to a native string which      *                 contains the path to the XML file to be parsed.      *      * @exception SAXException Any SAX exception, possibly      *            wrapping another exception.      * @exception XMLException An exception from the parser or client      *            handler code.      * @exception DOMException A DOM exception as per DOM spec.      * @see #parse(InputSource,...)      */    void parse(const char* const systemId);    /** Begin a progressive parse operation      *      * This method is used to start a progressive parse on a XML file.      * To continue parsing, subsequent calls must be to the parseNext      * method.      *      * It scans through the prolog and returns a token to be used on      * subsequent scanNext() calls. If the return value is true, then the      * token is legal and ready for further use. If it returns false, then      * the scan of the prolog failed and the token is not going to work on      * subsequent scanNext() calls.      *      * @param systemId A pointer to a Unicode string represting the path      *                 to the XML file to be parsed.      * @param toFill   A token maintaing state information to maintain      *                 internal consistency between invocation of 'parseNext'      *                 calls.      * @return 'true', if successful in parsing the prolog. It indicates the      *         user can go ahead with parsing the rest of the file. It      *         returns 'false' to indicate that the parser could not parse      *         the prolog.      *      * @see #parseNext      * @see #parseFirst(char*,...)      * @see #parseFirst(InputSource&,...)      */    bool parseFirst    (        const   XMLCh* const    systemId        ,       XMLPScanToken&  toFill    );    /** Begin a progressive parse operation      *      * This method is used to start a progressive parse on a XML file.      * To continue parsing, subsequent calls must be to the parseNext      * method.      *      * It scans through the prolog and returns a token to be used on      * subsequent scanNext() calls. If the return value is true, then the      * token is legal and ready for further use. If it returns false, then      * the scan of the prolog failed and the token is not going to work on      * subsequent scanNext() calls.      *      * @param systemId A pointer to a regular native string represting      *                 the path to the XML file to be parsed.      * @param toFill   A token maintaing state information to maintain      *                 internal consistency between invocation of 'parseNext'      *                 calls.      *      * @return 'true', if successful in parsing the prolog. It indicates the      *         user can go ahead with parsing the rest of the file. It      *         returns 'false' to indicate that the parser could not parse      *         the prolog.      *      * @see #parseNext      * @see #parseFirst(XMLCh*,...)      * @see #parseFirst(InputSource&,...)      */    bool parseFirst    (        const   char* const     systemId        ,       XMLPScanToken&  toFill    );    /** Begin a progressive parse operation      *      * This method is used to start a progressive parse on a XML file.      * To continue parsing, subsequent calls must be to the parseNext      * method.      *      * It scans through the prolog and returns a token to be used on      * subsequent scanNext() calls. If the return value is true, then the      * token is legal and ready for further use. If it returns false, then      * the scan of the prolog failed and the token is not going to work on      * subsequent scanNext() calls.      *      * @param source   A const reference to the InputSource object which      *                 points to the XML file to be parsed.      * @param toFill   A token maintaing state information to maintain      *                 internal consistency between invocation of 'parseNext'      *                 calls.      *      * @return 'true', if successful in parsing the prolog. It indicates the      *         user can go ahead with parsing the rest of the file. It      *         returns 'false' to indicate that the parser could not parse      *         the prolog.      *      * @see #parseNext      * @see #parseFirst(XMLCh*,...)      * @see #parseFirst(char*,...)      */    bool parseFirst    (        const   InputSource&    source        ,       XMLPScanToken&  toFill    );    /** Continue a progressive parse operation      *      * This method is used to continue with progressive parsing of      * XML files started by a call to 'parseFirst' method.      *      * It parses the XML file and stops as soon as it comes across      * a XML token (as defined in the XML specification).      *      * @param token A token maintaing state information to maintain      *              internal consistency between invocation of 'parseNext'      *              calls.      *      * @return 'true', if successful in parsing the next XML token.      *         It indicates the user can go ahead with parsing the rest      *         of the file. It returns 'false' to indicate that the parser      *         could not find next token as per the XML specification      *         production rule.      *      * @see #parseFirst(XMLCh*,...)      * @see #parseFirst(char*,...)      * @see #parseFirst(InputSource&,...)      */    bool parseNext(XMLPScanToken& token);    /** Reset the parser after a progressive parse      *      * If a progressive parse loop exits before the end of the document      * is reached, the parser has no way of knowing this. So it will leave      * open any files or sockets or memory buffers that were in use at      * the time that the parse loop exited.      *      * The next parse operation will cause these open files and such to      * be closed, but the next parse operation might occur at some unknown      * future point. To avoid this problem, you should reset the parser if      * you exit the loop early.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -