def METHOD_NAME(arg, replaced):
    if not replaced:
        return arg
    if 'value' == replaced:
        return '{0}._get_handle() if {0} else ffi.NULL'.format(arg)
    if 'pointer' == replaced:
        return '{0}._handle_ptr if {0} else ffi.NULL'.format(arg)