f3e3aab35a
Former-commit-id: 9c2cb47f45fa221e661ab616387c9cda183f283d
27 lines
447 B
C#
27 lines
447 B
C#
using System;
|
|
|
|
public abstract class ThingWithOrganizationId
|
|
{
|
|
public Guid OrganizationId;
|
|
}
|
|
|
|
public class Thing : ThingWithOrganizationId
|
|
{
|
|
}
|
|
|
|
public abstract class BaseService<TConstraint>
|
|
{
|
|
public abstract void Save<T> (T newThing) where T : TConstraint;
|
|
}
|
|
|
|
public class DerivedService:BaseService<Thing>
|
|
{
|
|
public override void Save<TThing>(TThing newThing)
|
|
{
|
|
Console.WriteLine (newThing.OrganizationId);
|
|
}
|
|
|
|
static void Main ()
|
|
{
|
|
}
|
|
} |