author | Jaroslav Tulach <jaroslav.tulach@apidesign.org> |
Thu, 30 Oct 2014 17:21:08 +0100 | |
changeset 1719 | d83b02a4b7a8 |
parent 772 | d382dacfd73f |
child 1787 | ea12a3bb4b33 |
permissions | -rw-r--r-- |
jaroslav@518 | 1 |
/** |
jaroslav@518 | 2 |
* Back 2 Browser Bytecode Translator |
jaroslav@518 | 3 |
* Copyright (C) 2012 Jaroslav Tulach <jaroslav.tulach@apidesign.org> |
jaroslav@518 | 4 |
* |
jaroslav@518 | 5 |
* This program is free software: you can redistribute it and/or modify |
jaroslav@518 | 6 |
* it under the terms of the GNU General Public License as published by |
jaroslav@518 | 7 |
* the Free Software Foundation, version 2 of the License. |
jaroslav@518 | 8 |
* |
jaroslav@518 | 9 |
* This program is distributed in the hope that it will be useful, |
jaroslav@518 | 10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
jaroslav@518 | 11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
jaroslav@518 | 12 |
* GNU General Public License for more details. |
jaroslav@518 | 13 |
* |
jaroslav@518 | 14 |
* You should have received a copy of the GNU General Public License |
jaroslav@518 | 15 |
* along with this program. Look for COPYING file in the top folder. |
jaroslav@518 | 16 |
* If not, see http://opensource.org/licenses/GPL-2.0. |
jaroslav@518 | 17 |
*/ |
jaroslav@518 | 18 |
package org.apidesign.bck2brwsr.vmtest; |
jaroslav@518 | 19 |
|
jaroslav@518 | 20 |
import java.lang.annotation.ElementType; |
jaroslav@518 | 21 |
import java.lang.annotation.Retention; |
jaroslav@518 | 22 |
import java.lang.annotation.RetentionPolicy; |
jaroslav@518 | 23 |
import java.lang.annotation.Target; |
jaroslav@518 | 24 |
|
jaroslav@518 | 25 |
/** Annotation to indicate that given method should be executed |
jaroslav@518 | 26 |
* in a browser environment. Has to be used in conjunction with {@link VMTest#create(java.lang.Class)} |
jaroslav@518 | 27 |
* factory method. |
jaroslav@518 | 28 |
* <p> |
jaroslav@518 | 29 |
* The browser to is by default executed via {@link java.awt.Desktop#browse(java.net.URI)}, |
jaroslav@518 | 30 |
* but one can change that by specifying <code>-Dvmtest.brwsrs=firefox,google-chrome</code> |
jaroslav@518 | 31 |
* property. |
jaroslav@945 | 32 |
* <p> |
jaroslav@945 | 33 |
* If the annotated method throws {@link InterruptedException}, it will return |
jaroslav@945 | 34 |
* the processing to the browser and after 100ms, called again. This is useful |
jaroslav@945 | 35 |
* for testing asynchronous communication, etc. |
jaroslav@518 | 36 |
* |
jaroslav@518 | 37 |
* @author Jaroslav Tulach <jtulach@netbeans.org> |
jaroslav@518 | 38 |
*/ |
jaroslav@518 | 39 |
@Retention(RetentionPolicy.RUNTIME) |
jaroslav@518 | 40 |
@Target(ElementType.METHOD) |
jaroslav@518 | 41 |
public @interface BrwsrTest { |
jaroslav@518 | 42 |
} |