Logo Search packages:      
Sourcecode: djvulibre version File versions

GP< DjVuPort > DjVuPortcaster::is_port_alive ( DjVuPort port  ) 

Returns a smart pointer to the port if port# is a valid pointer to an existing DjVuPort#. Returns a null pointer otherwise.

Definition at line 258 of file DjVuPort.cpp.

References GMapTemplate< KTYPE, VTYPE, TI >::contains().

Referenced by alias_to_port(), and prefix_to_ports().

{
   GP<DjVuPort> gp_port;
   GCriticalSectionLock lock(&map_lock);
   GPosition pos=cont_map.contains(port);
   if (pos && cont_map[pos] && ((DjVuPort *) port)->get_count()>0)
      gp_port=port;
   return gp_port;
}


Generated by  Doxygen 1.6.0   Back to index