Enabling lan card using ruby

Suppose I want to make a program which enables a lan card at some
particular time…How do I do it?
I need the syntax basically