| 
									
										
										
										
											2015-11-13 16:34:57 +00:00
										 |  |  | module.exports = function addNotYetDocumentedProperty(EXPORT_DOC_TYPES, log, createDocMessage) { | 
					
						
							|  |  |  |   return { | 
					
						
							|  |  |  |     $runAfter: ['tags-parsed'], | 
					
						
							|  |  |  |     $runBefore: ['rendering-docs'], | 
					
						
							|  |  |  |     $process: function(docs) { | 
					
						
							|  |  |  |       docs.forEach(function(doc) { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |         if (EXPORT_DOC_TYPES.indexOf(doc.docType) === -1) return; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |         // NotYetDocumented means that no top level comments and no member level comments
 | 
					
						
							| 
									
										
										
										
											2015-11-13 12:45:00 +00:00
										 |  |  |         doc.notYetDocumented = notYetDocumented(doc); | 
					
						
							| 
									
										
										
										
											2015-11-13 16:34:57 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |         if (doc.constructorDoc) { | 
					
						
							| 
									
										
										
										
											2015-11-13 12:45:00 +00:00
										 |  |  |           doc.constructorDoc.notYetDocumented = notYetDocumented(doc.constructorDoc); | 
					
						
							| 
									
										
										
										
											2015-11-13 16:34:57 +00:00
										 |  |  |           doc.notYetDocumented = doc.notYetDocumented && doc.constructorDoc.notYetDocumented; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |         if (doc.members) { | 
					
						
							|  |  |  |           doc.members.forEach(function(member) { | 
					
						
							| 
									
										
										
										
											2015-11-13 12:45:00 +00:00
										 |  |  |             member.notYetDocumented = notYetDocumented(member); | 
					
						
							| 
									
										
										
										
											2015-11-13 16:34:57 +00:00
										 |  |  |             doc.notYetDocumented = doc.notYetDocumented && member.notYetDocumented; | 
					
						
							|  |  |  |           }); | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |         if (doc.notYetDocumented) { | 
					
						
							| 
									
										
										
										
											2016-04-27 11:47:01 -04:00
										 |  |  |           // TODO: (ericjim) should I remove this?
 | 
					
						
							| 
									
										
										
										
											2015-11-13 16:34:57 +00:00
										 |  |  |           log.warn(createDocMessage("Not yet documented", doc)); | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |       }); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       return docs; | 
					
						
							|  |  |  |     } | 
					
						
							|  |  |  |   }; | 
					
						
							| 
									
										
										
										
											2015-11-13 12:45:00 +00:00
										 |  |  | }; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | function notYetDocumented(doc) { | 
					
						
							|  |  |  |   return !doc.noDescription && doc.description.trim().length == 0; | 
					
						
							|  |  |  | } |