2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
// -*- C++ -*-
|
|
|
|
//
|
|
|
|
// This file is part of the Coriolis Software.
|
2013-12-03 18:58:58 -06:00
|
|
|
// Copyright (c) UPMC 2008-2013, All Rights Reserved
|
2010-03-09 09:24:29 -06:00
|
|
|
//
|
2013-12-03 18:58:58 -06:00
|
|
|
// +-----------------------------------------------------------------+
|
2010-03-09 09:24:29 -06:00
|
|
|
// | C O R I O L I S |
|
|
|
|
// | K a t a b a t i c - Routing Toolbox |
|
|
|
|
// | |
|
|
|
|
// | Author : Jean-Paul CHAPUT |
|
2013-12-03 18:58:58 -06:00
|
|
|
// | E-mail : Jean-Paul.Chaput@lip6.fr |
|
2010-03-09 09:24:29 -06:00
|
|
|
// | =============================================================== |
|
|
|
|
// | C++ Module : "./Session.cpp" |
|
2013-12-03 18:58:58 -06:00
|
|
|
// +-----------------------------------------------------------------+
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
#include <cstdlib>
|
|
|
|
#include <sstream>
|
|
|
|
#include "hurricane/Error.h"
|
|
|
|
#include "hurricane/Horizontal.h"
|
|
|
|
#include "hurricane/Vertical.h"
|
|
|
|
#include "hurricane/Cell.h"
|
|
|
|
#include "hurricane/UpdateSession.h"
|
|
|
|
#include "crlcore/RoutingGauge.h"
|
|
|
|
#include "katabatic/Session.h"
|
|
|
|
#include "katabatic/AutoContact.h"
|
|
|
|
#include "katabatic/AutoSegment.h"
|
|
|
|
#include "katabatic/AutoSegment.h"
|
|
|
|
#include "katabatic/GCellGrid.h"
|
|
|
|
#include "katabatic/KatabaticEngine.h"
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
namespace {
|
|
|
|
|
|
|
|
|
|
|
|
const char* reopenSession =
|
|
|
|
"Session::open() :\n\n"
|
|
|
|
" Session already open for %s (internal error).";
|
|
|
|
|
|
|
|
const char* openSessionError =
|
|
|
|
"%s :\n\n"
|
|
|
|
" Session has not been opened (internal error).";
|
|
|
|
|
|
|
|
|
|
|
|
} // End of local namespace.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
namespace Katabatic {
|
|
|
|
|
|
|
|
|
|
|
|
using namespace std;
|
|
|
|
using Hurricane::tab;
|
|
|
|
using Hurricane::ltracein;
|
|
|
|
using Hurricane::ltraceout;
|
|
|
|
using Hurricane::inltrace;
|
2013-12-03 18:58:58 -06:00
|
|
|
using Hurricane::ltracelevel;
|
2010-03-09 09:24:29 -06:00
|
|
|
using Hurricane::Error;
|
|
|
|
using Hurricane::ForEachIterator;
|
|
|
|
using Hurricane::UpdateSession;
|
|
|
|
using Hurricane::Horizontal;
|
|
|
|
using Hurricane::Vertical;
|
|
|
|
using Hurricane::Cell;
|
|
|
|
|
|
|
|
|
|
|
|
// -------------------------------------------------------------------
|
|
|
|
// Class : "Katabatic::Session".
|
|
|
|
|
|
|
|
Session* Session::_session = NULL;
|
|
|
|
|
|
|
|
|
|
|
|
Session* Session::get ( const char* message )
|
|
|
|
{
|
2013-12-03 18:58:58 -06:00
|
|
|
if (not _session and message)
|
|
|
|
throw Error( openSessionError, message );
|
2010-03-09 09:24:29 -06:00
|
|
|
return _session;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Session::Session ( KatabaticEngine* ktbt )
|
2013-12-03 18:58:58 -06:00
|
|
|
: _katabatic (ktbt)
|
|
|
|
, _technology (ktbt->getRoutingGauge()->getTechnology())
|
|
|
|
, _routingGauge (ktbt->getRoutingGauge())
|
|
|
|
, _autoContacts ()
|
|
|
|
, _doglegs ()
|
|
|
|
, _segmentInvalidateds()
|
|
|
|
, _segmentRevalidateds()
|
|
|
|
, _netInvalidateds ()
|
|
|
|
, _netRevalidateds ()
|
2010-03-09 09:24:29 -06:00
|
|
|
{ }
|
|
|
|
|
|
|
|
|
|
|
|
void Session::_postCreate ()
|
|
|
|
{
|
2013-12-03 18:58:58 -06:00
|
|
|
UpdateSession::open();
|
2010-03-09 09:24:29 -06:00
|
|
|
_session = this;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Session::~Session ()
|
|
|
|
{ }
|
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
void Session::_preDestroy ()
|
2010-03-09 09:24:29 -06:00
|
|
|
{
|
2013-12-03 18:58:58 -06:00
|
|
|
if (_katabatic->getState() <= EngineActive) {
|
2010-03-09 09:24:29 -06:00
|
|
|
_revalidate ();
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (_katabatic->getGCellGrid())
|
|
|
|
_katabatic->getGCellGrid()->updateDensity();
|
2010-03-09 09:24:29 -06:00
|
|
|
}
|
|
|
|
UpdateSession::close();
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
bool Session::_doDestroyBaseContact () { return _katabatic->doDestroyBaseContact(); }
|
|
|
|
bool Session::_doDestroyBaseSegment () { return _katabatic->doDestroyBaseSegment(); }
|
|
|
|
bool Session::_doDestroyTool () { return _katabatic->doDestroyTool(); }
|
|
|
|
Configuration* Session::_getConfiguration () { return _katabatic->getConfiguration(); }
|
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
void Session::_invalidate ( Net* net )
|
2010-03-09 09:24:29 -06:00
|
|
|
{
|
2013-12-03 18:58:58 -06:00
|
|
|
ltrace(200) << "Session::invalidate(Net*) - " << net << endl;
|
|
|
|
_netInvalidateds.insert(net);
|
2010-03-09 09:24:29 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void Session::_canonize ()
|
|
|
|
{
|
|
|
|
ltrace(110) << "Katabatic::Session::_canonize()" << endl;
|
|
|
|
ltracein(110);
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (_segmentInvalidateds.empty()) {
|
|
|
|
ltrace(110) << "Invalidated AutoSegment collection <_segmentInvalidateds> is empty." << endl;
|
|
|
|
ltraceout(110);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2010-03-09 09:24:29 -06:00
|
|
|
set<Segment*> exploredSegments;
|
|
|
|
vector<AutoSegment*> aligneds;
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
// Should no longer be necessary to ensure determinism.
|
|
|
|
//sort( _segmentInvalidateds.begin(), _segmentInvalidateds.end(), AutoSegment::CompareId() );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
for ( size_t i=0 ; i<_segmentInvalidateds.size() ; i++ ) {
|
|
|
|
AutoSegment* seedSegment = _segmentInvalidateds[i];
|
|
|
|
AutoSegment* canonical = seedSegment;
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (exploredSegments.find(seedSegment->base()) == exploredSegments.end()) {
|
2010-03-09 09:24:29 -06:00
|
|
|
ltrace(110) << "New chunk from: " << seedSegment << endl;
|
2013-12-03 18:58:58 -06:00
|
|
|
aligneds.push_back( seedSegment );
|
|
|
|
|
|
|
|
bool isWeakGlobal = seedSegment->isGlobal();
|
|
|
|
if (not seedSegment->isNotAligned()) {
|
|
|
|
forEach ( AutoSegment*, aligned, seedSegment->getAligneds() ) {
|
|
|
|
ltrace(110) << "Aligned: " << *aligned << endl;
|
|
|
|
aligneds.push_back ( *aligned );
|
|
|
|
exploredSegments.insert ( aligned->base() );
|
|
|
|
|
|
|
|
isWeakGlobal = isWeakGlobal or aligned->isGlobal();
|
|
|
|
if (AutoSegment::CompareId()( *aligned, canonical ))
|
|
|
|
canonical = *aligned;
|
|
|
|
}
|
2010-03-09 09:24:29 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
ltracein(110);
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
canonical->setFlags( SegCanonical );
|
|
|
|
ltrace(110) << "Canonical: " << canonical << endl;
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
for ( size_t j=0 ; j<aligneds.size() ; j++ ) {
|
|
|
|
if (isWeakGlobal) aligneds[j]->setFlags ( SegWeakGlobal );
|
|
|
|
else aligneds[j]->unsetFlags( SegWeakGlobal );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (aligneds[j] == canonical) continue;
|
|
|
|
if (aligneds[j]->isCanonical()) {
|
* ./katabatic:
- New: In AutoSegment, adds a "_parent" attribute to keep track of the fragmentation
processus. Currently used only for strap segments, points to the original
segment in the appropriate direction (before the split).
- New: In GCell & LayerAssign, new method of layer assignment. Move up
the whole net trunk if only one of it's segment is inside an over-saturated
GCell. AutoSegment are moved up only if there is at least 2 free tracks
remaining on the upper level.
- Change: In Session::_canonize(), uses the lowest segment Id as canonical.
More reliable than geometricals criterions in the end. Assuming that the
segments are being created in deterministic order, which *should* be the
case consediring the way we are walking through the global routing.
- Change: In AutoSegment, completly suppress the CompareCanonical(), replace
it by the much simpler CompareId().
- Change: In GCell::rpDesaturate(), stops desaturation when bottom density
is under 0.5, otherwise we are causing a severe imbalance in M2/M4
densities. All wires pushed up to M4...
- Change: In ChipTools, for the Pad's RoutingPad, reslect the best component
using the one in the lowest layer. To avoid problem when splitting
AutoContact as we expect the base Contact to be on the lower layer.
- Bug: In GCellConfiguration::_GCell_xG_xL1_xL3(), add H/V alignement constraints
in fork case. This allow NE/SW contact to be splitted correctly later.
- Bug: In AutoContact::split(), the connexity on the splitted contacts was
not correctly restored, leading to canonization and parentage looping
errors. This was concealed by the Kite Track::_check() bug (incomplete
individual TrackSegment checking).
2010-12-30 12:41:19 -06:00
|
|
|
cerr << Error("Session::_canonize(): On %s\n"
|
|
|
|
" Segment is no longer the canonical one, this must not happens."
|
|
|
|
,getString(aligneds[j]).c_str()) << endl;
|
|
|
|
}
|
2013-12-03 18:58:58 -06:00
|
|
|
aligneds[j]->unsetFlags( SegCanonical );
|
2010-03-09 09:24:29 -06:00
|
|
|
ltrace(110) << "Secondary: " << aligneds[j] << endl;
|
|
|
|
}
|
2013-12-03 18:58:58 -06:00
|
|
|
if (aligneds.empty()) canonical->setFlags( SegNotAligned );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
ltrace(159) << "Align @" << DbU::getLambda(canonical->getAxis())
|
|
|
|
<< " on " << canonical << endl;
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
canonical->setAxis( canonical->getAxis(), KbRealignate );
|
|
|
|
aligneds.clear();
|
2010-03-09 09:24:29 -06:00
|
|
|
ltraceout(110);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
ltraceout(110);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void Session::_revalidateTopology ()
|
|
|
|
{
|
|
|
|
ltrace(110) << "Katabatic::Session::_revalidateTopology()" << endl;
|
|
|
|
ltracein(110);
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
set<Net*>::iterator inet = _netInvalidateds.begin();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
for ( ; inet != _netInvalidateds.end() ; inet++ ) {
|
|
|
|
ltrace(110) << "Katabatic::Session::_revalidateTopology(Net*)" << *inet << endl;
|
|
|
|
_katabatic->updateNetTopology ( *inet );
|
|
|
|
_katabatic->computeNetConstraints( *inet );
|
|
|
|
_katabatic->_computeNetOptimals ( *inet );
|
|
|
|
_katabatic->_computeNetTerminals ( *inet );
|
|
|
|
}
|
|
|
|
_canonize ();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
for ( size_t i=0 ; i<_segmentInvalidateds.size() ; ++i ) {
|
|
|
|
if (_segmentInvalidateds[i]->isCanonical()) {
|
|
|
|
if (_segmentInvalidateds[i]->isUnsetAxis()) _segmentInvalidateds[i]->toOptimalAxis();
|
|
|
|
else _segmentInvalidateds[i]->toConstraintAxis();
|
2010-03-09 09:24:29 -06:00
|
|
|
}
|
|
|
|
}
|
2013-12-03 18:58:58 -06:00
|
|
|
|
|
|
|
_netRevalidateds.clear();
|
|
|
|
_netRevalidateds.swap( _netInvalidateds );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
ltraceout(110);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
size_t Session::_revalidate ()
|
|
|
|
{
|
|
|
|
ltrace(110) << "Katabatic::Session::revalidate()" << endl;
|
|
|
|
ltracein(110);
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
ltrace(110) << "_segmentInvalidateds.size(): " << _segmentInvalidateds.size() << endl;
|
|
|
|
ltrace(110) << "_autoContacts.size(): " << _autoContacts.size() << endl;
|
|
|
|
|
2010-03-09 09:24:29 -06:00
|
|
|
size_t count = 0;
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (not _netInvalidateds.empty()) _revalidateTopology();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
ltrace(110) << "AutoContacts Revalidate (after _revalidateTopology())." << endl;
|
2010-03-09 09:24:29 -06:00
|
|
|
for ( size_t i=0 ; i < _autoContacts.size() ; i++, count++ )
|
2013-12-03 18:58:58 -06:00
|
|
|
_autoContacts[i]->updateGeometry();
|
|
|
|
_autoContacts.clear();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
ltrace(110) << "AutoSegments Revalidate (after AutoContact::updateGeometry())." << endl;
|
|
|
|
ltrace(110) << "_segmentInvalidateds.size(): " << _segmentInvalidateds.size() << endl;
|
2010-12-12 15:43:25 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
_segmentRevalidateds.clear();
|
|
|
|
for ( size_t i=0 ; i < _segmentInvalidateds.size() ; ++i, ++count ) {
|
|
|
|
_segmentInvalidateds[i]->revalidate();
|
2010-12-12 15:43:25 -06:00
|
|
|
if ( not _destroyedSegments.empty()
|
2013-12-03 18:58:58 -06:00
|
|
|
and (_destroyedSegments.find(_segmentInvalidateds[i]) != _destroyedSegments.end()) )
|
2010-12-12 15:43:25 -06:00
|
|
|
continue;
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
_segmentRevalidateds.push_back( _segmentInvalidateds[i] );
|
2010-12-12 15:43:25 -06:00
|
|
|
}
|
2013-12-03 18:58:58 -06:00
|
|
|
_segmentInvalidateds.clear();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
ltrace(110) << "AutoSegments/AutoContacts queued deletion." << endl;
|
2013-12-03 18:58:58 -06:00
|
|
|
unsigned int flags = _katabatic->getFlags( EngineDestroyMask );
|
|
|
|
_katabatic->setFlags( EngineDestroyMask );
|
2010-03-09 09:24:29 -06:00
|
|
|
set<AutoSegment*>::iterator isegment = _destroyedSegments.begin();
|
|
|
|
for ( ; isegment != _destroyedSegments.end() ; isegment++ ) {
|
|
|
|
AutoContact* source = (*isegment)->getAutoSource();
|
|
|
|
AutoContact* target = (*isegment)->getAutoTarget();
|
2013-12-03 18:58:58 -06:00
|
|
|
(*isegment)->destroy();
|
|
|
|
if (source and source->canDestroy(true)) source->destroy();
|
|
|
|
if (target and target->canDestroy(true)) target->destroy();
|
2010-03-09 09:24:29 -06:00
|
|
|
}
|
2013-12-03 18:58:58 -06:00
|
|
|
_katabatic->setFlags( flags );
|
|
|
|
set<AutoSegment*>().swap( _destroyedSegments );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
ltraceout(110);
|
|
|
|
|
|
|
|
return count;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Session* Session::open ( KatabaticEngine* ktbt )
|
|
|
|
{
|
|
|
|
ltrace(110) << "Session::open()" << endl;
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (_session) {
|
|
|
|
if (_session->_katabatic != ktbt)
|
|
|
|
throw Error( reopenSession, getString(_session->getKatabatic()).c_str() );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
return _session;
|
|
|
|
}
|
|
|
|
|
|
|
|
Session* session = new Session ( ktbt );
|
2013-12-03 18:58:58 -06:00
|
|
|
session->_postCreate();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
return session;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
void Session::close ()
|
2010-03-09 09:24:29 -06:00
|
|
|
{
|
|
|
|
ltrace(110) << "Session::close()" << endl;
|
|
|
|
ltracein(110);
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
if (not _session) throw Error( openSessionError, "Session::Close()" );
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
_session->_preDestroy();
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
delete _session;
|
|
|
|
_session = NULL;
|
|
|
|
|
|
|
|
ltraceout(110);
|
2013-12-03 18:58:58 -06:00
|
|
|
}
|
2010-03-09 09:24:29 -06:00
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
|
|
|
|
unsigned int Session::getLayerDirection ( const Layer* layer )
|
|
|
|
{
|
|
|
|
RoutingGauge* rg = get("getDirection()")->_routingGauge;
|
|
|
|
switch ( rg->getLayerDirection(layer) ) {
|
|
|
|
case Constant::Horizontal: return KbHorizontal;
|
|
|
|
case Constant::Vertical: return KbVertical;
|
|
|
|
}
|
|
|
|
return 0;
|
2010-03-09 09:24:29 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
bool Session::isInDemoMode ()
|
|
|
|
{ return get("isInDemoMode()")->_katabatic->isInDemoMode(); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
float Session::getSaturateRatio ()
|
|
|
|
{ return get("getSaturateRatio()")->_katabatic->getSaturateRatio(); }
|
|
|
|
|
|
|
|
|
2010-08-18 15:24:30 -05:00
|
|
|
size_t Session::getSaturateRp ()
|
|
|
|
{ return get("getSaturateRp()")->_katabatic->getSaturateRp(); }
|
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
bool Session::doWarnGCellOverload ()
|
|
|
|
{ return get("doWarnGCellOverload()")->_katabatic->doWarnOnGCellOverload(); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
2013-12-03 18:58:58 -06:00
|
|
|
void Session::setKatabaticFlags ( unsigned int flags )
|
|
|
|
{ get("setKabaticFlags()")->_katabatic->setFlags(flags); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
DbU::Unit Session::getExtensionCap ()
|
|
|
|
{ return getConfiguration()->getExtensionCap(); }
|
|
|
|
|
|
|
|
|
|
|
|
const Layer* Session::getRoutingLayer ( size_t depth )
|
|
|
|
{ return getConfiguration()->getRoutingLayer(depth); }
|
|
|
|
|
|
|
|
|
|
|
|
const Layer* Session::getContactLayer ( size_t depth )
|
|
|
|
{ return getConfiguration()->getContactLayer(depth); }
|
|
|
|
|
|
|
|
|
|
|
|
void Session::link ( AutoContact* autoContact )
|
2013-12-03 18:58:58 -06:00
|
|
|
{ return get("link(AutoContact*)")->_katabatic->_link( autoContact ); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
void Session::link ( AutoSegment* autoSegment )
|
2013-12-03 18:58:58 -06:00
|
|
|
{ return get("link(AutoSegment*)")->_katabatic->_link( autoSegment ); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
void Session::unlink ( AutoContact* autoContact )
|
2013-12-03 18:58:58 -06:00
|
|
|
{ return get("unlink(AutoContact*)")->_katabatic->_unlink( autoContact ); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
void Session::unlink ( AutoSegment* autoSegment )
|
2013-12-03 18:58:58 -06:00
|
|
|
{ return get("unlink(AutoSegment*)")->_katabatic->_unlink( autoSegment ); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
AutoContact* Session::lookup ( Contact* contact )
|
2013-12-03 18:58:58 -06:00
|
|
|
{ return get("lookup(Contact*)")->_katabatic->_lookup( contact ); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
AutoSegment* Session::lookup ( Segment* segment )
|
2013-12-03 18:58:58 -06:00
|
|
|
{ return get("lookup(Segment*)")->_katabatic->_lookup( segment ); }
|
2010-03-09 09:24:29 -06:00
|
|
|
|
|
|
|
|
|
|
|
string Session::_getString () const
|
|
|
|
{
|
|
|
|
return "<" + _getTypeName() + " "
|
|
|
|
+ getString(_katabatic->getCell()->getName())
|
|
|
|
+ ">";
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Record* Session::_getRecord () const
|
|
|
|
{
|
|
|
|
Record* record = new Record ( _getString() );
|
|
|
|
record->add ( getSlot ( "_katabatic" , _katabatic ) );
|
|
|
|
record->add ( getSlot ( "_autoContacts", &_autoContacts ) );
|
2013-12-03 18:58:58 -06:00
|
|
|
//record->add ( getSlot ( "_autoSegments", &_autoSegments ) );
|
2010-03-09 09:24:29 -06:00
|
|
|
return record;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
} // End of Katabatic namespace.
|