implemented line method