Header And Logo

| The world's most advanced open source database.


tstoreReceiver.h File Reference

#include "tcop/dest.h"
#include "utils/tuplestore.h"
Include dependency graph for tstoreReceiver.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


DestReceiverCreateTuplestoreDestReceiver (void)
void SetTuplestoreDestReceiverParams (DestReceiver *self, Tuplestorestate *tStore, MemoryContext tContext, bool detoast)

Function Documentation

DestReceiver* CreateTuplestoreDestReceiver ( void   ) 

Definition at line 187 of file tstoreReceiver.c.

References palloc0().

Referenced by CreateDestReceiver().

    TStoreState *self = (TStoreState *) palloc0(sizeof(TStoreState));

    self->pub.receiveSlot = tstoreReceiveSlot_notoast;  /* might change */
    self->pub.rStartup = tstoreStartupReceiver;
    self->pub.rShutdown = tstoreShutdownReceiver;
    self->pub.rDestroy = tstoreDestroyReceiver;
    self->pub.mydest = DestTuplestore;

    /* private fields will be set by SetTuplestoreDestReceiverParams */

    return (DestReceiver *) self;

void SetTuplestoreDestReceiverParams ( DestReceiver self,
Tuplestorestate tStore,
MemoryContext  tContext,
bool  detoast 

Definition at line 206 of file tstoreReceiver.c.

References Assert, TStoreState::cxt, DestTuplestore, TStoreState::detoast, _DestReceiver::mydest, TStoreState::pub, and TStoreState::tstore.

Referenced by FillPortalStore(), and PersistHoldablePortal().

    TStoreState *myState = (TStoreState *) self;

    Assert(myState->pub.mydest == DestTuplestore);
    myState->tstore = tStore;
    myState->cxt = tContext;
    myState->detoast = detoast;