I am a
VB developer and attempting to move this code into
VB as I move along for following purposes.... Although I am starting to think maybe I should just learn C# and go with the book...
How would I convert this to
VB? I am on page 66 of the book
The next step is to create the Data class that will manage the entity objects. Ideally, these would be
static classes with all static methods, but we want to ensure that they all implement certain abstract
methods so weâre limited to creating an abstract class with instance methods. To accomplish this,
right-click on the Framework folder and select Add New Item. Add a new class module and name it
ENTBaseData. It looks like this:
public abstract class ENTBaseData<T> where T : IENTBaseEntity
{
public abstract List<T> Select();
public abstract T Select(int id);
public abstract void Delete(HRPaidTimeOffDataContext db, int id);
public void Delete(string connectionString, int id)
{
using (HRPaidTimeOffDataContext db = new
HRPaidTimeOffDataContext(connectionString))
{
Delete(db, id);
}
}
}