ROSE 0.11.145.192
Public Types | Public Member Functions | Static Public Member Functions | List of all members
Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm Class Reference

Description

UTF-16 character encoding form.

Encodes each code point as one or two 16-bit code values.

Definition at line 309 of file String.h.

#include <Rose/BinaryAnalysis/String.h>

Inheritance diagram for Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm:
Inheritance graph
[legend]
Collaboration diagram for Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm:
Collaboration graph
[legend]

Public Types

typedef Sawyer::SharedPointer< Utf16CharacterEncodingFormPtr
 Shared-ownership pointer to a Utf16CharacterEncodingForm.
 
- Public Types inherited from Rose::BinaryAnalysis::Strings::CharacterEncodingForm
typedef Sawyer::SharedPointer< CharacterEncodingFormPtr
 Shared ownership pointer to a CharacterEncodingForm.
 

Public Member Functions

virtual CharacterEncodingForm::Ptr clone () const override
 Create a new encoder from this one.
 
virtual std::string name () const override
 Name of encoder.
 
virtual CodeValues encode (CodePoint cp) override
 Encode a code point into a sequence of one or more code values.
 
virtual State decode (CodeValue) override
 Decode one code value.
 
virtual CodePoint consume () override
 Consume a decoded code point.
 
virtual void reset () override
 Reset the decoder state machine.
 
- Public Member Functions inherited from Rose::BinaryAnalysis::Strings::CharacterEncodingForm
State state () const
 Decoder state.
 
- Public Member Functions inherited from Sawyer::SharedObject
 SharedObject ()
 Default constructor.
 
 SharedObject (const SharedObject &)
 Copy constructor.
 
virtual ~SharedObject ()
 Virtual destructor.
 
SharedObjectoperator= (const SharedObject &)
 Assignment.
 

Static Public Member Functions

static Ptr instance ()
 

Additional Inherited Members

- Protected Attributes inherited from Rose::BinaryAnalysis::Strings::CharacterEncodingForm
State state_ = INITIAL_STATE
 

Member Typedef Documentation

◆ Ptr

Shared-ownership pointer to a Utf16CharacterEncodingForm.

See Shared ownership.

Definition at line 315 of file String.h.

Constructor & Destructor Documentation

◆ Utf16CharacterEncodingForm()

Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::Utf16CharacterEncodingForm ( )
inlineprotected

Definition at line 312 of file String.h.

Member Function Documentation

◆ instance()

static Ptr Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::instance ( )
inlinestatic

Definition at line 317 of file String.h.

◆ clone()

virtual CharacterEncodingForm::Ptr Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::clone ( ) const
inlineoverridevirtual

Create a new encoder from this one.

Implements Rose::BinaryAnalysis::Strings::CharacterEncodingForm.

Definition at line 318 of file String.h.

◆ name()

virtual std::string Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::name ( ) const
inlineoverridevirtual

Name of encoder.

Implements Rose::BinaryAnalysis::Strings::CharacterEncodingForm.

Definition at line 319 of file String.h.

◆ encode()

virtual CodeValues Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::encode ( CodePoint  )
overridevirtual

Encode a code point into a sequence of one or more code values.

For instance, an ecoder for UTF-16 will encode a code point into one or more values in the range 0 through (2^16)-1.

Implements Rose::BinaryAnalysis::Strings::CharacterEncodingForm.

◆ decode()

virtual State Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::decode ( CodeValue  )
overridevirtual

Decode one code value.

Processes a single code value and updates the decoder state machine. Returns the decoder's new state. See documentation for Strings::State for restrictions on state transitions.

Implements Rose::BinaryAnalysis::Strings::CharacterEncodingForm.

◆ consume()

virtual CodePoint Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::consume ( )
overridevirtual

Consume a decoded code point.

The decoder must be in the FINAL_STATE or COMPLETED_STATE, and upon return will be in the INITIAL_STATE.

Implements Rose::BinaryAnalysis::Strings::CharacterEncodingForm.

◆ reset()

virtual void Rose::BinaryAnalysis::Strings::Utf16CharacterEncodingForm::reset ( )
overridevirtual

Reset the decoder state machine.

Implements Rose::BinaryAnalysis::Strings::CharacterEncodingForm.


The documentation for this class was generated from the following file: