本文整理汇总了Java中android.net.wifi.p2p.WifiP2pManager.Channel类的典型用法代码示例。如果您正苦于以下问题:Java Channel类的具体用法?Java Channel怎么用?Java Channel使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Channel类属于android.net.wifi.p2p.WifiP2pManager包,在下文中一共展示了Channel类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: deinit
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
public void deinit() {
mContext.unregisterReceiver(mNFGameBroadcastReceiver);
mWifiP2pManager.clearLocalServices(mChannel, new NFGameActionListener("clearLocalServices"));
mWifiP2pManager.clearServiceRequests(mChannel, new NFGameActionListener("clearServiceRequests"));
stopPeerDiscovery();
mWifiP2pManager.cancelConnect(mChannel, new NFGameActionListener("cancelConnect"));
mWifiP2pManager.removeGroup(mChannel, new NFGameActionListener("removeGroup"));
if (mNetId != -1) {
try {
Method deletePersistentGroup = mWifiP2pManager.getClass().getMethod("deletePersistentGroup",
Channel.class, int.class, ActionListener.class);
deletePersistentGroup.setAccessible(true);
deletePersistentGroup.invoke(mWifiP2pManager, mChannel, mNetId,
new NFGameActionListener("deletePersistentGroup"));
} catch (Exception e) {
e.printStackTrace();
}
}
}
示例2: AperiBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager
* WifiP2pManager system service
* @param channel
* WifiP2pChannel being listened on
* @param activity
* Activity associated with the receiver
*/
public AperiBroadcastReceiver(WifiP2pManager manager, Channel channel,
AperiMainActivity activity)
{
super();
if (manager == null) {
throw new IllegalArgumentException("manager is null");
} else if (channel == null) {
throw new IllegalArgumentException("channel is null");
} else if (activity == null) {
throw new IllegalArgumentException("activity is null");
} else {
mManager = manager;
mChannel = channel;
mActivity = activity;
}
}
示例3: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager WifiP2pManager system service
* @param channel Wifi p2p channel
* @param wfd wfd associated with the receiver
*/
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, Channel channel,
WiFiDirect wfd) {
super();
this.manager = manager;
this.channel = channel;
this.wfd = wfd;
connector = wfd.connector;
communicator = wfd.communicator;
}
示例4: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager WifiP2pManager system service
* @param channel Wifi p2p channel
* @param activity activity associated with the receiver
*/
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, Channel channel,
WiFiDirectBroadcastListener listener) {
super();
this.manager = manager;
this.channel = channel;
this.listener = listener;
}
示例5: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager WifiP2pManager system service
* @param channel Wifi p2p channel
* @param activity activity associated with the receiver
*/
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, Channel channel,
WiFiDirectActivity activity) {
super();
this.manager = manager;
this.channel = channel;
this.activity = activity;
}
示例6: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager WifiP2pManager system service
* @param channel Wifi p2p channel
* @param activity activity associated with the receiver
*/
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, Channel channel,
Activity activity) {
super();
this.manager = manager;
this.channel = channel;
this.activity = activity;
}
示例7: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager WifiP2pManager system service
* @param channel Wifi p2p channel
* @param activity activity associated with the receiver
*/
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, Channel channel,
WiFiDirectActivity activity) {
super();
this.manager = manager;
this.channel = channel;
this.activity = activity;
}
示例8: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* @param manager WifiP2pManager system service
* @param channel Wifi p2p channel
* @param activity activity associated with the receiver
*/
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, Channel channel,
WiFiDirectActivity activity) {
super();
this.manager = manager;
this.channel = channel;
this.activity = activity;
}
示例9: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/** Constructor */
public WiFiDirectBroadcastReceiver(WifiP2pManager manager,
Channel channel,
TransferActivity activity) {
super();
this.manager = manager;
this.channel = channel;
this.activity = activity;
}
示例10: BlaubotWifiP2PAdapter
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
public BlaubotWifiP2PAdapter(BlaubotUUIDSet uuidSet, WifiP2pManager manager, WifiManager wifiManager, Channel acceptorChannel) {
this.uuidSet = uuidSet;
this.wifiP2pManager = manager;
this.wifiManager = wifiManager;
this.acceptorWifiChannel = acceptorChannel;
this.knownDevices = new HashSet<>();
this.blaubotWifiP2PBroadcastReceiver = new BlaubotWifiP2PBroadcastReceiver(manager, acceptorChannel);
this.acceptor = new BlaubotWifiP2PAcceptor(this);
this.connector = new BlaubotWifiP2PConnector(this);
this.connectionStateMachineConfig = new ConnectionStateMachineConfig();
this.adapterConfig = new BlaubotAdapterConfig();
ConnectionStateMachineConfig.validateTimeouts(connectionStateMachineConfig, adapterConfig);
}
示例11: BlaubotWifiP2PBeacon
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
/**
* The string that we exploit to pre-filter upnp devices before we probe them if they are really a
* blaubot beacon.
* @param wifiP2pManager android's wifi p2p manager service
* @param beaconChannel the wifi p2p channel to be used for this beacon
* @param beaconPort the tcp port for this beacon to listen on
*/
public BlaubotWifiP2PBeacon(WifiP2pManager wifiP2pManager, Channel beaconChannel, int beaconPort) {
this.beaconPort = beaconPort;
this.knownActiveDevices = Collections.newSetFromMap(new ConcurrentHashMap<BlaubotWifiP2PDevice, Boolean>());
this.wifiP2pManager = wifiP2pManager;
this.wifiP2pBeaconChannel = beaconChannel;
this.wifiP2pBroadcastReceiver = new BlaubotWifiP2PBroadcastReceiver(wifiP2pManager, beaconChannel);
this.wifiP2pBroadcastReceiver.addEventListener(wifiDirectEventListener);
this.bonjourListener = new BonjourListener();
this.upnpListener = new UPNPListener();
this.wifiP2pManager.setDnsSdResponseListeners(beaconChannel, bonjourListener, bonjourListener);
this.wifiP2pManager.setUpnpServiceResponseListener(wifiP2pBeaconChannel, upnpListener);
}
示例12: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, WifiP2pManager.Channel channel, ConnectService service) {
super();
this.manager = manager;
this.channel = channel;
this.service = service;
this.infoListener = new InfoActionListener("Discovery Initiated", "Discovery Failed", service);
this.peersUpdater = new PeersListUpdater(service);
this.connInfo = new ConnectionInfo(service);
}
示例13: WiFiDirectBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
public WiFiDirectBroadcastReceiver(WifiP2pManager manager, WifiP2pManager.Channel channel, StartActivity activity) {
super();
this.manager = manager;
this.channel = channel;
this.activity = activity;
this.infoListener = new InfoActionListener("Discovery Initiated", "Discovery Failed", activity);
this.peersUpdater = new PeersListUpdater(activity);
this.connInfo = new ConnectionInfo(activity);
}
示例14: SynCarnetBroadcastReceiver
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
public SynCarnetBroadcastReceiver(WifiP2pManager manager, Channel channel, SynCarnet synCarnet, Boolean displayPeers) {
super();
this.manager = manager;
this.channel = channel;
this.synCarnet = synCarnet;
this.peerList = new PeerList(synCarnet, manager, channel, displayPeers);
this.displayPeers = displayPeers;
}
示例15: PeerList
import android.net.wifi.p2p.WifiP2pManager.Channel; //导入依赖的package包/类
public PeerList(SynCarnet synCarnet, WifiP2pManager manager, Channel channel, Boolean display) {
this.peerList = new ArrayList<WifiP2pDevice>();
this.synCarnet = synCarnet;
this.manager = manager;
this.channel = channel;
this.intent = intent;
this.peerSelection = new PeerSelection(manager, channel, synCarnet);
this.peerListDialog = new PeerListDialog(peerList, peerSelection);
this.display = display;
}