// Code generated by counterfeiter. DO NOT EDIT.
package kawasakifakes

import (
	"sync"

	"code.cloudfoundry.org/guardian/kawasaki"
	lager "code.cloudfoundry.org/lager/v3"
)

type FakeDnsResolvConfigurer struct {
	ConfigureStub        func(lager.Logger, kawasaki.NetworkConfig, int) error
	configureMutex       sync.RWMutex
	configureArgsForCall []struct {
		arg1 lager.Logger
		arg2 kawasaki.NetworkConfig
		arg3 int
	}
	configureReturns struct {
		result1 error
	}
	configureReturnsOnCall map[int]struct {
		result1 error
	}
	invocations      map[string][][]interface{}
	invocationsMutex sync.RWMutex
}

func (fake *FakeDnsResolvConfigurer) Configure(arg1 lager.Logger, arg2 kawasaki.NetworkConfig, arg3 int) error {
	fake.configureMutex.Lock()
	ret, specificReturn := fake.configureReturnsOnCall[len(fake.configureArgsForCall)]
	fake.configureArgsForCall = append(fake.configureArgsForCall, struct {
		arg1 lager.Logger
		arg2 kawasaki.NetworkConfig
		arg3 int
	}{arg1, arg2, arg3})
	stub := fake.ConfigureStub
	fakeReturns := fake.configureReturns
	fake.recordInvocation("Configure", []interface{}{arg1, arg2, arg3})
	fake.configureMutex.Unlock()
	if stub != nil {
		return stub(arg1, arg2, arg3)
	}
	if specificReturn {
		return ret.result1
	}
	return fakeReturns.result1
}

func (fake *FakeDnsResolvConfigurer) ConfigureCallCount() int {
	fake.configureMutex.RLock()
	defer fake.configureMutex.RUnlock()
	return len(fake.configureArgsForCall)
}

func (fake *FakeDnsResolvConfigurer) ConfigureCalls(stub func(lager.Logger, kawasaki.NetworkConfig, int) error) {
	fake.configureMutex.Lock()
	defer fake.configureMutex.Unlock()
	fake.ConfigureStub = stub
}

func (fake *FakeDnsResolvConfigurer) ConfigureArgsForCall(i int) (lager.Logger, kawasaki.NetworkConfig, int) {
	fake.configureMutex.RLock()
	defer fake.configureMutex.RUnlock()
	argsForCall := fake.configureArgsForCall[i]
	return argsForCall.arg1, argsForCall.arg2, argsForCall.arg3
}

func (fake *FakeDnsResolvConfigurer) ConfigureReturns(result1 error) {
	fake.configureMutex.Lock()
	defer fake.configureMutex.Unlock()
	fake.ConfigureStub = nil
	fake.configureReturns = struct {
		result1 error
	}{result1}
}

func (fake *FakeDnsResolvConfigurer) ConfigureReturnsOnCall(i int, result1 error) {
	fake.configureMutex.Lock()
	defer fake.configureMutex.Unlock()
	fake.ConfigureStub = nil
	if fake.configureReturnsOnCall == nil {
		fake.configureReturnsOnCall = make(map[int]struct {
			result1 error
		})
	}
	fake.configureReturnsOnCall[i] = struct {
		result1 error
	}{result1}
}

func (fake *FakeDnsResolvConfigurer) Invocations() map[string][][]interface{} {
	fake.invocationsMutex.RLock()
	defer fake.invocationsMutex.RUnlock()
	fake.configureMutex.RLock()
	defer fake.configureMutex.RUnlock()
	copiedInvocations := map[string][][]interface{}{}
	for key, value := range fake.invocations {
		copiedInvocations[key] = value
	}
	return copiedInvocations
}

func (fake *FakeDnsResolvConfigurer) recordInvocation(key string, args []interface{}) {
	fake.invocationsMutex.Lock()
	defer fake.invocationsMutex.Unlock()
	if fake.invocations == nil {
		fake.invocations = map[string][][]interface{}{}
	}
	if fake.invocations[key] == nil {
		fake.invocations[key] = [][]interface{}{}
	}
	fake.invocations[key] = append(fake.invocations[key], args)
}

var _ kawasaki.DnsResolvConfigurer = new(FakeDnsResolvConfigurer)
