public void AddMethod(int id, Method m)
 {
     m_Methods.Add(id, m);
     if (m.DefinitionFile != null)
         JavaFilesHit.Add(m.DefinitionFile);
     else if (m.DefinitionFileJsp != null)
         JavaFilesHit.Add(m.DefinitionFileJsp);
 }
        private void HandleMethod(string message)
        {
            string[] parts = message.Split(new char[] { ',' }, 9);
            int requestId = int.Parse(parts[1]);
            int id = int.Parse(parts[2]);
            string packageName = parts[3];
            string className = parts[4];
            string name = parts[5];
            int beginLine = int.Parse(parts[6]) - 1;
            int endLine = int.Parse(parts[7]) - 1;
            string filename = parts[8];
            JavaPackage package = m_Workspace.GetPackage(packageName);
            JavaCodeFile file = package != null ? package.GetFile(filename) : null;
            string methodName = packageName + "." + className + "." + name;
            Method m;
            if (!m_Methods.TryGetValue(methodName, out m))
            {
                // Link execution of JSP file
                JspFile jsp = null;
                if (packageName == "org.apache.jsp" && name == "_jspService")
                    jsp = m_Workspace.GetJspFile(className.Replace("_", "."));

                if (jsp != null)
                {
                    m = new Method(name, className, packageName, jsp);
                    jsp.Document.ResolvedMethod = m;
                }
                else
                {
                    m = new Method(name, className, packageName, file, beginLine);
                }
                m_Methods.Add(methodName, m);
            }
            m_Requests[requestId].AddMethod(id, m);
        }
 public Call(Method method)
 {
     Method = method;
 }