NDefWifi
com.rvi.domain.NDefWifi · Record · SocialCard 1.0.3
An open or WPA2-Personal network stored as a Wi-Fi credential record.
When to use it
Section titled “When to use it”Use OPEN with NONE and an empty or null password, or WPA2_PERSONAL with AES and an 8–63 character printable ASCII passphrase or a 64-digit hex key. The SSID must occupy 1–32 UTF-8 bytes.
Java example
Section titled “Java example”final NDefWifi guest = new NDefWifi( "Guest", WifiAuthentication.OPEN, WifiEncryption.NONE, null);final NDefMessage message = new NDefMessageCreator().add(guest).build();
System.out.println(new NDefDecoder().decode(message));Java imports
import com.rvi.application.NDefDecoder;import com.rvi.application.creator.NDefMessageCreator;import com.rvi.domain.NDefMessage;import com.rvi.domain.NDefWifi;import com.rvi.domain.WifiAuthentication;import com.rvi.domain.WifiEncryption;Open guest networks avoid embedding a reusable passphrase in a publicly readable tag.
How it works
Section titled “How it works”The value encodes into one Wi-Fi Simple Configuration credential. toString() redacts the password, but password() and the tag payload still carry it. Use a network intended for sharing and check whether the target device handles these records.
Related API
Section titled “Related API”WifiAuthentication · WifiEncryption · NDefWifiCreator · NDefDecoder