In order to explain my problem here is an example
namespace CheckAbstarct
{
class Program
{
static void Main(string[] args)
{
myAbstarctClass mac1 = ObjectFactory.ObjectCreator("aaa");
myAbstarctClass mac2 = ObjectFactory.ObjectCreator("bbb");
mac1.changeMyString();
mac2.changeMyString();
...
I've been struggling for this for an hour and I don't understand why there's a problem.
I have an abstract class
public abstract class IValidated
{
public bool IsValid { get { return (GetRuleViolation() == null); } }
public abstract RuleViolation GetRuleViolation();
}
And a validation class
public class RegisterModel : IVa...
My question is rather simple, given:
class MyClass{
function a(){
echo "F.A ";
}
function b(){
echo "F.B ";
}
}
$c=new MyClass;
$c->a()->b()->b()->a();
So that it will output:
F.A F.B F.B F.A
What changes to code need to be made for this to work, or should it work as is or even just what this is called...