public class WebsocketServerConnectorEditView
extends FrameLayout
Constructor and Description |
---|
WebsocketServerConnectorEditView(Context context,
AttributeSet attrs) |
WebsocketServerConnectorEditView(Context context,
AttributeSet attrs,
int defStyle) |
Modifier and Type | Method and Description |
---|---|
static Dialog |
createAsDialog(Context context,
Blaubot blaubot,
java.lang.String presetHostname,
int presetPort,
java.lang.String presetPath,
java.lang.String presetServerUniqueDeviceId)
Creates this view as a dialog that allows the user to create a server connector which is then
attached to the given blaubot instance.
|
BlaubotServerConnector |
createConnector(IBlaubotDevice ownDevice)
Tries to construct the server connector from the view's inputs.
|
public WebsocketServerConnectorEditView(Context context, AttributeSet attrs)
public WebsocketServerConnectorEditView(Context context, AttributeSet attrs, int defStyle)
public BlaubotServerConnector createConnector(IBlaubotDevice ownDevice) throws java.lang.IllegalArgumentException, java.lang.ClassNotFoundException
ownDevice
- the own device of the connecting blaubot instancejava.lang.IllegalArgumentException
- if the user input was not validjava.lang.ClassNotFoundException
- if the blaubot-websocket jar is not in the classpathpublic static Dialog createAsDialog(Context context, Blaubot blaubot, java.lang.String presetHostname, int presetPort, java.lang.String presetPath, java.lang.String presetServerUniqueDeviceId)
context
- the contextblaubot
- the blaubot instance to create the connector forpresetHostname
- the hostname with which the form is initially filledpresetPort
- the port with which the form is initially filledpresetPath
- the path with which the form is initially filledpresetServerUniqueDeviceId
- the server's unique device id with which the form is initially filled