예제 #1
0
def to_large_integer(number):
    kwargs = {}
    if is_64bit():
        kwargs['QuadPart'] = number
    else:
        kwargs['HighPart'] = (number & 0xFFFFFFFF00000000) >> 32
        kwargs['LowPart'] = number & 0xFFFFFFFF
    instance = structures.LARGE_INTEGER(**kwargs)
    return instance
예제 #2
0
def to_large_integer(number):
    kwargs = {}
    if is_64bit():
        kwargs['QuadPart'] = number
    else:
        kwargs['HighPart'] = (number & 0xFFFFFFFF00000000) >> 32
        kwargs['LowPart'] = number & 0xFFFFFFFF
    instance = structures.LARGE_INTEGER(**kwargs)
    return instance
예제 #3
0
def from_large_integer(instance):
    return instance.QuadPart if is_64bit() else ((instance.HighPart << 32) + instance.LowPart)
예제 #4
0
def from_large_integer(instance):
    return instance.QuadPart if is_64bit() else ((instance.HighPart << 32) +
                                                 instance.LowPart)