VTK
vtkUTF8TextCodec.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3 Program: Visualization Toolkit
4 Module: vtkUTF8TextCodec.h
5 
6 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7 All rights reserved.
8 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10 This software is distributed WITHOUT ANY WARRANTY; without even
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12 PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
36 #ifndef __vtkUTF8TextCodec_h
37 #define __vtkUTF8TextCodec_h
38 
39 #include "vtkTextCodec.h"
40 
41 
43 {
44 public:
46  static vtkUTF8TextCodec* New() ;
47  void PrintSelf(ostream& os, vtkIndent indent);
48 
50 
52  virtual const char* Name() {return "UTF-8" ;}
53  virtual bool CanHandle(const char* testStr);
55 
57  virtual bool IsValid(istream& InputStream) ;
58 
60 
63  virtual void ToUnicode(istream& InputStream,
66 
70  virtual vtkUnicodeString::value_type NextUnicode(istream& inputStream) ;
71 
72 //BTX
73 protected:
75  ~vtkUTF8TextCodec() ;
76 
77 private:
78  vtkUTF8TextCodec(const vtkUTF8TextCodec &) ; // Not implemented.
79  void operator=(const vtkUTF8TextCodec &) ; // Not implemented.
80 
81 //ETX
82 };
83 
84 
85 #endif
void PrintSelf(ostream &os, vtkIndent indent)
virtual bool CanHandle(const char *NameString)
virtual vtkUnicodeString::value_type NextUnicode(istream &inputStream)=0
vtkUnicodeStringValueType value_type
Virtual class to act as an interface for all text codecs.
Definition: vtkTextCodec.h:42
virtual const char * Name()
a simple class to control print indentation
Definition: vtkIndent.h:37
virtual void ToUnicode(istream &InputStream, vtkTextCodec::OutputIterator &output)=0
Class to read/write UTF-8 text.
virtual bool IsValid(istream &InputStream)
#define VTK_IO_EXPORT
static vtkObject * New()