public void setKey(@NonNull final byte[] key) {
        if (valid(key)) {
            this.key = key;
        }
    }
Sets a network key.

<p>
In order to change the key call {@link BaseMeshNetwork#updateNetKey(NetworkKey, String)}  or {@link BaseMeshNetwork#updateAppKey(ApplicationKey, String)})}}
</p>

@param key 16-byte network key
mesh/src/main/java/no/nordicsemi/android/mesh/MeshKey.java