當前位置: 首頁>>代碼示例>>Java>>正文


Java JsonRpcError類代碼示例

本文整理匯總了Java中com.googlecode.jsonrpc4j.JsonRpcError的典型用法代碼示例。如果您正苦於以下問題:Java JsonRpcError類的具體用法?Java JsonRpcError怎麽用?Java JsonRpcError使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


JsonRpcError類屬於com.googlecode.jsonrpc4j包,在下文中一共展示了JsonRpcError類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: childByText

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
@JsonRpcErrors({@JsonRpcError(exception=UiObjectNotFoundException.class, code=ERROR_CODE_BASE-2)})
String childByText(Selector collection, Selector child, String text, boolean allowScrollSearch) throws UiObjectNotFoundException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:3,代碼來源:AutomatorService.java

示例2: childByDescription

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
@JsonRpcErrors({@JsonRpcError(exception=UiObjectNotFoundException.class, code=ERROR_CODE_BASE-2)})
String childByDescription(Selector collection, Selector child, String text, boolean allowScrollSearch) throws UiObjectNotFoundException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:3,代碼來源:AutomatorService.java

示例3: testMethod

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
@JsonRpcErrors({@JsonRpcError(exception = CustomTestException.class, code = 1234)})
Object testMethod();
 
開發者ID:briandilley,項目名稱:jsonrpc4j,代碼行數:3,代碼來源:JsonRpcErrorsTest.java

示例4: drag

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Performs a swipe from one coordinate to another coordinate. You can control the smoothness and speed of the swipe by specifying the number of steps. Each step execution is throttled to 5 milliseconds per step, so for a 100 steps, the swipe will take around 0.5 seconds to complete.
 * @param startX X-axis value for the starting coordinate
 * @param startY Y-axis value for the starting coordinate
 * @param endX X-axis value for the ending coordinate
 * @param endY Y-axis value for the ending coordinate
 * @param steps is the number of steps for the swipe action
 * @return true if swipe is performed, false if the operation fails or the coordinates are invalid
 * @throws NotImplementedException
 */
@JsonRpcErrors({@JsonRpcError(exception=NotImplementedException.class, code=ERROR_CODE_BASE-3)})
boolean drag(int startX, int startY, int endX, int endY, int steps) throws NotImplementedException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:13,代碼來源:AutomatorService.java

示例5: takeScreenshot

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Take a screenshot of current window and store it as PNG The screenshot is adjusted per screen rotation
 * @param filename where the PNG should be written to
 * @param scale scale the screenshot down if needed; 1.0f for original size
 * @param quality quality of the PNG compression; range: 0-100
 * @return the file name of the screenshot. null if failed.
 * @throws NotImplementedException
 */
@JsonRpcErrors({@JsonRpcError(exception=NotImplementedException.class, code=ERROR_CODE_BASE-3)})
String takeScreenshot(String filename, float scale, int quality) throws NotImplementedException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:11,代碼來源:AutomatorService.java

示例6: freezeRotation

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Disables the sensors and freezes the device rotation at its current rotation state, or enable it.
 * @param freeze true to freeze the rotation, false to unfreeze the rotation.
 * @throws RemoteException
 */
@JsonRpcErrors({@JsonRpcError(exception=RemoteException.class, code=ERROR_CODE_BASE-1)})
void freezeRotation(boolean freeze) throws RemoteException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:8,代碼來源:AutomatorService.java

示例7: setOrientation

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Simulates orienting the device to the left/right/natural and also freezes rotation by disabling the sensors.
 * @param dir Left or l, Right or r, Natural or n, case insensitive
 * @throws RemoteException
 * @throws NotImplementedException
 */
@JsonRpcErrors({@JsonRpcError(exception=RemoteException.class, code=ERROR_CODE_BASE-1), @JsonRpcError(exception=NotImplementedException.class, code=ERROR_CODE_BASE-3)})
void setOrientation(String dir) throws RemoteException, NotImplementedException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:9,代碼來源:AutomatorService.java

示例8: openNotification

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Opens the notification shade.
 * @return true if successful, else return false
 * @throws NotImplementedException
 */
@JsonRpcErrors({@JsonRpcError(exception=NotImplementedException.class, code=ERROR_CODE_BASE-3)})
boolean openNotification() throws NotImplementedException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:8,代碼來源:AutomatorService.java

示例9: openQuickSettings

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Opens the Quick Settings shade.
 * @return true if successful, else return false
 * @throws NotImplementedException
 */
@JsonRpcErrors({@JsonRpcError(exception=NotImplementedException.class, code=ERROR_CODE_BASE-3)})
boolean openQuickSettings() throws NotImplementedException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:8,代碼來源:AutomatorService.java

示例10: pressKey

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Simulates a short press using key name.
 * @param key possible key name is home, back, left, right, up, down, center, menu, search, enter, delete(or del), recent(recent apps), volume_up, volume_down, volume_mute, camera, power
 * @return true if successful, else return false
 * @throws RemoteException
 */
@JsonRpcErrors({@JsonRpcError(exception=RemoteException.class, code=ERROR_CODE_BASE-1)})
boolean pressKey(String key) throws RemoteException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:9,代碼來源:AutomatorService.java

示例11: wakeUp

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * This method simulates pressing the power button if the screen is OFF else it does nothing if the screen is already ON. If the screen was OFF and it just got turned ON, this method will insert a 500ms delay to allow the device time to wake up and accept input.
 * @throws RemoteException
 */
@JsonRpcErrors({@JsonRpcError(exception=RemoteException.class, code=ERROR_CODE_BASE-1)})
void wakeUp() throws RemoteException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:7,代碼來源:AutomatorService.java

示例12: sleep

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * This method simply presses the power button if the screen is ON else it does nothing if the screen is already OFF.
 * @throws RemoteException
 */
@JsonRpcErrors({@JsonRpcError(exception=RemoteException.class, code=ERROR_CODE_BASE-1)})
void sleep() throws RemoteException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:7,代碼來源:AutomatorService.java

示例13: isScreenOn

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Checks the power manager if the screen is ON.
 * @return true if the screen is ON else false
 * @throws RemoteException
 */
@JsonRpcErrors({@JsonRpcError(exception=RemoteException.class, code=ERROR_CODE_BASE-1)})
boolean isScreenOn() throws RemoteException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:8,代碼來源:AutomatorService.java

示例14: clearTextField

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Clears the existing text contents in an editable field. The UiSelector of this object must reference a UI element that is editable. When you call this method, the method first sets focus at the start edge of the field. The method then simulates a long-press to select the existing text, and deletes the selected text. If a "Select-All" option is displayed, the method will automatically attempt to use it to ensure full text selection. Note that it is possible that not all the text in the field is selected; for example, if the text contains separators such as spaces, slashes, at symbol etc. Also, not all editable fields support the long-press functionality.
 * @param obj the selector of the UiObject.
 * @throws UiObjectNotFoundException
 */
@JsonRpcErrors({@JsonRpcError(exception=UiObjectNotFoundException.class, code=ERROR_CODE_BASE-2)})
void clearTextField(Selector obj) throws UiObjectNotFoundException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:8,代碼來源:AutomatorService.java

示例15: getText

import com.googlecode.jsonrpc4j.JsonRpcError; //導入依賴的package包/類
/**
 * Reads the text property of the UI element
 * @param obj the selector of the UiObject.
 * @return text value of the current node represented by this UiObject
 * @throws UiObjectNotFoundException
 */
@JsonRpcErrors({@JsonRpcError(exception=UiObjectNotFoundException.class, code=ERROR_CODE_BASE-2)})
String getText(Selector obj) throws UiObjectNotFoundException;
 
開發者ID:xiaocong,項目名稱:android-uiautomator-server,代碼行數:9,代碼來源:AutomatorService.java


注:本文中的com.googlecode.jsonrpc4j.JsonRpcError類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。