func (c *bucketHashCalculator) addNextNode(dataNode *dataNode) {
	chaincodeID, _ := dataNode.getKeyElements()
	if chaincodeID != c.currentChaincodeID {
		c.appendCurrentChaincodeData()
		c.currentChaincodeID = chaincodeID
		c.dataNodes = nil
	}
	c.dataNodes = append(c.dataNodes, dataNode)
}
// addNextNode - this method assumes that the datanodes are added in the increasing order of the keys
this method assumes that the datanodes are added in the increasing order of the keys
// addNextNode - this method assumes that the datanodes are added in the increasing order of the keys
func (c *bucketHashCalculator) addNextNode(dataNode *dataNode) {
	chaincodeID, _ := dataNode.getKeyElements()
	if chaincodeID != c.currentChaincodeID {
		c.appendCurrentChaincodeData()
		c.currentChaincodeID = chaincodeID
		c.dataNodes = nil
	}
	c.dataNodes = append(c.dataNodes, dataNode)
}
func ( c * bucketHashCalculator ) addNextNode ( dataNode * dataNode ) { chaincodeID , _ := dataNode . getKeyElements ( ) if chaincodeID != c . currentChaincodeID { c . appendCurrentChaincodeData ( ) c . currentChaincodeID = chaincodeID c . dataNodes = nil } c . dataNodes = append ( c . dataNodes , dataNode ) }
this method assumes that the datanodes are added in the increasing order of the keys
this method assumes that the datanodes are added in the increasing order of the keys