void _Snac_EntryPoint_Init( Snac_EntryPoint* self ) { /* General and Virtual info should already be set */ /* Snac_EntryPoint info */ self->constitutiveRun = _Snac_EntryPoint_Run_Constitutive; self->run = EntryPoint_GetRun( self ); /* run is set before this func is called... hence may have invalid value; set */ }
void ForceVector_Assemble( void* forceVector ) { ForceVector* self = (ForceVector*)forceVector; int ii; Journal_DPrintf( self->debug, "In %s - for vector \"%s\" - calling the \"%s\" E.P.\n", __func__, self->name, self->assembleForceVector->name ); /* Call the Entry point directly from the base class */ /* Note that it may be empty: this is deliberate. */ if ( 0 == self->assembleForceVector->hooks->count ) { Journal_DPrintf( self->debug, "(E.P. has no hooks loaded -> no assembly required.)\n" ); } ((FeEntryPoint_AssembleForceVector_CallFunction*)EntryPoint_GetRun( self->assembleForceVector ))( self->assembleForceVector, self ); /* Run all the modify callbacks. */ for( ii = 0; ii < self->nModifyCBs; ii++ ) { void* callback = self->modifyCBs[ii].callback; void* object = self->modifyCBs[ii].object; ((void(*)(void*))callback)( object ); } }