Example #1
0
 //=====================================================================
 /// <summary>
 /// Writes a method description.
 /// </summary>
 public void WriteMethod(StreamWriter w, MethodDef md)
 {
     this.WriteThingWithDescription(
         w, md.Name, md.Parameters, null, md.Description,
         md.Overridden, md.Source, md.Modifications,
         md.ModificationMods, md.IsIfcOnly);
 }
Example #2
0
        //=====================================================================
        /// <summary>
        /// Processes a line which appears to define a method.
        /// identifier "(" identifierList ")"
        /// </summary>
        /// <param name="name">the name of the method, which has already been parsed</param>
        private void ProcessMethod(String name, String line, bool ifcOnly)
        {
            if (CurrClassOrObj == null)
                return;
            MethodDef m = new MethodDef(Path.GetFileName(CurrentFileName),
                                        LineNumber);
            m.Name = name;
            m.IsIfcOnly = ifcOnly;
            m.Description = LastComment;
            m.ClassOrObject = CurrClassOrObj;
            if (! ParseArgList(ref line, m))
                return;

            if ((name == "dobjFor" || name == "iobjFor")
                && m.Parameters.Count == 1)
            {
                m.Name += "(" + m.Parameters[0] + ")";
                m.Parameters = null;
            }

            CurrClassOrObj.Methods.Add(m);
            LastComment = "";
        }