Skip to content
Snippets Groups Projects
Select Git revision
  • 90e4ea15ffaac89643678278c5e3ac57a8eeae9e
  • master default protected
  • develop protected
  • feat_remove_attr
  • python2.7
  • python3.8
6 results

statwriter.h

Blame
  • user avatar
    ilor authored
    add two new writers: a dummy "none" writer that disables output and a "stats" writer that outputs general info only about token counts and annotation info
    903e88c7
    History
    statwriter.h 471 B
    #ifndef LIBSORPUS2_IO_STATWRITER_H
    #define LIBCORPUS2_IO_STATWRITER_H
    
    #include <libcorpus2/io/writer.h>
    
    namespace Corpus2 {
    
    class StatWriter : public TokenWriter
    {
    public:
    	StatWriter(std::ostream& os, const Tagset& tagset,
    			const string_range_vector& params);
    
    	void write_token(const Token& t);
    
    	void write_sentence(const Sentence& t);
    
    	void write_chunk(const Chunk& c);
    
    	static bool registered;
    };
    
    } /* end ns Corpus2 */
    
    #endif // LIBCORPUS2_IO_STATWRITER_H