コード例 #1
0
ファイル: NetUtils.py プロジェクト: gklyne/OntologyCreator
def formatIpAdrs(ipbytes):
    """
    Format IP address string from IP addre4ss bytes
    """
    # return "%d.%d.%d.%d" % ipbytes
    return formatIntList(ipbytes,".")
コード例 #2
0
def formatIpAdrs(ipbytes):
    """
    Format IP address string from IP addre4ss bytes
    """
    # return "%d.%d.%d.%d" % ipbytes
    return formatIntList(ipbytes,".")
コード例 #3
0
ファイル: NetUtils.py プロジェクト: gklyne/OntologyCreator
def formatMacAdrs(macbytes,sep=":"):
    """
    Format MAC address as colon-separated hexadecimals for webBrick command
    """
    return formatIntList(macbytes, sep, formatInt("%02X"))
コード例 #4
0
def formatMacAdrs(macbytes,sep=":"):
    """
    Format MAC address as colon-separated hexadecimals for webBrick command
    """
    return formatIntList(macbytes, sep, formatInt("%02X"))