Convert API to virtual methods.