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

import (
	sync "sync"

	lager "code.cloudfoundry.org/lager/v3"
	volman "code.cloudfoundry.org/volman"
)

type FakeManager struct {
	ListDriversStub        func(lager.Logger) (volman.ListDriversResponse, error)
	listDriversMutex       sync.RWMutex
	listDriversArgsForCall []struct {
		arg1 lager.Logger
	}
	listDriversReturns struct {
		result1 volman.ListDriversResponse
		result2 error
	}
	listDriversReturnsOnCall map[int]struct {
		result1 volman.ListDriversResponse
		result2 error
	}
	MountStub        func(lager.Logger, string, string, string, map[string]interface{}) (volman.MountResponse, error)
	mountMutex       sync.RWMutex
	mountArgsForCall []struct {
		arg1 lager.Logger
		arg2 string
		arg3 string
		arg4 string
		arg5 map[string]interface{}
	}
	mountReturns struct {
		result1 volman.MountResponse
		result2 error
	}
	mountReturnsOnCall map[int]struct {
		result1 volman.MountResponse
		result2 error
	}
	UnmountStub        func(lager.Logger, string, string, string) error
	unmountMutex       sync.RWMutex
	unmountArgsForCall []struct {
		arg1 lager.Logger
		arg2 string
		arg3 string
		arg4 string
	}
	unmountReturns struct {
		result1 error
	}
	unmountReturnsOnCall map[int]struct {
		result1 error
	}
	invocations      map[string][][]interface{}
	invocationsMutex sync.RWMutex
}

func (fake *FakeManager) ListDrivers(arg1 lager.Logger) (volman.ListDriversResponse, error) {
	fake.listDriversMutex.Lock()
	ret, specificReturn := fake.listDriversReturnsOnCall[len(fake.listDriversArgsForCall)]
	fake.listDriversArgsForCall = append(fake.listDriversArgsForCall, struct {
		arg1 lager.Logger
	}{arg1})
	fake.recordInvocation("ListDrivers", []interface{}{arg1})
	fake.listDriversMutex.Unlock()
	if fake.ListDriversStub != nil {
		return fake.ListDriversStub(arg1)
	}
	if specificReturn {
		return ret.result1, ret.result2
	}
	fakeReturns := fake.listDriversReturns
	return fakeReturns.result1, fakeReturns.result2
}

func (fake *FakeManager) ListDriversCallCount() int {
	fake.listDriversMutex.RLock()
	defer fake.listDriversMutex.RUnlock()
	return len(fake.listDriversArgsForCall)
}

func (fake *FakeManager) ListDriversCalls(stub func(lager.Logger) (volman.ListDriversResponse, error)) {
	fake.listDriversMutex.Lock()
	defer fake.listDriversMutex.Unlock()
	fake.ListDriversStub = stub
}

func (fake *FakeManager) ListDriversArgsForCall(i int) lager.Logger {
	fake.listDriversMutex.RLock()
	defer fake.listDriversMutex.RUnlock()
	argsForCall := fake.listDriversArgsForCall[i]
	return argsForCall.arg1
}

func (fake *FakeManager) ListDriversReturns(result1 volman.ListDriversResponse, result2 error) {
	fake.listDriversMutex.Lock()
	defer fake.listDriversMutex.Unlock()
	fake.ListDriversStub = nil
	fake.listDriversReturns = struct {
		result1 volman.ListDriversResponse
		result2 error
	}{result1, result2}
}

func (fake *FakeManager) ListDriversReturnsOnCall(i int, result1 volman.ListDriversResponse, result2 error) {
	fake.listDriversMutex.Lock()
	defer fake.listDriversMutex.Unlock()
	fake.ListDriversStub = nil
	if fake.listDriversReturnsOnCall == nil {
		fake.listDriversReturnsOnCall = make(map[int]struct {
			result1 volman.ListDriversResponse
			result2 error
		})
	}
	fake.listDriversReturnsOnCall[i] = struct {
		result1 volman.ListDriversResponse
		result2 error
	}{result1, result2}
}

func (fake *FakeManager) Mount(arg1 lager.Logger, arg2 string, arg3 string, arg4 string, arg5 map[string]interface{}) (volman.MountResponse, error) {
	fake.mountMutex.Lock()
	ret, specificReturn := fake.mountReturnsOnCall[len(fake.mountArgsForCall)]
	fake.mountArgsForCall = append(fake.mountArgsForCall, struct {
		arg1 lager.Logger
		arg2 string
		arg3 string
		arg4 string
		arg5 map[string]interface{}
	}{arg1, arg2, arg3, arg4, arg5})
	fake.recordInvocation("Mount", []interface{}{arg1, arg2, arg3, arg4, arg5})
	fake.mountMutex.Unlock()
	if fake.MountStub != nil {
		return fake.MountStub(arg1, arg2, arg3, arg4, arg5)
	}
	if specificReturn {
		return ret.result1, ret.result2
	}
	fakeReturns := fake.mountReturns
	return fakeReturns.result1, fakeReturns.result2
}

func (fake *FakeManager) MountCallCount() int {
	fake.mountMutex.RLock()
	defer fake.mountMutex.RUnlock()
	return len(fake.mountArgsForCall)
}

func (fake *FakeManager) MountCalls(stub func(lager.Logger, string, string, string, map[string]interface{}) (volman.MountResponse, error)) {
	fake.mountMutex.Lock()
	defer fake.mountMutex.Unlock()
	fake.MountStub = stub
}

func (fake *FakeManager) MountArgsForCall(i int) (lager.Logger, string, string, string, map[string]interface{}) {
	fake.mountMutex.RLock()
	defer fake.mountMutex.RUnlock()
	argsForCall := fake.mountArgsForCall[i]
	return argsForCall.arg1, argsForCall.arg2, argsForCall.arg3, argsForCall.arg4, argsForCall.arg5
}

func (fake *FakeManager) MountReturns(result1 volman.MountResponse, result2 error) {
	fake.mountMutex.Lock()
	defer fake.mountMutex.Unlock()
	fake.MountStub = nil
	fake.mountReturns = struct {
		result1 volman.MountResponse
		result2 error
	}{result1, result2}
}

func (fake *FakeManager) MountReturnsOnCall(i int, result1 volman.MountResponse, result2 error) {
	fake.mountMutex.Lock()
	defer fake.mountMutex.Unlock()
	fake.MountStub = nil
	if fake.mountReturnsOnCall == nil {
		fake.mountReturnsOnCall = make(map[int]struct {
			result1 volman.MountResponse
			result2 error
		})
	}
	fake.mountReturnsOnCall[i] = struct {
		result1 volman.MountResponse
		result2 error
	}{result1, result2}
}

func (fake *FakeManager) Unmount(arg1 lager.Logger, arg2 string, arg3 string, arg4 string) error {
	fake.unmountMutex.Lock()
	ret, specificReturn := fake.unmountReturnsOnCall[len(fake.unmountArgsForCall)]
	fake.unmountArgsForCall = append(fake.unmountArgsForCall, struct {
		arg1 lager.Logger
		arg2 string
		arg3 string
		arg4 string
	}{arg1, arg2, arg3, arg4})
	fake.recordInvocation("Unmount", []interface{}{arg1, arg2, arg3, arg4})
	fake.unmountMutex.Unlock()
	if fake.UnmountStub != nil {
		return fake.UnmountStub(arg1, arg2, arg3, arg4)
	}
	if specificReturn {
		return ret.result1
	}
	fakeReturns := fake.unmountReturns
	return fakeReturns.result1
}

func (fake *FakeManager) UnmountCallCount() int {
	fake.unmountMutex.RLock()
	defer fake.unmountMutex.RUnlock()
	return len(fake.unmountArgsForCall)
}

func (fake *FakeManager) UnmountCalls(stub func(lager.Logger, string, string, string) error) {
	fake.unmountMutex.Lock()
	defer fake.unmountMutex.Unlock()
	fake.UnmountStub = stub
}

func (fake *FakeManager) UnmountArgsForCall(i int) (lager.Logger, string, string, string) {
	fake.unmountMutex.RLock()
	defer fake.unmountMutex.RUnlock()
	argsForCall := fake.unmountArgsForCall[i]
	return argsForCall.arg1, argsForCall.arg2, argsForCall.arg3, argsForCall.arg4
}

func (fake *FakeManager) UnmountReturns(result1 error) {
	fake.unmountMutex.Lock()
	defer fake.unmountMutex.Unlock()
	fake.UnmountStub = nil
	fake.unmountReturns = struct {
		result1 error
	}{result1}
}

func (fake *FakeManager) UnmountReturnsOnCall(i int, result1 error) {
	fake.unmountMutex.Lock()
	defer fake.unmountMutex.Unlock()
	fake.UnmountStub = nil
	if fake.unmountReturnsOnCall == nil {
		fake.unmountReturnsOnCall = make(map[int]struct {
			result1 error
		})
	}
	fake.unmountReturnsOnCall[i] = struct {
		result1 error
	}{result1}
}

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

func (fake *FakeManager) 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 _ volman.Manager = new(FakeManager)
