Farmland Allocation along the Rural-Urban Gradient: The Impacts of Urbanization and Urban Sprawl