1 /* 2 * Copyright (c) 2007 Mockito contributors 3 * This program is made available under the terms of the MIT License. 4 */ 5 package org.mockito.internal.verification; 6 7 import org.mockito.internal.verification.api.VerificationData; 8 import org.mockito.verification.VerificationMode; 9 10 public class MockAwareVerificationMode implements VerificationMode { 11 12 private final Object mock; 13 private final VerificationMode mode; 14 15 public MockAwareVerificationMode(Object mock, VerificationMode mode) { 16 this.mock = mock; 17 this.mode = mode; 18 } 19 20 public void verify(VerificationData data) { 21 mode.verify(data); 22 } 23 24 public Object getMock() { 25 return mock; 26 } 27 }