Skip to content

Commit

Permalink
Last part of 2.0.0 going up
Browse files Browse the repository at this point in the history
close #63
close #73
close #75
  • Loading branch information
isuPatches committed Jul 23, 2017
1 parent c41d135 commit 625ee13
Show file tree
Hide file tree
Showing 102 changed files with 2,577 additions and 984 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ android:
components:
- platform-tools
- tools
- build-tools-25.0.3
- build-tools-26.0.0
- android-22
- android-26
- sys-img-armeabi-v7a-android-22
Expand All @@ -21,4 +21,4 @@ before_script:
- android-wait-for-emulator
- adb shell input keyevent 82 &

script: travis_wait 60 ./gradlew clean connectedAndroidTest -PdisablePreDex --stacktrace
script: travis_wait 90 ./gradlew clean connectedAndroidTest -PdisablePreDex --stacktrace
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,20 @@ Wifi configuration and util library built for Android.
[![Android Weekly](https://img.shields.io/badge/Android%20Weekly-%23230-blue.svg)](http://androidweekly.net/issues/issue-230) [![Build Status](https://travis-ci.org/isuPatches/WiseFy.svg?branch=master)](https://travis-ci.org/isuPatches/WiseFy) [ ![Download](https://api.bintray.com/packages/isupatches/Maven/wisefy/images/download.svg) ](https://bintray.com/isupatches/Maven/wisefy/_latestVersion) <a href="http://www.methodscount.com/?lib=com.isupatches%3Awisefy%3A1.0.10"><img src="https://img.shields.io/badge/Methods and size-108 | 13 KB-e91e63.svg"/></a>

## What's New in 2.x

- Asynchronous API
- Certain methods have callbacks and are run on background thread
- Ability search by regex
- Nearby access points
- Saved Configurations
- SSIDs
- Ability to query for RSSI
- Ability to query for if device is roaming
- Additional methods to query for network security
- Full fledged documentation directory
- Tested against Android O

## Adding to your project

Make sure you have one of the following repositories accessible:
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ subprojects {

ext {
GROUP = "com.isupatches"
VERSION_NAME = "2.0.0-BETA1"
VERSION_NAME = "2.0.0"

BINTRAY_REPO = "Maven"
BINTRAY_NAME = "wisefy"
Expand Down
2 changes: 2 additions & 0 deletions changes/1.x.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
## v1.0.10 - 07/04/2017

## v1.0.9 - 07/03/2017

#### Undo bintray props
Expand Down
4 changes: 4 additions & 0 deletions changes/2.x.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
## v2.0.0 - 07/22/2017


## v2.0.0-BETA1 - 07/20/2017
6 changes: 3 additions & 3 deletions documentation/adding_and_removing_networks.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ mWiseFy.addOpenNetwork("Open Network", new AddOpenNetworkCallbacks() {
}

@Override
public void openNetworkAdded(WifiConfiguration wifiConfiguration) {
public void openNetworkAdded(WifiConfiguration openNetwork) {

}
});
Expand All @@ -62,7 +62,7 @@ mWiseFy.addWEPNetwork("WEP Network", "123456", new AddWEPNetworkCallbacks() {
}

@Override
public void wepNetworkAdded(WifiConfiguration wifiConfiguration) {
public void wepNetworkAdded(WifiConfiguration wepNetwork) {

}
});
Expand All @@ -83,7 +83,7 @@ mWiseFy.addWPA2Network("WPA2 Network", "12345678", new AddWPA2NetworkCallbacks()
}

@Override
public void wpa2NetworkAdded(WifiConfiguration wifiConfiguration) {
public void wpa2NetworkAdded(WifiConfiguration wpa2Network) {

}
});
Expand Down
6 changes: 6 additions & 0 deletions documentation/checking_device_connectivity.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ To check and see if the device is connected to a wifi network:
boolean isConnected = mWiseFy.isDeviceConnectedToWifiNetwork();
```

To check and see if the device is roaming:

```java
mWiseFy.isDeviceRoaming();
```

To check and see if Wifi is enabled on a device:

```java
Expand Down
67 changes: 63 additions & 4 deletions documentation/nearby_access_points.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,26 @@
#### Via The Synchronous API

To get nearby access points:<br/><br/>
<strong>Setting filterDuplicates to true will not return SSIDs with a weaker signal strength (will always take the highest)</strong>
<strong>Setting filterDuplicates to true will exclude access points for an SSID that have a weaker RSSI (will always take the highest signal strength)</strong>

```java
List<ScanResult> nearbyAccessPoints = mWiseFy.getNearbyAccessPoints(true);
```

To search for an access point given a regex (will return first match):<br/><br/>
<strong>Setting filterDuplicates to true will return the access point with the highest RSSI for the given SSID</strong>

```java
mWiseFy.searchForAccessPoint("regex for SSID", 3000, true);
```

To search for all access points matching a given regex:<br/><br/>
<strong>Setting filterDuplicates to true will exclude access points for an SSID that have a weaker RSSI (will always take the highest signal strength)</strong>

```java
mWiseFy.searchForAccessPoints("regex for SSID", true);
```

To search for an SSID given a regex (will return first match):

```java
Expand All @@ -21,8 +35,8 @@ List<String> ssids = mWiseFy.searchForSSIDs("regex for SSIDs");

#### Via The Asynchronous API

To get all nearby access points:<br/><br/>
<strong>Setting filterDuplicates to true will not return SSIDs with a weaker signal strength (will always take the highest)</strong>
To get nearby access points:<br/><br/>
<strong>Setting filterDuplicates to true will exclude access points for an SSID that have a weaker RSSI (will always take the highest signal strength)</strong>

```java
WiseFy.getNearbyAccessPoints(true, new GetNearbyAccessPointsCallbacks() {
Expand All @@ -38,6 +52,51 @@ WiseFy.getNearbyAccessPoints(true, new GetNearbyAccessPointsCallbacks() {
});
```

To search for an access point given a regex (will return first match):<br/><br/>
<strong>Setting filterDuplicates to true will return the access point with the highest RSSI (will always take the highest signal strength)</strong>

```java
mWiseFy.searchForAccessPoint("regex for SSID", 3000, true, new SearchForAccessPointCallbacks() {
@Override
public void searchForAccessPointWiseFyFailure(Integer wisefyReturnCode) {

}

@Override
public void accessPointFound(ScanResult accessPoint) {

}

@Override
public void accessPointNotFound() {

}
});
```

To search for all access points matching a given regex:<br/><br/>
<strong>Setting filterDuplicates to true will exclude access points for an SSID that have a weaker RSSI (will always take the highest signal strength)</strong>


```java
mWiseFy.searchForAccessPoints("regex for SSID", true, new SearchForAccessPointsCallbacks() {
@Override
public void searchForAccessPointsWiseFyFailure(Integer wisefyReturnCode) {

}

@Override
public void foundAccessPoints(List<ScanResult> accessPoints) {

}

@Override
public void noAccessPointsFound() {

}
});
```

To search for an SSID given a regex (will return first match):

```java
Expand All @@ -62,7 +121,7 @@ mWiseFy.searchForSSID("regex for SSID", 3000, new SearchForSSIDCallbacks() {
To search for all SSIDs matching a given regex:

```java
mWiseFy.searchForSSIDs("regex for SSIDs", new SearchForSSIDsCallbacks() {
mWiseFy.searchForSSIDs("regex for SSID", new SearchForSSIDsCallbacks() {
@Override
public void searchForSSIDsWiseFyFailure(Integer wisefyReturnCode) {

Expand Down
3 changes: 2 additions & 1 deletion documentation/rssi.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ To compare the signal strength of two networks:
int result = mWiseFy.compareSignalLevel(-35, -70);
```

To get the RSSI of the first SSID matching a given regex:
To get the RSSI of the first SSID matching a given regex:<br/><br/>
<strong>Setting takeHighest to true will return the access point with the highest RSSI for the given SSID</strong>

```java
Integer rssi = mWiseFy.getRSSI("regex for SSID", true, 3000);
Expand Down
3 changes: 3 additions & 0 deletions documentation/saved_networks.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ To get the first saved network that matches a given regex:
}
});
```

To retrieve all of the saved networks:

```java
Expand All @@ -66,6 +67,7 @@ mWiseFy.getSavedNetworks(new GetSavedNetworksCallbacks() {
}
});
```

To return all saved networks that match a given regex:

```java
Expand All @@ -86,6 +88,7 @@ mWiseFy.getSavedNetwork("regex for SSID", new GetSavedNetworkCallbacks() {
}
});
```

***Notes***

- Will return a WiseFy error code if parameter is missing
Expand Down
8 changes: 5 additions & 3 deletions javadoc/allclasses-frame.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_102) on Thu Jul 20 06:09:50 CDT 2017 -->
<title>All Classes (wisefy 2.0.0-BETA1 API)</title>
<meta name="date" content="2017-07-20">
<!-- Generated by javadoc (1.8.0_102) on Sat Jul 22 22:33:31 CDT 2017 -->
<title>All Classes (wisefy 2.0.0 API)</title>
<meta name="date" content="2017-07-22">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<script type="text/javascript" src="script.js"></script>
</head>
Expand All @@ -28,9 +28,11 @@ <h1 class="bar">All&nbsp;Classes</h1>
<li><a href="com/isupatches/wisefy/callbacks/GetRSSICallbacks.html" title="interface in com.isupatches.wisefy.callbacks" target="classFrame"><span class="interfaceName">GetRSSICallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/GetSavedNetworkCallbacks.html" title="interface in com.isupatches.wisefy.callbacks" target="classFrame"><span class="interfaceName">GetSavedNetworkCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/GetSavedNetworksCallbacks.html" title="interface in com.isupatches.wisefy.callbacks" target="classFrame"><span class="interfaceName">GetSavedNetworksCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/annotations/Internal.html" title="annotation in com.isupatches.wisefy.annotations" target="classFrame">Internal</a></li>
<li><a href="com/isupatches/wisefy/util/LogUtil.html" title="class in com.isupatches.wisefy.util" target="classFrame">LogUtil</a></li>
<li><a href="com/isupatches/wisefy/util/ManagerUtil.html" title="class in com.isupatches.wisefy.util" target="classFrame">ManagerUtil</a></li>
<li><a href="com/isupatches/wisefy/constants/NetworkTypes.html" title="class in com.isupatches.wisefy.constants" target="classFrame">NetworkTypes</a></li>
<li><a href="com/isupatches/wisefy/annotations/PublicAPI.html" title="annotation in com.isupatches.wisefy.annotations" target="classFrame">PublicAPI</a></li>
<li><a href="com/isupatches/wisefy/callbacks/RemoveNetworkCallbacks.html" title="interface in com.isupatches.wisefy.callbacks" target="classFrame"><span class="interfaceName">RemoveNetworkCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/SearchForAccessPointCallbacks.html" title="interface in com.isupatches.wisefy.callbacks" target="classFrame"><span class="interfaceName">SearchForAccessPointCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/SearchForAccessPointsCallbacks.html" title="interface in com.isupatches.wisefy.callbacks" target="classFrame"><span class="interfaceName">SearchForAccessPointsCallbacks</span></a></li>
Expand Down
8 changes: 5 additions & 3 deletions javadoc/allclasses-noframe.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_102) on Thu Jul 20 06:09:50 CDT 2017 -->
<title>All Classes (wisefy 2.0.0-BETA1 API)</title>
<meta name="date" content="2017-07-20">
<!-- Generated by javadoc (1.8.0_102) on Sat Jul 22 22:33:31 CDT 2017 -->
<title>All Classes (wisefy 2.0.0 API)</title>
<meta name="date" content="2017-07-22">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<script type="text/javascript" src="script.js"></script>
</head>
Expand All @@ -28,9 +28,11 @@ <h1 class="bar">All&nbsp;Classes</h1>
<li><a href="com/isupatches/wisefy/callbacks/GetRSSICallbacks.html" title="interface in com.isupatches.wisefy.callbacks"><span class="interfaceName">GetRSSICallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/GetSavedNetworkCallbacks.html" title="interface in com.isupatches.wisefy.callbacks"><span class="interfaceName">GetSavedNetworkCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/GetSavedNetworksCallbacks.html" title="interface in com.isupatches.wisefy.callbacks"><span class="interfaceName">GetSavedNetworksCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/annotations/Internal.html" title="annotation in com.isupatches.wisefy.annotations">Internal</a></li>
<li><a href="com/isupatches/wisefy/util/LogUtil.html" title="class in com.isupatches.wisefy.util">LogUtil</a></li>
<li><a href="com/isupatches/wisefy/util/ManagerUtil.html" title="class in com.isupatches.wisefy.util">ManagerUtil</a></li>
<li><a href="com/isupatches/wisefy/constants/NetworkTypes.html" title="class in com.isupatches.wisefy.constants">NetworkTypes</a></li>
<li><a href="com/isupatches/wisefy/annotations/PublicAPI.html" title="annotation in com.isupatches.wisefy.annotations">PublicAPI</a></li>
<li><a href="com/isupatches/wisefy/callbacks/RemoveNetworkCallbacks.html" title="interface in com.isupatches.wisefy.callbacks"><span class="interfaceName">RemoveNetworkCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/SearchForAccessPointCallbacks.html" title="interface in com.isupatches.wisefy.callbacks"><span class="interfaceName">SearchForAccessPointCallbacks</span></a></li>
<li><a href="com/isupatches/wisefy/callbacks/SearchForAccessPointsCallbacks.html" title="interface in com.isupatches.wisefy.callbacks"><span class="interfaceName">SearchForAccessPointsCallbacks</span></a></li>
Expand Down
8 changes: 4 additions & 4 deletions javadoc/com/isupatches/wisefy/WiseFy.brains.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_102) on Thu Jul 20 06:09:50 CDT 2017 -->
<title>WiseFy.brains (wisefy 2.0.0-BETA1 API)</title>
<meta name="date" content="2017-07-20">
<!-- Generated by javadoc (1.8.0_102) on Sat Jul 22 22:33:31 CDT 2017 -->
<title>WiseFy.brains (wisefy 2.0.0 API)</title>
<meta name="date" content="2017-07-22">
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="WiseFy.brains (wisefy 2.0.0-BETA1 API)";
parent.document.title="WiseFy.brains (wisefy 2.0.0 API)";
}
}
catch(err) {
Expand Down
Loading

0 comments on commit 625ee13

Please sign in to comment.