Skip to content

Commit

Permalink
refator package to github
Browse files Browse the repository at this point in the history
  • Loading branch information
cosyman committed Apr 21, 2015
1 parent 23ef7f8 commit 302ea00
Show file tree
Hide file tree
Showing 54 changed files with 1,064 additions and 1,064 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package org.cosysoft.device;
package com.github.cosysoft.device;

import java.util.TreeSet;

import org.cosysoft.device.android.AndroidDevice;
import com.github.cosysoft.device.android.AndroidDevice;

/**
* main class for phone resouces take and release
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.cosysoft.device.android;
package com.github.cosysoft.device.android;


public interface AndroidApp {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,116 +1,116 @@
package org.cosysoft.device.android;

import java.awt.Dimension;
import java.awt.image.BufferedImage;
import java.util.List;
import java.util.Locale;

import org.cosysoft.device.model.ClientDataInfo;
import org.cosysoft.device.model.DeviceInfo;

import com.android.ddmlib.Client;
import com.android.ddmlib.IDevice;
import com.android.ddmlib.logcat.LogCatListener;

/**
*
* @author ltyao
*
*/
public interface AndroidDevice {

/**
* test only
*
* @return
*/
IDevice getDevice();

String getSerialNumber();

Locale getLocale();

String getName();

AndroidDeviceBrand getBrand();

Dimension getScreenSize();

void tap(int x, int y);

void swipe(int x1, int y1, int x2, int y2);

BufferedImage takeScreenshot();

void takeScreenshot(String fileUrl);

boolean isDeviceReady();

boolean isScreenOn();

DeviceTargetPlatform getTargetPlatform();

String currentActivity();

void invokeActivity(String activity);

/**
* io.appium.unlock/.Unlock
*/
void unlock();

void install(AndroidApp app);

boolean isInstalled(String appBasePackage);

boolean isInstalled(AndroidApp app);

void uninstall(AndroidApp app);

void uninstall(String appBasePackage);

boolean start(AndroidApp app);

void forwardPort(int local, int remote);

void removeForwardPort(int local);

void clearUserData(AndroidApp app);

void clearUserData(String appBasePackage);

void kill(AndroidApp aut);

void kill(String appBasePackage);

String runAdbCommand(String parameter);

/**
* @see KeyEvent
* @param value
*/
void inputKeyevent(int value);

String getExternalStoragePath();

String getCrashLog();

boolean isWifiOff();

DeviceInfo getDeviceInfo();

void restartADB();

/**
*
* @param logCatListener
*/
void addLogCatListener(LogCatListener logCatListener);

void removeLogCatListener(LogCatListener logCatListener);

List<ClientDataInfo> getClientDatasInfo();

Client getClientByAppName(String appName);

}
package com.github.cosysoft.device.android;

import java.awt.Dimension;
import java.awt.image.BufferedImage;
import java.util.List;
import java.util.Locale;

import com.github.cosysoft.device.model.ClientDataInfo;
import com.github.cosysoft.device.model.DeviceInfo;

import com.android.ddmlib.Client;
import com.android.ddmlib.IDevice;
import com.android.ddmlib.logcat.LogCatListener;

/**
*
* @author ltyao
*
*/
public interface AndroidDevice {

/**
* test only
*
* @return
*/
IDevice getDevice();

String getSerialNumber();

Locale getLocale();

String getName();

AndroidDeviceBrand getBrand();

Dimension getScreenSize();

void tap(int x, int y);

void swipe(int x1, int y1, int x2, int y2);

BufferedImage takeScreenshot();

void takeScreenshot(String fileUrl);

boolean isDeviceReady();

boolean isScreenOn();

DeviceTargetPlatform getTargetPlatform();

String currentActivity();

void invokeActivity(String activity);

/**
* io.appium.unlock/.Unlock
*/
void unlock();

void install(AndroidApp app);

boolean isInstalled(String appBasePackage);

boolean isInstalled(AndroidApp app);

void uninstall(AndroidApp app);

void uninstall(String appBasePackage);

boolean start(AndroidApp app);

void forwardPort(int local, int remote);

void removeForwardPort(int local);

void clearUserData(AndroidApp app);

void clearUserData(String appBasePackage);

void kill(AndroidApp aut);

void kill(String appBasePackage);

String runAdbCommand(String parameter);

/**
* @see KeyEvent
* @param value
*/
void inputKeyevent(int value);

String getExternalStoragePath();

String getCrashLog();

boolean isWifiOff();

DeviceInfo getDeviceInfo();

void restartADB();

/**
*
* @param logCatListener
*/
void addLogCatListener(LogCatListener logCatListener);

void removeLogCatListener(LogCatListener logCatListener);

List<ClientDataInfo> getClientDatasInfo();

Client getClientByAppName(String appName);

}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.cosysoft.device.android;
package com.github.cosysoft.device.android;

import java.util.ArrayList;
import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* or implied. See the License for the specific language governing permissions and limitations under
* the License.
*/
package org.cosysoft.device.android;
package com.github.cosysoft.device.android;

public enum DeviceTargetPlatform {
ANDROID10("2.3.3"), ANDROID11("3.0"), ANDROID12("3.1"), ANDROID13("3.2"), ANDROID14(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.cosysoft.device.android;
package com.github.cosysoft.device.android;

/**
* Copy of the public static Key Codes from:
Expand Down
Loading

0 comments on commit 302ea00

Please sign in to comment.