Zebra LinkOS Multiplatform SDK for Xamarin
1.1
Link-OS Portable Class Library Plugin for Xamarin
|
A class used to discover printers on an IP Network.
Note: There are no cancel discovery methods. Be carefull when using these to properly dispose of discoverer objects if navigating prior to finishing discovery.
More...
Public Member Functions | |
void | FindPrinters (IDiscoveryHandler discoveryHandler) |
This method will search the network using a combination of discovery methods to find printers on the network. This is a convenience method that can be used as an alternative to the other discovery methods (e.g. multicast) This method will invoke the DiscoveryHandler.OnFoundPrinter event for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. When DiscoveryHandler.OnDiscoveryError is invoked, the discovery will be canceled and DiscoveryHandler.OnDiscoveryFinished will not be invoked. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence. More... | |
void | FindPrinters (IDiscoveryHandler discoveryHandler, string[] printersToFind, int waitForResponsesTimeout=3000) |
Sends a discovery request to the list of printer DNS names or IPs in printersToFind. This method will invoke the DiscoveryHandler.OnFoundPrinter method for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence. More... | |
void | SubnetSearch (IDiscoveryHandler discoveryHandler, string subnetRange, int waitForResponsesTimeout=3000) |
Sends a discovery packet to the IPs specified in the subnetRange. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. Subnet searches are defined by the first three subnet octets, followed by a range, such as 192.168.2. This method accepts IP addresses of the form, assuming a subnet of 192.168.2: 192.168.2.254 (will send a discovery packet to 192.168.2.254) 192.168.2.* (will send a discovery packet for the range 192.168.2.1 - 192.168.2.254) 192.168.2.8-* (will send a discovery packet for the range 192.168.2.8 - 192.168.2.254) 192.168.2.37-42 (will send a discovery packet for the range 192.168.2.37 - 192.168.2.42) This method will invoke the DiscoveryHandler.OnFoundPrinter method for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence. More... | |
void | LocalBroadcast (IDiscoveryHandler discoveryHandler, int waitForResponsesTimeout=3000) |
Sends a local broadcast packet. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. This method will invoke the DiscoveryHandler.OnFoundPrinter event for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. When DiscoveryHandler.OnDiscoveryError is invoked, the discovery will be canceled and DiscoveryHandler.OnDiscoveryFinished will not be invoked. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence. More... | |
void | DirectedBroadcast (IDiscoveryHandler discoveryHandler, string ipAddress, int waitForResponsesTimeout=3000) |
Sends a directed broadcast discovery packet to the subnet specified by ipAddress. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. Directed broadcasts are defined by the first three subnet octets, followed by 255, such as 192.168.2.255. This method accepts IP addresses of the form, assuming a subnet of 192.168.2: 192.168.2.255 192.168.2.1 (last octet will be replaced with 255) 192.168.2 (will append 255 for the last octet) 192.168.2. (will append 255 for the last octet) This method will invoke the DiscoveryHandler.OnFoundPrinter method for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence. More... | |
void | Multicast (IDiscoveryHandler discoveryHandler, int hops, object androidContext, int waitForResponsesTimeout=3000) |
Sends a multicast discovery packet. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence. More... | |
A class used to discover printers on an IP Network.
Note: There are no cancel discovery methods. Be carefull when using these to properly dispose of discoverer objects if navigating prior to finishing discovery.
void LinkOS.Plugin.Abstractions.INetworkDiscoverer.DirectedBroadcast | ( | IDiscoveryHandler | discoveryHandler, |
string | ipAddress, | ||
int | waitForResponsesTimeout = 3000 |
||
) |
Sends a directed broadcast discovery packet to the subnet specified by ipAddress. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. Directed broadcasts are defined by the first three subnet octets, followed by 255, such as 192.168.2.255. This method accepts IP addresses of the form, assuming a subnet of 192.168.2: 192.168.2.255 192.168.2.1 (last octet will be replaced with 255) 192.168.2 (will append 255 for the last octet) 192.168.2. (will append 255 for the last octet) This method will invoke the DiscoveryHandler.OnFoundPrinter method for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence.
discoveryHandler | a DiscoveryHandler instance that is used to handle discovery events (e.g. found a printer, errors, discovery finished). |
ipAddress | the IP address of the subnet. |
waitForResponsesTimeout | time to wait, in milliseconds, before determining that there are no more discovery responses. |
Implemented in LinkOS.Plugin.NetworkDiscovererImplementation.
void LinkOS.Plugin.Abstractions.INetworkDiscoverer.FindPrinters | ( | IDiscoveryHandler | discoveryHandler | ) |
This method will search the network using a combination of discovery methods to find printers on the network. This is a convenience method that can be used as an alternative to the other discovery methods (e.g. multicast) This method will invoke the DiscoveryHandler.OnFoundPrinter event for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. When DiscoveryHandler.OnDiscoveryError is invoked, the discovery will be canceled and DiscoveryHandler.OnDiscoveryFinished will not be invoked. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence.
discoveryHandler | a DiscoveryHandler instance that is used to handle discovery events (e.g. found a printer, errors, discovery finished). |
Implemented in LinkOS.Plugin.NetworkDiscovererImplementation.
void LinkOS.Plugin.Abstractions.INetworkDiscoverer.FindPrinters | ( | IDiscoveryHandler | discoveryHandler, |
string[] | printersToFind, | ||
int | waitForResponsesTimeout = 3000 |
||
) |
Sends a discovery request to the list of printer DNS names or IPs in printersToFind. This method will invoke the DiscoveryHandler.OnFoundPrinter method for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence.
discoveryHandler | a DiscoveryHandler instance that is used to handle discovery events (e.g. found a printer, errors, discovery finished). |
printersToFind | A list of IP addresses or DNS names for the printers to be discovered. |
waitForResponsesTimeout | time to wait, in milliseconds, before determining that there are no more discovery responses. |
Implemented in LinkOS.Plugin.NetworkDiscovererImplementation.
void LinkOS.Plugin.Abstractions.INetworkDiscoverer.LocalBroadcast | ( | IDiscoveryHandler | discoveryHandler, |
int | waitForResponsesTimeout = 3000 |
||
) |
Sends a local broadcast packet. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. This method will invoke the DiscoveryHandler.OnFoundPrinter event for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. When DiscoveryHandler.OnDiscoveryError is invoked, the discovery will be canceled and DiscoveryHandler.OnDiscoveryFinished will not be invoked. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence.
discoveryHandler | a DiscoveryHandler instance that is used to handle discovery events (e.g. found a printer, errors, discovery finished). |
waitForResponsesTimeout | time to wait, in milliseconds, before determining that there are no more discovery responses. |
Implemented in LinkOS.Plugin.NetworkDiscovererImplementation.
void LinkOS.Plugin.Abstractions.INetworkDiscoverer.Multicast | ( | IDiscoveryHandler | discoveryHandler, |
int | hops, | ||
object | androidContext, | ||
int | waitForResponsesTimeout = 3000 |
||
) |
Sends a multicast discovery packet. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence.
discoveryHandler | a DiscoveryHandler instance that is used to handle discovery events (e.g. found a printer, errors, discovery finished). |
hops | number of hops. |
androidContext | the Android context, set to null in iOS |
waitForResponsesTimeout | time to wait, in milliseconds, before determining that there are no more discovery responses. |
Implemented in LinkOS.Plugin.NetworkDiscovererImplementation.
void LinkOS.Plugin.Abstractions.INetworkDiscoverer.SubnetSearch | ( | IDiscoveryHandler | discoveryHandler, |
string | subnetRange, | ||
int | waitForResponsesTimeout = 3000 |
||
) |
Sends a discovery packet to the IPs specified in the subnetRange. This method will wait up to waitForResponsesTimeout milliseconds determining that there are no more discovery responses. Subnet searches are defined by the first three subnet octets, followed by a range, such as 192.168.2. This method accepts IP addresses of the form, assuming a subnet of 192.168.2: 192.168.2.254 (will send a discovery packet to 192.168.2.254) 192.168.2.* (will send a discovery packet for the range 192.168.2.1 - 192.168.2.254) 192.168.2.8-* (will send a discovery packet for the range 192.168.2.8 - 192.168.2.254) 192.168.2.37-42 (will send a discovery packet for the range 192.168.2.37 - 192.168.2.42) This method will invoke the DiscoveryHandler.OnFoundPrinter method for each printer that is found during discovery. DiscoveryHandler.OnDiscoveryFinished will be invoked when the discovery is finished and DiscoveryHandler.OnDiscoveryError will be invoked when any errors are encountered during discovery. If a printer responds to the discovery request more than once, the DiscoveryHandler.OnFoundPrinter event will only be invoked on the first occurrence.
discoveryHandler | a DiscoveryHandler instance that is used to handle discovery events (e.g. found a printer, errors, discovery finished). |
subnetRange | the subnet search range |
waitForResponsesTimeout | time to wait, in milliseconds, before determining that there are no more discovery responses. |
Implemented in LinkOS.Plugin.NetworkDiscovererImplementation.