A Wifi configuration and util library built in Kotlin for Android.
Developed by Patches 04/24/2016 - present
Logo/icon created by mansya (2018)Supports Android SDK levels 23-34
For the 5.x versions of Wisefy, a new Bill of Materials (BOM for short) has been implemented. This is similar to the Compose or Firebase BOMs where the platform is used but then it is possible to pick and choose the sub-dependencies to pull in.
Adding the Wisefy BOM would look something like:
implementation(platform(libs.isupatches.wisefy.bom))
if using Gradle version catalogs, or:
implementation(platofrm("com.isupatches.android.wisefy:wisefy-bom:5.0.0-RC3"))
if used directly. Once the platform is installed, it is possible to import just the portions of the library desired.
implementation(libs.isupatches.wisefy.accesspoints)
implementation(libs.isupatches.wisefy.addnetwork)
implementation(libs.isupatches.wisefy.core)
implementation(libs.isupatches.wisefy.ktx)
implementation(libs.isupatches.wisefy.networkconnection)
implementation(libs.isupatches.wisefy.networkinfo)
implementation(libs.isupatches.wisefy.removenetwork)
implementation(libs.isupatches.wisefy.savednetworks)
implementation(libs.isupatches.wisefy.signal)
implementation(libs.isupatches.wisefy.wifi)
implementation(libs.isupatches.wisefy.wisefy)
Here are the descriptions of what functionality each artifact provides:
:accesspoints
For getting and searching for nearby networks:addnetwork
For adding a Wifi network:core
For base Wisefy functionality:networkconnection
For connecting and disconnecting from networks:networkinfo
For information about the device's current network and current connectivity status:removenetwork
For removing a Wifi network:savednetworks
For getting and searching for saved networks:signal
For calculating a signal level and comparing signal levels:wifi
For enabling and disabling WifiThe 5.0 version of WiseFy works to rectify the problems that caused it to be overly challenging as a single developer to keep up with the ever-changing Wifi APIs for new Android operating systems, especially with a lot of functionality becoming privatized. It also strives to simplify the API and removes redundancy within the APIs that caused additional overhead for maintenance.
I hope you enjoy the rewrite and please create an issue if you see anything odd or have questions!
wisefysample
renamed to app
gradle.lockfile
s and Gradle ranges are enabled for more control over versioning
Types of classes:
Query
- Indicates a read only operation where nothing is modified or writtenRequest
- Indicates an action where some state is modified or a value is writtenResult
- Indicates the return from an action or queryData
- Indicates a complex return for a result that includes several different properties, fields, and functionsTypes of property values:
value
- A field within a Result
object for a Data
class (a Wisefy based class)rawValue
- A field for a OS level class or object (not a Wisefy based class) within a Data
objectSuffixes:
Package structure for each section is as follows:
Supporting sub-directories can include
fun connectToNetwork(request: ConnectToNetworkRequest): ConnectToNetworkResult
fun connectToNetwork(request: ConnectToNetworkRequest, callbacks: ConnectToNetworkCallbacks?)
fun disconnectFromCurrentNetwork(request: DisconnectFromCurrentNetworkRequest): DisconnectFromCurrentNetworkResult
fun disconnectFromCurrentNetwork(request: DisconnectFromCurrentNetworkRequest, callbacks: DisconnectFromCurrentNetworkCallbacks?)
To keep the documentation clean and because of the amount of architectural changes for the 5.x release, the documentation was stripped and then completely re-written.
For auto-generated Dokka markdown files based on the KDocs please see here.
For more high-level examples based on different functionality please see here.
You may find a list of frequently asked questions here.
Want to help? Have an idea for a cool feature or want to fix a bug for the community? See CONTRIBUTING for how you can make impactful changes for Wisefy.
Copyright 2022 Patches Barrett
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.