All Questions
4
questions
0
votes
1
answer
38
views
Ensuring parameter types when implementing interface and inheriting
I have a problem with Classes and Interfaces.
I want to achive that an Interface declaretes a method that takes the type of the implemented class.
When I inherit from this class the method should only ...
0
votes
3
answers
150
views
Any ideas of how make internal a base class implementation having a child class of that class public in C#?
Any ideas of how make internal a base class having a child class of that class public in c#?
In code:
internal class Base { }
public class Child : Base {}
I have a layered architecture and need to ...
1
vote
4
answers
420
views
Expose constructor only to base class, possible?
public class Base<S>
{
public static Derived<S, T> Create<T>()
{
return new Derived<S, T>(); //if not public, I wont get it here.
}
}
public class Derived&...
2
votes
2
answers
767
views
Having a Base Class access a Child's members in C# Inheritance
I'm sure I'm missing something since C# isn't my forte and I'm coming from a PHP background, but I'm writing a base class (called GVProgram) that will be inherited by child classes (ProgramA, ProgramB)...