001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portal.kernel.test;
016    
017    import org.junit.runners.model.Statement;
018    
019    /**
020     * @author Miguel Pastor
021     */
022    public abstract class AbstractStatementCallback extends Statement {
023    
024            public AbstractStatementCallback(
025                    Statement statement, TestContextHandler testContextHandler) {
026    
027                    _statement = statement;
028                    _testContextHandler = testContextHandler;
029            }
030    
031            @Override
032            public abstract void evaluate() throws Throwable;
033    
034            public Statement getStatement() {
035                    return _statement;
036            }
037    
038            public TestContextHandler getTestContextHandler() {
039                    return _testContextHandler;
040            }
041    
042            private Statement _statement;
043            private TestContextHandler _testContextHandler;
044    
045    }