private string GetDocumentation() { if (String.IsNullOrWhiteSpace(this.MethodName)) { return(null); } if (this.Class == null) { return(null); } if (this.MethodType == null) { return(null); } Method mth; if (this.MethodType == Classes.MethodType.Class) { mth = this.Class.ClassMethods.FirstOrDefault(m => m.Selector == this.MethodName); } else { mth = this.Class.InstanceMethods.FirstOrDefault(m => m.Selector == this.MethodName); } var msg = MethodHelper.GetMessageForMethod(this.MethodName, this.MethodType, this.Class, this.ProtocolName); return(MethodHelper.BuildDocumentation(msg, 0)); }