// AddHvs adds a new hvs in the height HeightLogs, returns true if the element is new and false otherwise
AddHvs adds a new hvs in the height HeightLogs, returns true if the element is new and false otherwise
// AddHvs adds a new hvs in the height HeightLogs returns true if the element is new and false otherwise
func (hl *HeightLogs) AddHvs(processID string, hvs *common.HeightVoteSet) bool {
	hl.mutex.Lock()
	defer hl.mutex.Unlock()
	value, _ := hl.receivedLogsMap[processID]
	if !value {
		hl.messageLogs[processID] = hvs
		hl.receivedLogsMap[processID] = true
		return true
	}
	return false
}
func ( hl * HeightLogs ) AddHvs ( processID string , hvs * common . HeightVoteSet ) bool { hl . mutex . Lock ( ) defer hl . mutex . Unlock ( ) value , _ := hl . receivedLogsMap [ processID ] if ! value { hl . messageLogs [ processID ] = hvs hl . receivedLogsMap [ processID ] = true return true } return false }
AddHvs adds a new hvs in the height HeightLogs, returns true if the element is new and false otherwise
AddHvs adds a new hvs in the height HeightLogs returns true if the element is new and false otherwise