Logo Search packages:      
Sourcecode: harvestman version File versions  Download package

def HarvestMan::urlparser::HarvestManUrlParser::get_domain_with_port (   self,
  intranet = 0 
)

Return the domain (server) with port number
appended to it, if the port number is not the
default for the current protocol 

Definition at line 715 of file urlparser.py.

00715                                               :
        """ Return the domain (server) with port number
        appended to it, if the port number is not the
        default for the current protocol """

        if intranet or ((self.protocol == 'http://' and self.port != 80) \
                        or (self.protocol == 'https://' and self.port != 443) \
                        or (self.protocol == 'ftp://' and self.port != 21)):
            return self.domain + ':' + str(self.port)
        else:
            return self.domain


Generated by  Doxygen 1.6.0   Back to index