Interface RestSBDevice

  • All Known Implementing Classes:
    DefaultRestSBDevice

    public interface RestSBDevice
    Represents an abstraction of a Rest Device in ONOS.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      RestSBDevice.AuthenticationScheme authentication()
      The authentication scheme of rest device.
      org.onosproject.net.DeviceId deviceId()
      Returns the ONOS deviceID for this device.
      java.util.Optional<java.lang.String> hwVersion()
      The hardware version of the rest device.
      org.onlab.packet.IpAddress ip()
      Returns the ip of this device.
      boolean isActive()
      Returns the state of this device.
      boolean isProxy()
      Returns the proxy state of this device (if true, the device is proxying multiple ONOS devices).
      java.util.Optional<java.lang.String> manufacturer()
      The manufacturer of the rest device.
      java.lang.String password()
      Returns the password of this device.
      int port()
      Returns the port of this device.
      java.lang.String protocol()
      Returns the protocol for the REST request, usually HTTP o HTTPS.
      void setActive​(boolean active)
      Sets or unsets the state of the device.
      java.util.Optional<java.lang.String> swVersion()
      The software version of rest device.
      java.util.Optional<java.lang.String> testUrl()
      Returns the url for the REST TEST requests.
      java.lang.String token()
      The access token of rest device if authentication is OAuth2.
      java.lang.String url()
      Returns the url for the REST requests, to be used instead of IP and PORT.
      java.lang.String username()
      Returns the username of this device.
    • Method Detail

      • ip

        org.onlab.packet.IpAddress ip()
        Returns the ip of this device.
        Returns:
        ip
      • port

        int port()
        Returns the port of this device.
        Returns:
        port
      • token

        java.lang.String token()
        The access token of rest device if authentication is OAuth2.
        Returns:
        token
      • username

        java.lang.String username()
        Returns the username of this device.
        Returns:
        username
      • password

        java.lang.String password()
        Returns the password of this device.
        Returns:
        password
      • deviceId

        org.onosproject.net.DeviceId deviceId()
        Returns the ONOS deviceID for this device.
        Returns:
        DeviceId
      • setActive

        void setActive​(boolean active)
        Sets or unsets the state of the device.
        Parameters:
        active - boolean
      • isActive

        boolean isActive()
        Returns the state of this device.
        Returns:
        state
      • protocol

        java.lang.String protocol()
        Returns the protocol for the REST request, usually HTTP o HTTPS.
        Returns:
        protocol
      • url

        java.lang.String url()
        Returns the url for the REST requests, to be used instead of IP and PORT.
        Returns:
        url
      • isProxy

        boolean isProxy()
        Returns the proxy state of this device (if true, the device is proxying multiple ONOS devices).
        Returns:
        proxy state
      • testUrl

        java.util.Optional<java.lang.String> testUrl()
        Returns the url for the REST TEST requests.
        Returns:
        testUrl
      • manufacturer

        java.util.Optional<java.lang.String> manufacturer()
        The manufacturer of the rest device.
        Returns:
        the name of the manufacturer
      • hwVersion

        java.util.Optional<java.lang.String> hwVersion()
        The hardware version of the rest device.
        Returns:
        the hardware version
      • swVersion

        java.util.Optional<java.lang.String> swVersion()
        The software version of rest device.
        Returns:
        the software version.