pycl/Code/ngram.py
def addNgram(self, ngram):
		"""Adds an ngram to the collection."""
		if len(ngram) == self.ngrams["__n__"]:
			self.ngrams[ngram] = self.ngrams.get(ngram, 0) + 1
			self.ngrams["__count__"] += 1
			self.__changed = True
		# else:
			# raise some exception
Adds an ngram to the collection.
Adds an ngram to the collection.
Adds an ngram to the collection .
def addNgram(self, ngram):
		if len(ngram) == self.ngrams["__n__"]:
			self.ngrams[ngram] = self.ngrams.get(ngram, 0) + 1
			self.ngrams["__count__"] += 1
			self.__changed = True
def addNgram ( self , ngram ) : if len ( ngram ) == self . ngrams [ "__n__" ] : self . ngrams [ ngram ] = self . ngrams . get ( ngram , 0 ) + 1 self . ngrams [ "__count__" ] += 1 self . __changed = True
Adds an ngram to the collection.
Adds an ngram to the collection .
"""Adds an ngram to the collection.""" # else: # raise some exception
self
ngram