CIRCT 24.0.0git
Loading...
Searching...
No Matches
esi::WindowType Class Reference

Windows represent a fixed-size sliding window over a stream of data. More...

#include <Types.h>

Inheritance diagram for esi::WindowType:
Collaboration diagram for esi::WindowType:

Classes

struct  Field
 Field information describing a field within a frame. More...
struct  Frame
 Frame information describing which fields are included in a particular frame. More...

Public Member Functions

 WindowType (const ID &id, const std::string &name, const Type *intoType, const Type *loweredType, const std::vector< Frame > &frames)
const std::string & getName () const
const Type * getIntoType () const
const Type * getLoweredType () const
const std::vector< Frame > & getFrames () const
std::ptrdiff_t getBitWidth () const override
Public Member Functions inherited from esi::Type
 Type (const ID &id)
virtual ~Type ()=default
ID getID () const
void setHWBitwidth (std::ptrdiff_t bw)
 Set from manifest JSON hwBitwidth.
virtual MutableBitVector serialize (const std::any &obj) const
 Serialize an object to a MutableBitVector (LSB-first stream).
virtual std::any deserialize (BitVector &data) const
 Deserialize from a BitVector stream (LSB-first).
std::any deserialize (const MessageData &data) const
virtual void ensureValid (const std::any &obj) const
 Ensure that a std::any object is valid for this type.
std::optional< std::string > isValid (const std::any &obj) const
void dump (std::ostream &os, bool oneLine=false) const
std::string toString (bool oneLine=false) const

Private Attributes

std::string name
const Type * intoType
const Type * loweredType
std::vector< Frame > frames

Additional Inherited Members

Public Types inherited from esi::Type
using ID = std::string
Protected Attributes inherited from esi::Type
ID id
std::ptrdiff_t hwBitwidth = -1

Detailed Description

Windows represent a fixed-size sliding window over a stream of data.

They define an "into" type (the data structure being windowed) and a "loweredType" (the hardware representation including control signals).

Definition at line 334 of file Types.h.

Constructor & Destructor Documentation

◆ WindowType()

esi::WindowType::WindowType ( const ID & id,
const std::string & name,
const Type * intoType,
const Type * loweredType,
const std::vector< Frame > & frames )
inline

Definition at line 350 of file Types.h.

References frames, esi::Type::id, intoType, loweredType, name, and esi::Type::Type().

Member Function Documentation

◆ getBitWidth()

std::optional< int64_t > WindowType::getBitWidth ( ) const
inlineoverridevirtual

Reimplemented from esi::Type.

Definition at line 360 of file Types.h.

References loweredType.

◆ getFrames()

const std::vector< Frame > & esi::WindowType::getFrames ( ) const
inline

Definition at line 358 of file Types.h.

References frames.

Referenced by NB_MODULE().

◆ getIntoType()

const Type * esi::WindowType::getIntoType ( ) const
inline

Definition at line 356 of file Types.h.

References intoType, and esi::Type::Type().

Referenced by NB_MODULE().

◆ getLoweredType()

Type WindowType::getLoweredType ( ) const
inline

Definition at line 357 of file Types.h.

References loweredType, and esi::Type::Type().

Referenced by NB_MODULE().

◆ getName()

const std::string & esi::WindowType::getName ( ) const
inline

Definition at line 355 of file Types.h.

References name.

Referenced by NB_MODULE().

Member Data Documentation

◆ frames

std::vector<Frame> esi::WindowType::frames
private

Definition at line 368 of file Types.h.

Referenced by getFrames(), and WindowType().

◆ intoType

const Type* esi::WindowType::intoType
private

Definition at line 366 of file Types.h.

Referenced by getIntoType(), and WindowType().

◆ loweredType

const Type* esi::WindowType::loweredType
private

Definition at line 367 of file Types.h.

Referenced by getBitWidth(), getLoweredType(), and WindowType().

◆ name

std::string esi::WindowType::name
private

Definition at line 365 of file Types.h.

Referenced by esiaccel.types.TypeAlias::__str__(), getName(), and WindowType().


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