public void Visit(MethodInvocation classDot)
 {
     _methInvocation = true;
     classDot.Id.Accept(this);
     _sb.Append(".");
     classDot.FunctionCall.Accept(this);
     _methInvocation = false;
 }
 public void Visit(MethodInvocation classDot)
 {
     classDot.Id.Accept(this);
     _sb.Append(".");
     classDot.FunctionCall.Accept(this);
 }
 public void Visit(MethodInvocation mi)
 {
     if (!_env.IsVisitingServer())
         throw new TypeCheckingException("you can invoke methods only from a Server instance.");
     if (_env.VisitPartEnv.Functions[_env.VisitFunName].IdToClient.ContainsKey(mi.Id.Name))
     {
         _env.InvokingOn = _env.VisitPartEnv.Functions[_env.VisitFunName].IdToClient[mi.Id.Name];
         if (!_env.InvokingOn.Functions.ContainsKey(mi.FunctionCall.Name))
         {
             throw new TypeCheckingException(
                 String.Format(
                     "the client {0} doesn't contain the method {1}",
                     _env.InvokingOn.PartName, mi.FunctionCall.Name
                     ));
         }
         mi.FunctionCall.Accept(this);
         mi.SmclType = mi.FunctionCall.SmclType;
     }
     else
     {
         throw new TypeCheckingException("invoking a method from an undefined variable --> " + mi.Id.Name);
     }
     _env.InvokingOn = null;
 }