A B C D E F G H I L M N O P R S T U V 

A

addBehaviorDefiningInvocation(BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.BehaviorDefiningInvocations
 
addBehaviorDefiningInvocation(BehaviorDefiningInvocation, BehaviorDefiningInvocations) - Method in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
addObservedMockInvocation(ObservedInvocation) - Method in class org.unitils.mock.core.Scenario
 
AfterCreateMock - Annotation Type in org.unitils.mock.annotation
Annotation for indicating that a method is to be called after a mock was created.
afterInit() - Method in class org.unitils.mock.MockModule
 
afterTestMethod(Object, Method, Throwable) - Method in class org.unitils.mock.MockModule.MockTestListener
 
alwaysMatchingBehaviorDefiningInvocations - Variable in class org.unitils.mock.core.MockObject
 
alwaysMatchingBehaviorDefiningInvocations - Variable in class org.unitils.mock.core.MockProxy
 
any(Class<T>) - Static method in class org.unitils.mock.ArgumentMatchers
 
AnyArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher for checking whether an argument value is of a certain type.
AnyArgumentMatcher(Class<?>) - Constructor for class org.unitils.mock.argumentmatcher.impl.AnyArgumentMatcher
Creates a matcher for the given expected type.
anyBoolean() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyByte() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyChar() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyDouble() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyFloat() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyInt() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyLong() - Static method in class org.unitils.mock.ArgumentMatchers
 
anyShort() - Static method in class org.unitils.mock.ArgumentMatchers
 
ArgumentMatcher - Annotation Type in org.unitils.mock.annotation
An annotation for indicating that a method is an argument matcher method.
ArgumentMatcher - Interface in org.unitils.mock.argumentmatcher
A matcher that can check whether a given argument matches certain criteria.
ArgumentMatcher.MatchResult - Enum in org.unitils.mock.argumentmatcher
 
ArgumentMatcherPositionFinder - Class in org.unitils.mock.argumentmatcher
Utility class for locating argument matchers in method invocations.
ArgumentMatcherPositionFinder() - Constructor for class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder
 
ArgumentMatcherPositionFinder.ArgumentMatcherValue - Class in org.unitils.mock.argumentmatcher
A value representing a found argument matcher invocation
ArgumentMatcherPositionFinder.ArgumentMatcherValue(Type) - Constructor for class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.ArgumentMatcherValue
 
ArgumentMatcherPositionFinder.MethodAnalyzer - Class in org.unitils.mock.argumentmatcher
Analyzer that passes the line nrs to the given interpreter.
ArgumentMatcherPositionFinder.MethodAnalyzer(MethodNode, ArgumentMatcherPositionFinder.MethodInterpreter) - Constructor for class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodAnalyzer
Creates an analyzer.
ArgumentMatcherPositionFinder.MethodInterpreter - Class in org.unitils.mock.argumentmatcher
Interpreter that implements the argument matcher finder behavior.
ArgumentMatcherPositionFinder.MethodInterpreter(Class<?>, String, String, String, int, int, int) - Constructor for class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Creates an interpreter.
ArgumentMatcherRepository - Class in org.unitils.mock.argumentmatcher
A repository for holding the current set of argument matchers.
ArgumentMatcherRepository() - Constructor for class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
 
ArgumentMatchers - Class in org.unitils.mock
todo javadoc
ArgumentMatchers() - Constructor for class org.unitils.mock.ArgumentMatchers
 
argumentMatchers - Variable in class org.unitils.mock.core.BehaviorDefiningInvocation
 
assertCanExecute(MockBehavior, ProxyInvocation, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.MockProxy
Check whether the mock behavior can applied for this invocation
assertCanExecute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.DefaultValueReturningMockBehavior
Checks whether the mock behavior can be executed for the given invocation.
assertCanExecute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.ExceptionThrowingMockBehavior
Checks whether the mock behavior can be executed for the given invocation.
assertCanExecute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.OriginalBehaviorInvokingMockBehavior
Checks whether the mock behavior can be executed for the given invocation.
assertCanExecute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.StubMockBehavior
Stub behavior is always allowed.
assertCanExecute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.ValueReturningMockBehavior
Checks whether the mock behavior can be executed for the given invocation.
assertCanExecute(ProxyInvocation) - Method in interface org.unitils.mock.mockbehavior.ValidatableMockBehavior
Checks whether the mock behavior can be executed for the given invocation.
assertInvoked() - Method in class org.unitils.mock.core.MockObject
Asserts that an invocation that matches the invocation following this call has been observed on this mock object during this test.
assertInvoked(BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.Scenario
 
assertInvoked() - Method in interface org.unitils.mock.Mock
Asserts that an invocation that matches the invocation following this call has been observed on this mock object during this test.
assertInvokedInOrder(BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.Scenario
 
assertInvokedInSequence() - Method in class org.unitils.mock.core.MockObject
Asserts that an invocation that matches the invocation following this call has been observed on this mock object during this test.
assertInvokedInSequence() - Method in interface org.unitils.mock.Mock
Asserts that an invocation that matches the invocation following this call has been observed on this mock object during this test.
AssertInvokedInSequenceVerifyingMatchingInvocationHandler - Class in org.unitils.mock.core.matching.impl
 
AssertInvokedInSequenceVerifyingMatchingInvocationHandler(Scenario, MockFactory) - Constructor for class org.unitils.mock.core.matching.impl.AssertInvokedInSequenceVerifyingMatchingInvocationHandler
 
AssertInvokedVerifyingMatchingInvocationHandler - Class in org.unitils.mock.core.matching.impl
 
AssertInvokedVerifyingMatchingInvocationHandler(Scenario, MockFactory) - Constructor for class org.unitils.mock.core.matching.impl.AssertInvokedVerifyingMatchingInvocationHandler
 
assertNoMoreInvocations(StackTraceElement[]) - Method in class org.unitils.mock.core.Scenario
 
assertNoMoreInvocations() - Static method in class org.unitils.mock.MockUnitils
 
assertNotExpectingInvocation() - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
assertNotInvoked() - Method in class org.unitils.mock.core.MockObject
Asserts that no invocation that matches the invocation following this call has been observed on this mock object during this test.
assertNotInvoked(BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.Scenario
 
assertNotInvoked() - Method in interface org.unitils.mock.Mock
Asserts that no invocation that matches the invocation following this call has been observed on this mock object during this test.
AssertNotInvokedVerifyingMatchingInvocationHandler - Class in org.unitils.mock.core.matching.impl
 
AssertNotInvokedVerifyingMatchingInvocationHandler(Scenario, MockFactory) - Constructor for class org.unitils.mock.core.matching.impl.AssertNotInvokedVerifyingMatchingInvocationHandler
 
AssertVerifyingMatchingInvocationHandler - Class in org.unitils.mock.core.matching.impl
 
AssertVerifyingMatchingInvocationHandler(Scenario, MockFactory) - Constructor for class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 

B

beforeTestSetUp(Object, Method) - Method in class org.unitils.mock.MockModule.MockTestListener
 
BehaviorDefiningInvocation - Class in org.unitils.mock.core
 
BehaviorDefiningInvocation(ProxyInvocation, MockBehavior, List<ArgumentMatcher>) - Constructor for class org.unitils.mock.core.BehaviorDefiningInvocation
Creates a behavior defining invocation for the given prosy invocation.
behaviorDefiningInvocation - Variable in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior
 
BehaviorDefiningInvocations - Class in org.unitils.mock.core
 
BehaviorDefiningInvocations(boolean) - Constructor for class org.unitils.mock.core.BehaviorDefiningInvocations
 
behaviorDefiningInvocations - Variable in class org.unitils.mock.core.BehaviorDefiningInvocations
 
behaviorDefiningInvocations - Variable in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
BehaviorDefiningMatchingInvocationHandler - Class in org.unitils.mock.core.matching.impl
 
BehaviorDefiningMatchingInvocationHandler(MockBehavior, BehaviorDefiningInvocations, MockFactory) - Constructor for class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior - Class in org.unitils.mock.core.matching.impl
 
BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior(Mock<?>, BehaviorDefiningInvocation) - Constructor for class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior
 
binaryOperation(AbstractInsnNode, Value, Value) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 

C

callAfterCreateMockMethods(Object, Mock<?>, String) - Method in class org.unitils.mock.MockModule
Calls all AfterCreateMock annotated methods on the test, passing the given mock.
CglibProxyMethodInterceptor<T> - Class in org.unitils.mock.core.proxy
A cglib method intercepter that will delegate the invocations to the given invocation hanlder.
CglibProxyMethodInterceptor(String, Class<T>, ProxyInvocationHandler) - Constructor for class org.unitils.mock.core.proxy.CglibProxyMethodInterceptor
Creates an interceptor.
CglibProxyMethodInterceptor.CglibProxyInvocation - Class in org.unitils.mock.core.proxy
An invocation implementation that uses the cglib method proxy to be able to invoke the original behavior.
CglibProxyMethodInterceptor.CglibProxyInvocation(String, Method, List<Object>, StackTraceElement[], Object, MethodProxy) - Constructor for class org.unitils.mock.core.proxy.CglibProxyMethodInterceptor.CglibProxyInvocation
Creates an invocation.
chainedMocksPerName - Variable in class org.unitils.mock.core.MockObject
 
clear() - Method in class org.unitils.mock.core.BehaviorDefiningInvocations
 
cloneArray(Object, Map<Object, Object>) - Static method in class org.unitils.mock.core.proxy.CloneUtil
Clones the given array and all it's elements.
cloneFields(Class<?>, Object, Object, Map<Object, Object>) - Static method in class org.unitils.mock.core.proxy.CloneUtil
Clones all values in all fields of the given class and superclasses.
cloneObject(Object, Map<Object, Object>) - Static method in class org.unitils.mock.core.proxy.CloneUtil
Actual implementation of the cloning.
CloneUtil - Class in org.unitils.mock.core.proxy
Utility class for deep cloning objects.
CloneUtil() - Constructor for class org.unitils.mock.core.proxy.CloneUtil
 
copyOperation(AbstractInsnNode, Value) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
createAlwaysMatchingBehaviorDefiningInvocations() - Method in class org.unitils.mock.core.MockObject
 
createAlwaysMatchingBehaviorDefiningMatchingInvocationHandler(MockBehavior) - Method in class org.unitils.mock.core.MockObject
 
createAndInjectDummiesIntoTest(Object) - Method in class org.unitils.mock.MockModule
checks for the Dummy annotation on the testObject.
createAndInjectMocksIntoTest(Object) - Method in class org.unitils.mock.MockModule
 
createAndInjectPartialMocksIntoTest(Object) - Method in class org.unitils.mock.MockModule
 
createArgumentMatchers(ProxyInvocation) - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
createArgumentMatcherValue(Value) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
createAssertInvokedInSequenceVerifyingMatchingInvocationHandler() - Method in class org.unitils.mock.core.MockObject
 
createAssertInvokedVerifyingMatchingInvocationHandler() - Method in class org.unitils.mock.core.MockObject
 
createAssertNotInvokedVerifyingMatchingInvocationHandler() - Method in class org.unitils.mock.core.MockObject
 
createChainedMock(ProxyInvocation) - Method in class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 
createChainedMock(ProxyInvocation, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
createChainedMock(String, Class<T>) - Method in interface org.unitils.mock.core.MockFactory
 
createChainedMock(String, Class<M>) - Method in class org.unitils.mock.core.MockObject
 
createDeepClone(T) - Static method in class org.unitils.mock.core.proxy.CloneUtil
Creates a deep clone of the given object.
createDetailedObservedInvocationsReport() - Method in class org.unitils.mock.core.Scenario
 
createDummy(Class<T>) - Static method in class org.unitils.mock.dummy.DummyObjectUtil
Creates the dummy proxy object.
createDummy(Class<T>, MockBehavior) - Static method in class org.unitils.mock.dummy.DummyObjectUtil
 
createDummy(Class<T>) - Static method in class org.unitils.mock.MockUnitils
 
createEnhancedClass(Class<T>, Class<?>...) - Static method in class org.unitils.mock.core.proxy.ProxyFactory
 
createFullReport() - Method in class org.unitils.mock.core.Scenario
 
createInitializedOrUninitializedInstanceOfType(Class<T>) - Static method in class org.unitils.mock.core.proxy.ProxyFactory
Creates an instance of the given type.
createInstanceUsingClone(Object) - Static method in class org.unitils.mock.core.proxy.CloneUtil
If the given value is cloneable and the cloning succeeds, the clone is returned, else null is returned.
createInstanceUsingObjenesis(Object) - Static method in class org.unitils.mock.core.proxy.CloneUtil
Tries to create an instance of the same type as the given value using Objenesis.
createLargeValueName(Class<?>, Map<Class<?>, Integer>) - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport
Creates a name to replace a large value.
createMatchingInvocationBuilder() - Method in class org.unitils.mock.core.MockObject
 
createMock(Object, String, Class<?>) - Method in class org.unitils.mock.MockModule
 
createMockProxy() - Method in class org.unitils.mock.core.MockObject
 
createMockProxy() - Method in class org.unitils.mock.core.PartialMockObject
 
createObservedInvocationsReport() - Method in class org.unitils.mock.core.Scenario
 
createOneTimeMatchingBehaviorDefiningInvocations() - Method in class org.unitils.mock.core.MockObject
 
createOneTimeMatchingBehaviorDefiningMatchingInvocationHandler(MockBehavior) - Method in class org.unitils.mock.core.MockObject
 
createPartialMock(Object, String, Class<?>) - Method in class org.unitils.mock.MockModule
 
createProxy(String, ProxyInvocationHandler, Class<T>, Class<?>...) - Static method in class org.unitils.mock.core.proxy.ProxyFactory
Creates a proxy object for the given type.
createProxy(String, boolean, ProxyInvocationHandler, Class<T>, Class<?>...) - Static method in class org.unitils.mock.core.proxy.ProxyFactory
Creates a proxy object for the given type.
createReport(Scenario) - Method in class org.unitils.mock.report.impl.DefaultScenarioReport
Creates a report.
createReport(List<ObservedInvocation>) - Method in class org.unitils.mock.report.impl.DetailedObservedInvocationsReport
Creates a string representation of the given scenario as described in the class javadoc.
createReport(List<ObservedInvocation>) - Method in class org.unitils.mock.report.impl.ObservedInvocationsReport
Creates a string representation of the given invocations as described in the class javadoc.
createReport(Object, List<ObservedInvocation>) - Method in class org.unitils.mock.report.impl.SuggestedAssertsReport
Creates a string representation of the given invocations.
createReport(Scenario) - Method in interface org.unitils.mock.report.ScenarioReport
Creates a report.
createScenario(Object) - Method in class org.unitils.mock.core.MockObject
 
createSuggestedAssertsReport() - Method in class org.unitils.mock.core.Scenario
 
createUninitializedInstanceOfType(Class<T>) - Static method in class org.unitils.mock.core.proxy.ProxyFactory
Creates an instance of the given type.
createUninitializedProxy(String, ProxyInvocationHandler, Class<T>, Class<?>...) - Static method in class org.unitils.mock.core.proxy.ProxyFactory
Creates a proxy object for the given type.
currentIndex - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
currentLineNr - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
currentMatcherMethod - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
currentMockName - Variable in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 

D

DefaultArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher for checking whether an argument equals a given value.
DefaultArgumentMatcher(Object) - Constructor for class org.unitils.mock.argumentmatcher.impl.DefaultArgumentMatcher
Creates a matcher for the given value.
DefaultScenarioReport - Class in org.unitils.mock.report.impl
Creates a report of the given scenario.
DefaultScenarioReport() - Constructor for class org.unitils.mock.report.impl.DefaultScenarioReport
 
DefaultValueReturningMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that returns a default value.
DefaultValueReturningMockBehavior() - Constructor for class org.unitils.mock.mockbehavior.impl.DefaultValueReturningMockBehavior
 
definingMethodName - Variable in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
DetailedObservedInvocationsReport - Class in org.unitils.mock.report.impl
A view that displays the details of the observed invocations.
DetailedObservedInvocationsReport(Object) - Constructor for class org.unitils.mock.report.impl.DetailedObservedInvocationsReport
 
Dummy - Annotation Type in org.unitils.mock.annotation
Annotation that can be used on fields to create dummy objects for these fields.
DummyObject - Interface in org.unitils.mock.dummy
 
DummyObjectUtil - Class in org.unitils.mock.dummy
Class for handling the dummy object behavior.
DummyObjectUtil() - Constructor for class org.unitils.mock.dummy.DummyObjectUtil
 
DummyObjectUtil.DummyObjectInvocationHandler - Class in org.unitils.mock.dummy
Invocation handler for the dummy proxy object that will return default values for every invocation.
DummyObjectUtil.DummyObjectInvocationHandler(Class<?>, MockBehavior) - Constructor for class org.unitils.mock.dummy.DummyObjectUtil.DummyObjectInvocationHandler
 
DummyValueReturningMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that returns a default value.
DummyValueReturningMockBehavior() - Constructor for class org.unitils.mock.mockbehavior.impl.DummyValueReturningMockBehavior
 

E

eq(T) - Static method in class org.unitils.mock.ArgumentMatchers
 
EqualsArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher for checking whether an argument equals a given value.
EqualsArgumentMatcher(Object) - Constructor for class org.unitils.mock.argumentmatcher.impl.EqualsArgumentMatcher
Creates a matcher for the given value.
ExceptionThrowingMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that throws a given exception.
ExceptionThrowingMockBehavior(Throwable) - Constructor for class org.unitils.mock.mockbehavior.impl.ExceptionThrowingMockBehavior
Creates the throwing behavior for the given exception.
execute(ProxyInvocation) - Method in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior
 
execute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.DefaultValueReturningMockBehavior
Executes the mock behavior.
execute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.DummyValueReturningMockBehavior
Executes the mock behavior.
execute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.ExceptionThrowingMockBehavior
Executes the mock behavior.
execute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.NoopMockBehavior
Empty mock behavior.
execute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.OriginalBehaviorInvokingMockBehavior
Executes the mock behavior.
execute(ProxyInvocation) - Method in class org.unitils.mock.mockbehavior.impl.ValueReturningMockBehavior
Executes the mock behavior.
execute(ProxyInvocation) - Method in interface org.unitils.mock.mockbehavior.MockBehavior
Executes the mock behavior.

F

findArgumentMatcherIndexes(ClassNode, MethodNode, Class<?>, String, Method, int, int, int) - Static method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder
Locates the argument matchers for the method invocation on the given line.
formatBehaviorDetails(ObservedInvocation) - Method in class org.unitils.mock.report.impl.DetailedObservedInvocationsReport
Creates a string representation of the behavior details of the given invocation.
formatInvocationIndex(int, int) - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport
Formats the invocation number, and adds spaces to make sure everything is formatted nicely on the same line width.
formatInvokedAt(ProxyInvocation) - Method in class org.unitils.mock.report.impl.DetailedObservedInvocationsReport
Creates a string representation of the details of the given invocation.
formatInvokedAt(ProxyInvocation) - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport
Creates a string representation of the details of the given invocation.
formatLargeObjects(List<ProxyInvocationsReport.FormattedObject>) - Method in class org.unitils.mock.report.impl.DetailedObservedInvocationsReport
Format the values that were to long to be displayed inline
formatMockName(ObservedInvocation) - Method in class org.unitils.mock.report.impl.ObservedInvocationsReport
 
formatMockName(ObservedInvocation) - Method in class org.unitils.mock.report.impl.SuggestedAssertsReport
 
formatObject(Object) - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport
 
formatObservedInvocation(ObservedInvocation, List<ProxyInvocationsReport.FormattedObject>, Map<Object, ProxyInvocationsReport.FormattedObject>, Map<Class<?>, Integer>) - Method in class org.unitils.mock.report.impl.ObservedInvocationsReport
Creates a string representation of the given invocation.
formatValue(Object, Object, Class<?>, List<ProxyInvocationsReport.FormattedObject>, Map<Object, ProxyInvocationsReport.FormattedObject>, Map<Class<?>, Integer>) - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport
Formats the given value.
fromLineNr - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 

G

getArgumentMatcherIndexes(ProxyInvocation, int, int, int) - Static method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder
Locates the argument matchers for the given proxy method invocation.
getArgumentMatcherIndexes(Class<?>, String, Method, int, int, int) - Static method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder
Locates the argument matchers for the method invocation on the given line.
getArgumentMatcherIndexes(MethodInsnNode, List) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
getArgumentMatchers() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
 
getArguments() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getArgumentsAtInvocationTime() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
The arguments at the time that they were used.
getAssertInvokedErrorMessage(ProxyInvocation, StackTraceElement) - Method in class org.unitils.mock.core.Scenario
 
getAssertLocationIndication(StackTraceElement) - Method in class org.unitils.mock.core.Scenario
 
getAssertNotInvokedErrorMessage(ProxyInvocation, ObservedInvocation, StackTraceElement[]) - Method in class org.unitils.mock.core.Scenario
 
getBehaviorDefiningInvocation() - Method in class org.unitils.mock.core.ObservedInvocation
 
getCurrentScenario() - Static method in class org.unitils.mock.core.MockObject
 
getDefaultMockBehavior(ProxyInvocation) - Method in class org.unitils.mock.core.MockProxy
 
getDefaultMockBehavior(ProxyInvocation) - Method in class org.unitils.mock.core.PartialMockProxy
 
getFieldName(Object, Object) - Method in class org.unitils.mock.report.impl.SuggestedAssertsReport
Checks whether the given argument value is a value of a field in the test object and, if so, returns the name of that field.
getFieldValuesAndNames(Object) - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport
Gets all the field values in the given test object with their corresponding field names.
getInstance() - Static method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
 
getInvocationLineNr(Class<?>) - Static method in class org.unitils.mock.core.proxy.StackTraceUtils
 
getInvocationStackTrace(Class<?>) - Static method in class org.unitils.mock.core.proxy.StackTraceUtils
 
getInvocationStackTrace(Class<?>, boolean) - Static method in class org.unitils.mock.core.proxy.StackTraceUtils
 
getInvokedAt() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getInvokedAtTrace() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getInvokedOutOfOrderErrorMessage(ObservedInvocation, ObservedInvocation, StackTraceElement) - Method in class org.unitils.mock.core.Scenario
 
getLineNumber() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getMatchingBehaviorDefiningInvocation(ProxyInvocation) - Method in class org.unitils.mock.core.BehaviorDefiningInvocations
First we find all behavior defining invocations that have matching argument matchers and take the one with the highest matching score (identity match scores higher than an equals match).
getMatchingBehaviorDefiningInvocation(ProxyInvocation) - Method in class org.unitils.mock.core.MockProxy
 
getMatchingInvocationBuilder() - Method in class org.unitils.mock.core.MockObject
 
getMatchInvocationEndLineNr() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
 
getMatchInvocationIndex() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
 
getMatchInvocationStartLineNr() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
 
getMethod(MethodInsnNode) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Finds a method using the ASM method node
getMethod() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getMock() - Method in class org.unitils.mock.core.MockObject
Returns the mock proxy instance.
getMock() - Method in interface org.unitils.mock.Mock
Gets the mock proxy instance.
getMockBehavior() - Method in class org.unitils.mock.core.BehaviorDefiningInvocation
 
getMockBehavior() - Method in class org.unitils.mock.core.ObservedInvocation
 
getMockedClass(Field) - Method in class org.unitils.mock.MockModule
 
getMockedType() - Method in class org.unitils.mock.core.MockObject
 
getMockName() - Method in class org.unitils.mock.core.proxy.CglibProxyMethodInterceptor
 
getMockName() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getMockName(Object) - Static method in class org.unitils.mock.core.proxy.ProxyUtils
note: don't remove, used through reflection from ObjectFormatter
getName() - Method in class org.unitils.mock.core.MockObject
 
getName() - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport.FormattedObject
 
getNoMoreInvocationsErrorMessage(List<ObservedInvocation>, StackTraceElement) - Method in class org.unitils.mock.core.Scenario
 
getNrOfArgumentMacherValues(List<Value>) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
getNrOfNotNullArguments() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getObjectToInject() - Method in class org.unitils.mock.core.MockObject
Returns the mock proxy instance.
getObjectToInjectType(Field) - Method in class org.unitils.mock.core.MockObject
 
getObservedInvocations() - Method in class org.unitils.mock.core.Scenario
 
getProxiedMethodStackTrace() - Static method in class org.unitils.mock.core.proxy.ProxyUtils
First finds a trace element in which a cglib proxy method was invoked.
getProxiedType() - Method in class org.unitils.mock.core.proxy.CglibProxyMethodInterceptor
 
getProxiedTypeIfProxy(Object) - Static method in class org.unitils.mock.core.proxy.ProxyUtils
 
getProxy() - Method in class org.unitils.mock.core.MockProxy
 
getProxy() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
 
getRepresentation() - Method in class org.unitils.mock.report.impl.ProxyInvocationsReport.FormattedObject
 
getResult() - Method in class org.unitils.mock.core.ObservedInvocation
 
getResultArgumentMatcherIndexes() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Gets the result after the analysis was performed.
getResultAtInvocationTime() - Method in class org.unitils.mock.core.ObservedInvocation
 
getScenario(Object) - Method in class org.unitils.mock.core.MockObject
 
getScore() - Method in enum org.unitils.mock.argumentmatcher.ArgumentMatcher.MatchResult
 
getStackTraceStartingFrom(StackTraceElement[], int) - Static method in class org.unitils.mock.core.proxy.StackTraceUtils
 
getSuggestedArgument(Object) - Method in class org.unitils.mock.report.impl.SuggestedAssertsReport
Creates an appropriate value so that the assert statement will be able to match the given argument value that was observed in the scenario.
getSuggestedAssertStatement(Object, ObservedInvocation) - Method in class org.unitils.mock.report.impl.SuggestedAssertsReport
Creates an assert statement for the given method invocation and arguments.
getTestListener() - Method in class org.unitils.mock.MockModule
Creates the listener for plugging in the behavior of this module into the test runs.
getTestObject() - Method in class org.unitils.mock.core.Scenario
 
getValidMockBehavior(ProxyInvocation, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.MockProxy
 
getValue(Value, Value...) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
getValue(Value, List<Value>) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 

H

handledMethodInsnNodes - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
handleInvocation(ProxyInvocation, List<ArgumentMatcher>) - Method in class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 
handleInvocation(ProxyInvocation, List<ArgumentMatcher>) - Method in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
handleInvocation(ProxyInvocation) - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder.InvocationHandler
 
handleInvocation(ProxyInvocation, List<ArgumentMatcher>) - Method in interface org.unitils.mock.core.matching.MatchingInvocationHandler
 
handleInvocation(ProxyInvocation) - Method in class org.unitils.mock.core.MockProxy.InvocationHandler
 
handleInvocation(ProxyInvocation) - Method in interface org.unitils.mock.core.proxy.ProxyInvocationHandler
Handles the given method invocation of the proxy.
handleInvocation(ProxyInvocation) - Method in class org.unitils.mock.dummy.DummyObjectUtil.DummyObjectInvocationHandler
Handles the given method invocation of the dummy object.
handleMockInvocation(ProxyInvocation) - Method in class org.unitils.mock.core.MockProxy
 
handleProxyInvocation(ProxyInvocation, MatchingInvocationHandler) - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
hasMockBehavior() - Method in class org.unitils.mock.core.ObservedInvocation
 

I

index - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
init(Properties) - Method in class org.unitils.mock.MockModule
 
injectMock(Object, Field, Mock<?>) - Method in class org.unitils.mock.MockModule
 
installChain() - Method in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior
 
instructionAlreadyHandled(MethodInsnNode) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
instructionOutOfRange() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
intercept(Object, Method, Object[], MethodProxy) - Method in class org.unitils.mock.core.proxy.CglibProxyMethodInterceptor
Intercepts the method call by wrapping the invocation in a CglibProxyMethodInterceptor.CglibProxyInvocation and delegating the handling to the invocation handler.
interpretedClass - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
interpretedMethodName - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
invocationVerificationStatuses - Variable in class org.unitils.mock.core.Scenario
 
invokedAt - Variable in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
invokedMethodDescriptor - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
invokedMethodName - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
invokeOriginalBehavior() - Method in class org.unitils.mock.core.proxy.CglibProxyMethodInterceptor.CglibProxyInvocation
Invokes the original behavior by calling the method proxy.
invokeOriginalBehavior() - Method in class org.unitils.mock.core.proxy.ProxyInvocation
Calls the actual method that was proxied using the same arguments.
isArgumentMatcherMethod(Method) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
isChainedMock() - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
isImmutable(Object) - Static method in class org.unitils.mock.core.proxy.CloneUtil
 
isInvokedMethod(MethodInsnNode) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
isJdkClass(Object) - Static method in class org.unitils.mock.core.proxy.CloneUtil
 
isMatcherMethod(Method) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
isNull(Class<T>) - Static method in class org.unitils.mock.ArgumentMatchers
 
isProxy(Object) - Static method in class org.unitils.mock.core.proxy.ProxyUtils
 
isProxyClassName(String) - Static method in class org.unitils.mock.core.proxy.ProxyUtils
 

L

lenEq(T) - Static method in class org.unitils.mock.ArgumentMatchers
 
LenEqArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher for checking whether an argument equals a given value.
LenEqArgumentMatcher(Object) - Constructor for class org.unitils.mock.argumentmatcher.impl.LenEqArgumentMatcher
Creates a matcher for the given value.
logDetailedObservedScenario() - Static method in class org.unitils.mock.MockUnitils
 
logFullScenarioReport() - Static method in class org.unitils.mock.MockUnitils
 
logObservedScenario() - Static method in class org.unitils.mock.MockUnitils
 
logSuggestedAsserts() - Static method in class org.unitils.mock.MockUnitils
 

M

matches(Object, Object) - Method in interface org.unitils.mock.argumentmatcher.ArgumentMatcher
Returns true if the given object matches this object's expected argument, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.AnyArgumentMatcher
Returns true if the given argument is of the expected type, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.DefaultArgumentMatcher
Returns true if the given object matches the expected argument, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.EqualsArgumentMatcher
Returns true if the given object matches the expected argument, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.LenEqArgumentMatcher
Returns true if the given object matches the expected argument, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.NotNullArgumentMatcher
Returns true if the given object is not null, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.NullArgumentMatcher
Returns true if the given object is not null, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.RefEqArgumentMatcher
Returns true if the given object matches the expected argument, false otherwise.
matches(Object, Object) - Method in class org.unitils.mock.argumentmatcher.impl.SameArgumentMatcher
Returns true if the given object matches the expected argument, false otherwise.
matches(ProxyInvocation) - Method in class org.unitils.mock.core.BehaviorDefiningInvocation
Returns whether or not the given ProxyInvocation matches this object's predefined Method and arguments.
MatchingInvocationBuilder - Class in org.unitils.mock.core.matching
 
MatchingInvocationBuilder() - Constructor for class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
matchingInvocationBuilder - Variable in class org.unitils.mock.core.MockProxy
 
MatchingInvocationBuilder.InvocationHandler - Class in org.unitils.mock.core.matching
 
MatchingInvocationBuilder.InvocationHandler(MatchingInvocationHandler) - Constructor for class org.unitils.mock.core.matching.MatchingInvocationBuilder.InvocationHandler
 
matchingInvocationBuilderThreadLocal - Static variable in class org.unitils.mock.core.MockObject
 
matchingInvocationHandler - Variable in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
MatchingInvocationHandler - Interface in org.unitils.mock.core.matching
 
MatchStatement - Annotation Type in org.unitils.mock.annotation
 
MAX_INLINE_PARAMETER_LENGTH - Static variable in class org.unitils.mock.report.impl.ProxyInvocationsReport
The maximum length of an inline value
merge(Value, Value) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Merges two values.
methodInterpreter - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodAnalyzer
 
methodNode - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodAnalyzer
 
mock - Variable in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior
 
Mock<T> - Interface in org.unitils.mock
Declares the contract for a controller object that enables defining the behavior of methods of a mock object, or for performing assert statements that verify that certain calls were effectively made.
mockBehavior - Variable in class org.unitils.mock.core.BehaviorDefiningInvocation
 
mockBehavior - Variable in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
MockBehavior - Interface in org.unitils.mock.mockbehavior
Behavior for a mock instance.
mockedType - Variable in class org.unitils.mock.core.MockObject
 
mockFactory - Variable in class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 
mockFactory - Variable in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler
 
MockFactory - Interface in org.unitils.mock.core
 
MockModule - Class in org.unitils.mock
Module for testing with mock objects.
MockModule() - Constructor for class org.unitils.mock.MockModule
 
MockModule.MockTestListener - Class in org.unitils.mock
Test listener that handles the scenario and mock creation, and makes sure a final syntax check is performed after each test and that scenario reports are logged if required.
MockModule.MockTestListener() - Constructor for class org.unitils.mock.MockModule.MockTestListener
 
MockObject<T> - Class in org.unitils.mock.core
Implementation of a Mock.
MockObject(Class<?>, Object) - Constructor for class org.unitils.mock.core.MockObject
Creates a mock of the given type with un-capitalized type name + Mock as name, e.g. myServiceMock.
MockObject(String, Class<?>, Object) - Constructor for class org.unitils.mock.core.MockObject
Creates a mock of the given type.
mockProxy - Variable in class org.unitils.mock.core.MockObject
 
MockProxy<T> - Class in org.unitils.mock.core
 
MockProxy(String, Class<T>, BehaviorDefiningInvocations, BehaviorDefiningInvocations, Scenario, MatchingInvocationBuilder) - Constructor for class org.unitils.mock.core.MockProxy
 
MockProxy.InvocationHandler - Class in org.unitils.mock.core
 
MockProxy.InvocationHandler() - Constructor for class org.unitils.mock.core.MockProxy.InvocationHandler
 
MockUnitils - Class in org.unitils.mock
 
MockUnitils() - Constructor for class org.unitils.mock.MockUnitils
 

N

name - Variable in class org.unitils.mock.core.MockObject
 
naryOperation(AbstractInsnNode, List) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Handles an instruction of a method call.
newControlFlowEdge(int, int) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodAnalyzer
Overridden to handle the line number instructions.
NoopMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that does nothing.
NoopMockBehavior() - Constructor for class org.unitils.mock.mockbehavior.impl.NoopMockBehavior
 
notNull(Class<T>) - Static method in class org.unitils.mock.ArgumentMatchers
 
NotNullArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher that will check whether an argument is not null.
NotNullArgumentMatcher() - Constructor for class org.unitils.mock.argumentmatcher.impl.NotNullArgumentMatcher
 
NullArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher that will check whether an argument is null.
NullArgumentMatcher() - Constructor for class org.unitils.mock.argumentmatcher.impl.NullArgumentMatcher
 

O

OBJECT_FORMATTER_MAX_NR_ARRAY_OR_COLLECTION_ELEMENTS - Static variable in class org.unitils.mock.report.impl.ProxyInvocationsReport
The maximum nr of elements for arrays and collections to display in the reports
OBJECT_FORMATTER_MAX_RECURSION_DEPT - Static variable in class org.unitils.mock.report.impl.ProxyInvocationsReport
The maximum depth (child objects) of objects to display in the reports.
objectFormatter - Variable in class org.unitils.mock.report.impl.ProxyInvocationsReport
 
ObservedInvocation - Class in org.unitils.mock.core
 
ObservedInvocation(ProxyInvocation, BehaviorDefiningInvocation, MockBehavior) - Constructor for class org.unitils.mock.core.ObservedInvocation
Creates a observed invocation for the given prosy invocation.
observedInvocations - Variable in class org.unitils.mock.core.Scenario
 
ObservedInvocationsReport - Class in org.unitils.mock.report.impl
A view that displays the observed invocations and the location where they were invoked.
ObservedInvocationsReport(Object) - Constructor for class org.unitils.mock.report.impl.ObservedInvocationsReport
 
oncePerforms(MockBehavior) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that will be performed when the invocation following this call matches the observed behavior.
oncePerforms(MockBehavior) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that will be performed when the invocation following this call matches the observed behavior.
onceRaises(Throwable) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that it raises the given exception when the invocation following this call matches the observed behavior.
onceRaises(Class<? extends Throwable>) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that it raises an instance of the given exception class when the invocation following this call matches the observed behavior.
onceRaises(Throwable) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that it raises an instance of the given exception class when the invocation following this call matches the observed behavior.
onceRaises(Class<? extends Throwable>) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that it raises an instance of the given exception class when the invocation following this call matches the observed behavior.
onceReturns(Object) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that it will return the given value when the invocation following this call matches the observed behavior.
onceReturns(Object) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that it will return the given value when the invocation following this call matches the observed behavior.
oneTimeMatchingBehaviorDefiningInvocations - Variable in class org.unitils.mock.core.MockObject
 
oneTimeMatchingBehaviorDefiningInvocations - Variable in class org.unitils.mock.core.MockProxy
 
org.unitils.mock - package org.unitils.mock
 
org.unitils.mock.annotation - package org.unitils.mock.annotation
 
org.unitils.mock.argumentmatcher - package org.unitils.mock.argumentmatcher
 
org.unitils.mock.argumentmatcher.impl - package org.unitils.mock.argumentmatcher.impl
 
org.unitils.mock.core - package org.unitils.mock.core
 
org.unitils.mock.core.matching - package org.unitils.mock.core.matching
 
org.unitils.mock.core.matching.impl - package org.unitils.mock.core.matching.impl
 
org.unitils.mock.core.proxy - package org.unitils.mock.core.proxy
 
org.unitils.mock.dummy - package org.unitils.mock.dummy
 
org.unitils.mock.mockbehavior - package org.unitils.mock.mockbehavior
 
org.unitils.mock.mockbehavior.impl - package org.unitils.mock.mockbehavior.impl
 
org.unitils.mock.report - package org.unitils.mock.report
 
org.unitils.mock.report.impl - package org.unitils.mock.report.impl
 
OriginalBehaviorInvokingMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that, instead of mocking the method invocation, performs the actual behavior of the mocked class.
OriginalBehaviorInvokingMockBehavior() - Constructor for class org.unitils.mock.mockbehavior.impl.OriginalBehaviorInvokingMockBehavior
 
originalMockBehavior - Variable in class org.unitils.mock.core.matching.impl.BehaviorDefiningMatchingInvocationHandler.ChainedMockBehavior
 

P

PartialMock<T> - Interface in org.unitils.mock
Declares the contract for a controller object that enables defining the behavior of methods of a partial mock object, or for performing assert statements that verify that certain calls were effectively made.
PartialMockObject<T> - Class in org.unitils.mock.core
Implementation of a PartialMock.
PartialMockObject(Object, Object) - Constructor for class org.unitils.mock.core.PartialMockObject
Creates a mock of the same type as the given mock prototype with un-capitalized type name + Mock as name, e.g. myServiceMock.
PartialMockObject(String, Object, Object) - Constructor for class org.unitils.mock.core.PartialMockObject
Creates a mock of the same type as the given mock prototype with the given name.
PartialMockObject(Class<?>, Object) - Constructor for class org.unitils.mock.core.PartialMockObject
Creates a mock of the given type with un-capitalized type name + Mock as name, e.g. myServiceMock.
PartialMockObject(String, Class<?>, Object) - Constructor for class org.unitils.mock.core.PartialMockObject
Creates a mock of the given type for the given scenario.
PartialMockProxy<T> - Class in org.unitils.mock.core
 
PartialMockProxy(String, Class<T>, BehaviorDefiningInvocations, BehaviorDefiningInvocations, Scenario, MatchingInvocationBuilder) - Constructor for class org.unitils.mock.core.PartialMockProxy
 
performAssertion(Scenario, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.matching.impl.AssertInvokedInSequenceVerifyingMatchingInvocationHandler
 
performAssertion(Scenario, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.matching.impl.AssertInvokedVerifyingMatchingInvocationHandler
 
performAssertion(Scenario, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.matching.impl.AssertNotInvokedVerifyingMatchingInvocationHandler
 
performAssertion(Scenario, BehaviorDefiningInvocation) - Method in class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 
performChainedAssertion(Mock<?>) - Method in class org.unitils.mock.core.matching.impl.AssertInvokedInSequenceVerifyingMatchingInvocationHandler
 
performChainedAssertion(Mock<?>) - Method in class org.unitils.mock.core.matching.impl.AssertInvokedVerifyingMatchingInvocationHandler
 
performChainedAssertion(Mock<?>) - Method in class org.unitils.mock.core.matching.impl.AssertNotInvokedVerifyingMatchingInvocationHandler
 
performChainedAssertion(Mock<?>) - Method in class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 
performs(MockBehavior) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that will be performed when the invocation following this call matches the observed behavior.
performs(MockBehavior) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that will be performed when the invocation following this call matches the observed behavior.
proxy - Variable in class org.unitils.mock.core.MockProxy
 
ProxyFactory - Class in org.unitils.mock.core.proxy
Utility class to create and work with proxy objects.
ProxyFactory() - Constructor for class org.unitils.mock.core.proxy.ProxyFactory
 
ProxyInvocation - Class in org.unitils.mock.core.proxy
An invocation of a proxy method.
ProxyInvocation(String, Object, Method, List<Object>, StackTraceElement[]) - Constructor for class org.unitils.mock.core.proxy.ProxyInvocation
Creates an invocation.
ProxyInvocation(ProxyInvocation) - Constructor for class org.unitils.mock.core.proxy.ProxyInvocation
Creates a copy of the given proxy invocation.
ProxyInvocationHandler - Interface in org.unitils.mock.core.proxy
A class for handling method invocations of a proxy.
ProxyInvocationsReport - Class in org.unitils.mock.report.impl
A base class for reports about proxy invocations.
ProxyInvocationsReport(Object) - Constructor for class org.unitils.mock.report.impl.ProxyInvocationsReport
 
ProxyInvocationsReport.FormattedObject - Class in org.unitils.mock.report.impl
Class for representing a value that was too large to be displayed inline.
ProxyInvocationsReport.FormattedObject(String, String) - Constructor for class org.unitils.mock.report.impl.ProxyInvocationsReport.FormattedObject
Creates a large value
ProxyUtils - Class in org.unitils.mock.core.proxy
Utility class to create and work with proxy objects.
ProxyUtils() - Constructor for class org.unitils.mock.core.proxy.ProxyUtils
 

R

raises(Throwable) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that it raises the given exception when the invocation following this call matches the observed behavior.
raises(Class<? extends Throwable>) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that it raises the given exception when the invocation following this call matches the observed behavior.
raises(Throwable) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that it raises the given exception when the invocation following this call matches the observed behavior.
raises(Class<? extends Throwable>) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that it raises an instance of the given exception class when the invocation following this call matches the observed behavior.
readClass(Class<?>) - Static method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder
Uses ASM to read the byte code of the given class.
refEq(T) - Static method in class org.unitils.mock.ArgumentMatchers
 
RefEqArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher for checking whether an argument equals a given value.
RefEqArgumentMatcher(Object) - Constructor for class org.unitils.mock.argumentmatcher.impl.RefEqArgumentMatcher
Creates a matcher for the given value.
registerArgumentMatcher(ArgumentMatcher, int) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
Registers an argument matcher at the given line nr.
registerArgumentMatcher(ArgumentMatcher) - Static method in class org.unitils.mock.ArgumentMatchers
 
registerEndOfMatchingInvocation(int, String) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
Stops the registering of argument matchers.
registerStartOfMatchingInvocation(int) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
From the moment that this method is called until ArgumentMatcherRepository.registerEndOfMatchingInvocation(int, java.lang.String) has been called, argument matchers can be registered.
removeWhenUsed - Variable in class org.unitils.mock.core.BehaviorDefiningInvocations
 
reset() - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherRepository
Clears the current argument matchers.
reset() - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
reset() - Method in class org.unitils.mock.core.Scenario
 
resetBehavior() - Method in class org.unitils.mock.core.MockObject
Removes all behavior defined for this mock.
resetBehavior() - Method in interface org.unitils.mock.Mock
Removes all behavior defined for this mock.
resolveNumber(Class<?>) - Method in class org.unitils.mock.mockbehavior.impl.DefaultValueReturningMockBehavior
Checking for the default java implementations of Number, this avoids class cast exceptions when using them
resultArgumentMatcherIndexes - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
returns(Object) - Method in class org.unitils.mock.core.MockObject
Defines behavior for this mock so that it will return the given value when the invocation following this call matches the observed behavior.
returns(Object) - Method in interface org.unitils.mock.Mock
Defines behavior for this mock so that it will return the given value when the invocation following this call matches the observed behavior.

S

same(T) - Static method in class org.unitils.mock.ArgumentMatchers
 
SameArgumentMatcher - Class in org.unitils.mock.argumentmatcher.impl
A matcher that will check whether an argument is the same instance (object identical) as the given value.
SameArgumentMatcher(Object) - Constructor for class org.unitils.mock.argumentmatcher.impl.SameArgumentMatcher
Creates a matcher for the given value.
scenario - Variable in class org.unitils.mock.core.matching.impl.AssertVerifyingMatchingInvocationHandler
 
scenario - Variable in class org.unitils.mock.core.MockProxy
 
Scenario - Class in org.unitils.mock.core
 
Scenario(Object) - Constructor for class org.unitils.mock.core.Scenario
 
Scenario.VerificationStatus - Enum in org.unitils.mock.core
 
ScenarioReport - Interface in org.unitils.mock.report
Creates a report of the given Scenario.
scenarioThreadLocal - Static variable in class org.unitils.mock.core.MockObject
 
setCurrentLineNr(int) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Sets the line nr that is being analyzed.
setMockBehavior(MockBehavior) - Method in class org.unitils.mock.core.BehaviorDefiningInvocation
 
setResult(Object) - Method in class org.unitils.mock.core.ObservedInvocation
Sets the result of the invocation.
setTestObject(Object) - Method in class org.unitils.mock.core.Scenario
 
StackTraceUtils - Class in org.unitils.mock.core.proxy
Class offering utilities involving the call stack
StackTraceUtils() - Constructor for class org.unitils.mock.core.proxy.StackTraceUtils
 
startMatchingInvocation(String, Class<T>, MatchingInvocationHandler) - Method in class org.unitils.mock.core.matching.MatchingInvocationBuilder
 
startMatchingInvocation(MatchingInvocationHandler) - Method in class org.unitils.mock.core.MockObject
 
stub() - Method in class org.unitils.mock.core.PartialMockObject
Stubs out (removes) the behavior of the method when the invocation following this call matches the observed behavior.
stub() - Method in interface org.unitils.mock.PartialMock
Stubs out (removes) the behavior of the method when the invocation following this call matches the observed behavior.
StubMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that returns a default value if a value can be returned, nothing happens when the result type is void.
StubMockBehavior() - Constructor for class org.unitils.mock.mockbehavior.impl.StubMockBehavior
 
SuggestedAssertsReport - Class in org.unitils.mock.report.impl
A view that will return a list of suggested assert statements that one can use in a test for the given scenario.
SuggestedAssertsReport() - Constructor for class org.unitils.mock.report.impl.SuggestedAssertsReport
 

T

ternaryOperation(AbstractInsnNode, Value, Value, Value) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
testedObjectFieldValuesAndNames - Variable in class org.unitils.mock.report.impl.ProxyInvocationsReport
 
testObject - Variable in class org.unitils.mock.core.Scenario
 
throwUnitilsException(String) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
Throws a UnitilsException with the given error message.
toLineNr - Variable in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 

U

unaryOperation(AbstractInsnNode, Value) - Method in class org.unitils.mock.argumentmatcher.ArgumentMatcherPositionFinder.MethodInterpreter
 
unwrapValueToReturnIfNeeded(Object) - Method in class org.unitils.mock.mockbehavior.impl.ValueReturningMockBehavior
If the value to return is an wrapper object, e.g. a mock, this will return the wrapped instance instead of the wrapper.

V

ValidatableMockBehavior - Interface in org.unitils.mock.mockbehavior
todo javadoc
valueOf(String) - Static method in enum org.unitils.mock.argumentmatcher.ArgumentMatcher.MatchResult
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.unitils.mock.core.Scenario.VerificationStatus
Returns the enum constant of this type with the specified name.
ValueReturningMockBehavior - Class in org.unitils.mock.mockbehavior.impl
Mock behavior that returns a given value.
ValueReturningMockBehavior(Object) - Constructor for class org.unitils.mock.mockbehavior.impl.ValueReturningMockBehavior
Creates the returning behavior for the given value.
values() - Static method in enum org.unitils.mock.argumentmatcher.ArgumentMatcher.MatchResult
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.unitils.mock.core.Scenario.VerificationStatus
Returns an array containing the constants of this enum type, in the order they are declared.
A B C D E F G H I L M N O P R S T U V 

Copyright © 2016. All Rights Reserved.